summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2012-12-17 15:11:20 +0100
committerRainer Gerhards <rgerhards@adiscon.com>2012-12-17 15:11:20 +0100
commit283ec2d6e8c4c037ee789759ddf6efecf570fff1 (patch)
treeaab81081b9c04873a7eb6b3f5bb5334f07f18fad
parentb96693cef7343aaf0406fc242ebd17c8981051d5 (diff)
parent0014a37998d3f516be5db3aabeff4166544af5f7 (diff)
downloadrsyslog-283ec2d6e8c4c037ee789759ddf6efecf570fff1.tar.gz
rsyslog-283ec2d6e8c4c037ee789759ddf6efecf570fff1.tar.bz2
rsyslog-283ec2d6e8c4c037ee789759ddf6efecf570fff1.zip
Merge branch 'v5-stable' into v6-stable
-rw-r--r--ChangeLog3
-rw-r--r--plugins/omudpspoof/omudpspoof.c8
2 files changed, 10 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index db0aaa6a..5f88033a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -730,6 +730,9 @@ Version 5.10.2 [V5-STABLE], 201?-??-??
Thanks to Marius Tomaschewski for the bug report and the patch idea.
- bugfix: invalid DST handling under Solaris
Thanks to Scott Severtson for the patch.
+- bugfix[kind of]: omudpspoof discarded messages >1472 bytes (MTU size)
+ it now truncates these message, but ensures they are sent. Note that
+ 7.2.5+ will switch to fragmented UDP messages instead (up to 64K)
---------------------------------------------------------------------------
Version 5.10.1 [V5-STABLE], 2012-10-17
- bugfix: imuxsock and imklog truncated head of received message
diff --git a/plugins/omudpspoof/omudpspoof.c b/plugins/omudpspoof/omudpspoof.c
index 531a0dcf..d2c5364c 100644
--- a/plugins/omudpspoof/omudpspoof.c
+++ b/plugins/omudpspoof/omudpspoof.c
@@ -337,6 +337,12 @@ UDPSend(instanceData *pData, uchar *pszSourcename, char *msg, size_t len)
CHKiRet(doTryResume(pData));
}
+ if(len > 1472) {
+ DBGPRINTF("omudpspoof: msg with length %d truncated to 1472 bytes: '%.768s'\n",
+ len, msg);
+ len = 1472;
+ }
+
ip = ipo = udp = 0;
if(pData->sourcePort++ >= pData->sourcePortEnd){
pData->sourcePort = pData->sourcePortStart;
@@ -385,7 +391,7 @@ UDPSend(instanceData *pData, uchar *pszSourcename, char *msg, size_t len)
/* Write it to the wire. */
lsent = libnet_write(libnet_handle);
if (lsent == -1) {
- DBGPRINTF("Write error: %s\n", libnet_geterror(libnet_handle));
+ DBGPRINTF("omudpspoof: write error: %s\n", libnet_geterror(libnet_handle));
} else {
bSendSuccess = RSTRUE;
break;