<?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: Search lookup for non-matching values in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Search-lookup-for-non-matching-values/m-p/309337#M160233</link>
    <description>&lt;P&gt;Try like this. The NOT subsearch will exclude all those foreign ip address from the main result itself.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=exchange_smtp Context=authenticated OR EHLO NOT [| inputlookup smtpforeignip.csv | table ipaddress ]| iplocation ipaddress | search Country != "United States" | transaction Session keepevicted=true | Search Context=authenticated | eval merged=user.Country | lookup user_location username as merged | search NOT target=* | table Data,Session,ipaddress,user,Country
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Tue, 11 Jul 2017 15:51:08 GMT</pubDate>
    <dc:creator>somesoni2</dc:creator>
    <dc:date>2017-07-11T15:51:08Z</dc:date>
    <item>
      <title>Search lookup for non-matching values</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Search-lookup-for-non-matching-values/m-p/309336#M160232</link>
      <description>&lt;P&gt;I have the following search (MySearch), which is tied to an alert. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=exchange_smtp Context=authenticated OR EHLO | iplocation ipaddress | search Country != "United States" | transaction Session keepevicted=true | Search Context=authenticated | eval merged=user.Country | lookup user_location username as merged | search NOT target=* | table Data,Session,ipaddress,user,Country
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I have a lookup file called smtpforeignip.csv with a search that populates and updates this file with ipaddress,user,Country.&lt;/P&gt;

&lt;P&gt;I want to modify MySearch to do a comparison against smtpforeignip.csv.  If there is a matching ipaddress I do not want the alert to trigger.  I ONLY want the alert to trigger when there is a non-matching ipaddress.&lt;/P&gt;</description>
      <pubDate>Tue, 11 Jul 2017 15:07:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Search-lookup-for-non-matching-values/m-p/309336#M160232</guid>
      <dc:creator>ldunzweiler</dc:creator>
      <dc:date>2017-07-11T15:07:11Z</dc:date>
    </item>
    <item>
      <title>Re: Search lookup for non-matching values</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Search-lookup-for-non-matching-values/m-p/309337#M160233</link>
      <description>&lt;P&gt;Try like this. The NOT subsearch will exclude all those foreign ip address from the main result itself.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=exchange_smtp Context=authenticated OR EHLO NOT [| inputlookup smtpforeignip.csv | table ipaddress ]| iplocation ipaddress | search Country != "United States" | transaction Session keepevicted=true | Search Context=authenticated | eval merged=user.Country | lookup user_location username as merged | search NOT target=* | table Data,Session,ipaddress,user,Country
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 11 Jul 2017 15:51:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Search-lookup-for-non-matching-values/m-p/309337#M160233</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2017-07-11T15:51:08Z</dc:date>
    </item>
  </channel>
</rss>

