diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..de3df7d --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +SOURCES/rsyslog-8.24.0.tar.gz +SOURCES/rsyslog-doc-8.24.0.tar.gz diff --git a/.rsyslog.metadata b/.rsyslog.metadata new file mode 100644 index 0000000..289264b --- /dev/null +++ b/.rsyslog.metadata @@ -0,0 +1,2 @@ +615ee5b47ca4c3a28de3c8ee4477c721c20f31aa SOURCES/rsyslog-8.24.0.tar.gz +c0bbe5466738ac97575e0301cf26f0ec45d77b20 SOURCES/rsyslog-doc-8.24.0.tar.gz diff --git a/README.md b/README.md deleted file mode 100644 index 0e7897f..0000000 --- a/README.md +++ /dev/null @@ -1,5 +0,0 @@ -The master branch has no content - -Look at the c7 branch if you are working with CentOS-7, or the c4/c5/c6 branch for CentOS-4, 5 or 6 - -If you find this file in a distro specific branch, it means that no content has been checked in yet diff --git a/SOURCES/rsyslog-8.24.0-doc-polling-by-default.patch b/SOURCES/rsyslog-8.24.0-doc-polling-by-default.patch new file mode 100644 index 0000000..d7848c5 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-doc-polling-by-default.patch @@ -0,0 +1,18 @@ +--- a/source/configuration/modules/imfile.rst 2017-10-31 10:28:39.582763203 +0100 ++++ b/source/configuration/modules/imfile.rst 2017-10-31 10:29:52.961142905 +0100 +@@ -100,12 +100,13 @@ + single: imfile; mode + .. function:: mode ["inotify"/"polling"] + +- *Default: "inotify"* ++ *Default: "polling"* + + *Available since: 8.1.5* + + This specifies if imfile is shall run in inotify ("inotify") or polling +- ("polling") mode. Traditionally, imfile used polling mode, which is ++ ("polling") mode. Traditionally, imfile used polling mode (and this option ++ is ON by default in RHEL because of backwards compatibility), which is + much more resource-intense (and slower) than inotify mode. It is + suggested that users turn on "polling" mode only if they experience + strange problems in inotify mode. In theory, there should never be a diff --git a/SOURCES/rsyslog-8.24.0-msg_c_nonoverwrite_merge.patch b/SOURCES/rsyslog-8.24.0-msg_c_nonoverwrite_merge.patch new file mode 100644 index 0000000..1ca26ff --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-msg_c_nonoverwrite_merge.patch @@ -0,0 +1,65 @@ +From fa7d98b0cb0512d84355e3aafdc5a3e366842f2a Mon Sep 17 00:00:00 2001 +From: Radovan Sroka +Date: Mon, 21 Nov 2016 13:38:18 +0100 +Subject: [PATCH 2/4] Rebased from: Patch2: + rsyslog-7.2.1-msg_c_nonoverwrite_merge.patch + +Resolves: + no adressed bugzila +--- + runtime/msg.c | 25 +++++++++++++++++++++++-- + 1 file changed, 23 insertions(+), 2 deletions(-) + +diff --git a/runtime/msg.c b/runtime/msg.c +index f6e017b..5430331 100644 +--- a/runtime/msg.c ++++ b/runtime/msg.c +@@ -4632,6 +4632,27 @@ finalize_it: + RETiRet; + } + ++static rsRetVal jsonMerge(struct json_object *existing, struct json_object *json); ++ ++static rsRetVal ++jsonMergeNonOverwrite(struct json_object *existing, struct json_object *json) ++{ ++ DEFiRet; ++ ++ struct json_object_iterator it = json_object_iter_begin(existing); ++ struct json_object_iterator itEnd = json_object_iter_end(existing); ++ while (!json_object_iter_equal(&it, &itEnd)) { ++ json_object_object_add(json, json_object_iter_peek_name(&it), ++ json_object_get(json_object_iter_peek_value(&it))); ++ json_object_iter_next(&it); ++ } ++ ++ CHKiRet(jsonMerge(existing, json)); ++finalize_it: ++ RETiRet; ++} ++ ++ + static rsRetVal + jsonMerge(struct json_object *existing, struct json_object *json) + { +@@ -4714,7 +4735,7 @@ msgAddJSON(msg_t * const pM, uchar *name, struct json_object *json, int force_re + if(*pjroot == NULL) + *pjroot = json; + else +- CHKiRet(jsonMerge(*pjroot, json)); ++ CHKiRet(jsonMergeNonOverwrite(*pjroot, json)); + } else { + if(*pjroot == NULL) { + /* now we need a root obj */ +@@ -4742,7 +4763,7 @@ msgAddJSON(msg_t * const pM, uchar *name, struct json_object *json, int force_re + json_object_object_add(parent, (char*)leaf, json); + } else { + if(json_object_get_type(json) == json_type_object) { +- CHKiRet(jsonMerge(*pjroot, json)); ++ CHKiRet(jsonMergeNonOverwrite(*pjroot, json)); + } else { + /* TODO: improve the code below, however, the current + * state is not really bad */ +-- +2.7.4 + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1056548-getaddrinfo.patch b/SOURCES/rsyslog-8.24.0-rhbz1056548-getaddrinfo.patch new file mode 100644 index 0000000..82012cd --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1056548-getaddrinfo.patch @@ -0,0 +1,56 @@ +diff --git a/runtime/net.c b/runtime/net.c +index 3610fc5..2d8de94 100644 +--- a/runtime/net.c ++++ b/runtime/net.c +@@ -1181,26 +1181,24 @@ getLocalHostname(uchar **ppName) + } + + char *dot = strstr(hnbuf, "."); ++ struct addrinfo *res = NULL; + if(!empty_hostname && dot == NULL) { + /* we need to (try) to find the real name via resolver */ +- struct hostent *hent = gethostbyname((char*)hnbuf); +- if(hent) { +- int i = 0; +- if(hent->h_aliases) { +- const size_t hnlen = strlen(hnbuf); +- for(i = 0; hent->h_aliases[i]; i++) { +- if(!strncmp(hent->h_aliases[i], hnbuf, hnlen) +- && hent->h_aliases[i][hnlen] == '.') { +- break; /* match! */ +- } +- } +- } +- if(hent->h_aliases && hent->h_aliases[i]) { +- CHKmalloc(fqdn = (uchar*)strdup(hent->h_aliases[i])); +- } else { +- CHKmalloc(fqdn = (uchar*)strdup(hent->h_name)); ++ struct addrinfo flags; ++ memset(&flags, 0, sizeof(flags)); ++ flags.ai_flags = AI_CANONNAME; ++ int error = getaddrinfo((char*)hnbuf, NULL, &flags, &res); ++ if (error != 0) { ++ dbgprintf("getaddrinfo: %s\n", gai_strerror(error)); ++ ABORT_FINALIZE(RS_RET_IO_ERROR); ++ } ++ if (res != NULL) { ++ /* When AI_CANONNAME is set first member of res linked-list */ ++ /* should contain what we need */ ++ if (res->ai_canonname != NULL && res->ai_canonname[0] != '\0') { ++ CHKmalloc(fqdn = (uchar*)strdup(res->ai_canonname)); ++ dot = strstr((char*)fqdn, "."); + } +- dot = strstr((char*)fqdn, "."); + } + } + +@@ -1215,6 +1213,9 @@ getLocalHostname(uchar **ppName) + + *ppName = fqdn; + finalize_it: ++ if (res != NULL) { ++ freeaddrinfo(res); ++ } + RETiRet; + } + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1088021-systemd-time-backwards.patch b/SOURCES/rsyslog-8.24.0-rhbz1088021-systemd-time-backwards.patch new file mode 100644 index 0000000..2800f03 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1088021-systemd-time-backwards.patch @@ -0,0 +1,28 @@ +diff -up ./plugins/imjournal/imjournal.c.time ./plugins/imjournal/imjournal.c +--- ./plugins/imjournal/imjournal.c.time 2016-12-21 17:50:13.849000000 +0100 ++++ ./plugins/imjournal/imjournal.c 2016-12-21 18:20:03.908000000 +0100 +@@ -538,7 +538,24 @@ loadJournalState(void) + "couldn't seek to cursor `%s'\n", readCursor); + iRet = RS_RET_ERR; + } else { ++ char * tmp_cursor = NULL; + sd_journal_next(j); ++ /* ++ * This is resolving the situation when system is after reboot and boot_id doesn't match ++ * so cursor pointing into "future". Usually sd_journal_next jump to head of journal due to journal aproximation, ++ * but when system time goes backwards and cursor is still invalid, rsyslog stops logging. We use ++ * sd_journal_get_cursor to validate our cursor. When cursor is invalid we are trying to jump to the head of journal ++ * This problem with time is not affecting persistent journal. ++ * */ ++ if (sd_journal_get_cursor(j, &tmp_cursor) < 0 && sd_journal_has_persistent_files(j) == 0) { ++ errmsg.LogError(0, RS_RET_IO_ERROR, "imjournal: " ++ "loaded invalid cursor, seeking to the head of journal\n"); ++ if (sd_journal_seek_head(j) < 0) { ++ errmsg.LogError(0, RS_RET_ERR, "imjournal: " ++ "sd_journal_seek_head() failed, when cursor is invalid\n"); ++ iRet = RS_RET_ERR; ++ } ++ } + } + } else { + errmsg.LogError(0, RS_RET_IO_ERROR, "imjournal: " diff --git a/SOURCES/rsyslog-8.24.0-rhbz1165236-snmp-mib.patch b/SOURCES/rsyslog-8.24.0-rhbz1165236-snmp-mib.patch new file mode 100644 index 0000000..efdae89 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1165236-snmp-mib.patch @@ -0,0 +1,20 @@ +@@ -, +, @@ +--- + plugins/omsnmp/omsnmp.c | 6 ++++++ + 1 file changed, 6 insertions(+) +--- a/plugins/omsnmp/omsnmp.c ++++ a/plugins/omsnmp/omsnmp.c +@@ -454,6 +454,12 @@ CODESTARTnewActInst + } + } + ++ /* Init NetSNMP library and read in MIB database */ ++ init_snmp("rsyslog"); ++ ++ /* Set some defaults in the NetSNMP library */ ++ netsnmp_ds_set_int(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_DEFAULT_PORT, pData->iPort ); ++ + CHKiRet(OMSRsetEntry(*ppOMSR, 0, (uchar*)strdup((pData->tplName == NULL) ? + "RSYSLOG_FileFormat" : (char*)pData->tplName), + OMSR_NO_RQD_TPL_OPTS)); +-- diff --git a/SOURCES/rsyslog-8.24.0-rhbz1196230-ratelimit-add-source.patch b/SOURCES/rsyslog-8.24.0-rhbz1196230-ratelimit-add-source.patch new file mode 100644 index 0000000..b1d140c --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1196230-ratelimit-add-source.patch @@ -0,0 +1,52 @@ +From f4958b548776e8b9c9c5ef211116eb503aff8e5b Mon Sep 17 00:00:00 2001 +From: Jiri Vymazal +Date: Tue, 18 Apr 2017 16:42:22 +0200 +Subject: [PATCH] Putting process name into ratelimiter with imuxsock + +--- + plugins/imuxsock/imuxsock.c | 25 ++++++++++++++++++++----- + 1 file changed, 20 insertions(+), 5 deletions(-) + +diff --git a/plugins/imuxsock/imuxsock.c b/plugins/imuxsock/imuxsock.c +index 277c30e..1a57f6e 100644 +--- a/plugins/imuxsock/imuxsock.c ++++ b/plugins/imuxsock/imuxsock.c +@@ -594,7 +594,7 @@ findRatelimiter(lstn_t *pLstn, struct ucred *cred, ratelimit_t **prl) + ratelimit_t *rl = NULL; + int r; + pid_t *keybuf; +- char pidbuf[256]; ++ char pinfobuf[512]; + DEFiRet; + + if(cred == NULL) +@@ -616,10 +616,25 @@ findRatelimiter(lstn_t *pLstn, struct ucred *cred, ratelimit_t **prl) + DBGPRINTF("imuxsock: no ratelimiter for pid %lu, creating one\n", + (unsigned long) cred->pid); + STATSCOUNTER_INC(ctrNumRatelimiters, mutCtrNumRatelimiters); +- snprintf(pidbuf, sizeof(pidbuf), "pid %lu", +- (unsigned long) cred->pid); +- pidbuf[sizeof(pidbuf)-1] = '\0'; /* to be on safe side */ +- CHKiRet(ratelimitNew(&rl, "imuxsock", pidbuf)); ++ /* read process name from system */ ++ char procName[256]; /* enough for any sane process name */ ++ snprintf(procName, sizeof(procName), "/proc/%lu/cmdline", (unsigned long) cred->pid); ++ FILE *f = fopen(procName, "r"); ++ if (f) { ++ size_t len; ++ len = fread(procName, sizeof(char), 256, f); ++ if (len > 0) { ++ snprintf(pinfobuf, sizeof(pinfobuf), "pid: %lu, name: %s", ++ (unsigned long) cred->pid, procName); ++ } ++ fclose(f); ++ } ++ else { ++ snprintf(pinfobuf, sizeof(pinfobuf), "pid: %lu", ++ (unsigned long) cred->pid); ++ } ++ pinfobuf[sizeof(pinfobuf)-1] = '\0'; /* to be on safe side */ ++ CHKiRet(ratelimitNew(&rl, "imuxsock", pinfobuf)); + ratelimitSetLinuxLike(rl, pLstn->ratelimitInterval, pLstn->ratelimitBurst); + ratelimitSetSeverity(rl, pLstn->ratelimitSev); + CHKmalloc(keybuf = malloc(sizeof(pid_t))); diff --git a/SOURCES/rsyslog-8.24.0-rhbz1245194-imjournal-ste-file.patch b/SOURCES/rsyslog-8.24.0-rhbz1245194-imjournal-ste-file.patch new file mode 100644 index 0000000..cd8b910 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1245194-imjournal-ste-file.patch @@ -0,0 +1,24 @@ +From: Jiri Vymazal +Date: Fri, 13 Jan 2017 13:38:53 -0500 +Subject: [PATCH 1/1] Rebased from: Patch33: + rsyslog-7.4.7-rhbz1245194-imjournal-ste-file.patch + +Resolves: +rhbz#1245194 +--- + plugins/imjournal/imjournal.c | 2 ++ + 1 file changed, 2 insertions(+), 0 deletions(-) + +diff --git a/plugins/imjournal/imjournal.c b/plugins/imjournal/imjournal.c +index d4ea0d5..9d40e04 100644 +--- a/plugins/imjournal/imjournal.c ++++ b/plugins/imjournal/imjournal.c +@@ -793,6 +793,8 @@ + NULL, &cs.stateFile, STD_LOADABLE_MODULE_ID)); + CHKiRet(omsdRegCFSLineHdlr((uchar *)"imjournalignorepreviousmessages", 0, eCmdHdlrBinary, + NULL, &cs.bIgnorePrevious, STD_LOADABLE_MODULE_ID)); ++ CHKiRet(omsdRegCFSLineHdlr((uchar *)"imjournalignorenonvalidstatefile", 0, eCmdHdlrBinary, ++ NULL, &cs.bIgnoreNonValidStatefile, STD_LOADABLE_MODULE_ID)); + CHKiRet(omsdRegCFSLineHdlr((uchar *)"imjournaldefaultseverity", 0, eCmdHdlrSeverity, + NULL, &cs.iDfltSeverity, STD_LOADABLE_MODULE_ID)); + CHKiRet(omsdRegCFSLineHdlr((uchar *)"imjournaldefaultfacility", 0, eCmdHdlrCustomHandler, diff --git a/SOURCES/rsyslog-8.24.0-rhbz1303617-imfile-wildcards.patch b/SOURCES/rsyslog-8.24.0-rhbz1303617-imfile-wildcards.patch new file mode 100644 index 0000000..be1f0ce --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1303617-imfile-wildcards.patch @@ -0,0 +1,30 @@ +From 75dc28c1cb4d3988608352f83f7dc420c17d7c64 Mon Sep 17 00:00:00 2001 +From: Tomas Sykora +Date: Thu, 24 Nov 2016 10:27:48 -0500 +Subject: [PATCH 2/4] Rebased from: + rsyslog-7.4.7-rhbz1303617-imfile-wildcards.patch + +Resolves: +rhbz#1303617 + +-this patch was already upstreamed, we just have different default option (polling) than upstream +--- + plugins/imfile/imfile.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/plugins/imfile/imfile.c b/plugins/imfile/imfile.c +index 519768c..09a321e 100644 +--- a/plugins/imfile/imfile.c ++++ b/plugins/imfile/imfile.c +@@ -1121,7 +1121,7 @@ BEGINsetModCnf + struct cnfparamvals *pvals = NULL; + int i; + CODESTARTsetModCnf +- loadModConf->opMode = OPMODE_INOTIFY; /* new style config has different default! */ ++ loadModConf->opMode = OPMODE_POLLING; /* Difference from upstream, upstream has default option INOTIFY */ + pvals = nvlstGetParams(lst, &modpblk, NULL); + if(pvals == NULL) { + errmsg.LogError(0, RS_RET_MISSING_CNFPARAMS, "imfile: error processing module " +-- +2.7.4 + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1399569-flushontxend.patch b/SOURCES/rsyslog-8.24.0-rhbz1399569-flushontxend.patch new file mode 100644 index 0000000..abe61bc --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1399569-flushontxend.patch @@ -0,0 +1,36 @@ +From 1a80a71e91f445f29763fbd724a1c6f3fbf2077a Mon Sep 17 00:00:00 2001 +From: Tomas Sykora +Date: Fri, 23 Dec 2016 06:49:22 -0500 +Subject: [PATCH 1/3] When flushOnTXEnd is off messages should be written to a + file only when the buffer is full. This was broken with upstream commit + 6de0103, which was reverted with this patch. + +Resolves: RHBZ#1399569 +--- + tools/omfile.c | 9 ++------- + 1 file changed, 2 insertions(+), 7 deletions(-) + +diff --git a/tools/omfile.c b/tools/omfile.c +index 77bf65c..4d849c5 100644 +--- a/tools/omfile.c ++++ b/tools/omfile.c +@@ -1046,14 +1046,9 @@ CODESTARTcommitTransaction + writeFile(pData, pParams, i); + } + /* Note: pStrm may be NULL if there was an error opening the stream */ +- if(pData->bUseAsyncWriter) { +- if(pData->bFlushOnTXEnd && pData->pStrm != NULL) { ++ if(pData->bFlushOnTXEnd && pData->pStrm != NULL) { ++ if(!pData->bUseAsyncWriter) + CHKiRet(strm.Flush(pData->pStrm)); +- } +- } else { +- if(pData->pStrm != NULL) { +- CHKiRet(strm.Flush(pData->pStrm)); +- } + } + + finalize_it: +-- +2.9.3 + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1400594-tls-config.patch b/SOURCES/rsyslog-8.24.0-rhbz1400594-tls-config.patch new file mode 100644 index 0000000..5011000 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1400594-tls-config.patch @@ -0,0 +1,29 @@ +From 83ea7bc475cc722033082e51416947842810d1fc Mon Sep 17 00:00:00 2001 +From: Tomas Sykora +Date: Fri, 23 Dec 2016 06:51:52 -0500 +Subject: [PATCH 2/3] In rsyslog v7 because of bug mix of old and new syntax + had to be used to configure tls server-client. In rsyslog v8 this bug was + fixed but the mixed configuration didn't worked anymore which was a + regresion. With this patch, mixed configuration workes again. + +Resolves: RHBZ#1400594 +--- + tools/omfwd.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/tools/omfwd.c b/tools/omfwd.c +index 45fcfd6..c1d3e64 100644 +--- a/tools/omfwd.c ++++ b/tools/omfwd.c +@@ -925,6 +925,8 @@ initTCP(wrkrInstanceData_t *pWrkrData) + CHKiRet(tcpclt.SetSendPrepRetry(pWrkrData->pTCPClt, TCPSendPrepRetry)); + CHKiRet(tcpclt.SetFraming(pWrkrData->pTCPClt, pData->tcp_framing)); + CHKiRet(tcpclt.SetRebindInterval(pWrkrData->pTCPClt, pData->iRebindInterval)); ++ if (cs.iStrmDrvrMode) ++ pData->iStrmDrvrMode = cs.iStrmDrvrMode; + } + finalize_it: + RETiRet; +-- +2.9.3 + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1401456-sd-service-network.patch b/SOURCES/rsyslog-8.24.0-rhbz1401456-sd-service-network.patch new file mode 100644 index 0000000..f3cbf26 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1401456-sd-service-network.patch @@ -0,0 +1,12 @@ +diff -up ./rsyslog.service.in.network ./rsyslog.service.in +--- ./rsyslog.service.in.network 2017-08-30 09:19:50.845218557 -0400 ++++ ./rsyslog.service.in 2017-08-30 09:21:34.141218557 -0400 +@@ -1,6 +1,8 @@ + [Unit] + Description=System Logging Service + Requires=syslog.socket ++Wants=network.target network-online.target ++After=network.target network-online.target + Documentation=man:rsyslogd(8) + Documentation=http://www.rsyslog.com/doc/ + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1401870-watermark.patch b/SOURCES/rsyslog-8.24.0-rhbz1401870-watermark.patch new file mode 100644 index 0000000..7d931e5 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1401870-watermark.patch @@ -0,0 +1,31 @@ +From f1cff52cc3bca3ed050f5e8e2c25698bebcf3258 Mon Sep 17 00:00:00 2001 +From: Tomas Sykora +Date: Fri, 23 Dec 2016 06:56:41 -0500 +Subject: [PATCH 3/3] When highwatermark is reached, messages should be + imediately written to a queue file. Instead of that, messages weren't written + until rsyslog was stopped. This was caused by overwritting watermark values + by -1. + +Resolves: RHBZ#1401870 +--- + action.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/action.c b/action.c +index 45828cc..3f8c82c 100644 +--- a/action.c ++++ b/action.c +@@ -276,8 +276,8 @@ actionResetQueueParams(void) + cs.ActionQueType = QUEUETYPE_DIRECT; /* type of the main message queue above */ + cs.iActionQueueSize = 1000; /* size of the main message queue above */ + cs.iActionQueueDeqBatchSize = 16; /* default batch size */ +- cs.iActionQHighWtrMark = -1; /* high water mark for disk-assisted queues */ +- cs.iActionQLowWtrMark = -1; /* low water mark for disk-assisted queues */ ++ cs.iActionQHighWtrMark = 800; /* high water mark for disk-assisted queues */ ++ cs.iActionQLowWtrMark = 200; /* low water mark for disk-assisted queues */ + cs.iActionQDiscardMark = 980; /* begin to discard messages */ + cs.iActionQDiscardSeverity = 8; /* discard warning and above */ + cs.iActionQueueNumWorkers = 1; /* number of worker threads for the mm queue above */ +-- +2.9.3 + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1403831-missing-cmd-line-switches.patch b/SOURCES/rsyslog-8.24.0-rhbz1403831-missing-cmd-line-switches.patch new file mode 100644 index 0000000..74ec4e9 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1403831-missing-cmd-line-switches.patch @@ -0,0 +1,123 @@ +From e62f3e1a46a6599a6b8dc22e9df0ebefe00b7d08 Mon Sep 17 00:00:00 2001 +From: jvymazal +Date: Fri, 13 Jan 2017 12:06:04 +0100 +Subject: [PATCH] added obsolete command-line switches for backward + comaptibility (#1) + +* added obsolete command-line switches for backward comaptibility + +* removed the added warnings since we are not obsoleting any cmd-line opts + +Resolves: RHBZ#1403831 +--- + tools/rsyslogd.c | 49 +++++++++++++++++++------------------------------ + 1 file changed, 19 insertions(+), 30 deletions(-) + +diff --git a/tools/rsyslogd.c b/tools/rsyslogd.c +index b53eeaf..5e3cde2 100644 +--- a/tools/rsyslogd.c ++++ b/tools/rsyslogd.c +@@ -1191,6 +1191,15 @@ initAll(int argc, char **argv) + case 'w': /* disable disallowed host warnings */ + case 'C': + case 'x': /* disable dns for remote messages */ ++ case 'a': /* obsolete switches from here below for backwards compatibility */ ++ case 'c': ++ case 'g': ++ case 'h': ++ case 'm': ++ case 'o': ++ case 'p': ++ case 'r': ++ case 't': + CHKiRet(bufOptAdd(ch, optarg)); + break; + #if defined(_AIX) +@@ -1249,27 +1258,15 @@ initAll(int argc, char **argv) + DBGPRINTF("deque option %c, optarg '%s'\n", ch, (arg == NULL) ? "" : arg); + switch((char)ch) { + case '4': +- fprintf (stderr, "rsyslogd: the -4 command line option will go away " +- "soon.\nPlease use the global(net.ipprotocol=\"ipv4-only\") " +- "configuration parameter instead.\n"); + glbl.SetDefPFFamily(PF_INET); + break; + case '6': +- fprintf (stderr, "rsyslogd: the -6 command line option will go away " +- "soon.\nPlease use the global(net.ipprotocol=\"ipv6-only\") " +- "configuration parameter instead.\n"); + glbl.SetDefPFFamily(PF_INET6); + break; + case 'A': +- fprintf (stderr, "rsyslogd: the -A command line option will go away " +- "soon.\n" +- "Please use the omfwd parameter \"upd.sendToAll\" instead.\n"); + send_to_all++; + break; + case 'S': /* Source IP for local client to be used on multihomed host */ +- fprintf (stderr, "rsyslogd: the -S command line option will go away " +- "soon.\n" +- "Please use the omrelp parameter \"localClientIP\" instead.\n"); + if(glbl.GetSourceIPofLocalClient() != NULL) { + fprintf (stderr, "rsyslogd: Only one -S argument allowed, the first one is taken.\n"); + } else { +@@ -1283,9 +1280,6 @@ initAll(int argc, char **argv) + PidFile = arg; + break; + case 'l': +- fprintf (stderr, "rsyslogd: the -l command line option will go away " +- "soon.\n Make yourself heard on the rsyslog mailing " +- "list if you need it any longer.\n"); + if(glbl.GetLocalHosts() != NULL) { + fprintf (stderr, "rsyslogd: Only one -l argument allowed, the first one is taken.\n"); + } else { +@@ -1299,21 +1293,12 @@ initAll(int argc, char **argv) + iConfigVerify = (arg == NULL) ? 0 : atoi(arg); + break; + case 'q': /* add hostname if DNS resolving has failed */ +- fprintf (stderr, "rsyslogd: the -q command line option will go away " +- "soon.\nPlease use the global(net.aclAddHostnameOnFail=\"on\") " +- "configuration parameter instead.\n"); + *(net.pACLAddHostnameOnFail) = 1; + break; + case 'Q': /* dont resolve hostnames in ACL to IPs */ +- fprintf (stderr, "rsyslogd: the -Q command line option will go away " +- "soon.\nPlease use the global(net.aclResolveHostname=\"off\") " +- "configuration parameter instead.\n"); + *(net.pACLDontResolve) = 1; + break; + case 's': +- fprintf (stderr, "rsyslogd: the -s command line option will go away " +- "soon.\n Make yourself heard on the rsyslog mailing " +- "list if you need it any longer.\n"); + if(glbl.GetStripDomains() != NULL) { + fprintf (stderr, "rsyslogd: Only one -s argument allowed, the first one is taken.\n"); + } else { +@@ -1353,17 +1338,21 @@ initAll(int argc, char **argv) + bChDirRoot = 0; + break; + case 'w': /* disable disallowed host warnigs */ +- fprintf (stderr, "rsyslogd: the -w command line option will go away " +- "soon.\nPlease use the global(net.permitWarning=\"off\") " +- "configuration parameter instead.\n"); + glbl.SetOption_DisallowWarning(0); + break; + case 'x': /* disable dns for remote messages */ +- fprintf (stderr, "rsyslogd: the -x command line option will go away " +- "soon.\nPlease use the global(net.enableDNS=\"off\") " +- "configuration parameter instead.\n"); + glbl.SetDisableDNS(1); + break; ++ case 'a': ++ case 'c': ++ case 'g': ++ case 'h': ++ case 'm': ++ case 'o': ++ case 'p': ++ case 'r': ++ case 't': ++ break; + case '?': + default: + rsyslogd_usage(); diff --git a/SOURCES/rsyslog-8.24.0-rhbz1403907-imudp-deprecated-parameter.patch b/SOURCES/rsyslog-8.24.0-rhbz1403907-imudp-deprecated-parameter.patch new file mode 100644 index 0000000..dbb8685 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1403907-imudp-deprecated-parameter.patch @@ -0,0 +1,30 @@ +From: Jiri Vymazal +Date: Fri, 03 Feb 2017 15:12:42 -0500 +Subject: [PATCH 1/1] rsyslog-8.24.0-rhbz1403907-imudp-deprecated-parameter.patch + +Resolves: +rhbz#1403907 +--- + plugins/imudp/imudp.c | 4 ---- + 1 file changed, 4 deletions(-) + +--- a/plugins/imudp/imudp.c 2017-01-10 10:00:04.000000000 +0100 ++++ b/plugins/imudp/imudp.c 2017-02-03 14:46:59.075987660 +0100 +@@ -920,8 +920,6 @@ + inst->bAppendPortToInpname = (int) pvals[i].val.d.n; + bAppendPortUsed = 1; + } else if(!strcmp(inppblk.descr[i].name, "inputname")) { +- errmsg.LogError(0, RS_RET_DEPRECATED , "imudp: deprecated parameter inputname " +- "used. Suggest to use name instead"); + if(inst->inputname != NULL) { + errmsg.LogError(0, RS_RET_INVALID_PARAMS, "imudp: name and inputname " + "parameter specified - only one can be used"); +@@ -929,8 +927,6 @@ + } + inst->inputname = (uchar*)es_str2cstr(pvals[i].val.d.estr, NULL); + } else if(!strcmp(inppblk.descr[i].name, "inputname.appendport")) { +- errmsg.LogError(0, RS_RET_DEPRECATED , "imudp: deprecated parameter inputname.appendport " +- "used. Suggest to use name.appendport instead"); + if(bAppendPortUsed) { + errmsg.LogError(0, RS_RET_INVALID_PARAMS, "imudp: name.appendport and " + "inputname.appendport parameter specified - only one can be used"); diff --git a/SOURCES/rsyslog-8.24.0-rhbz1419228-journal-switch-persistent.patch b/SOURCES/rsyslog-8.24.0-rhbz1419228-journal-switch-persistent.patch new file mode 100644 index 0000000..bd1d320 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1419228-journal-switch-persistent.patch @@ -0,0 +1,116 @@ +diff -up ./plugins/imjournal/imjournal.c.journal ./plugins/imjournal/imjournal.c +--- ./plugins/imjournal/imjournal.c.journal 2017-03-13 14:38:11.820000000 +0100 ++++ ./plugins/imjournal/imjournal.c 2017-03-13 14:45:16.006000000 +0100 +@@ -115,6 +115,25 @@ static const char *pid_field_name; /* re + static ratelimit_t *ratelimiter = NULL; + static sd_journal *j; + ++static rsRetVal persistJournalState(void); ++static rsRetVal loadJournalState(void); ++ ++static rsRetVal openJournal(sd_journal** jj) { ++ DEFiRet; ++ ++ if (sd_journal_open(jj, SD_JOURNAL_LOCAL_ONLY) < 0) ++ iRet = RS_RET_IO_ERROR; ++ RETiRet; ++} ++ ++static void closeJournal(sd_journal** jj) { ++ ++ if (cs.stateFile) { /* can't persist without a state file */ ++ persistJournalState(); ++ } ++ sd_journal_close(*jj); ++} ++ + + /* ugly workaround to handle facility numbers; values + * derived from names need to be eight times smaller, +@@ -436,20 +455,25 @@ persistJournalState (void) + } + + ++static rsRetVal skipOldMessages(void); + /* Polls the journal for new messages. Similar to sd_journal_wait() + * except for the special handling of EINTR. + */ ++ ++#define POLL_TIMEOUT 1000 /* timeout for poll is 1s */ ++ + static rsRetVal + pollJournal(void) + { + DEFiRet; + struct pollfd pollfd; +- int r; ++ int pr = 0; ++ int jr = 0; + + pollfd.fd = sd_journal_get_fd(j); + pollfd.events = sd_journal_get_events(j); +- r = poll(&pollfd, 1, -1); +- if (r == -1) { ++ pr = poll(&pollfd, 1, POLL_TIMEOUT); ++ if (pr == -1) { + if (errno == EINTR) { + /* EINTR is also received during termination + * so return now to check the term state. +@@ -465,12 +489,30 @@ pollJournal(void) + } + } + +- assert(r == 1); + +- r = sd_journal_process(j); +- if (r < 0) { +- char errStr[256]; ++ jr = sd_journal_process(j); ++ ++ if (pr == 1 && jr == SD_JOURNAL_INVALIDATE) { ++ /* do not persist stateFile sd_journal_get_cursor will fail! */ ++ char* tmp = cs.stateFile; ++ cs.stateFile = NULL; ++ closeJournal(&j); ++ cs.stateFile = tmp; ++ ++ iRet = openJournal(&j); ++ if (iRet != RS_RET_OK) { ++ char errStr[256]; ++ rs_strerror_r(errno, errStr, sizeof(errStr)); ++ errmsg.LogError(0, RS_RET_IO_ERROR, ++ "sd_journal_open() failed: '%s'", errStr); ++ ABORT_FINALIZE(RS_RET_ERR); ++ } + ++ iRet = loadJournalState(); ++ errmsg.LogError(0, RS_RET_OK, "imjournal: " ++ "journal reloaded..."); ++ } else if (jr < 0) { ++ char errStr[256]; + rs_strerror_r(errno, errStr, sizeof(errStr)); + errmsg.LogError(0, RS_RET_ERR, + "sd_journal_process() failed: '%s'", errStr); +@@ -694,20 +736,13 @@ ENDfreeCnf + /* open journal */ + BEGINwillRun + CODESTARTwillRun +- int ret; +- ret = sd_journal_open(&j, SD_JOURNAL_LOCAL_ONLY); +- if (ret < 0) { +- iRet = RS_RET_IO_ERROR; +- } ++ iRet = openJournal(&j); + ENDwillRun + + /* close journal */ + BEGINafterRun + CODESTARTafterRun +- if (cs.stateFile) { /* can't persist without a state file */ +- persistJournalState(); +- } +- sd_journal_close(j); ++ closeJournal(&j); + ratelimitDestruct(ratelimiter); + ENDafterRun + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1422414-glbDoneLoadCnf-segfault.patch b/SOURCES/rsyslog-8.24.0-rhbz1422414-glbDoneLoadCnf-segfault.patch new file mode 100644 index 0000000..bfb171f --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1422414-glbDoneLoadCnf-segfault.patch @@ -0,0 +1,84 @@ +From d649d77cd585f70c6122d7e4ce95e82ad0e9af5e Mon Sep 17 00:00:00 2001 +From: Radovan Sroka +Date: Thu, 23 Feb 2017 15:05:27 +0100 +Subject: [PATCH] Fixed segfault in glblDoneLoadCnf() + +This is caused by uninitialized net static structure in glbl objUse(net) +is not called after start of glbl module. + +It looks like it is not possible to use objUse(net) when glbl module +starts. So we call it inside of glblDoneLoadCnf(). +--- + runtime/glbl.c | 6 ++++-- + runtime/glbl.h | 2 +- + runtime/rsconf.c | 6 +++--- + 3 files changed, 8 insertions(+), 6 deletions(-) + +diff --git a/runtime/glbl.c b/runtime/glbl.c +index 2079c46..1a32c2d 100644 +--- a/runtime/glbl.c ++++ b/runtime/glbl.c +@@ -1076,11 +1076,13 @@ do_setenv(const char *const var) + /* This processes the "regular" parameters which are to be set after the + * config has been fully loaded. + */ +-void ++rsRetVal + glblDoneLoadCnf(void) + { + int i; + unsigned char *cstr; ++ DEFiRet; ++ CHKiRet(objUse(net, CORE_COMPONENT)); + + qsort(tzinfos, ntzinfos, sizeof(tzinfo_t), qs_arrcmp_tzinfo); + DBGPRINTF("Timezone information table (%d entries):\n", ntzinfos); +@@ -1210,7 +1212,7 @@ glblDoneLoadCnf(void) + stddbg = -1; + } + +-finalize_it: return; ++finalize_it: RETiRet; + } + + +diff --git a/runtime/glbl.h b/runtime/glbl.h +index 6d18a2c..048c0a6 100644 +--- a/runtime/glbl.h ++++ b/runtime/glbl.h +@@ -125,7 +125,7 @@ void glblProcessCnf(struct cnfobj *o); + void glblProcessTimezone(struct cnfobj *o); + void glblProcessMainQCnf(struct cnfobj *o); + void glblDestructMainqCnfObj(void); +-void glblDoneLoadCnf(void); ++rsRetVal glblDoneLoadCnf(void); + const uchar * glblGetWorkDirRaw(void); + tzinfo_t* glblFindTimezoneInfo(char *id); + int GetGnuTLSLoglevel(void); +diff --git a/runtime/rsconf.c b/runtime/rsconf.c +index dc6bd7f..f337e1f 100644 +--- a/runtime/rsconf.c ++++ b/runtime/rsconf.c +@@ -627,11 +627,11 @@ dropPrivileges(rsconf_t *cnf) + /* tell the rsysog core (including ourselfs) that the config load is done and + * we need to prepare to move over to activate mode. + */ +-static inline void ++static inline rsRetVal + tellCoreConfigLoadDone(void) + { + DBGPRINTF("telling rsyslog core that config load for %p is done\n", loadConf); +- glblDoneLoadCnf(); ++ return glblDoneLoadCnf(); + } + + +@@ -1345,7 +1345,7 @@ ourConf = loadConf; // TODO: remove, once ourConf is gone! + DBGPRINTF("Number of actions in this configuration: %d\n", iActionNbr); + rulesetOptimizeAll(loadConf); + +- tellCoreConfigLoadDone(); ++ CHKiRet(tellCoreConfigLoadDone()); + tellModulesConfigLoadDone(); + + tellModulesCheckConfig(); diff --git a/SOURCES/rsyslog-8.24.0-rhbz1422789-missing-chdir-w-chroot.patch b/SOURCES/rsyslog-8.24.0-rhbz1422789-missing-chdir-w-chroot.patch new file mode 100644 index 0000000..e67e13f --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1422789-missing-chdir-w-chroot.patch @@ -0,0 +1,15 @@ +diff --git a/tools/rsyslogd.c b/tools/rsyslogd.c +index c099705..12b037f 100644 +--- a/tools/rsyslogd.c ++++ b/tools/rsyslogd.c +@@ -1350,6 +1350,10 @@ initAll(int argc, char **argv) + perror("chroot"); + exit(1); + } ++ if(chdir("/") != 0) { ++ perror("chdir"); ++ exit(1); ++ } + break; + case 'u': /* misc user settings */ + iHelperUOpt = (arg == NULL) ? 0 : atoi(arg); diff --git a/SOURCES/rsyslog-8.24.0-rhbz1427821-backport-num2ipv4.patch b/SOURCES/rsyslog-8.24.0-rhbz1427821-backport-num2ipv4.patch new file mode 100644 index 0000000..2822fa0 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1427821-backport-num2ipv4.patch @@ -0,0 +1,243 @@ +From d6f180ec175f3660e36478b9e32ec6ca73e33604 Mon Sep 17 00:00:00 2001 +From: Jan Gerhards +Date: Fri, 10 Feb 2017 14:30:01 +0100 +Subject: [PATCH] add num2ipv4 function and test + +closes https://github.com/rsyslog/rsyslog/issues/1322 + +testbench: add testcase empty string for num2ipv4 function + +see https://github.com/rsyslog/rsyslog/issues/1412 +--- + grammar/rainerscript.c | 115 ++++++++++++++++++++++++++++++++++++++++++++++ + grammar/rainerscript.h | 4 +- + tests/Makefile.am | 2 + + tests/rscript_num2ipv4.sh | 41 +++++++++++++++++ + 4 files changed, 161 insertions(+), 1 deletion(-) + create mode 100755 tests/rscript_num2ipv4.sh + +diff --git a/grammar/rainerscript.c b/grammar/rainerscript.c +index 30af5e7b..2f0fc2d8 100644 +--- a/grammar/rainerscript.c ++++ b/grammar/rainerscript.c +@@ -1710,6 +1710,113 @@ doRandomGen(struct svar *__restrict__ const sourceVal) { + return x % max; + } + ++static long long ++ipv42num(char *str) ++{ ++ unsigned num[4] = {0, 0, 0, 0}; ++ long long value = -1; ++ size_t len = strlen(str); ++ int cyc = 0; ++ int prevdot = 0; ++ int startblank = 0; ++ int endblank = 0; ++ DBGPRINTF("rainerscript: (ipv42num) arg: '%s'\n", str); ++ for(unsigned int i = 0 ; i < len ; i++) { ++ switch(str[i]){ ++ case '0': ++ case '1': ++ case '2': ++ case '3': ++ case '4': ++ case '5': ++ case '6': ++ case '7': ++ case '8': ++ case '9': ++ if(endblank == 1){ ++ DBGPRINTF("rainerscript: (ipv42num) error: wrong IP-Address format (invalid space(1))\n"); ++ goto done; ++ } ++ prevdot = 0; ++ startblank = 0; ++ DBGPRINTF("rainerscript: (ipv42num) cycle: %d\n", cyc); ++ num[cyc] = num[cyc]*10+(str[i]-'0'); ++ break; ++ case ' ': ++ prevdot = 0; ++ if(i == 0 || startblank == 1){ ++ startblank = 1; ++ break; ++ } ++ else{ ++ endblank = 1; ++ break; ++ } ++ case '.': ++ if(endblank == 1){ ++ DBGPRINTF("rainerscript: (ipv42num) error: wrong IP-Address format (inalid space(2))\n"); ++ goto done; ++ } ++ startblank = 0; ++ if(prevdot == 1){ ++ DBGPRINTF("rainerscript: (ipv42num) error: wrong IP-Address format (two dots after one another)\n"); ++ goto done; ++ } ++ prevdot = 1; ++ cyc++; ++ if(cyc > 3){ ++ DBGPRINTF("rainerscript: (ipv42num) error: wrong IP-Address format (too many dots)\n"); ++ goto done; ++ } ++ break; ++ default: ++ DBGPRINTF("rainerscript: (ipv42num) error: wrong IP-Address format (invalid charakter)\n"); ++ goto done; ++ } ++ } ++ if(cyc != 3){ ++ DBGPRINTF("rainerscript: (ipv42num) error: wrong IP-Address format (wrong number of dots)\n"); ++ goto done; ++ } ++ value = num[0]*256*256*256+num[1]*256*256+num[2]*256+num[3]; ++done: ++ DBGPRINTF("rainerscript: (ipv42num): return value:'%lld'\n",value); ++ return(value); ++} ++ ++ ++static es_str_t* ++num2ipv4(struct svar *__restrict__ const sourceVal) { ++ int success = 0; ++ int numip[4]; ++ char str[16]; ++ size_t len; ++ es_str_t *estr; ++ long long num = var2Number(sourceVal, &success); ++ DBGPRINTF("rainrescript: (num2ipv4) var2Number output: '%lld\n'", num); ++ if (! success) { ++ DBGPRINTF("rainerscript: (num2ipv4) couldn't access number\n"); ++ len = snprintf(str, 16, "-1"); ++ goto done; ++ } ++ if(num < 0 || num > 4294967295) { ++ DBGPRINTF("rainerscript: (num2ipv4) invalid number(too big/negative); does not represent IPv4 address\n"); ++ len = snprintf(str, 16, "-1"); ++ goto done; ++ } ++ for(int i = 0 ; i < 4 ; i++){ ++ numip[i] = num % 256; ++ num = num / 256; ++ } ++ DBGPRINTF("rainerscript: (num2ipv4) Numbers: 1:'%d' 2:'%d' 3:'%d' 4:'%d'\n", numip[0], numip[1], numip[2], numip[3]); ++ len = snprintf(str, 16, "%d.%d.%d.%d", numip[3], numip[2], numip[1], numip[0]); ++done: ++ DBGPRINTF("rainerscript: (num2ipv4) ipv4-Address: %s, lengh: %zu\n", str, len); ++ estr = es_newStrFromCStr(str, len); ++ return(estr); ++} ++ ++ + /* Perform a function call. This has been moved out of cnfExprEval in order + * to keep the code small and easier to maintain. + */ +@@ -1775,6 +1882,12 @@ doFuncCall(struct cnffunc *__restrict__ const func, struct svar *__restrict__ co + ret->datatype = 'N'; + varFreeMembers(&r[0]); + break; ++ case CNFFUNC_NUM2IPV4: ++ cnfexprEval(func->expr[0], &r[0], usrptr); ++ ret->d.estr = num2ipv4(&r[0]); ++ ret->datatype = 'S'; ++ varFreeMembers(&r[0]); ++ break; + case CNFFUNC_GETENV: + /* note: the optimizer shall have replaced calls to getenv() + * with a constant argument to a single string (once obtained via +@@ -3958,6 +4071,8 @@ funcName2ID(es_str_t *fname, unsigned short nParams) + GENERATE_FUNC("strlen", 1, CNFFUNC_STRLEN); + } else if(FUNC_NAME("getenv")) { + GENERATE_FUNC("getenv", 1, CNFFUNC_GETENV); ++ } else if(FUNC_NAME("num2ipv4")) { ++ GENERATE_FUNC("num2ipv4", 1, CNFFUNC_NUM2IPV4); + } else if(FUNC_NAME("tolower")) { + GENERATE_FUNC("tolower", 1, CNFFUNC_TOLOWER); + } else if(FUNC_NAME("cstr")) { +diff --git a/grammar/rainerscript.h b/grammar/rainerscript.h +index 7bac7566..0fdbdc72 100644 +--- a/grammar/rainerscript.h ++++ b/grammar/rainerscript.h +@@ -232,7 +232,9 @@ enum cnffuncid { + CNFFUNC_REPLACE, + CNFFUNC_WRAP, + CNFFUNC_RANDOM, +- CNFFUNC_DYN_INC ++ CNFFUNC_DYN_INC, ++ CNFFUNC_IPV42NUM, ++ CNFFUNC_NUM2IPV4 + }; + + struct cnffunc { +diff --git a/tests/Makefile.am b/tests/Makefile.am +index f792b44a..572c6250 100644 +--- a/tests/Makefile.am ++++ b/tests/Makefile.am +@@ -206,6 +206,7 @@ TESTS += \ + rscript_lt_var.sh \ + rscript_ne.sh \ + rscript_ne_var.sh \ ++ rscript_num2ipv4.sh \ + empty-prop-comparison.sh \ + rs_optimizer_pri.sh \ + cee_simple.sh \ +@@ -728,6 +729,7 @@ EXTRA_DIST= \ + rscript_ne.sh \ + testsuites/rscript_ne.conf \ + rscript_ne_var.sh \ ++ rscript_num2ipv4.sh \ + testsuites/rscript_ne_var.conf \ + rscript_eq.sh \ + testsuites/rscript_eq.conf \ +diff --git a/tests/rscript_num2ipv4.sh b/tests/rscript_num2ipv4.sh +new file mode 100755 +index 00000000..6e0026a9 +--- /dev/null ++++ b/tests/rscript_num2ipv4.sh +@@ -0,0 +1,41 @@ ++#!/bin/bash ++# add 2017-02-09 by Jan Gerhards, released under ASL 2.0 ++. $srcdir/diag.sh init ++. $srcdir/diag.sh generate-conf ++. $srcdir/diag.sh add-conf ' ++module(load="../plugins/imtcp/.libs/imtcp") ++input(type="imtcp" port="13514") ++ ++set $!ip!v1 = num2ipv4("0"); ++set $!ip!v2 = num2ipv4("1"); ++set $!ip!v3 = num2ipv4("256"); ++set $!ip!v4 = num2ipv4("65536"); ++set $!ip!v5 = num2ipv4("16777216"); ++set $!ip!v6 = num2ipv4("135"); ++set $!ip!v7 = num2ipv4("16843009"); ++set $!ip!v8 = num2ipv4("3777036554"); ++set $!ip!v9 = num2ipv4("2885681153"); ++set $!ip!v10 = num2ipv4("4294967295"); ++ ++set $!ip!e1 = num2ipv4("a"); ++set $!ip!e2 = num2ipv4("-123"); ++set $!ip!e3 = num2ipv4("1725464567890"); ++set $!ip!e4 = num2ipv4("4294967296"); ++set $!ip!e5 = num2ipv4("2839."); ++set $!ip!e6 = num2ipv4(""); ++ ++ ++template(name="outfmt" type="string" string="%!ip%\n") ++local4.* action(type="omfile" file="rsyslog.out.log" template="outfmt") ++' ++. $srcdir/diag.sh startup ++. $srcdir/diag.sh tcpflood -m1 -y ++. $srcdir/diag.sh shutdown-when-empty ++. $srcdir/diag.sh wait-shutdown ++echo '{ "v1": "0.0.0.0", "v2": "0.0.0.1", "v3": "0.0.1.0", "v4": "0.1.0.0", "v5": "1.0.0.0", "v6": "0.0.0.135", "v7": "1.1.1.1", "v8": "225.33.1.10", "v9": "172.0.0.1", "v10": "255.255.255.255", "e1": "-1", "e2": "-1", "e3": "-1", "e4": "-1", "e5": "-1", "e6": "-1" }' | cmp rsyslog.out.log ++if [ ! $? -eq 0 ]; then ++ echo "invalid function output detected, rsyslog.out.log is:" ++ cat rsyslog.out.log ++ . $srcdir/diag.sh error-exit 1 ++fi; ++. $srcdir/diag.sh exit +-- +2.12.2 + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1427821-str2num-emty-string-handle.patch b/SOURCES/rsyslog-8.24.0-rhbz1427821-str2num-emty-string-handle.patch new file mode 100644 index 0000000..ab35376 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1427821-str2num-emty-string-handle.patch @@ -0,0 +1,28 @@ +@@ -, +, @@ +--- + grammar/rainerscript.c | 8 ++++++++ + 1 file changed, 8 insertions(+) +--- a/grammar/rainerscript.c ++++ a/grammar/rainerscript.c +@@ -1276,6 +1276,13 @@ str2num(es_str_t *s, int *bSuccess) + int64_t num = 0; + const uchar *const c = es_getBufAddr(s); + ++ if(s->lenStr == 0) { ++ DBGPRINTF("rainerscript: str2num: strlen == 0; invalid input (no string)\n"); ++ if(bSuccess != NULL) { ++ *bSuccess = 1; ++ } ++ goto done; ++ } + if(c[0] == '-') { + neg = -1; + i = -1; +@@ -1290,6 +1297,7 @@ str2num(es_str_t *s, int *bSuccess) + num *= neg; + if(bSuccess != NULL) + *bSuccess = (i == s->lenStr) ? 1 : 0; ++done: + return num; + } + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1427828-set-unset-not-checking-varName.patch b/SOURCES/rsyslog-8.24.0-rhbz1427828-set-unset-not-checking-varName.patch new file mode 100644 index 0000000..8d89d2b --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1427828-set-unset-not-checking-varName.patch @@ -0,0 +1,90 @@ +From e2767839bc23f1a2f70543efabfe0ca1be166ee9 Mon Sep 17 00:00:00 2001 +From: Rainer Gerhards +Date: Tue, 24 Jan 2017 13:24:29 +0100 +Subject: [PATCH] rainescript: set/unset statement do not check variable name + validity + +Only JSON-based variables can be use with set and unset. Unfortunately, +this restriction is not checked. If an invalid variable is given +(e.g. $invalid), this is not detected upon config processing on +startup. During execution phase, this can lead to a segfault, a +memory leak or other types of problems. + +see also https://github.com/rsyslog/rsyslog/issues/1376 +closes https://github.com/rsyslog/rsyslog/issues/1377 +--- + grammar/rainerscript.c | 43 +++++++++++++++++++++++++++++++++++++++---- + 1 file changed, 39 insertions(+), 4 deletions(-) + +diff --git a/grammar/rainerscript.c b/grammar/rainerscript.c +index 0ebd6f1..2106ef9 100644 +--- a/grammar/rainerscript.c ++++ b/grammar/rainerscript.c +@@ -3062,6 +3062,19 @@ cnfstmtNew(unsigned s_type) + return cnfstmt; + } + ++/* This function disables a cnfstmt by setting it to NOP. This is ++ * useful when we detect errors late in the parsing processing, where ++ * we need to return a valid cnfstmt. The optimizer later removes the ++ * NOPs, so all is well. ++ * NOTE: this call assumes that no dynamic data structures have been ++ * allocated. If so, these MUST be freed before calling cnfstmtDisable(). ++ */ ++static void ++cnfstmtDisable(struct cnfstmt *cnfstmt) ++{ ++ cnfstmt->nodetype = S_NOP; ++} ++ + void cnfstmtDestructLst(struct cnfstmt *root); + + static void cnfIteratorDestruct(struct cnfitr *itr); +@@ -3166,11 +3179,22 @@ cnfIteratorDestruct(struct cnfitr *itr) + struct cnfstmt * + cnfstmtNewSet(char *var, struct cnfexpr *expr, int force_reset) + { ++ propid_t propid; + struct cnfstmt* cnfstmt; + if((cnfstmt = cnfstmtNew(S_SET)) != NULL) { +- cnfstmt->d.s_set.varname = (uchar*) var; +- cnfstmt->d.s_set.expr = expr; +- cnfstmt->d.s_set.force_reset = force_reset; ++ if(propNameToID((uchar *)var, &propid) == RS_RET_OK ++ && ( propid == PROP_CEE ++ || propid == PROP_LOCAL_VAR ++ || propid == PROP_GLOBAL_VAR) ++ ) { ++ cnfstmt->d.s_set.varname = (uchar*) var; ++ cnfstmt->d.s_set.expr = expr; ++ cnfstmt->d.s_set.force_reset = force_reset; ++ } else { ++ parser_errmsg("invalid variable '%s' in set statement.", var); ++ free(var); ++ cnfstmtDisable(cnfstmt); ++ } + } + return cnfstmt; + } +@@ -3254,9 +3278,20 @@ cnfstmtNewReloadLookupTable(struct cnffparamlst *fparams) + struct cnfstmt * + cnfstmtNewUnset(char *var) + { ++ propid_t propid; + struct cnfstmt* cnfstmt; + if((cnfstmt = cnfstmtNew(S_UNSET)) != NULL) { +- cnfstmt->d.s_unset.varname = (uchar*) var; ++ if(propNameToID((uchar *)var, &propid) == RS_RET_OK ++ && ( propid == PROP_CEE ++ || propid == PROP_LOCAL_VAR ++ || propid == PROP_GLOBAL_VAR) ++ ) { ++ cnfstmt->d.s_unset.varname = (uchar*) var; ++ } else { ++ parser_errmsg("invalid variable '%s' in unset statement.", var); ++ free(var); ++ cnfstmtDisable(cnfstmt); ++ } + } + return cnfstmt; + } diff --git a/SOURCES/rsyslog-8.24.0-rhbz1431616-pmrfc3164sd-backport.patch b/SOURCES/rsyslog-8.24.0-rhbz1431616-pmrfc3164sd-backport.patch new file mode 100644 index 0000000..39e16b6 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1431616-pmrfc3164sd-backport.patch @@ -0,0 +1,413 @@ +diff -up ./configure.ac.pmrfc3164sd ./configure.ac +--- ./configure.ac.pmrfc3164sd 2017-01-10 10:01:24.000000000 +0100 ++++ ./configure.ac 2017-04-03 10:10:40.912388923 +0200 +@@ -1559,6 +1559,18 @@ AC_ARG_ENABLE(pmpanngfw, + ) + AM_CONDITIONAL(ENABLE_PMPANNGFW, test x$enable_pmpanngfw = xyes) + ++# settings for pmrfc3164sd ++AC_ARG_ENABLE(pmrfc3164sd, ++ [AS_HELP_STRING([--enable-pmrfc3164sd],[Compiles rfc3164sd parser module @<:@default=no@:>@])], ++ [case "${enableval}" in ++ yes) enable_pmrfc3164sd="yes" ;; ++ no) enable_pmrfc3164sd="no" ;; ++ *) AC_MSG_ERROR(bad value ${enableval} for --enable-pmrfc3164sd) ;; ++ esac], ++ [enable_pmrfc3164sd=no] ++) ++AM_CONDITIONAL(ENABLE_PMRFC3164SD, test x$enable_pmrfc3164sd = xyes) ++ + + # settings for omruleset + AC_ARG_ENABLE(omruleset, +@@ -1953,6 +1965,7 @@ AC_CONFIG_FILES([Makefile \ + plugins/mmexternal/Makefile \ + plugins/omstdout/Makefile \ + plugins/omjournal/Makefile \ ++ plugins/pmrfc3164sd/Makefile \ + plugins/pmciscoios/Makefile \ + plugins/pmnull/Makefile \ + plugins/omruleset/Makefile \ +@@ -2057,6 +2070,7 @@ echo " omamqp1 module will be compile + echo " omtcl module will be compiled: $enable_omtcl" + echo + echo "---{ parser modules }---" ++echo " pmrfc3164sd module will be compiled: $enable_pmrfc3164sd" + echo " pmlastmsg module will be compiled: $enable_pmlastmsg" + echo " pmcisconames module will be compiled: $enable_pmcisconames" + echo " pmciscoios module will be compiled: $enable_pmciscoios" +diff -up ./Makefile.am.pmrfc3164sd ./Makefile.am +--- ./Makefile.am.pmrfc3164sd 2017-01-10 10:00:04.000000000 +0100 ++++ ./Makefile.am 2017-04-03 10:10:40.912388923 +0200 +@@ -115,6 +115,10 @@ if ENABLE_PMLASTMSG + SUBDIRS += plugins/pmlastmsg + endif + ++if ENABLE_PMRFC3164SD ++SUBDIRS += plugins/pmrfc3164sd ++endif ++ + if ENABLE_OMRULESET + SUBDIRS += plugins/omruleset + endif +diff -up ./plugins/pmrfc3164sd/Makefile.am.pmrfc3164sd ./plugins/pmrfc3164sd/Makefile.am +--- ./plugins/pmrfc3164sd/Makefile.am.pmrfc3164sd 2017-04-03 10:10:40.912388923 +0200 ++++ ./plugins/pmrfc3164sd/Makefile.am 2017-04-03 10:10:40.912388923 +0200 +@@ -0,0 +1,8 @@ ++pkglib_LTLIBRARIES = pmrfc3164sd.la ++ ++pmrfc3164sd_la_SOURCES = pmrfc3164sd.c ++pmrfc3164sd_la_CPPFLAGS = $(RSRT_CFLAGS) $(PTHREADS_CFLAGS) -I ../../tools ++pmrfc3164sd_la_LDFLAGS = -module -avoid-version ++pmrfc3164sd_la_LIBADD = ++ ++EXTRA_DIST = +diff -up ./plugins/pmrfc3164sd/pmrfc3164sd.c.pmrfc3164sd ./plugins/pmrfc3164sd/pmrfc3164sd.c +--- ./plugins/pmrfc3164sd/pmrfc3164sd.c.pmrfc3164sd 2017-04-03 10:10:40.913388923 +0200 ++++ ./plugins/pmrfc3164sd/pmrfc3164sd.c 2017-04-03 10:26:52.012341658 +0200 +@@ -0,0 +1,345 @@ ++/* pmrfc3164sd.c ++ * This is a parser module for RFC3164(legacy syslog)-formatted messages. ++ * ++ * NOTE: read comments in module-template.h to understand how this file ++ * works! ++ * ++ * File begun on 2009-11-04 by RGerhards ++ * ++ * Copyright 2007, 2009 Rainer Gerhards and Adiscon GmbH. ++ * ++ * This file is part of rsyslog. ++ * ++ * Rsyslog is free software: you can redistribute it and/or modify ++ * it under the terms of the GNU General Public License as published by ++ * the Free Software Foundation, either version 3 of the License, or ++ * (at your option) any later version. ++ * ++ * Rsyslog is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ * GNU General Public License for more details. ++ * ++ * You should have received a copy of the GNU General Public License ++ * along with Rsyslog. If not, see . ++ * ++ * A copy of the GPL can be found in the file "COPYING" in this distribution. ++ */ ++#include "config.h" ++#include "rsyslog.h" ++#include ++#include ++#include ++#include ++#include ++#include "syslogd.h" ++#include "conf.h" ++#include "syslogd-types.h" ++#include "template.h" ++#include "msg.h" ++#include "module-template.h" ++#include "glbl.h" ++#include "errmsg.h" ++#include "parser.h" ++#include "datetime.h" ++#include "unicode-helper.h" ++ ++MODULE_TYPE_PARSER ++MODULE_TYPE_NOKEEP ++MODULE_CNFNAME("pmrfc3164sd") ++PARSER_NAME("contrib.rfc3164sd") ++ ++/* internal structures ++ */ ++DEF_PMOD_STATIC_DATA ++DEFobjCurrIf(errmsg) ++DEFobjCurrIf(glbl) ++DEFobjCurrIf(parser) ++DEFobjCurrIf(datetime) ++ ++ ++/* static data */ ++static int bParseHOSTNAMEandTAG; /* cache for the equally-named global param - performance enhancement */ ++ ++ ++BEGINisCompatibleWithFeature ++CODESTARTisCompatibleWithFeature ++ if(eFeat == sFEATUREAutomaticSanitazion) ++ iRet = RS_RET_OK; ++ if(eFeat == sFEATUREAutomaticPRIParsing) ++ iRet = RS_RET_OK; ++ENDisCompatibleWithFeature ++ ++/* Helper to parseRFCSyslogMsg. This function parses the structured ++ * data field of a message. It does NOT parse inside structured data, ++ * just gets the field as whole. Parsing the single entities is left ++ * to other functions. The parsepointer is advanced ++ * to after the terminating SP. The caller must ensure that the ++ * provided buffer is large enough to hold the to be extracted value. ++ * Returns 0 if everything is fine or 1 if either the field is not ++ * SP-terminated or any other error occurs. -- rger, 2005-11-24 ++ * The function now receives the size of the string and makes sure ++ * that it does not process more than that. The *pLenStr counter is ++ * updated on exit. -- rgerhards, 2009-09-23 ++ */ ++static int parseRFCStructuredData(uchar **pp2parse, uchar *pResult, int *pLenStr) ++{ ++ uchar *p2parse; ++ int bCont = 1; ++ int iRet = 0; ++ int lenStr; ++ ++ assert(pp2parse != NULL); ++ assert(*pp2parse != NULL); ++ assert(pResult != NULL); ++ ++ p2parse = *pp2parse; ++ lenStr = *pLenStr; ++ ++ /* this is the actual parsing loop ++ * Remeber: structured data starts with [ and includes any characters ++ * until the first ] followed by a SP. There may be spaces inside ++ * structured data. There may also be \] inside the structured data, which ++ * do NOT terminate an element. ++ */ ++ ++ /* trim */ ++ while(lenStr > 0 && *p2parse == ' ') { ++ ++p2parse; /* eat SP, but only if not at end of string */ ++ --lenStr; ++ } ++ ++ if(lenStr == 0 || *p2parse != '[') ++ return 1; /* this is NOT structured data! */ ++ ++ if(*p2parse == '-') { /* empty structured data? */ ++ *pResult++ = '-'; ++ ++p2parse; ++ --lenStr; ++ } else { ++ while(bCont) { ++ if(lenStr < 2) { ++ /* we now need to check if we have only structured data */ ++ if(lenStr > 0 && *p2parse == ']') { ++ *pResult++ = *p2parse; ++ p2parse++; ++ lenStr--; ++ bCont = 0; ++ } else { ++ iRet = 1; /* this is not valid! */ ++ bCont = 0; ++ } ++ } else if(*p2parse == '\\' && *(p2parse+1) == ']') { ++ /* this is escaped, need to copy both */ ++ *pResult++ = *p2parse++; ++ *pResult++ = *p2parse++; ++ lenStr -= 2; ++ } else if(*p2parse == ']' && *(p2parse+1) == ' ') { ++ /* found end, just need to copy the ] and eat the SP */ ++ *pResult++ = *p2parse; ++ p2parse += 2; ++ lenStr -= 2; ++ bCont = 0; ++ } else { ++ *pResult++ = *p2parse++; ++ --lenStr; ++ } ++ } ++ } ++ ++ if(lenStr > 0 && *p2parse == ' ') { ++ ++p2parse; /* eat SP, but only if not at end of string */ ++ --lenStr; ++ } else { ++ iRet = 1; /* there MUST be an SP! */ ++ } ++ *pResult = '\0'; ++ ++ /* set the new parse pointer */ ++ *pp2parse = p2parse; ++ *pLenStr = lenStr; ++ return 0; ++} ++ ++/* parse a legay-formatted syslog message. ++ */ ++BEGINparse ++ uchar *p2parse; ++ int lenMsg; ++ int bTAGCharDetected; ++ int i; /* general index for parsing */ ++ uchar bufParseTAG[CONF_TAG_MAXSIZE]; ++ uchar bufParseHOSTNAME[CONF_HOSTNAME_MAXSIZE]; ++ uchar *pBuf = NULL; ++CODESTARTparse ++ dbgprintf("Message will now be parsed by the legacy syslog parser with structured-data support.\n"); ++ assert(pMsg != NULL); ++ assert(pMsg->pszRawMsg != NULL); ++ lenMsg = pMsg->iLenRawMsg - pMsg->offAfterPRI; /* note: offAfterPRI is already the number of PRI chars (do not add one!) */ ++ p2parse = pMsg->pszRawMsg + pMsg->offAfterPRI; /* point to start of text, after PRI */ ++ setProtocolVersion(pMsg, MSG_LEGACY_PROTOCOL); ++ ++ /* Check to see if msg contains a timestamp. We start by assuming ++ * that the message timestamp is the time of reception (which we ++ * generated ourselfs and then try to actually find one inside the ++ * message. There we go from high-to low precison and are done ++ * when we find a matching one. -- rgerhards, 2008-09-16 ++ */ ++ if(datetime.ParseTIMESTAMP3339(&(pMsg->tTIMESTAMP), &p2parse, &lenMsg) == RS_RET_OK) { ++ /* we are done - parse pointer is moved by ParseTIMESTAMP3339 */; ++ } else if(datetime.ParseTIMESTAMP3164(&(pMsg->tTIMESTAMP), &p2parse, &lenMsg, NO_PARSE3164_TZSTRING, NO_PERMIT_YEAR_AFTER_TIME) == RS_RET_OK) { ++ /* we are done - parse pointer is moved by ParseTIMESTAMP3164 */; ++ } else if(*p2parse == ' ' && lenMsg > 1) { /* try to see if it is slighly malformed - HP procurve seems to do that sometimes */ ++ ++p2parse; /* move over space */ ++ --lenMsg; ++ if(datetime.ParseTIMESTAMP3164(&(pMsg->tTIMESTAMP), &p2parse, &lenMsg, NO_PARSE3164_TZSTRING, NO_PERMIT_YEAR_AFTER_TIME) == RS_RET_OK) { ++ /* indeed, we got it! */ ++ /* we are done - parse pointer is moved by ParseTIMESTAMP3164 */; ++ } else {/* parse pointer needs to be restored, as we moved it off-by-one ++ * for this try. ++ */ ++ --p2parse; ++ ++lenMsg; ++ } ++ } ++ ++ if(pMsg->msgFlags & IGNDATE) { ++ /* we need to ignore the msg data, so simply copy over reception date */ ++ memcpy(&pMsg->tTIMESTAMP, &pMsg->tRcvdAt, sizeof(struct syslogTime)); ++ } ++ ++ /* rgerhards, 2006-03-13: next, we parse the hostname and tag. But we ++ * do this only when the user has not forbidden this. I now introduce some ++ * code that allows a user to configure rsyslogd to treat the rest of the ++ * message as MSG part completely. In this case, the hostname will be the ++ * machine that we received the message from and the tag will be empty. This ++ * is meant to be an interim solution, but for now it is in the code. ++ */ ++ if(bParseHOSTNAMEandTAG && !(pMsg->msgFlags & INTERNAL_MSG)) { ++ /* parse HOSTNAME - but only if this is network-received! ++ * rger, 2005-11-14: we still have a problem with BSD messages. These messages ++ * do NOT include a host name. In most cases, this leads to the TAG to be treated ++ * as hostname and the first word of the message as the TAG. Clearly, this is not ++ * of advantage ;) I think I have now found a way to handle this situation: there ++ * are certain characters which are frequently used in TAG (e.g. ':'), which are ++ * *invalid* in host names. So while parsing the hostname, I check for these characters. ++ * If I find them, I set a simple flag but continue. After parsing, I check the flag. ++ * If it was set, then we most probably do not have a hostname but a TAG. Thus, I change ++ * the fields. I think this logic shall work with any type of syslog message. ++ * rgerhards, 2009-06-23: and I now have extended this logic to every character ++ * that is not a valid hostname. ++ */ ++ bTAGCharDetected = 0; ++ if(lenMsg > 0 && pMsg->msgFlags & PARSE_HOSTNAME) { ++ i = 0; ++ while(i < lenMsg && (isalnum(p2parse[i]) || p2parse[i] == '.' || p2parse[i] == '.' ++ || p2parse[i] == '_' || p2parse[i] == '-') && i < (CONF_HOSTNAME_MAXSIZE - 1)) { ++ bufParseHOSTNAME[i] = p2parse[i]; ++ ++i; ++ } ++ ++ if(i == lenMsg) { ++ /* we have a message that is empty immediately after the hostname, ++ * but the hostname thus is valid! -- rgerhards, 2010-02-22 ++ */ ++ p2parse += i; ++ lenMsg -= i; ++ bufParseHOSTNAME[i] = '\0'; ++ MsgSetHOSTNAME(pMsg, bufParseHOSTNAME, i); ++ } else if(i > 0 && p2parse[i] == ' ' && isalnum(p2parse[i-1])) { ++ /* we got a hostname! */ ++ p2parse += i + 1; /* "eat" it (including SP delimiter) */ ++ lenMsg -= i + 1; ++ bufParseHOSTNAME[i] = '\0'; ++ MsgSetHOSTNAME(pMsg, bufParseHOSTNAME, i); ++ } ++ } ++ ++ /* now parse TAG - that should be present in message from all sources. ++ * This code is somewhat not compliant with RFC 3164. As of 3164, ++ * the TAG field is ended by any non-alphanumeric character. In ++ * practice, however, the TAG often contains dashes and other things, ++ * which would end the TAG. So it is not desirable. As such, we only ++ * accept colon and SP to be terminators. Even there is a slight difference: ++ * a colon is PART of the TAG, while a SP is NOT part of the tag ++ * (it is CONTENT). Starting 2008-04-04, we have removed the 32 character ++ * size limit (from RFC3164) on the tag. This had bad effects on existing ++ * envrionments, as sysklogd didn't obey it either (probably another bug ++ * in RFC3164...). We now receive the full size, but will modify the ++ * outputs so that only 32 characters max are used by default. ++ */ ++ i = 0; ++ while(lenMsg > 0 && *p2parse != ':' && *p2parse != ' ' && i < CONF_TAG_MAXSIZE) { ++ bufParseTAG[i++] = *p2parse++; ++ --lenMsg; ++ } ++ if(lenMsg > 0 && *p2parse == ':') { ++ ++p2parse; ++ --lenMsg; ++ bufParseTAG[i++] = ':'; ++ } ++ ++ /* no TAG can only be detected if the message immediatly ends, in which case an empty TAG ++ * is considered OK. So we do not need to check for empty TAG. -- rgerhards, 2009-06-23 ++ */ ++ bufParseTAG[i] = '\0'; /* terminate string */ ++ MsgSetTAG(pMsg, bufParseTAG, i); ++ } else {/* we enter this code area when the user has instructed rsyslog NOT ++ * to parse HOSTNAME and TAG - rgerhards, 2006-03-13 ++ */ ++ if(!(pMsg->msgFlags & INTERNAL_MSG)) { ++ DBGPRINTF("HOSTNAME and TAG not parsed by user configuraton.\n"); ++ } ++ } ++ ++ CHKmalloc(pBuf = MALLOC(sizeof(uchar) * (lenMsg + 1))); ++ ++ /* STRUCTURED-DATA */ ++ if (parseRFCStructuredData(&p2parse, pBuf, &lenMsg) == 0) ++ MsgSetStructuredData(pMsg, (char*)pBuf); ++ else ++ MsgSetStructuredData(pMsg, "-"); ++ ++ /* The rest is the actual MSG */ ++ MsgSetMSGoffs(pMsg, p2parse - pMsg->pszRawMsg); ++ ++finalize_it: ++ if(pBuf != NULL) ++ free(pBuf); ++ENDparse ++ ++ ++BEGINmodExit ++CODESTARTmodExit ++ /* release what we no longer need */ ++ objRelease(errmsg, CORE_COMPONENT); ++ objRelease(glbl, CORE_COMPONENT); ++ objRelease(parser, CORE_COMPONENT); ++ objRelease(datetime, CORE_COMPONENT); ++ENDmodExit ++ ++ ++BEGINqueryEtryPt ++CODESTARTqueryEtryPt ++CODEqueryEtryPt_STD_PMOD_QUERIES ++CODEqueryEtryPt_IsCompatibleWithFeature_IF_OMOD_QUERIES ++ENDqueryEtryPt ++ ++ ++BEGINmodInit() ++CODESTARTmodInit ++ *ipIFVersProvided = CURR_MOD_IF_VERSION; /* we only support the current interface specification */ ++CODEmodInit_QueryRegCFSLineHdlr ++ CHKiRet(objUse(glbl, CORE_COMPONENT)); ++ CHKiRet(objUse(errmsg, CORE_COMPONENT)); ++ CHKiRet(objUse(parser, CORE_COMPONENT)); ++ CHKiRet(objUse(datetime, CORE_COMPONENT)); ++ ++ dbgprintf("rfc3164sd parser init called\n"); ++ bParseHOSTNAMEandTAG = glbl.GetParseHOSTNAMEandTAG(); /* cache value, is set only during rsyslogd option processing */ ++ ++ ++ENDmodInit ++ ++/* vim:set ai: ++ */ diff --git a/SOURCES/rsyslog-8.24.0-rhbz1459896-queues-defaults-doc.patch b/SOURCES/rsyslog-8.24.0-rhbz1459896-queues-defaults-doc.patch new file mode 100644 index 0000000..e7bdc91 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1459896-queues-defaults-doc.patch @@ -0,0 +1,138 @@ +From c8be9a713a57f07311560af50c24267b30bef21b Mon Sep 17 00:00:00 2001 +From: Jiri Vymazal +Date: Tue, 29 Aug 2017 16:32:15 +0200 +Subject: [PATCH] fixed queue default values + +--- + source/concepts/queues.rst | 7 +++---- + source/configuration/global/index.rst | 6 +++--- + source/configuration/global/options/rsconf1_mainmsgqueuesize.rst | 2 +- + source/rainerscript/queue_parameters.rst | 15 ++++++++++++--- + source/configuration/action/index.rst | 12 ++++++------ + 5 files changed, 24 insertions(+), 16 deletions(-) + +diff --git a/source/concepts/queues.rst b/source/concepts/queues.rst +index c71413c..9b41128 100644 +--- a/source/concepts/queues.rst ++++ b/source/concepts/queues.rst +@@ -273,10 +273,9 @@ actually needed. + The water marks can be set via the "*$QueueHighWatermark*\ " + and  "*$QueueLowWatermark*\ " configuration file directives. + Note that these are actual numbers, not percentages. Be sure they make +-sense (also in respect to "*$QueueSize*\ "), as rsyslodg does +-currently not perform any checks on the numbers provided. It is easy to +-screw up the system here (yes, a feature enhancement request is filed +-;)). ++sense (also in respect to "*$QueueSize*\ "). Rsyslodg does ++perform some checks on the numbers provided, and issues warning when ++numbers are "suspicious". + + Limiting the Queue Size + ----------------------- +diff --git a/source/configuration/global/index.rst b/source/configuration/global/index.rst +index 2738f21..a53ef23 100644 +--- a/source/configuration/global/index.rst ++++ b/source/configuration/global/index.rst +@@ -137,13 +137,13 @@ To understand queue parameters, read + - **$MainMsgQueueDequeueSlowdown** [number is timeout in + *micro*\ seconds (1000000us is 1sec!), default 0 (no delay). Simple + rate-limiting!] +-- **$MainMsgQueueDiscardMark** [default 9750] ++- **$MainMsgQueueDiscardMark** [default 98000] + - **$MainMsgQueueDiscardSeverity** [either a textual or + numerical severity! default 4 (warning)] + - **$MainMsgQueueFileName** +-- **$MainMsgQueueHighWaterMark** [default 8000] ++- **$MainMsgQueueHighWaterMark** [default 80000] + - **$MainMsgQueueImmediateShutdown** [on/**off**] +-- **$MainMsgQueueLowWaterMark** [default 2000] ++- **$MainMsgQueueLowWaterMark** [default 20000] + - **$MainMsgQueueMaxFileSize** , default 1m + - **$MainMsgQueueTimeoutActionCompletion** [number is timeout in + ms (1000ms is 1sec!), default 1000, 0 means immediate!] +diff --git a/source/configuration/global/options/rsconf1_mainmsgqueuesize.rst b/source/configuration/global/options/rsconf1_mainmsgqueuesize.rst +index 050407c..3e902cf 100644 +--- a/source/configuration/global/options/rsconf1_mainmsgqueuesize.rst ++++ b/source/configuration/global/options/rsconf1_mainmsgqueuesize.rst +@@ -3,7 +3,7 @@ $MainMsgQueueSize + + **Type:** global configuration directive + +-**Default:** 10000 ++**Default:** 100000 + + **Description:** + +diff --git a/source/rainerscript/queue_parameters.rst b/source/rainerscript/queue_parameters.rst +index 4453721..3f2b7a2 100644 +--- a/source/rainerscript/queue_parameters.rst ++++ b/source/rainerscript/queue_parameters.rst +@@ -33,8 +33,14 @@ read the :doc:`queues <../concepts/queues>` documentation. + For more information on the current status of this restriction see + the `rsyslog FAQ: "lower bound for queue + sizes" `_. ++ ++ The default depends on queue type and, if you need ++ a specific value, please specify it. Otherwise rsyslog selects what ++ it consideres appropriate. For example, ruleset queues have a default ++ size of 50000 and action queues which are configured to be non-direct ++ have a size of 1000. + - **queue.dequeuebatchsize** number +- default 16 ++ default 128 + - **queue.maxdiskspace** number + The maximum size that all queue files together will use on disk. Note + that the actual size may be slightly larger than the configured max, +@@ -46,8 +47,9 @@ read the :doc:`queues <../concepts/queues>` documentation. + processing, because disk queue mode is very considerably slower than + in-memory queue mode. Going to disk should be reserved for cases + where an output action destination is offline for some period. ++ default 90% of queue size + - **queue.lowwatermark** number +- default 2000 ++ default 70% of queue size + - **queue.fulldelaymark** number + Number of messages when the queue should block delayable messages. + Messages are NO LONGER PROCESSED until the queue has sufficient space +@@ -59,9 +61,11 @@ read the :doc:`queues <../concepts/queues>` documentation. + out of space. Please note that if you use a DA queue, setting the + fulldelaymark BELOW the highwatermark makes the queue never activate + disk mode for delayable inputs. So this is probably not what you want. ++ default 97% of queue size + - **queue.lightdelaymark** number ++ default 70% of queue size + - **queue.discardmark** number +- default 9750 ++ default 80% of queue size + - **queue.discardseverity** number + \*numerical\* severity! default 8 (nothing discarded) + - **queue.checkpointinterval** number +diff --git a/source/configuration/action/index.rst b/source/configuration/action/index.rst +index 3e7cd24..9352866 100644 +--- a/source/configuration/action/index.rst ++++ b/source/configuration/action/index.rst +@@ -163,18 +163,18 @@ following action, only. The next and all other actions will be + in "direct" mode (no real queue) if not explicitely specified otherwise. + + - **$ActionQueueCheckpointInterval** +-- **$ActionQueueDequeueBatchSize** [default 16] ++- **$ActionQueueDequeueBatchSize** [default 128] + - **$ActionQueueDequeueSlowdown** [number is timeout in + *micro*\ seconds (1000000us is 1sec!), default 0 (no delay). Simple + rate-limiting!] +-- **$ActionQueueDiscardMark** [default 9750] +-- **$ActionQueueDiscardSeverity** [\*numerical\* severity! default +- 4 (warning)] ++- **$ActionQueueDiscardMark** [default 80% of queue size] ++- **$ActionQueueDiscardSeverity** [\*numerical\* severity! default ++ 8 (nothing discarded)] + - **$ActionQueueFileName** +-- **$ActionQueueHighWaterMark** [default 8000] ++- **$ActionQueueHighWaterMark** [default 90% of queue size] + - **$ActionQueueImmediateShutdown** [on/**off**] + - **$ActionQueueSize** +-- **$ActionQueueLowWaterMark** [default 2000] ++- **$ActionQueueLowWaterMark** [default 70% of queue size] + - **$ActionQueueMaxFileSize** , default 1m + - **$ActionQueueTimeoutActionCompletion** [number is timeout in ms + (1000ms is 1sec!), default 1000, 0 means immediate!] diff --git a/SOURCES/rsyslog-8.24.0-rhbz1462160-set.statement-crash.patch b/SOURCES/rsyslog-8.24.0-rhbz1462160-set.statement-crash.patch new file mode 100644 index 0000000..112f75c --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1462160-set.statement-crash.patch @@ -0,0 +1,150 @@ +diff -up ./plugins/imjournal/imjournal.c.default_tag ./plugins/imjournal/imjournal.c +--- ./plugins/imjournal/imjournal.c.default_tag 2017-01-10 04:00:04.000000000 -0500 ++++ ./plugins/imjournal/imjournal.c 2017-08-28 07:55:19.545930923 -0400 +@@ -78,6 +78,7 @@ static struct configSettings_s { + int iDfltSeverity; + int iDfltFacility; + int bUseJnlPID; ++ char *dfltTag; + } cs; + + static rsRetVal facilityHdlr(uchar **pp, void *pVal); +@@ -93,6 +94,7 @@ static struct cnfparamdescr modpdescr[] + { "defaultseverity", eCmdHdlrSeverity, 0 }, + { "defaultfacility", eCmdHdlrString, 0 }, + { "usepidfromsystem", eCmdHdlrBinary, 0 }, ++ { "defaulttag", eCmdHdlrGetWord, 0 }, + }; + static struct cnfparamblk modpblk = + { CNFPARAMBLK_VERSION, +@@ -103,6 +105,7 @@ static struct cnfparamblk modpblk = + #define DFLT_persiststateinterval 10 + #define DFLT_SEVERITY pri2sev(LOG_NOTICE) + #define DFLT_FACILITY pri2fac(LOG_USER) ++#define DFLT_TAG "journal" + + static int bLegacyCnfModGlobalsPermitted = 1;/* are legacy module-global config parameters permitted? */ + +@@ -194,8 +197,13 @@ enqMsg(uchar *msg, uchar *pszTag, int iF + } + MsgSetFlowControlType(pMsg, eFLOWCTL_LIGHT_DELAY); + MsgSetInputName(pMsg, pInputName); ++ /* Recalculating the message length shouldn't cause problems as all ++ * potential zero-bytes have been excaped in sanitizeValue(). */ + len = strlen((char*)msg); + MsgSetRawMsg(pMsg, (char*)msg, len); ++ /* NB: SanitizeMsg() only touches the raw message and its ++ * length which only contain the msg part. Thus the TAG and ++ * other fields are not sanitized. */ + if(len > 0) + parser.SanitizeMsg(pMsg); + MsgSetMSGoffs(pMsg, 0); /* we do not have a header... */ +@@ -233,7 +241,7 @@ readjournal(void) + + /* Information from messages */ + char *message = NULL; +- char *sys_iden; ++ char *sys_iden = NULL; + char *sys_iden_help = NULL; + + const void *get; +@@ -294,29 +302,34 @@ readjournal(void) + /* Get message identifier, client pid and add ':' */ + if (sd_journal_get_data(j, "SYSLOG_IDENTIFIER", &get, &length) >= 0) { + CHKiRet(sanitizeValue(((const char *)get) + 18, length - 18, &sys_iden)); +- } else { +- CHKmalloc(sys_iden = strdup("journal")); + } + +- if (sd_journal_get_data(j, pid_field_name, &pidget, &pidlength) >= 0) { +- char *sys_pid; +- int val_ofs; +- +- val_ofs = strlen(pid_field_name) + 1; /* name + '=' */ +- CHKiRet_Hdlr(sanitizeValue(((const char *)pidget) + val_ofs, pidlength - val_ofs, &sys_pid)) { +- free (sys_iden); +- FINALIZE; ++ if (sys_iden == NULL && !cs.dfltTag[0]) { ++ /* This is a special case: if no tag was obtained from ++ * the message and the user has set the default tag to ++ * an empty string, nothing is inserted. ++ */ ++ CHKmalloc(sys_iden_help = calloc(1, 1)); ++ } else { ++ if (sys_iden == NULL) { ++ /* Use a predefined tag if it can't be obtained from the message */ ++ CHKmalloc(sys_iden = strdup(cs.dfltTag)); ++ } ++ if (sd_journal_get_data(j, "SYSLOG_PID", &pidget, &pidlength) >= 0) { ++ char *sys_pid; ++ CHKiRet_Hdlr(sanitizeValue(((const char *)pidget) + 11, pidlength - 11, &sys_pid)) { ++ free (sys_iden); ++ FINALIZE; ++ } ++ r = asprintf(&sys_iden_help, "%s[%s]:", sys_iden, sys_pid); ++ free (sys_pid); ++ } else { ++ r = asprintf(&sys_iden_help, "%s:", sys_iden); ++ } ++ free (sys_iden); ++ if (-1 == r) { ++ ABORT_FINALIZE(RS_RET_OUT_OF_MEMORY); + } +- r = asprintf(&sys_iden_help, "%s[%s]:", sys_iden, sys_pid); +- free (sys_pid); +- } else { +- r = asprintf(&sys_iden_help, "%s:", sys_iden); +- } +- +- free (sys_iden); +- +- if (-1 == r) { +- ABORT_FINALIZE(RS_RET_OUT_OF_MEMORY); + } + + json = json_object_new_object(); +@@ -585,6 +598,10 @@ CODESTARTrunInput + pid_field_name = "SYSLOG_PID"; + } + ++ if (cs.dfltTag == NULL) { ++ cs.dfltTag = strdup(DFLT_TAG); ++ } ++ + /* this is an endless loop - it is terminated when the thread is + * signalled to do so. This, however, is handled by the framework. + */ +@@ -633,6 +650,7 @@ CODESTARTbeginCnfLoad + cs.ratelimitInterval = 600; + cs.iDfltSeverity = DFLT_SEVERITY; + cs.iDfltFacility = DFLT_FACILITY; ++ cs.dfltTag = NULL; + cs.bUseJnlPID = 0; + ENDbeginCnfLoad + +@@ -655,6 +673,7 @@ ENDactivateCnf + BEGINfreeCnf + CODESTARTfreeCnf + free(cs.stateFile); ++ free(cs.dfltTag); + ENDfreeCnf + + /* open journal */ +@@ -739,6 +758,8 @@ CODESTARTsetModCnf + free(fac); + } else if (!strcmp(modpblk.descr[i].name, "usepidfromsystem")) { + cs.bUseJnlPID = (int) pvals[i].val.d.n; ++ } else if (!strcmp(modpblk.descr[i].name, "defaulttag")) { ++ cs.dfltTag = (char *)es_str2cstr(pvals[i].val.d.estr, NULL); + } else { + dbgprintf("imjournal: program error, non-handled " + "param '%s' in beginCnfLoad\n", modpblk.descr[i].name); +@@ -799,6 +820,8 @@ CODEmodInit_QueryRegCFSLineHdlr + facilityHdlr, &cs.iDfltFacility, STD_LOADABLE_MODULE_ID)); + CHKiRet(omsdRegCFSLineHdlr((uchar *)"imjournalusepidfromsystem", 0, eCmdHdlrBinary, + NULL, &cs.bUseJnlPID, STD_LOADABLE_MODULE_ID)); ++ CHKiRet(omsdRegCFSLineHdlr((uchar *)"imjournaldefaulttag", 0, eCmdHdlrGetWord, ++ NULL, &cs.dfltTag, STD_LOADABLE_MODULE_ID)); + ENDmodInit + /* vim:set ai: + */ diff --git a/SOURCES/rsyslog-8.24.0-rhbz1488186-fixed-nullptr-check.patch b/SOURCES/rsyslog-8.24.0-rhbz1488186-fixed-nullptr-check.patch new file mode 100644 index 0000000..19f84d4 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1488186-fixed-nullptr-check.patch @@ -0,0 +1,27 @@ +From a5b40bb57cf47d964ad3873ddf550e7885df9f8e Mon Sep 17 00:00:00 2001 +From: Marek Tamaskovic +Date: Wed, 6 Sep 2017 17:08:45 +0200 +Subject: [PATCH] fixed nullptr check + +--- + plugins/imjournal/imjournal.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/plugins/imjournal/imjournal.c b/plugins/imjournal/imjournal.c +index e3e0f39..938e8b8 100644 +--- a/plugins/imjournal/imjournal.c ++++ b/plugins/imjournal/imjournal.c +@@ -514,7 +514,9 @@ pollJournal(void) + ABORT_FINALIZE(RS_RET_ERR); + } + +- iRet = loadJournalState(); ++ if(cs.stateFile != NULL){ ++ iRet = loadJournalState(); ++ } + LogMsg(0, RS_RET_OK, LOG_NOTICE, "imjournal: journal reloaded..."); + } else if (jr < 0) { + char errStr[256]; +-- +2.9.5 + diff --git a/SOURCES/rsyslog-8.24.0-rhbz1497985-journal-reloaded-message.patch b/SOURCES/rsyslog-8.24.0-rhbz1497985-journal-reloaded-message.patch new file mode 100644 index 0000000..31237c4 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1497985-journal-reloaded-message.patch @@ -0,0 +1,46 @@ +diff -up ./plugins/imjournal/imjournal.c.journal-reloaded ./plugins/imjournal/imjournal.c +--- ./plugins/imjournal/imjournal.c.journal-reloaded 2017-10-09 11:05:53.698885473 -0400 ++++ ./plugins/imjournal/imjournal.c 2017-10-09 11:08:54.179885473 -0400 +@@ -509,8 +509,7 @@ pollJournal(void) + } + + iRet = loadJournalState(); +- errmsg.LogError(0, RS_RET_OK, "imjournal: " +- "journal reloaded..."); ++ LogMsg(0, RS_RET_OK, LOG_NOTICE, "imjournal: journal reloaded..."); + } else if (jr < 0) { + char errStr[256]; + rs_strerror_r(errno, errStr, sizeof(errStr)); +diff -up ./runtime/errmsg.c.journal-reloaded ./runtime/errmsg.c +--- ./runtime/errmsg.c.journal-reloaded 2016-12-03 12:41:03.000000000 -0500 ++++ ./runtime/errmsg.c 2017-10-09 11:05:53.704885473 -0400 +@@ -115,7 +115,7 @@ doLogMsg(const int iErrno, const int iEr + * maps to a specific error event). + * rgerhards, 2008-06-27 + */ +-static void __attribute__((format(printf, 3, 4))) ++void __attribute__((format(printf, 3, 4))) + LogError(const int iErrno, const int iErrCode, const char *fmt, ... ) + { + va_list ap; +@@ -144,7 +144,7 @@ LogError(const int iErrno, const int iEr + * maps to a specific error event). + * rgerhards, 2008-06-27 + */ +-static void __attribute__((format(printf, 4, 5))) ++void __attribute__((format(printf, 4, 5))) + LogMsg(const int iErrno, const int iErrCode, const int severity, const char *fmt, ... ) + { + va_list ap; +diff -up ./runtime/errmsg.h.journal-reloaded ./runtime/errmsg.h +--- ./runtime/errmsg.h.journal-reloaded 2016-12-03 12:41:03.000000000 -0500 ++++ ./runtime/errmsg.h 2017-10-09 11:05:53.704885473 -0400 +@@ -44,5 +44,8 @@ ENDinterface(errmsg) + PROTOTYPEObj(errmsg); + void resetErrMsgsFlag(void); + int hadErrMsgs(void); ++void __attribute__((format(printf, 3, 4))) LogError(const int iErrno, const int iErrCode, const char *fmt, ... ); ++void __attribute__((format(printf, 4, 5))) ++ LogMsg(const int iErrno, const int iErrCode, const int severity, const char *fmt, ... ); + + #endif /* #ifndef INCLUDED_ERRMSG_H */ diff --git a/SOURCES/rsyslog-8.24.0-rhbz1505103-omrelp-rebindinterval.patch b/SOURCES/rsyslog-8.24.0-rhbz1505103-omrelp-rebindinterval.patch new file mode 100644 index 0000000..39fda2b --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1505103-omrelp-rebindinterval.patch @@ -0,0 +1,28 @@ +From cc09e7a6e893157a4d7a173c78f4b0a0496e8fbd Mon Sep 17 00:00:00 2001 +From: Rainer Gerhards +Date: Thu, 28 Sep 2017 19:08:35 +0200 +Subject: [PATCH] omrelp bugfix: segfault if rebindinterval config param is + used + +closes https://github.com/rsyslog/rsyslog/issues/120 +--- + plugins/omrelp/omrelp.c | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +diff --git a/plugins/omrelp/omrelp.c b/plugins/omrelp/omrelp.c +index 3df062e0e..d32a66e07 100644 +--- a/plugins/omrelp/omrelp.c ++++ b/plugins/omrelp/omrelp.c +@@ -566,8 +566,10 @@ ENDdoAction + + BEGINendTransaction + CODESTARTendTransaction +- dbgprintf("omrelp: endTransaction\n"); +- relpCltHintBurstEnd(pWrkrData->pRelpClt); ++ DBGPRINTF("omrelp: endTransaction, connected %d\n", pWrkrData->bIsConnected); ++ if(pWrkrData->bIsConnected) { ++ relpCltHintBurstEnd(pWrkrData->pRelpClt); ++ } + ENDendTransaction + + BEGINparseSelectorAct diff --git a/SOURCES/rsyslog-8.24.0-rhbz1507028-recover_qi-doc.patch b/SOURCES/rsyslog-8.24.0-rhbz1507028-recover_qi-doc.patch new file mode 100644 index 0000000..42a69b1 --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-rhbz1507028-recover_qi-doc.patch @@ -0,0 +1,27 @@ +From ff07a7cfc171dc2151cc8afe44776525d34a9e01 Mon Sep 17 00:00:00 2001 +From: jvymazal +Date: Tue, 3 Jan 2017 10:24:26 +0100 +Subject: [PATCH] Update queues.rst + +Update queues.rst +--- + source/concepts/queues.rst | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/source/concepts/queues.rst b/source/concepts/queues.rst +index eb394e8..c71413c 100644 +--- a/source/concepts/queues.rst ++++ b/source/concepts/queues.rst +@@ -153,6 +153,12 @@ can be requested via "*QueueSyncQueueFiles on/off* with the + default being off. Activating this option has a performance penalty, so + it should not be turned on without reason. + ++If you happen to lose or otherwise need the housekeeping structures and ++have all yours queue chunks you can use perl script included in rsyslog ++package to generate it. ++Usage: recover_qi.pl -w *$WorkDirectory* -f QueueFileName -d 8 > QueueFileName.qi ++ ++ + In-Memory Queues + ~~~~~~~~~~~~~~~~ + diff --git a/SOURCES/rsyslog-8.24.0-sd-service.patch b/SOURCES/rsyslog-8.24.0-sd-service.patch new file mode 100644 index 0000000..3018ada --- /dev/null +++ b/SOURCES/rsyslog-8.24.0-sd-service.patch @@ -0,0 +1,30 @@ +From fc47fd36a8549fae46ab7dbff31d542c829c1004 Mon Sep 17 00:00:00 2001 +From: Radovan Sroka +Date: Mon, 21 Nov 2016 16:49:48 +0100 +Subject: [PATCH 1/4] Rebased from: Patch0: rsyslog-7.4.1-sd-service.patch + +Resolves: + no bugzilla +--- + rsyslog.service.in | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +diff --git a/rsyslog.service.in b/rsyslog.service.in +index cb629ee..74d2149 100644 +--- a/rsyslog.service.in ++++ b/rsyslog.service.in +@@ -6,7 +6,10 @@ Documentation=http://www.rsyslog.com/doc/ + + [Service] + Type=notify +-ExecStart=@sbindir@/rsyslogd -n ++EnvironmentFile=-/etc/sysconfig/rsyslog ++ExecStart=@sbindir@/rsyslogd -n $SYSLOGD_OPTIONS ++Restart=on-failure ++UMask=0066 + StandardOutput=null + Restart=on-failure + +-- +2.7.4 + diff --git a/SOURCES/rsyslog.conf b/SOURCES/rsyslog.conf new file mode 100644 index 0000000..735472d --- /dev/null +++ b/SOURCES/rsyslog.conf @@ -0,0 +1,91 @@ +# rsyslog configuration file + +# For more information see /usr/share/doc/rsyslog-*/rsyslog_conf.html +# If you experience problems, see http://www.rsyslog.com/doc/troubleshoot.html + +#### MODULES #### + +# The imjournal module bellow is now used as a message source instead of imuxsock. +$ModLoad imuxsock # provides support for local system logging (e.g. via logger command) +$ModLoad imjournal # provides access to the systemd journal +#$ModLoad imklog # reads kernel messages (the same are read from journald) +#$ModLoad immark # provides --MARK-- message capability + +# Provides UDP syslog reception +#$ModLoad imudp +#$UDPServerRun 514 + +# Provides TCP syslog reception +#$ModLoad imtcp +#$InputTCPServerRun 514 + + +#### GLOBAL DIRECTIVES #### + +# Where to place auxiliary files +$WorkDirectory /var/lib/rsyslog + +# Use default timestamp format +$ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat + +# File syncing capability is disabled by default. This feature is usually not required, +# not useful and an extreme performance hit +#$ActionFileEnableSync on + +# Include all config files in /etc/rsyslog.d/ +$IncludeConfig /etc/rsyslog.d/*.conf + +# Turn off message reception via local log socket; +# local messages are retrieved through imjournal now. +$OmitLocalLogging on + +# File to store the position in the journal +$IMJournalStateFile imjournal.state + + +#### RULES #### + +# Log all kernel messages to the console. +# Logging much else clutters up the screen. +#kern.* /dev/console + +# Log anything (except mail) of level info or higher. +# Don't log private authentication messages! +*.info;mail.none;authpriv.none;cron.none /var/log/messages + +# The authpriv file has restricted access. +authpriv.* /var/log/secure + +# Log all the mail messages in one place. +mail.* -/var/log/maillog + + +# Log cron stuff +cron.* /var/log/cron + +# Everybody gets emergency messages +*.emerg :omusrmsg:* + +# Save news errors of level crit and higher in a special file. +uucp,news.crit /var/log/spooler + +# Save boot messages also to boot.log +local7.* /var/log/boot.log + + +# ### begin forwarding rule ### +# The statement between the begin ... end define a SINGLE forwarding +# rule. They belong together, do NOT split them. If you create multiple +# forwarding rules, duplicate the whole block! +# Remote Logging (we use TCP for reliable delivery) +# +# An on-disk queue is created for this action. If the remote host is +# down, messages are spooled to disk and sent when it is up again. +#$ActionQueueFileName fwdRule1 # unique name prefix for spool files +#$ActionQueueMaxDiskSpace 1g # 1gb space limit (use as much as possible) +#$ActionQueueSaveOnShutdown on # save messages to disk on shutdown +#$ActionQueueType LinkedList # run asynchronously +#$ActionResumeRetryCount -1 # infinite retries if host is down +# remote host is: name/ip:port, e.g. 192.168.0.1:514, port optional +#*.* @@remote-host:514 +# ### end of the forwarding rule ### diff --git a/SOURCES/rsyslog.log b/SOURCES/rsyslog.log new file mode 100644 index 0000000..e4b15af --- /dev/null +++ b/SOURCES/rsyslog.log @@ -0,0 +1,12 @@ +/var/log/cron +/var/log/maillog +/var/log/messages +/var/log/secure +/var/log/spooler +{ + missingok + sharedscripts + postrotate + /bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2> /dev/null || true + endscript +} diff --git a/SOURCES/rsyslog.sysconfig b/SOURCES/rsyslog.sysconfig new file mode 100644 index 0000000..bc65731 --- /dev/null +++ b/SOURCES/rsyslog.sysconfig @@ -0,0 +1,5 @@ +# Options for rsyslogd +# Syslogd options are deprecated since rsyslog v3. +# If you want to use them, switch to compatibility mode 2 by "-c 2" +# See rsyslogd(8) for more details +SYSLOGD_OPTIONS="" diff --git a/SPECS/rsyslog.spec b/SPECS/rsyslog.spec new file mode 100644 index 0000000..9b4df2f --- /dev/null +++ b/SPECS/rsyslog.spec @@ -0,0 +1,1344 @@ +%define rsyslog_statedir %{_sharedstatedir}/rsyslog +%define rsyslog_pkidir %{_sysconfdir}/pki/rsyslog +%define rsyslog_docdir %{_docdir}/%{name}-%{version} +%if 0%{?rhel} >= 7 +%global want_hiredis 0 +%global want_mongodb 0 +%global want_rabbitmq 0 +%else +%global want_hiredis 1 +%global want_mongodb 1 +%global want_rabbitmq 1 +%endif + +Summary: Enhanced system logging and kernel message trapping daemon +Name: rsyslog +Version: 8.24.0 +Release: 16%{?dist} +License: (GPLv3+ and ASL 2.0) +Group: System Environment/Daemons +ExcludeArch: i686 ppc s390 +URL: http://www.rsyslog.com/ +Source0: http://www.rsyslog.com/files/download/rsyslog/%{name}-%{version}.tar.gz +Source1: http://www.rsyslog.com/files/download/rsyslog/%{name}-doc-%{version}.tar.gz +Source2: rsyslog.conf +Source3: rsyslog.sysconfig +Source4: rsyslog.log + +BuildRequires: automake +BuildRequires: autoconf +BuildRequires: libtool +BuildRequires: bison +BuildRequires: flex +BuildRequires: libfastjson-devel +BuildRequires: libestr-devel >= 0.1.9 +BuildRequires: libuuid-devel +BuildRequires: pkgconfig +BuildRequires: python-docutils +BuildRequires: python-sphinx +# it depens on rhbz#1419228 +BuildRequires: systemd-devel >= 219-39 +BuildRequires: zlib-devel + +Requires: logrotate >= 3.5.2 +Requires: bash >= 2.0 +Requires: libestr >= 0.1.9 +Requires(post): systemd +Requires(preun): systemd +Requires(postun): systemd + +Provides: syslog +Obsoletes: sysklogd < 1.5-11 + +# tweak the upstream service file to honour configuration from /etc/sysconfig/rsyslog +Patch0: rsyslog-8.24.0-sd-service.patch +Patch1: rsyslog-8.24.0-msg_c_nonoverwrite_merge.patch +#Patch2: rsyslog-8.24.0-rhbz1188503-imjournal-default-tag.patch + +Patch3: rsyslog-8.24.0-rhbz1303617-imfile-wildcards.patch +Patch4: rsyslog-8.24.0-doc-polling-by-default.patch +Patch5: rsyslog-8.24.0-rhbz1399569-flushontxend.patch +Patch6: rsyslog-8.24.0-rhbz1400594-tls-config.patch +Patch7: rsyslog-8.24.0-rhbz1401870-watermark.patch + +Patch8: rsyslog-8.24.0-rhbz1403831-missing-cmd-line-switches.patch +Patch9: rsyslog-8.24.0-rhbz1245194-imjournal-ste-file.patch +Patch10: rsyslog-8.24.0-rhbz1507028-recover_qi-doc.patch +Patch11: rsyslog-8.24.0-rhbz1088021-systemd-time-backwards.patch +Patch12: rsyslog-8.24.0-rhbz1403907-imudp-deprecated-parameter.patch +Patch13: rsyslog-8.24.0-rhbz1196230-ratelimit-add-source.patch +Patch14: rsyslog-8.24.0-rhbz1422789-missing-chdir-w-chroot.patch +Patch15: rsyslog-8.24.0-rhbz1422414-glbDoneLoadCnf-segfault.patch +Patch16: rsyslog-8.24.0-rhbz1427828-set-unset-not-checking-varName.patch + +Patch17: rsyslog-8.24.0-rhbz1427821-backport-num2ipv4.patch +Patch18: rsyslog-8.24.0-rhbz1427821-str2num-emty-string-handle.patch + +Patch19: rsyslog-8.24.0-rhbz1165236-snmp-mib.patch +Patch20: rsyslog-8.24.0-rhbz1419228-journal-switch-persistent.patch +Patch21: rsyslog-8.24.0-rhbz1431616-pmrfc3164sd-backport.patch + +Patch22: rsyslog-8.24.0-rhbz1056548-getaddrinfo.patch + +Patch23: rsyslog-8.24.0-rhbz1401456-sd-service-network.patch +Patch24: rsyslog-8.24.0-rhbz1459896-queues-defaults-doc.patch +Patch25: rsyslog-8.24.0-rhbz1497985-journal-reloaded-message.patch +Patch26: rsyslog-8.24.0-rhbz1462160-set.statement-crash.patch +Patch27: rsyslog-8.24.0-rhbz1488186-fixed-nullptr-check.patch +Patch28: rsyslog-8.24.0-rhbz1505103-omrelp-rebindinterval.patch + +%package crypto +Summary: Encryption support +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: libgcrypt-devel + +%package doc +Summary: HTML Documentation for rsyslog +Group: Documentation +#no reason to have arched documentation +BuildArch: noarch + +%package elasticsearch +Summary: ElasticSearch output module for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: libcurl-devel + +%if %{want_hiredis} +%package hiredis +Summary: Redis support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: hiredis-devel +%endif + +%package mmjsonparse +Summary: JSON enhanced logging support +Group: System Environment/Daemons +Requires: %name = %version-%release + +%package mmnormalize +Summary: Log normalization support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: libee-devel liblognorm-devel + +%package mmaudit +Summary: Message modification module supporting Linux audit format +Group: System Environment/Daemons +Requires: %name = %version-%release + +%package mmsnmptrapd +Summary: Message modification module for snmptrapd generated messages +Group: System Environment/Daemons +Requires: %name = %version-%release + +%package libdbi +Summary: Libdbi database support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: libdbi-devel + +%package mysql +Summary: MySQL support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: mysql >= 4.0 +BuildRequires: mysql-devel >= 4.0 + +%if %{want_mongodb} +%package mongodb +Summary: MongoDB support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: libmongo-client-devel +%endif + +%package pgsql +Summary: PostgresSQL support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: postgresql-devel + +%if %{want_rabbitmq} +%package rabbitmq +Summary: RabbitMQ support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: librabbitmq-devel >= 0.2 +%endif + +%package gssapi +Summary: GSSAPI authentication and encryption support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: krb5-devel + +%package relp +Summary: RELP protocol support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +Requires: librelp >= 1.0.3 +BuildRequires: librelp-devel >= 1.0.3 + +%package gnutls +Summary: TLS protocol support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: gnutls-devel + +%package snmp +Summary: SNMP protocol support for rsyslog +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: net-snmp-devel + +%package udpspoof +Summary: Provides the omudpspoof module +Group: System Environment/Daemons +Requires: %name = %version-%release +BuildRequires: libnet-devel + +%description +Rsyslog is an enhanced, multi-threaded syslog daemon. It supports MySQL, +syslog/TCP, RFC 3195, permitted sender lists, filtering on any message part, +and fine grain output format control. It is compatible with stock sysklogd +and can be used as a drop-in replacement. Rsyslog is simple to set up, with +advanced features suitable for enterprise-class, encryption-protected syslog +relay chains. + +%description crypto +This package contains a module providing log file encryption and a +command line tool to process encrypted logs. + +%description doc +This subpackage contains documentation for rsyslog. + +%description elasticsearch +This module provides the capability for rsyslog to feed logs directly into +Elasticsearch. + +%if %{want_hiredis} +%description hiredis +This module provides output to Redis. +%endif + +%description mmjsonparse +This module provides the capability to recognize and parse JSON enhanced +syslog messages. + +%description mmnormalize +This module provides the capability to normalize log messages via liblognorm. + +%description mmaudit +This module provides message modification supporting Linux audit format +in various settings. + +%description mmsnmptrapd +This message modification module takes messages generated from snmptrapd and +modifies them so that they look like they originated from the read originator. + +%description libdbi +This module supports a large number of database systems via +libdbi. Libdbi abstracts the database layer and provides drivers for +many systems. Drivers are available via the libdbi-drivers project. + +%description mysql +The rsyslog-mysql package contains a dynamic shared object that will add +MySQL database support to rsyslog. + +%if %{want_mongodb} +%description mongodb +The rsyslog-mongodb package contains a dynamic shared object that will add +MongoDB database support to rsyslog. +%endif + +%description pgsql +The rsyslog-pgsql package contains a dynamic shared object that will add +PostgreSQL database support to rsyslog. + +%if %{want_rabbitmq} +%description rabbitmq +This module allows rsyslog to send messages to a RabbitMQ server. +%endif + +%description gssapi +The rsyslog-gssapi package contains the rsyslog plugins which support GSSAPI +authentication and secure connections. GSSAPI is commonly used for Kerberos +authentication. + +%description relp +The rsyslog-relp package contains the rsyslog plugins that provide +the ability to receive syslog messages via the reliable RELP +protocol. + +%description gnutls +The rsyslog-gnutls package contains the rsyslog plugins that provide the +ability to receive syslog messages via upcoming syslog-transport-tls +IETF standard protocol. + +%description snmp +The rsyslog-snmp package contains the rsyslog plugin that provides the +ability to send syslog messages as SNMPv1 and SNMPv2c traps. + +%description udpspoof +This module is similar to the regular UDP forwarder, but permits to +spoof the sender address. Also, it enables to circle through a number +of source ports. + +%prep +# set up rsyslog-doc sources +%setup -q -a 1 -T -c +%patch4 -p1 +%patch10 -p1 +%patch24 -p1 +#regenerate the docs +mv build/searchindex.js searchindex_backup.js +sphinx-build -b html source build +#clean up +mv searchindex_backup.js build/searchindex.js +rm -r LICENSE README.md build.sh source build/objects.inv +mv build doc + +# set up rsyslog sources +%setup -q -D + +%patch0 -p1 -b .service +%patch1 -p1 -b .msg_merge +#%patch2 is obsoleted by patch25 +%patch3 -p1 -b .wildcards +#%patch4 is applied right after doc setup + +%patch5 -p1 -b .flushontxend +%patch6 -p1 -b .tls-config +%patch7 -p1 -b .watermark + +%patch8 -p1 -b .missg-cmd-line-switches +%patch9 -p1 -b .ste-file +#%patch10 is applied right after doc setup +%patch11 -p1 -b .systemd-time +%patch12 -p1 -b .imudp-deprecated-parameter +%patch13 -p1 -b .ratelimit-add-source +%patch14 -p1 -b .missing-chdir-w-chroot +%patch15 -p1 -b .glbDoneLoadCnf-segfault +%patch16 -p1 -b .set-unset-check-varName + +%patch17 -p1 -b .num2ipv4 +%patch18 -p1 -b .str2num-handle-emty-strings +%patch19 -p1 -b .snmp-mib +%patch20 -p1 -b .journal-switch +%patch21 -p1 -b .pmrfc3164sd +%patch22 -p1 -b .getaddrinfo + +%patch23 -p1 -b .sd-service-network +#%%patch24 is applied right after doc setup +%patch25 -p1 -b .journal-reloaded +%patch26 -p1 -b .set-statement-crash +%patch27 -p1 -b .nullptr-check +%patch28 -p1 -b .rebindinterval + +autoreconf + +%build +%ifarch sparc64 +#sparc64 need big PIE +export CFLAGS="$RPM_OPT_FLAGS -fPIE -DPATH_PIDFILE=\\\"/var/run/syslogd.pid\\\"" +export LDFLAGS="-pie -Wl,-z,relro -Wl,-z,now" +%else +export CFLAGS="$RPM_OPT_FLAGS -fpie -DPATH_PIDFILE=\\\"/var/run/syslogd.pid\\\"" +export LDFLAGS="-pie -Wl,-z,relro -Wl,-z,now" +%endif + +%if %{want_hiredis} +# the hiredis-devel package doesn't provide a pkg-config file +export HIREDIS_CFLAGS=-I/usr/include/hiredis +export HIREDIS_LIBS=-L%{_libdir} +%endif +%configure \ + --prefix=/usr \ + --disable-static \ + --disable-testbench \ + --disable-liblogging-stdlog \ + --enable-elasticsearch \ + --enable-generate-man-pages \ + --enable-gnutls \ + --enable-gssapi-krb5 \ + --enable-imdiag \ + --enable-imfile \ + --enable-imjournal \ + --enable-impstats \ + --enable-imptcp \ + --enable-libdbi \ + --enable-mail \ + --enable-mmanon \ + --enable-mmaudit \ + --enable-mmcount \ + --enable-mmjsonparse \ + --enable-mmnormalize \ + --enable-mmsnmptrapd \ + --enable-mmutf8fix \ + --enable-mysql \ +%if %{want_hiredis} + --enable-omhiredis \ +%endif + --enable-omjournal \ +%if %{want_mongodb} + --enable-ommongodb \ +%endif + --enable-omprog \ +%if %{want_rabbitmq} + --enable-omrabbitmq \ +%endif + --enable-omruleset \ + --enable-omstdout \ + --enable-omudpspoof \ + --enable-omuxsock \ + --enable-pgsql \ + --enable-pmaixforwardedfrom \ + --enable-pmcisconames \ + --enable-pmlastmsg \ + --enable-pmrfc3164sd \ + --enable-pmsnare \ + --enable-relp \ + --enable-snmp \ + --enable-unlimited-select \ + --enable-usertools \ + +make + +%install +make DESTDIR=%{buildroot} install + +install -d -m 755 %{buildroot}%{_sysconfdir}/sysconfig +install -d -m 755 %{buildroot}%{_sysconfdir}/logrotate.d +install -d -m 755 %{buildroot}%{_sysconfdir}/rsyslog.d +install -d -m 700 %{buildroot}%{rsyslog_statedir} +install -d -m 700 %{buildroot}%{rsyslog_pkidir} +install -d -m 755 %{buildroot}%{rsyslog_docdir}/html + +install -p -m 644 %{SOURCE2} %{buildroot}%{_sysconfdir}/rsyslog.conf +install -p -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/sysconfig/rsyslog +install -p -m 644 %{SOURCE4} %{buildroot}%{_sysconfdir}/logrotate.d/syslog +install -p -m 644 plugins/ommysql/createDB.sql %{buildroot}%{rsyslog_docdir}/mysql-createDB.sql +install -p -m 644 plugins/ompgsql/createDB.sql %{buildroot}%{rsyslog_docdir}/pgsql-createDB.sql +# extract documentation +cp -r doc/* %{buildroot}%{rsyslog_docdir}/html +# get rid of libtool libraries +rm -f %{buildroot}%{_libdir}/rsyslog/*.la +# get rid of socket activation by default +sed -i '/^Alias/s/^/;/;/^Requires=syslog.socket/s/^/;/' %{buildroot}%{_unitdir}/rsyslog.service + +# convert line endings from "\r\n" to "\n" +cat tools/recover_qi.pl | tr -d '\r' > %{buildroot}%{_bindir}/rsyslog-recover-qi.pl + +%post +for n in /var/log/{messages,secure,maillog,spooler} +do + [ -f $n ] && continue + umask 066 && touch $n +done +%systemd_post rsyslog.service + +%preun +%systemd_preun rsyslog.service + +%postun +%systemd_postun_with_restart rsyslog.service + +%files +%defattr(-,root,root,-) +%doc AUTHORS COPYING* ChangeLog +%exclude %{rsyslog_docdir}/html +%exclude %{rsyslog_docdir}/mysql-createDB.sql +%exclude %{rsyslog_docdir}/pgsql-createDB.sql +%dir %{_libdir}/rsyslog +%dir %{_sysconfdir}/rsyslog.d +%dir %{rsyslog_statedir} +%dir %{rsyslog_pkidir} +%{_sbindir}/rsyslogd +%attr(755,root,root) %{_bindir}/rsyslog-recover-qi.pl +%{_mandir}/man5/rsyslog.conf.5.gz +%{_mandir}/man8/rsyslogd.8.gz +%{_unitdir}/rsyslog.service +%config(noreplace) %{_sysconfdir}/rsyslog.conf +%config(noreplace) %{_sysconfdir}/sysconfig/rsyslog +%config(noreplace) %{_sysconfdir}/logrotate.d/syslog +# plugins +%{_libdir}/rsyslog/imdiag.so +%{_libdir}/rsyslog/imfile.so +%{_libdir}/rsyslog/imjournal.so +%{_libdir}/rsyslog/imklog.so +%{_libdir}/rsyslog/immark.so +%{_libdir}/rsyslog/impstats.so +%{_libdir}/rsyslog/imptcp.so +%{_libdir}/rsyslog/imtcp.so +%{_libdir}/rsyslog/imudp.so +%{_libdir}/rsyslog/imuxsock.so +%{_libdir}/rsyslog/lmnet.so +%{_libdir}/rsyslog/lmnetstrms.so +%{_libdir}/rsyslog/lmnsd_ptcp.so +%{_libdir}/rsyslog/lmregexp.so +%{_libdir}/rsyslog/lmstrmsrv.so +%{_libdir}/rsyslog/lmtcpclt.so +%{_libdir}/rsyslog/lmtcpsrv.so +%{_libdir}/rsyslog/lmzlibw.so +%{_libdir}/rsyslog/mmanon.so +%{_libdir}/rsyslog/mmcount.so +%{_libdir}/rsyslog/mmexternal.so +%{_libdir}/rsyslog/mmutf8fix.so +%{_libdir}/rsyslog/omjournal.so +%{_libdir}/rsyslog/ommail.so +%{_libdir}/rsyslog/omprog.so +%{_libdir}/rsyslog/omruleset.so +%{_libdir}/rsyslog/omstdout.so +%{_libdir}/rsyslog/omtesting.so +%{_libdir}/rsyslog/omuxsock.so +%{_libdir}/rsyslog/pmaixforwardedfrom.so +%{_libdir}/rsyslog/pmcisconames.so +%{_libdir}/rsyslog/pmlastmsg.so +%{_libdir}/rsyslog/pmrfc3164sd.so +%{_libdir}/rsyslog/pmsnare.so + +%files crypto +%defattr(-,root,root) +%{_bindir}/rscryutil +%{_mandir}/man1/rscryutil.1.gz +%{_libdir}/rsyslog/lmcry_gcry.so + +%files doc +%defattr(-,root,root) +%doc %{rsyslog_docdir}/html + +%files elasticsearch +%defattr(-,root,root) +%{_libdir}/rsyslog/omelasticsearch.so + +%if %{want_hiredis} +%files hiredis +%defattr(-,root,root) +%{_libdir}/rsyslog/omhiredis.so +%endif + +%files libdbi +%defattr(-,root,root) +%{_libdir}/rsyslog/omlibdbi.so + +%files mmaudit +%defattr(-,root,root) +%{_libdir}/rsyslog/mmaudit.so + +%files mmjsonparse +%defattr(-,root,root) +%{_libdir}/rsyslog/mmjsonparse.so + +%files mmnormalize +%defattr(-,root,root) +%{_libdir}/rsyslog/mmnormalize.so + +%files mmsnmptrapd +%defattr(-,root,root) +%{_libdir}/rsyslog/mmsnmptrapd.so + +%files mysql +%defattr(-,root,root) +%doc %{rsyslog_docdir}/mysql-createDB.sql +%{_libdir}/rsyslog/ommysql.so + +%if %{want_mongodb} +%files mongodb +%defattr(-,root,root) +%{_bindir}/logctl +%{_libdir}/rsyslog/ommongodb.so +%endif + +%files pgsql +%defattr(-,root,root) +%doc %{rsyslog_docdir}/pgsql-createDB.sql +%{_libdir}/rsyslog/ompgsql.so + +%if %{want_rabbitmq} +%files rabbitmq +%defattr(-,root,root) +%{_libdir}/rsyslog/omrabbitmq.so +%endif + +%files gssapi +%defattr(-,root,root) +%{_libdir}/rsyslog/lmgssutil.so +%{_libdir}/rsyslog/imgssapi.so +%{_libdir}/rsyslog/omgssapi.so + +%files relp +%defattr(-,root,root) +%{_libdir}/rsyslog/imrelp.so +%{_libdir}/rsyslog/omrelp.so + +%files gnutls +%defattr(-,root,root) +%{_libdir}/rsyslog/lmnsd_gtls.so + +%files snmp +%defattr(-,root,root) +%{_libdir}/rsyslog/omsnmp.so + +%files udpspoof +%defattr(-,root,root) +%{_libdir}/rsyslog/omudpspoof.so + +%changelog +* Thu Nov 09 2017 Jiri Vymazal - 8.24.0-16 +RHEL 7.5 ERRATUM +- edited the patch to conform to latest upstream doc + resolves: rhbz#1459896 (failedQA) +- disabled 32-bit builds on all arches as they are not shipped + anymore in RHEL7 + +* Tue Oct 31 2017 Jiri Vymazal - 8.24.0-15 +RHEL 7.5 ERRATUM +- made rsyslog-doc noarch and fixed search on doc regeneration + resolves: rhbz#1507028 + +* Tue Oct 31 2017 Jiri Vymazal - 8.24.0-14 +RHEL 7.5 ERRATUM +- renamed patch for undocumented recover_qi script to correct bz number + resolves: rhbz#1507028 +- added patch ensuring relp conneciton is active before closing it + resolves: rhbz#1505103 + +* Mon Oct 09 2017 Jiri Vymazal - 8.24.0-13 +RHEL 7.5 ERRATUM +- added patch to properly resolve FQDN + resolves: rhbz#1401456 +- added documentation patch correcting qeues default values + resolves: rhbz#1459896 +- added patch adjusting log level of journal reloaded msg + resolves: rhbz#1497985 +- added patch to prevent crash with invalid set statement + this also obsoletes patch2 (for 1188503) + resolves: rhbz#1462160 +- added patch with nullptr check to prevent ABRT + resolves: rhbz#1488186 + +* Wed May 10 2017 Radovan Sroka - 8.24.0-12 +- added BuildRequires for systemd >= 219-39 depends on rhbz#1419228 + +* Tue May 09 2017 Radovan Sroka - 8.24.0-11 +RHEL 7.4 ERRATUM +- added new patch that backports num2ipv4 due to rhbz#1427821 + resolves: rhbz#1427821 +- enable pmrfc3164sd module + resolves: rhbz#1431616 + +* Wed May 03 2017 Jiri Vymazal - 8.24.0-10 +RHEL 7.4 ERRATUM +- edited patches Patch19 and Patch21 + resolves: rhbz#1419228(coverity scan problems) + resolves: rhbz#1056548(failed QA, coverity scan problems) + +* Tue May 02 2017 Jiri Vymazal - 8.24.0-9 +RHEL 7.4 ERRATUM +- added autoreconf call +- added patch to replace gethostbyname with getaddrinfo call + resolves: rhbz#1056548(failed QA) + +* Wed Apr 19 2017 Radovan Sroka - 8.24.0-8 +RHEL 7.4 ERRATUM +- added dependency automake autoconf libtool due to yum-builddep +- reenable omruleset module + resolves: rhbz#1431615 + resolves: rhbz#1428403 + resolves: rhbz#1427821(fix regression, failed QA) + resolves: rhbz#1432069 +- resolves: rhbz#1165236 + resolves: rhbz#1419228 + resolves: rhbz#1431616 + resolves: rhbz#1196230(failed QA) + +* Thu Mar 02 2017 Radovan Sroka - 8.24.0-7 +- reverted logrotate file that was added by mistake + +* Wed Mar 01 2017 Radovan Sroka - 8.24.0-6 +- RHEL 7.4 ERRATUM +- rsyslog rebase to 8.24 +- added patch to prevent segfault while setting aclResolveHostname + config options + resolves: rhbz#1422414 +- added patch to check config variable names at startup + resolves: rhbz#1427828 +- added patch for str2num to handle empty strings + resolves: rhbz#1427821 +- fixed typo in added-chdir patch + resolves: rhbz#1422789 +- added patch to log source process when beginning rate-limiting + resolves: rhbz#1196230 +- added patch to chdir after chroot + resolves: rhbz#1422789 +- added patch to remove "inputname" imudp module parameter + deprecation warnings + resolves: rhbz#1403907 +- added patch which resolves situation when time goes backwards + and statefile is invalid + resolves rhbz#1088021 +- added a patch to bring back deprecated cmd-line switches and + remove associated warnings + resolves: rhbz#1403831 +- added documentation recover_qi.pl + resolves: rhbz#1286707 +- add another setup for doc package +- add --enable-generate-man-pages to configure parameters; + the rscryutil man page isn't generated without it + https://github.com/rsyslog/rsyslog/pull/469 +- enable mmcount, mmexternal modules +- remove omruleset and pmrfc3164sd modules + +* Thu Jul 14 2016 Tomas Heinrich 7.4.7-16 +- add a patch to prevent races in libjson-c calls + resolves: rhbz#1222746 + +* Sun Jul 10 2016 Tomas Heinrich 7.4.7-15 +- add a patch to make state file handling in imjournal more robust + resolves: rhbz#1245194 +- add a patch to support wildcards in imfile + resolves: rhbz#1303617 + +* Fri May 20 2016 Tomas Heinrich 7.4.7-14 +- add a patch to prevent loss of partial messages + resolves: rhbz#1312459 +- add a patch to allow multiple rulesets in imrelp + resolves: rhbz#1223566 +- add a patch to fix a race condition during shutdown + resolves: rhbz#1295798 +- add a patch to backport the mmutf8fix plugin + resolves: rhbz#1146237 +- add a patch to order service startup after the network + resolves: rhbz#1263853 + +* Mon May 16 2016 Tomas Heinrich 7.4.7-13 +- add a patch to prevent crashes when using multiple rulesets + resolves: rhbz#1224336 +- add a patch to keep the imjournal state file updated + resolves: rhbz#1216957 +- add a patch to fix an undefined behavior caused by the maxMessageSize directive + resolves: rhbz#1214257 +- add a patch to prevent crashes when using rulesets with a parser + resolves: rhbz#1282687 + +* Fri Aug 28 2015 Tomas Heinrich 7.4.7-12 +- amend the patch for rhbz#1151041 + resolves: rhbz#1257150 + +* Tue Aug 18 2015 Radovan Sroka 7.4.7-11 +- add patch that resolves config.guess system-recognition on ppc64le architecture + resolves: rhbz:1254511 + +* Mon Aug 03 2015 Tomas Heinrich 7.4.7-10 +- add a patch to prevent field truncation in imjournal + resolves: rhbz#1101602 +- add a patch to enable setting a default TAG + resolves: rhbz#1188503 +- add a patch to fix a nonfunction hostname setting in imuxsock + resolves: rhbz#1184402 + +* Mon Jul 20 2015 Tomas Heinrich 7.4.7-9 +- update the patch fixing a race condition in directory creation + resolves: rhbz#1202489 +- improve provided documentation + - move documentation from all subpackages under a single directory + - add missing images + - remove doc files without content + - add a patch making various corrections to the HTML documentation + resolves: rhbz#1238713 +- add a patch to prevent division-by-zero errors + resolves: rhbz#1078878 +- add a patch to clarify usage of the SysSock.Use option + resolves: rhbz#1143846 +- add a patch to support arbitrary number of listeners in imuxsock + - drop patch for rhbz#1053669 as it has been merged into this one + resolves: rhbz#1151041 + +* Fri Jul 03 2015 Tomas Heinrich 7.4.7-8 +- modify the service file to automatically restart rsyslog on failure + resolves: rhbz#1061322 +- add explicitly versioned dependencies on libraries which do not have + correctly versioned sonames + resolves: rhbz#1107839 +- make logrotate tolerate missing log files + resolves: rhbz#1144465 +- backport the mmcount plugin + resolves: rhbz#1151037 +- set the default service umask to 0066 + resolves: rhbz#1228192 +- add a patch to make imjournal sanitize messages as imuxsock does it + resolves: rhbz#743890 +- add a patch to fix a bug preventing certain imuxsock directives from + taking effect + resolves: rhbz#1184410 +- add a patch to fix a race condition in directory creation + resolves: rhbz#1202489 + +* Tue Oct 07 2014 Tomas Heinrich 7.4.7-7 +- fix CVE-2014-3634 + resolves: #1149153 + +* Wed Mar 26 2014 Tomas Heinrich 7.4.7-6 +- disable the imklog plugin by default + the patch for rhbz#1038136 caused duplication of kernel messages since the + messages read by the imklog plugin were now also pulled in from journald + resolves: #1078654 + +* Wed Feb 19 2014 Tomas Heinrich 7.4.7-5 +- move the rscryutil man page to the crypto subpackage + resolves: #1056565 +- add a patch to prevent message loss in imjournal + rsyslog-7.4.7-bz1038136-imjournal-message-loss.patch + resolves: #1038136 + +* Fri Jan 24 2014 Daniel Mach - 7.4.7-4 +- Mass rebuild 2014-01-24 + +* Mon Jan 20 2014 Tomas Heinrich 7.4.7-3 +- replace rsyslog-7.3.15-imuxsock-warning.patch + with rsyslog-7.4.7-bz1053669-imuxsock-wrn.patch + resolves: #1053669 +- add rsyslog-7.4.7-bz1052266-dont-link-libee.patch to prevent + linking the main binary with libee + resolves: #1052266 +- add rsyslog-7.4.7-bz1054171-omjournal-warning.patch to fix + a condition for issuing a warning in omjournal + resolves: #1054171 +- drop the "v5" string from the conf file as it's misleading + resolves: #1040036 + +* Wed Jan 15 2014 Honza Horak - 7.4.7-2 +- Rebuild for mariadb-libs + Related: #1045013 + +* Mon Jan 06 2014 Tomas Heinrich 7.4.7-1 +- rebase to 7.4.7 + add requirement on libestr >= 0.1.9 + resolves: #836485 + resolves: #1020854 + resolves: #1040036 +- drop patch 4; not needed anymore + rsyslog-7.4.2-imuxsock-rfc3339.patch +- install the rsyslog-recover-qi.pl tool +- fix a typo in a package description +- add missing defattr directives +- add a patch to remove references to Google ads in the html docs + rsyslog-7.4.7-bz1030044-remove-ads.patch + Resolves: #1030043 +- add a patch to allow numeric specification of UIDs/GUIDs + rsyslog-7.4.7-numeric-uid.patch + resolves: #1032198 +- change the installation prefix to "/usr" + resolves: #1032223 +- fix a bad date in the changelog + resolves: #1043622 +- resolve a build issue with missing mysql_config by adding + additional BuildRequires for the mysql package +- add a patch to resolve build issue on ppc + rsyslog-7.4.7-omelasticsearch-atomic-inst.patch + +* Fri Dec 27 2013 Daniel Mach - 7.4.2-5 +- Mass rebuild 2013-12-27 + +* Wed Nov 06 2013 Tomas Heinrich 7.4.2-4 +- add a patch to fix issues with rfc 3339 timestamp parsing + resolves: #1020826 + +* Fri Jul 12 2013 Jan Safranek - 7.4.2-3 +- Rebuilt for new net-snmp + +* Wed Jul 10 2013 Tomas Heinrich 7.4.2-2 +- make compilation of the rabbitmq plugin optional + resolves: #978919 + +* Tue Jul 09 2013 Tomas Heinrich 7.4.2-1 +- rebase to 7.4.2 + most importantly, this release fixes a potential vulnerability, + see http://www.lsexperts.de/advisories/lse-2013-07-03.txt + the impact should be low as only those using the omelasticsearch + plugin with a specific configuration are exposed + +* Mon Jun 17 2013 Tomas Heinrich 7.4.1-1 +- rebase to 7.4.1 + this release adds code that somewhat mitigates damage in cases + where large amounts of messages are received from systemd + journal (see rhbz#974132) +- regenerate patch 0 +- drop patches merged upstream: 4..8 +- add a dependency on the version of systemd which resolves the bug + mentioned above +- update option name in rsyslog.conf + +* Wed Jun 12 2013 Tomas Heinrich 7.4.0-1 +- rebase to 7.4.0 +- drop autoconf automake libtool from BuildRequires +- depends on systemd >= 201 because of the sd_journal_get_events() api +- add a patch to prevent a segfault in imjournal caused by a bug in + systemd journal +- add a patch to prevent an endless loop in the ratelimiter +- add a patch to prevent another endless loop in the ratelimiter +- add a patch to prevent a segfault in imjournal for undefined state file +- add a patch to correctly reset state in the ratelimiter + +* Tue Jun 04 2013 Tomas Heinrich 7.3.15-1.20130604git6e72fa6 +- rebase to an upstream snapshot, effectively version 7.3.15 + plus several more changes +- drop patches 3, 4 - merged upstream +- add a patch to silence warnings emitted by the imuxsock module +- drop the imkmsg plugin +- enable compilation of additional modules + imjournal, mmanon, omjournal, omrabbitmq +- new subpackages: crypto, rabbitmq +- add python-docutils and autoconf to global BuildRequires +- drop the option for backwards compatibility from the + sysconfig file - it is no longer supported +- call autoreconf to prepare the snapshot for building +- switch the local message source from imuxsock to imjournal + the imuxsock module is left enabled so it is easy to swich back to + it and because systemd drops a file into /etc/rsyslog.d which only + imuxsock can parse + +* Wed Apr 10 2013 Tomas Heinrich 7.3.10-1 +- rebase to 7.3.10 +- add a patch to resolve #950088 - ratelimiter segfault, merged upstream + rsyslog-7.3.10-ratelimit-segv.patch +- add a patch to correct a default value, merged upstream + rsyslog-7.3.10-correct-def-val.patch +- drop patch 5 - fixed upstream + +* Thu Apr 04 2013 Tomas Heinrich 7.3.9-1 +- rebase to 7.3.9 + +* Thu Feb 14 2013 Fedora Release Engineering - 7.2.5-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Mon Jan 21 2013 Tomas Heinrich 7.2.5-2 +- update a line in rsyslog.conf for the new syntax + +* Sun Jan 13 2013 Tomas Heinrich 7.2.5-1 +- upgrade to upstream version 7.2.5 +- update the compatibility mode in sysconfig file + +* Mon Dec 17 2012 Tomas Heinrich 7.2.4-2 +- add a condition to disable several subpackages + +* Mon Dec 10 2012 Tomas Heinrich 7.2.4-1 +- upgrade to upstream version 7.2.4 +- remove trailing whitespace + +* Tue Nov 20 2012 Tomas Heinrich 7.2.2-1 +- upgrade to upstream version 7.2.2 + update BuildRequires +- remove patches merged upstream + rsyslog-5.8.7-sysklogd-compat-1-template.patch + rsyslog-5.8.7-sysklogd-compat-2-option.patch + rsyslog-5.8.11-close-fd1-when-forking.patch +- add patch from Milan Bartos + rsyslog-7.2.1-msg_c_nonoverwrite_merge.patch +- remove the rsyslog-sysvinit package +- clean up BuildRequires, Requires +- remove the 'BuildRoot' tag +- split off a doc package +- compile additional modules (some of them in separate packages): + elasticsearch + hiredis + mmjsonparse + mmnormalize + mmaudit + mmsnmptrapd + mongodb +- correct impossible timestamps in older changelog entries +- correct typos, trailing spaces, etc +- s/RPM_BUILD_ROOT/{buildroot}/ +- remove the 'clean' section +- replace post* scriptlets with systemd macros + +* Sat Jul 21 2012 Fedora Release Engineering - 5.8.11-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Wed Jun 20 2012 Tomas Heinrich 5.8.11-2 +- update systemd patch: remove the 'ExecStartPre' option + +* Wed May 23 2012 Tomas Heinrich 5.8.11-1 +- upgrade to new upstream stable version 5.8.11 +- add impstats and imptcp modules +- include new license text files +- consider lock file in 'status' action +- add patch to update information on debugging in the man page +- add patch to prevent debug output to stdout after forking +- add patch to support ssl certificates with domain names longer than 128 chars + +* Fri Mar 30 2012 Jon Ciesla 5.8.7-2 +- libnet rebuild. + +* Mon Jan 23 2012 Tomas Heinrich 5.8.7-1 +- upgrade to new upstream version 5.8.7 +- change license from 'GPLv3+' to '(GPLv3+ and ASL 2.0)' + http://blog.gerhards.net/2012/01/rsyslog-licensing-update.html +- use a specific version for obsoleting sysklogd +- add patches for better sysklogd compatibility (taken from upstream) + +* Sat Jan 14 2012 Fedora Release Engineering - 5.8.6-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Tue Oct 25 2011 Tomas Heinrich 5.8.6-1 +- upgrade to new upstream version 5.8.6 +- obsolete sysklogd + Resolves: #748495 + +* Tue Oct 11 2011 Tomas Heinrich 5.8.5-3 +- modify logrotate configuration to omit boot.log + Resolves: #745093 + +* Tue Sep 06 2011 Tomas Heinrich 5.8.5-2 +- add systemd-units to BuildRequires for the _unitdir macro definition + +* Mon Sep 05 2011 Tomas Heinrich 5.8.5-1 +- upgrade to new upstream version (CVE-2011-3200) + +* Fri Jul 22 2011 Tomas Heinrich 5.8.2-3 +- move the SysV init script into a subpackage +- Resolves: 697533 + +* Mon Jul 11 2011 Tomas Heinrich 5.8.2-2 +- rebuild for net-snmp-5.7 (soname bump in libnetsnmp) + +* Mon Jun 27 2011 Tomas Heinrich 5.8.2-1 +- upgrade to new upstream version 5.8.2 + +* Mon Jun 13 2011 Tomas Heinrich 5.8.1-2 +- scriptlet correction +- use macro in unit file's path + +* Fri May 20 2011 Tomas Heinrich 5.8.1-1 +- upgrade to new upstream version +- correct systemd scriptlets (#705829) + +* Mon May 16 2011 Bill Nottingham - 5.7.9-3 +- combine triggers (as rpm will only execute one) - fixes upgrades (#699198) + +* Tue Apr 05 2011 Tomas Heinrich 5.7.10-1 +- upgrade to new upstream version 5.7.10 + +* Wed Mar 23 2011 Dan Horák - 5.7.9-2 +- rebuilt for mysql 5.5.10 (soname bump in libmysqlclient) + +* Fri Mar 18 2011 Tomas Heinrich 5.7.9-1 +- upgrade to new upstream version 5.7.9 +- enable compilation of several new modules, + create new subpackages for some of them +- integrate changes from Lennart Poettering + to add support for systemd + - add rsyslog-5.7.9-systemd.patch to tweak the upstream + service file to honour configuration from /etc/sysconfig/rsyslog + +* Fri Mar 18 2011 Dennis Gilmore - 5.6.2-3 +- sparc64 needs big PIE + +* Wed Feb 09 2011 Fedora Release Engineering - 5.6.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Mon Dec 20 2010 Tomas Heinrich 5.6.2-1 +- upgrade to new upstream stable version 5.6.2 +- drop rsyslog-5.5.7-remove_include.patch; applied upstream +- provide omsnmp module +- use correct name for lock file (#659398) +- enable specification of the pid file (#579411) +- init script adjustments + +* Wed Oct 06 2010 Tomas Heinrich 5.5.7-1 +- upgrade to upstream version 5.5.7 +- update configuration and init files for the new major version +- add several directories for storing auxiliary data +- add ChangeLog to documentation +- drop unlimited-select.patch; integrated upstream +- add rsyslog-5.5.7-remove_include.patch to fix compilation + +* Tue Sep 07 2010 Tomas Heinrich 4.6.3-2 +- build rsyslog with PIE and RELRO + +* Thu Jul 15 2010 Tomas Heinrich 4.6.3-1 +- upgrade to new upstream stable version 4.6.3 + +* Wed Apr 07 2010 Tomas Heinrich 4.6.2-1 +- upgrade to new upstream stable version 4.6.2 +- correct the default value of the OMFileFlushOnTXEnd directive + +* Thu Feb 11 2010 Tomas Heinrich 4.4.2-6 +- modify rsyslog-4.4.2-unlimited-select.patch so that + running autoreconf is not needed +- remove autoconf, automake, libtool from BuildRequires +- change exec-prefix to nil + +* Wed Feb 10 2010 Tomas Heinrich 4.4.2-5 +- remove '_smp_mflags' make argument as it seems to be + producing corrupted builds + +* Mon Feb 08 2010 Tomas Heinrich 4.4.2-4 +- redefine _libdir as it doesn't use _exec_prefix + +* Thu Dec 17 2009 Tomas Heinrich 4.4.2-3 +- change exec-prefix to / + +* Wed Dec 09 2009 Robert Scheck 4.4.2-2 +- run libtoolize to avoid errors due mismatching libtool version + +* Thu Dec 03 2009 Tomas Heinrich 4.4.2-1 +- upgrade to new upstream stable version 4.4.2 +- add support for arbitrary number of open file descriptors + +* Mon Sep 14 2009 Tomas Heinrich 4.4.1-2 +- adjust init script according to guidelines (#522071) + +* Thu Sep 03 2009 Tomas Heinrich 4.4.1-1 +- upgrade to new upstream stable version + +* Fri Aug 21 2009 Tomas Mraz - 4.2.0-3 +- rebuilt with new openssl + +* Sun Jul 26 2009 Fedora Release Engineering - 4.2.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Tue Jul 14 2009 Tomas Heinrich 4.2.0-1 +- upgrade + +* Mon Apr 13 2009 Tomas Heinrich 3.21.11-1 +- upgrade + +* Tue Mar 31 2009 Lubomir Rintel 3.21.10-4 +- Backport HUPisRestart option + +* Wed Mar 18 2009 Tomas Heinrich 3.21.10-3 +- fix variables' type conversion in expression-based filters (#485937) + +* Wed Feb 25 2009 Fedora Release Engineering - 3.21.10-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + +* Tue Feb 10 2009 Tomas Heinrich 3.21.10-1 +- upgrade + +* Sat Jan 24 2009 Caolán McNamara 3.21.9-3 +- rebuild for dependencies + +* Wed Jan 07 2009 Tomas Heinrich 3.21.9-2 +- fix several legacy options handling +- fix internal message output (#478612) + +* Mon Dec 15 2008 Peter Vrabec 3.21.9-1 +- update is fixing $AllowedSender security issue + +* Mon Sep 15 2008 Peter Vrabec 3.21.3-4 +- use RPM_OPT_FLAGS +- use same pid file and logrotate file as syslog-ng (#441664) +- mark config files as noreplace (#428155) + +* Mon Sep 01 2008 Tomas Heinrich 3.21.3-3 +- fix a wrong module name in the rsyslog.conf manual page (#455086) +- expand the rsyslog.conf manual page (#456030) + +* Thu Aug 28 2008 Tomas Heinrich 3.21.3-2 +- fix clock rollback issue (#460230) + +* Wed Aug 20 2008 Peter Vrabec 3.21.3-1 +- upgrade to bugfix release + +* Wed Jul 23 2008 Peter Vrabec 3.21.0-1 +- upgrade + +* Mon Jul 14 2008 Peter Vrabec 3.19.9-2 +- adjust default config file + +* Fri Jul 11 2008 Lubomir Rintel 3.19.9-1 +- upgrade + +* Wed Jun 25 2008 Peter Vrabec 3.19.7-3 +- rebuild because of new gnutls + +* Fri Jun 13 2008 Peter Vrabec 3.19.7-2 +- do not translate Oopses (#450329) + +* Fri Jun 13 2008 Peter Vrabec 3.19.7-1 +- upgrade + +* Wed May 28 2008 Peter Vrabec 3.19.4-1 +- upgrade + +* Mon May 26 2008 Peter Vrabec 3.19.3-1 +- upgrade to new upstream release + +* Wed May 14 2008 Tomas Heinrich 3.16.1-1 +- upgrade + +* Tue Apr 08 2008 Peter Vrabec 3.14.1-5 +- prevent undesired error description in legacy + warning messages + +* Tue Apr 08 2008 Peter Vrabec 3.14.1-4 +- adjust symbol lookup method to 2.6 kernel + +* Tue Apr 08 2008 Peter Vrabec 3.14.1-3 +- fix segfault of expression based filters + +* Mon Apr 07 2008 Peter Vrabec 3.14.1-2 +- init script fixes (#441170,#440968) + +* Fri Apr 04 2008 Peter Vrabec 3.14.1-1 +- upgrade + +* Tue Mar 25 2008 Peter Vrabec 3.12.4-1 +- upgrade + +* Wed Mar 19 2008 Peter Vrabec 3.12.3-1 +- upgrade +- fix some significant memory leaks + +* Tue Mar 11 2008 Peter Vrabec 3.12.1-2 +- init script fixes (#436854) +- fix config file parsing (#436722) + +* Thu Mar 06 2008 Peter Vrabec 3.12.1-1 +- upgrade + +* Wed Mar 05 2008 Peter Vrabec 3.12.0-1 +- upgrade + +* Mon Feb 25 2008 Peter Vrabec 3.11.5-1 +- upgrade + +* Fri Feb 01 2008 Peter Vrabec 3.11.0-1 +- upgrade to the latests development release +- provide PostgresSQL support +- provide GSSAPI support + +* Mon Jan 21 2008 Peter Vrabec 2.0.0-7 +- change from requires sysklogd to conflicts sysklogd + +* Fri Jan 18 2008 Peter Vrabec 2.0.0-6 +- change logrotate file +- use rsyslog own pid file + +* Thu Jan 17 2008 Peter Vrabec 2.0.0-5 +- fixing bad descriptor (#428775) + +* Wed Jan 16 2008 Peter Vrabec 2.0.0-4 +- rename logrotate file + +* Wed Jan 16 2008 Peter Vrabec 2.0.0-3 +- fix post script and init file + +* Wed Jan 16 2008 Peter Vrabec 2.0.0-2 +- change pid filename and use logrotata script from sysklogd + +* Tue Jan 15 2008 Peter Vrabec 2.0.0-1 +- upgrade to stable release +- spec file clean up + +* Wed Jan 02 2008 Peter Vrabec 1.21.2-1 +- new upstream release + +* Thu Dec 06 2007 Release Engineering - 1.19.11-2 +- Rebuild for deps + +* Thu Nov 29 2007 Peter Vrabec 1.19.11-1 +- new upstream release +- add conflicts (#400671) + +* Mon Nov 19 2007 Peter Vrabec 1.19.10-1 +- new upstream release + +* Wed Oct 03 2007 Peter Vrabec 1.19.6-3 +- remove NUL character from recieved messages + +* Tue Sep 25 2007 Tomas Heinrich 1.19.6-2 +- fix message suppression (303341) + +* Tue Sep 25 2007 Tomas Heinrich 1.19.6-1 +- upstream bugfix release + +* Tue Aug 28 2007 Peter Vrabec 1.19.2-1 +- upstream bugfix release +- support for negative app selector, patch from + theinric@redhat.com + +* Fri Aug 17 2007 Peter Vrabec 1.19.0-1 +- new upstream release with MySQL support(as plugin) + +* Wed Aug 08 2007 Peter Vrabec 1.18.1-1 +- upstream bugfix release + +* Mon Aug 06 2007 Peter Vrabec 1.18.0-1 +- new upstream release + +* Thu Aug 02 2007 Peter Vrabec 1.17.6-1 +- upstream bugfix release + +* Mon Jul 30 2007 Peter Vrabec 1.17.5-1 +- upstream bugfix release +- fix typo in provides + +* Wed Jul 25 2007 Jeremy Katz - 1.17.2-4 +- rebuild for toolchain bug + +* Tue Jul 24 2007 Peter Vrabec 1.17.2-3 +- take care of sysklogd configuration files in %%post + +* Tue Jul 24 2007 Peter Vrabec 1.17.2-2 +- use EVR in provides/obsoletes sysklogd + +* Mon Jul 23 2007 Peter Vrabec 1.17.2-1 +- upstream bug fix release + +* Fri Jul 20 2007 Peter Vrabec 1.17.1-1 +- upstream bug fix release +- include html docs (#248712) +- make "-r" option compatible with sysklogd config (248982) + +* Tue Jul 17 2007 Peter Vrabec 1.17.0-1 +- feature rich upstream release + +* Thu Jul 12 2007 Peter Vrabec 1.15.1-2 +- use obsoletes and hadle old config files + +* Wed Jul 11 2007 Peter Vrabec 1.15.1-1 +- new upstream bugfix release + +* Tue Jul 10 2007 Peter Vrabec 1.15.0-1 +- new upstream release introduce capability to generate output + file names based on templates + +* Tue Jul 03 2007 Peter Vrabec 1.14.2-1 +- new upstream bugfix release + +* Mon Jul 02 2007 Peter Vrabec 1.14.1-1 +- new upstream release with IPv6 support + +* Tue Jun 26 2007 Peter Vrabec 1.13.5-3 +- add BuildRequires for zlib compression feature + +* Mon Jun 25 2007 Peter Vrabec 1.13.5-2 +- some spec file adjustments. +- fix syslog init script error codes (#245330) + +* Fri Jun 22 2007 Peter Vrabec 1.13.5-1 +- new upstream release + +* Fri Jun 22 2007 Peter Vrabec 1.13.4-2 +- some spec file adjustments. + +* Mon Jun 18 2007 Peter Vrabec 1.13.4-1 +- upgrade to new upstream release + +* Wed Jun 13 2007 Peter Vrabec 1.13.2-2 +- DB support off + +* Tue Jun 12 2007 Peter Vrabec 1.13.2-1 +- new upstream release based on redhat patch + +* Fri Jun 08 2007 Peter Vrabec 1.13.1-2 +- rsyslog package provides its own kernel log. daemon (rklogd) + +* Mon Jun 04 2007 Peter Vrabec 1.13.1-1 +- Initial rpm build