<?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: WinEventLog whitelisting by SourceName not working in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372703#M67600</link>
    <description>&lt;P&gt;hi jrlane,&lt;BR /&gt;
from &lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/Admin/Inputsconf"&gt;http://docs.splunk.com/Documentation/Splunk/latest/Admin/Inputsconf&lt;/A&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;whitelist = **&amp;lt;regular expression&amp;gt;**
* If set, files from this input are monitored only if their path matches the specified regex.
* Takes precedence over the deprecated _whitelist setting, which functions the same way.
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;in white list you have to insert a regex not a string or a field as the one you used in your example &lt;CODE&gt;index="myindex" SourceName="AD FS Auditing" EventCode=500&lt;/CODE&gt;&lt;BR /&gt;
So if you use a rex command in your search instead of string you can see that your regex is wrong (backslashes before brachets and equal).&lt;BR /&gt;
try using &lt;CODE&gt;whitelist1= SourceName\=\"AD FS Auditing\"&lt;/CODE&gt; in your inputs.conf.&lt;/P&gt;

&lt;P&gt;You can verify this regex in this way:&lt;BR /&gt;
using the regex of your whitelist, you don't have events&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="myindex" EventCode=500
| rex "SourceName="AD FS Auditing""
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;instead if you use the correct regex, you'll find events&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="myindex" EventCode=500
| rex "SourceName\=\"AD FS Auditing\""
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Try it.&lt;/P&gt;

&lt;P&gt;Bye.&lt;BR /&gt;
Giuseppe&lt;/P&gt;</description>
    <pubDate>Sat, 19 Aug 2017 06:11:39 GMT</pubDate>
    <dc:creator>gcusello</dc:creator>
    <dc:date>2017-08-19T06:11:39Z</dc:date>
    <item>
      <title>WinEventLog whitelisting by SourceName not working</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372698#M67595</link>
      <description>&lt;P&gt;I'm trying to whitelist a few event logs by eventcode as well as whitelist all events with the SourceName "AD FS Auditing". My config is as follows.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;[WinEventLog://Security]
whitelist= 4624, 4625
whitelist1= SourceName="AD FS Auditing"
index=windows_evt
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;With this config any events i put in the first whitelist line work perfectly, but the second line is not functional. As a test if I add an event code that will have a SourceName of &lt;CODE&gt;"AD FS Auditing"&lt;/CODE&gt; (say EventCode=500) they come in just fine. I have tried various combinations of things for source name such as &lt;CODE&gt;"^AD FS Auditing$"&lt;/CODE&gt; and &lt;CODE&gt;".*AD FS Auditing.*"&lt;/CODE&gt; with no success.&lt;/P&gt;</description>
      <pubDate>Sat, 06 Jun 2020 23:54:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372698#M67595</guid>
      <dc:creator>jrlane</dc:creator>
      <dc:date>2020-06-06T23:54:07Z</dc:date>
    </item>
    <item>
      <title>Re: WinEventLog whitelisting by SourceName not working</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372699#M67596</link>
      <description>&lt;P&gt;Hi  jrlane,&lt;BR /&gt;
probably there's an error in your regex: e.g. before brachets and equal you have to insert a backslash ().&lt;/P&gt;

&lt;P&gt;Try your regex in &lt;A href="https://regex101.com/"&gt;https://regex101.com/&lt;/A&gt; or in Splunk before insert it in whitelist.&lt;/P&gt;

&lt;P&gt;Bye.&lt;BR /&gt;
Giuseppe&lt;/P&gt;</description>
      <pubDate>Fri, 18 Aug 2017 06:08:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372699#M67596</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2017-08-18T06:08:31Z</dc:date>
    </item>
    <item>
      <title>Re: WinEventLog whitelisting by SourceName not working</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372700#M67597</link>
      <description>&lt;P&gt;Hi  jrlane,&lt;BR /&gt;
probably there's an error in your regex: e.g. before brachets and equal you have to insert a backslash ().&lt;/P&gt;

&lt;P&gt;Try your regex in &lt;A href="https://regex101.com/"&gt;https://regex101.com/&lt;/A&gt; or in Splunk before insert it in whitelist.&lt;/P&gt;

&lt;P&gt;Bye.&lt;BR /&gt;
Giuseppe&lt;/P&gt;</description>
      <pubDate>Fri, 18 Aug 2017 06:08:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372700#M67597</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2017-08-18T06:08:31Z</dc:date>
    </item>
    <item>
      <title>Re: WinEventLog whitelisting by SourceName not working</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372701#M67598</link>
      <description>&lt;P&gt;I don't see how regex could be the problem. Running this query &lt;CODE&gt;"index="myindex" SourceName="AD FS Auditing" EventCode=500&lt;/CODE&gt; I get the the results I need, there should be no regex required on SourceName, it's an exact string.&lt;/P&gt;</description>
      <pubDate>Fri, 18 Aug 2017 13:51:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372701#M67598</guid>
      <dc:creator>jrlane</dc:creator>
      <dc:date>2017-08-18T13:51:05Z</dc:date>
    </item>
    <item>
      <title>Re: WinEventLog whitelisting by SourceName not working</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372702#M67599</link>
      <description>&lt;P&gt;You are using both whitelist formats in the same stanza.  That does not work, according to &lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/Data/MonitorWindowseventlogdata"&gt;http://docs.splunk.com/Documentation/Splunk/latest/Data/MonitorWindowseventlogdata&lt;/A&gt;.  &lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;You can specify one of two formats:&lt;/P&gt;

&lt;P&gt;One or more Event Log event codes or event IDs (Event Code/ID format.)&lt;BR /&gt;&lt;BR /&gt;
One or more sets of keys and regular expressions (Advanced filtering format.) &lt;BR /&gt;
You cannot mix formats in a single entry. You also cannot mix formats in the same stanza.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;P&gt;Try this instead:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; [WinEventLog://Security]
 whitelist= EventCode="4624|4625"
 whitelist1= SourceName="AD FS Auditing"
 index=windows_evt
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 19 Aug 2017 04:37:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372702#M67599</guid>
      <dc:creator>spayneort</dc:creator>
      <dc:date>2017-08-19T04:37:08Z</dc:date>
    </item>
    <item>
      <title>Re: WinEventLog whitelisting by SourceName not working</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372703#M67600</link>
      <description>&lt;P&gt;hi jrlane,&lt;BR /&gt;
from &lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/Admin/Inputsconf"&gt;http://docs.splunk.com/Documentation/Splunk/latest/Admin/Inputsconf&lt;/A&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;whitelist = **&amp;lt;regular expression&amp;gt;**
* If set, files from this input are monitored only if their path matches the specified regex.
* Takes precedence over the deprecated _whitelist setting, which functions the same way.
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;in white list you have to insert a regex not a string or a field as the one you used in your example &lt;CODE&gt;index="myindex" SourceName="AD FS Auditing" EventCode=500&lt;/CODE&gt;&lt;BR /&gt;
So if you use a rex command in your search instead of string you can see that your regex is wrong (backslashes before brachets and equal).&lt;BR /&gt;
try using &lt;CODE&gt;whitelist1= SourceName\=\"AD FS Auditing\"&lt;/CODE&gt; in your inputs.conf.&lt;/P&gt;

&lt;P&gt;You can verify this regex in this way:&lt;BR /&gt;
using the regex of your whitelist, you don't have events&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="myindex" EventCode=500
| rex "SourceName="AD FS Auditing""
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;instead if you use the correct regex, you'll find events&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="myindex" EventCode=500
| rex "SourceName\=\"AD FS Auditing\""
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Try it.&lt;/P&gt;

&lt;P&gt;Bye.&lt;BR /&gt;
Giuseppe&lt;/P&gt;</description>
      <pubDate>Sat, 19 Aug 2017 06:11:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372703#M67600</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2017-08-19T06:11:39Z</dc:date>
    </item>
    <item>
      <title>Re: WinEventLog whitelisting by SourceName not working</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372704#M67601</link>
      <description>&lt;P&gt;Whitelisting for Wineventlog is a little bit tricky.&lt;/P&gt;

&lt;P&gt;First of all you can whitelist only with these fields:&lt;BR /&gt;
Category, CategoryString, ComputerName, EventCode, EventType, Keywords,&lt;BR /&gt;
    LogName, Message, OpCode, RecordNumber, Sid, SidType, SourceName,&lt;BR /&gt;
    TaskCategory, Type, User&lt;/P&gt;

&lt;P&gt;Then the logic behind differen whitelist rules is like this:&lt;/P&gt;

&lt;P&gt;whitelist OR whitelist1 OR whitelist2 OR .... OR whitelistN&lt;/P&gt;

&lt;P&gt;where each whitelist rule logic is like this &lt;/P&gt;

&lt;P&gt;rule1 AND rule2 AND ... AND ruleN&lt;/P&gt;

&lt;P&gt;Here a concrete example:&lt;/P&gt;

&lt;P&gt;whitelist =  EventCode="4624|4625"&lt;BR /&gt;
whitelist1 = SourceName="AD FS Auditing"&lt;BR /&gt;
whitelist2 = Keywords="Audit Success" User="Bob Marley"&lt;/P&gt;

&lt;P&gt;This translates to:&lt;/P&gt;

&lt;P&gt;EventCode="4624|4625" OR SourceName="AD FS Auditing" OR (Keywords="Audit Success" AND User="Bob Marley")&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jun 2020 09:17:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/WinEventLog-whitelisting-by-SourceName-not-working/m-p/372704#M67601</guid>
      <dc:creator>sonny_monti</dc:creator>
      <dc:date>2020-06-04T09:17:30Z</dc:date>
    </item>
  </channel>
</rss>

