<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to extract fields from the message of a windows event log? in All Apps and Add-ons</title>
    <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302042#M36040</link>
    <description>&lt;P&gt;Hi jwindley,&lt;/P&gt;

&lt;P&gt;this is what I have in my avecto app:&lt;/P&gt;

&lt;P&gt;props.conf&lt;BR /&gt;
[source::WinEventLog:Application]&lt;BR /&gt;
REPORT-MESSAGE = avec-wel-message, avec-wel-eq-kv, avec-wel-col-kv&lt;BR /&gt;
KV_MODE=none&lt;/P&gt;

&lt;H1&gt;Note the below  settings are effectively legacy, in place here to handle&lt;/H1&gt;

&lt;H1&gt;data coming from much much older forwarders (3.x &amp;amp; 4.x)&lt;/H1&gt;

&lt;P&gt;SHOULD_LINEMERGE = false&lt;BR /&gt;
MAX_TIMESTAMP_LOOKAHEAD=30&lt;BR /&gt;
LINE_BREAKER = (&lt;A href="https://community.splunk.com/?=d%7B2%7D/d%7B2%7D/d%7B2,4%7D%20d%7B2%7D:d%7B2%7D:d%7B2%7D%20%5BaApPmM%5D%7B2%7D" target="_blank"&gt;\r\n&lt;/A&gt;)&lt;BR /&gt;
TRANSFORMS-FIELDS = strip-winevt-linebreaker&lt;/P&gt;

&lt;P&gt;transforms.conf&lt;BR /&gt;
[avec-wel-message]&lt;BR /&gt;
REGEX = (?sm)^(?&amp;lt;_pre_msg&amp;gt;.+)\nMessage=(?.+)$&lt;BR /&gt;
CLEAN_KEYS = false&lt;/P&gt;

&lt;P&gt;[avec-wel-eq-kv]&lt;BR /&gt;
SOURCE_KEY = _pre_msg&lt;BR /&gt;
DELIMS     = "\n","="&lt;BR /&gt;
MV_ADD     = true&lt;/P&gt;

&lt;P&gt;[avec-wel-col-kv]&lt;BR /&gt;
SOURCE_KEY = Message&lt;BR /&gt;
REGEX      = \n?&lt;A href="%5B%5E:nr%5D+" target="_blank"&gt; \t&lt;/A&gt;:[ \t]++([^\r]*)&lt;BR /&gt;
FORMAT     = $1::$2&lt;BR /&gt;
MV_ADD     = true&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 22:14:23 GMT</pubDate>
    <dc:creator>john0499</dc:creator>
    <dc:date>2020-09-29T22:14:23Z</dc:date>
    <item>
      <title>How to extract fields from the message of a windows event log?</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302038#M36036</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;

&lt;P&gt;I have a problem extracting fields after the Message= portion of a windows application event log. Everything after Message= is being added as single value to the message field.&lt;/P&gt;

&lt;P&gt;I think it may be the due to the formatting of the data after Message=, which seems to have a leading space or tab. It looks like this:&lt;/P&gt;

&lt;P&gt;Message=Process started in passive mode.&lt;/P&gt;

&lt;P&gt;Command Line: C:\something\something\something.exe&lt;BR /&gt;
Process Id: 8988&lt;BR /&gt;
...&lt;/P&gt;

&lt;P&gt;(the the white space is being removed from this post - its in front of 'Command' and 'Process')&lt;/P&gt;

&lt;P&gt;There are about 50 more fields after these, all on new lines but with a space  or tab before them.&lt;/P&gt;

&lt;P&gt;I have tried playing with the regex from transforms.conf below, but I've only been able to move the problem from the message field to a new field called Command_Line that contains a value of everything below it.&lt;/P&gt;

&lt;P&gt;[wel-col-kv]&lt;BR /&gt;
SOURCE_KEY = Message&lt;BR /&gt;
REGEX      = \n([^:\n\r]+):[ \t]++([^\n]*)&lt;BR /&gt;
FORMAT     = $1::$2&lt;BR /&gt;
MV_ADD     = true&lt;/P&gt;

&lt;P&gt;I have found some similar questions asked but haven't been able to come up with a solution yet. Any help would be greatly appreciated.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 14:07:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302038#M36036</guid>
      <dc:creator>john0499</dc:creator>
      <dc:date>2020-09-29T14:07:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract fields from the message of a windows event log?</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302039#M36037</link>
      <description>&lt;P&gt;are you using the Windows TA? &lt;BR /&gt;
&lt;A href="https://splunkbase.splunk.com/app/742/"&gt;https://splunkbase.splunk.com/app/742/&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 24 May 2017 02:48:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302039#M36037</guid>
      <dc:creator>adonio</dc:creator>
      <dc:date>2017-05-24T02:48:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract fields from the message of a windows event log?</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302040#M36038</link>
      <description>&lt;P&gt;I do have the TA, although I don't believe it's actually needed as windows event extraction is included in the default transforms.conf&lt;/P&gt;

&lt;P&gt;I managed to get it working with the following changes to the default:&lt;/P&gt;

&lt;P&gt;REGEX      = \n?&lt;A href="%5B%5E:nr%5D+"&gt; \t&lt;/A&gt;:[ \t]++([^\r]*)&lt;/P&gt;

&lt;P&gt;FYI this was to extract avecto defendpoint events&lt;/P&gt;</description>
      <pubDate>Mon, 29 May 2017 23:46:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302040#M36038</guid>
      <dc:creator>john0499</dc:creator>
      <dc:date>2017-05-29T23:46:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract fields from the message of a windows event log?</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302041#M36039</link>
      <description>&lt;P&gt;Hi John, I have the same problem parsing the avecto logs from Message. I tried your new regex but it didn't solve it for me. Strangely though the default regex parses everything fine for me in regex101. Did you make any other changes at all other than to the wel-col-kv settings?&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 27 Nov 2018 10:01:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302041#M36039</guid>
      <dc:creator>jwindley_splunk</dc:creator>
      <dc:date>2018-11-27T10:01:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract fields from the message of a windows event log?</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302042#M36040</link>
      <description>&lt;P&gt;Hi jwindley,&lt;/P&gt;

&lt;P&gt;this is what I have in my avecto app:&lt;/P&gt;

&lt;P&gt;props.conf&lt;BR /&gt;
[source::WinEventLog:Application]&lt;BR /&gt;
REPORT-MESSAGE = avec-wel-message, avec-wel-eq-kv, avec-wel-col-kv&lt;BR /&gt;
KV_MODE=none&lt;/P&gt;

&lt;H1&gt;Note the below  settings are effectively legacy, in place here to handle&lt;/H1&gt;

&lt;H1&gt;data coming from much much older forwarders (3.x &amp;amp; 4.x)&lt;/H1&gt;

&lt;P&gt;SHOULD_LINEMERGE = false&lt;BR /&gt;
MAX_TIMESTAMP_LOOKAHEAD=30&lt;BR /&gt;
LINE_BREAKER = (&lt;A href="https://community.splunk.com/?=d%7B2%7D/d%7B2%7D/d%7B2,4%7D%20d%7B2%7D:d%7B2%7D:d%7B2%7D%20%5BaApPmM%5D%7B2%7D" target="_blank"&gt;\r\n&lt;/A&gt;)&lt;BR /&gt;
TRANSFORMS-FIELDS = strip-winevt-linebreaker&lt;/P&gt;

&lt;P&gt;transforms.conf&lt;BR /&gt;
[avec-wel-message]&lt;BR /&gt;
REGEX = (?sm)^(?&amp;lt;_pre_msg&amp;gt;.+)\nMessage=(?.+)$&lt;BR /&gt;
CLEAN_KEYS = false&lt;/P&gt;

&lt;P&gt;[avec-wel-eq-kv]&lt;BR /&gt;
SOURCE_KEY = _pre_msg&lt;BR /&gt;
DELIMS     = "\n","="&lt;BR /&gt;
MV_ADD     = true&lt;/P&gt;

&lt;P&gt;[avec-wel-col-kv]&lt;BR /&gt;
SOURCE_KEY = Message&lt;BR /&gt;
REGEX      = \n?&lt;A href="%5B%5E:nr%5D+" target="_blank"&gt; \t&lt;/A&gt;:[ \t]++([^\r]*)&lt;BR /&gt;
FORMAT     = $1::$2&lt;BR /&gt;
MV_ADD     = true&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 22:14:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/How-to-extract-fields-from-the-message-of-a-windows-event-log/m-p/302042#M36040</guid>
      <dc:creator>john0499</dc:creator>
      <dc:date>2020-09-29T22:14:23Z</dc:date>
    </item>
  </channel>
</rss>

