<?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 do you filter Windows Event Log? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10021#M341</link>
    <description>&lt;P&gt;That works great! Yes I do want to drop specific events. How do you another condition in the regex? Say with the EventCode, I also want to include all username "Anonymous Logon"? I'm thinking on the regex "(?m)^EventCode=540.*ANONYMOUS LOGON.*Logon Type: 3"&lt;/P&gt;</description>
    <pubDate>Mon, 28 Sep 2020 09:11:05 GMT</pubDate>
    <dc:creator>BunnyHop</dc:creator>
    <dc:date>2020-09-28T09:11:05Z</dc:date>
    <item>
      <title>How do you filter Windows Event Log?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10019#M339</link>
      <description>&lt;P&gt;I've tried to filter native event logs being indexed using the [WinEventLog...] sourcetype.  Here are the config:&lt;/P&gt;

&lt;P&gt;props.conf&lt;/P&gt;

&lt;PRE&gt;
[WinEventLog:Security]
TRANSFORMS-set = delete
&lt;/PRE&gt;

&lt;P&gt;transforms.conf&lt;/P&gt;

&lt;PRE&gt;
[delete]
REGEX = .*EventCode\=540.*
DEST_KEY = queue
FORMAT = nullQueue
&lt;/PRE&gt;

&lt;P&gt;Wondering if this is a bug?!&lt;/P&gt;</description>
      <pubDate>Sat, 06 Mar 2010 09:09:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10019#M339</guid>
      <dc:creator>BunnyHop</dc:creator>
      <dc:date>2010-03-06T09:09:29Z</dc:date>
    </item>
    <item>
      <title>Re: How do you filter Windows Event Log?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10020#M340</link>
      <description>&lt;P&gt;Though you don't actually say, I assume your problem is the events with EventCode 540 are not being dropped and that you want them to be. I do not know of any bugs in this area.&lt;/P&gt;

&lt;P&gt;However, if that is what you are trying to do, one problem is that the "&lt;CODE&gt;EventCode&lt;/CODE&gt;" you are presumably looking for is usually found at the beginning of a line, while the regex in your configuration requires a "&lt;CODE&gt;.&lt;/CODE&gt;" before it. By default, "&lt;CODE&gt;.&lt;/CODE&gt;" does not match line breaks, so your regex will not match what you intend. A regex that does do what you probably want is "&lt;CODE&gt;(?m)^EventCode=540&lt;/CODE&gt;".&lt;/P&gt;</description>
      <pubDate>Sat, 06 Mar 2010 15:17:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10020#M340</guid>
      <dc:creator>gkanapathy</dc:creator>
      <dc:date>2010-03-06T15:17:51Z</dc:date>
    </item>
    <item>
      <title>Re: How do you filter Windows Event Log?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10021#M341</link>
      <description>&lt;P&gt;That works great! Yes I do want to drop specific events. How do you another condition in the regex? Say with the EventCode, I also want to include all username "Anonymous Logon"? I'm thinking on the regex "(?m)^EventCode=540.*ANONYMOUS LOGON.*Logon Type: 3"&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 09:11:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10021#M341</guid>
      <dc:creator>BunnyHop</dc:creator>
      <dc:date>2020-09-28T09:11:05Z</dc:date>
    </item>
    <item>
      <title>Re: How do you filter Windows Event Log?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10022#M342</link>
      <description>&lt;P&gt;You should look at the documents for PCRE: &lt;A href="http://perldoc.perl.org/perlre.html"&gt;http://perldoc.perl.org/perlre.html&lt;/A&gt;&lt;BR /&gt;
You probably want to use the &lt;CODE&gt;(?msi)&lt;/CODE&gt; prefix on your regex if you want it to work.&lt;/P&gt;</description>
      <pubDate>Wed, 10 Mar 2010 14:35:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10022#M342</guid>
      <dc:creator>gkanapathy</dc:creator>
      <dc:date>2010-03-10T14:35:01Z</dc:date>
    </item>
    <item>
      <title>Re: How do you filter Windows Event Log?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10023#M343</link>
      <description>&lt;P&gt;Took awhile but I was able to get my exact regex.  I did use the (?msi) prefix.  Thanks alot!&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2010 04:41:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10023#M343</guid>
      <dc:creator>BunnyHop</dc:creator>
      <dc:date>2010-03-11T04:41:31Z</dc:date>
    </item>
    <item>
      <title>Re: How do you filter Windows Event Log?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10024#M344</link>
      <description>&lt;P&gt;I recommend adding a not-a-digit at the end of that regex.  For example: "&lt;CODE&gt;(?m)^EventCode=540\D&lt;/CODE&gt;" just so you aren't matching some other event code.&lt;/P&gt;</description>
      <pubDate>Sat, 28 Aug 2010 07:52:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-you-filter-Windows-Event-Log/m-p/10024#M344</guid>
      <dc:creator>Lowell</dc:creator>
      <dc:date>2010-08-28T07:52:01Z</dc:date>
    </item>
  </channel>
</rss>

