From 5fccf771f37973a2cea543fbdf1ed94ed9706faf Mon Sep 17 00:00:00 2001 From: Michael Biebl Date: Tue, 11 Mar 2014 19:04:23 +0100 Subject: Imported Upstream version 7.4.8 --- plugins/mmanon/mmanon.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'plugins/mmanon/mmanon.c') diff --git a/plugins/mmanon/mmanon.c b/plugins/mmanon/mmanon.c index a1c99d0..16a4f34 100644 --- a/plugins/mmanon/mmanon.c +++ b/plugins/mmanon/mmanon.c @@ -170,7 +170,6 @@ CODESTARTnewActInst cstr); free(cstr); } - pData->replChar = es_getBufAddr(pvals[i].val.d.estr)[0]; } else if(!strcmp(actpblk.descr[i].name, "replacementchar")) { pData->replChar = es_getBufAddr(pvals[i].val.d.estr)[0]; } else if(!strcmp(actpblk.descr[i].name, "ipv4.bits")) { @@ -307,7 +306,7 @@ anonip(instanceData *pData, uchar *msg, int *pLenMsg, int *idx) ++i; ipstart[3] = i; octet = getnum(msg, lenMsg, &i); - if(octet > 255 || !(msg[i] == ' ' || msg[i] == ':')) goto done; + if(octet > 255) goto done; ipv4addr |= octet; /* OK, we now found an ip address */ @@ -339,6 +338,8 @@ anonip(instanceData *pData, uchar *msg, int *pLenMsg, int *idx) if(i - endpos > 0) { *pLenMsg = lenMsg - (i - endpos); memmove(msg+endpos, msg+i, lenMsg - i + 1); + /* correct index for next search! */ + i -= (i - endpos); } } -- cgit v1.2.3