remove NUL character from recieved messages
This commit is contained in:
parent
f0d26583c1
commit
f580f886e8
22
rsyslog-1.19.6-dropNul.patch
Normal file
22
rsyslog-1.19.6-dropNul.patch
Normal file
@ -0,0 +1,22 @@
|
||||
--- syslogd.c.dropNul 2007-10-03 17:38:07.000000000 +0200
|
||||
+++ syslogd.c 2007-10-03 17:43:23.000000000 +0200
|
||||
@@ -2023,13 +2023,18 @@ void printchopped(char *hname, char *msg
|
||||
|
||||
dbgprintf("Message length: %d, File descriptor: %d.\n", len, fd);
|
||||
|
||||
+ if(*(msg + len - 1) == '\0') {
|
||||
+ dbgprintf("dropped NUL at very end of message\n");
|
||||
+ len--;
|
||||
+ }
|
||||
+
|
||||
/* we first check if we need to drop trailing LFs, which often make
|
||||
* their way into syslog messages unintentionally. In order to remain
|
||||
* compatible to recent IETF developments, we allow the user to
|
||||
* turn on/off this handling. rgerhards, 2007-07-23
|
||||
*/
|
||||
if(bDropTrailingLF && *(msg + len - 1) == '\n') {
|
||||
- *(msg + len - 1) = '\0';
|
||||
+ dbgprintf("dropped LF at very end of message (DropTrailingLF is set)\n");
|
||||
len--;
|
||||
}
|
||||
|
@ -3,7 +3,7 @@
|
||||
Summary: Enhanced system logging and kernel message trapping daemons
|
||||
Name: rsyslog
|
||||
Version: 1.19.6
|
||||
Release: 2%{?dist}
|
||||
Release: 3%{?dist}
|
||||
License: GPLv2+
|
||||
Group: System Environment/Daemons
|
||||
URL: http://www.rsyslog.com/
|
||||
@ -11,6 +11,7 @@ Source0: http://download.adiscon.com/rsyslog/%{name}-%{version}.tar.gz
|
||||
Source1: rsyslog.init
|
||||
Source2: rsyslog.sysconfig
|
||||
Patch1: rsyslog-1.19.6-repmsg.patch
|
||||
Patch2: rsyslog-1.19.6-dropNul.patch
|
||||
Conflicts: logrotate < 3.5.2
|
||||
BuildRequires: zlib-devel
|
||||
BuildRequires: autoconf automake
|
||||
@ -47,6 +48,7 @@ MySQL database support to rsyslog.
|
||||
%prep
|
||||
%setup -q
|
||||
%patch1 -p1 -b .repmsg
|
||||
%patch2 -p0 -b .dropnul
|
||||
|
||||
%build
|
||||
%configure --sbindir=%{sbindir} --disable-static
|
||||
@ -119,6 +121,9 @@ fi
|
||||
%{_libdir}/rsyslog/ommysql.so
|
||||
|
||||
%changelog
|
||||
* Wed Oct 03 2007 Peter Vrabec <pvrabec@redhat.com> 1.19.6-3
|
||||
- remove NUL character from recieved messages
|
||||
|
||||
* Tue Sep 25 2007 Tomas Heinrich <theinric@redhat.com> 1.19.6-2
|
||||
- fix message suppression (303341)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user