diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2012-11-14 15:21:42 +0100 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2012-11-14 15:21:42 +0100 |
commit | 25a33416e9597087e16483859ecbdd6cdac2df64 (patch) | |
tree | fe42619afa77f2fa81f212ab0cf45cd66ae1ca4e | |
parent | 05eb0a5052c5d679269ef33cfe07bd4394833a63 (diff) | |
download | rsyslog-25a33416e9597087e16483859ecbdd6cdac2df64.tar.gz rsyslog-25a33416e9597087e16483859ecbdd6cdac2df64.tar.bz2 rsyslog-25a33416e9597087e16483859ecbdd6cdac2df64.zip |
bugfix: garbled message if field name was used with jsonf property option
The length for the field name was invalidly computed, resulting in either
truncated field names or including extra random data. If the random data
contained NULs, the rest of the message became unreadable.
closes: http://bugzilla.adiscon.com/show_bug.cgi?id=374
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | template.c | 2 |
2 files changed, 7 insertions, 2 deletions
@@ -20,7 +20,7 @@ Version 7.2.2 [v7-stable] 2012-10-?? This could happen in RainerScript comparisons (like contains); in some cases an unitialized variable was accessed, which could lead to an invalid free and in turn to a segfault. - Closes: http://bugzilla.adiscon.com/show_bug.cgi?id=372 + closes: http://bugzilla.adiscon.com/show_bug.cgi?id=372 Thanks to Georgi Georgiev for reporting this bug and his great help in solving it. - bugfix: no error msg on unreadable $IncludeConfig path @@ -31,6 +31,11 @@ Version 7.2.2 [v7-stable] 2012-10-?? - bugfix: make rsyslog compile on kfreebsd again closes: http://bugzilla.adiscon.com/show_bug.cgi?id=380 Thanks to Guillem Jover for the patch. +- bugfix: garbled message if field name was used with jsonf property option + The length for the field name was invalidly computed, resulting in either + truncated field names or including extra random data. If the random data + contained NULs, the rest of the message became unreadable. + closes: http://bugzilla.adiscon.com/show_bug.cgi?id=374 ---------------------------------------------------------------------------- Version 7.2.1 [v7-stable] 2012-10-29 - bugfix: ruleset()-object did only support a single statement @@ -1096,7 +1096,7 @@ static int do_Parameter(unsigned char **pp, struct template *pTpl) } } else { pTpe->fieldName = ustrdup(cstrGetSzStrNoNULL(pStrField)); - pTpe->lenFieldName = cstrLen(pStrProp); + pTpe->lenFieldName = ustrlen(pTpe->fieldName); cstrDestruct(&pStrField); } if(pTpe->fieldName == NULL) |