2017-07-06 06:22 AM
I'm trying to parse the following custom log messages:
%AUDITD-4: type=EXECVE msg=audit(1499333941.360:486455): argc=3 a0="ls" a1="-lhatr" a2="/var/netwitness/concentrator/index"
Basically there can be any number of arguments and they are of the for argn=" "
I thought I would try and use the tagval parser map and defined the following message:
<TAGVALMAP
delimiter=" "" />
<MESSAGE
level="6"
parse="1"
parsedefvalue="1"
tableid="89"
id1="%AUDITD-4:13"
id2="%AUDITD-4"
eventcategory="1612000000"
tagval="true"
missField="true"
content="type=<event_description> msg=audit(<fld1>): argc=<fld2> a0="<filename>" a1="<a1>" a2="<a2>" a3="<a3>" a4="<a4>" a5="<a5>" a6="<a6>" a7="<a7>" a8="<a8>" "/>
However when I try and load the parser I get the following error:
Jul 6 10:18:04 SIEM-DO-HLD01 NwLogDecoder[31525]: [LogParse] [failure] Invalid message for auditd, id %AUDITD-4:13: Missing last value field in tagval message
Can anyone help perhaps wRAlmdLu8uOnkbiouAPmB5mqnlFr6baANOTo7eT0Oa4=?
2017-07-06 01:25 PM
Dave
You are already calling out the quot in the header part:
<TAGVALMAP
delimiter=" "" />
There is no reason to call it out in your parser:
content="type=<event_description> msg=audit(<fld1>): argc=<fld2> a0="<filename>" a1="<a1>" a2="<a2>" a3="<a3>" a4="<a4>" a5="<a5>" a6="<a6>" a7="<a7>" a8="<a8>" "/>
Should be:
content="type=<event_description> msg=audit(<fld1>): argc=<fld2> a0=<filename> a1=<a1>
and so on
Dave
2017-07-06 01:25 PM
Dave
You are already calling out the quot in the header part:
<TAGVALMAP
delimiter=" "" />
There is no reason to call it out in your parser:
content="type=<event_description> msg=audit(<fld1>): argc=<fld2> a0="<filename>" a1="<a1>" a2="<a2>" a3="<a3>" a4="<a4>" a5="<a5>" a6="<a6>" a7="<a7>" a8="<a8>" "/>
Should be:
content="type=<event_description> msg=audit(<fld1>): argc=<fld2> a0=<filename> a1=<a1>
and so on
Dave
2017-07-10 04:21 AM
Thanks very much @Dave_Glover that did the trick.