<?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 How to get ADFS Location Login Lookup based on IP address with iplocation region country and time? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-ADFS-Location-Login-Lookup-based-on-IP-address-with/m-p/363899#M107429</link>
    <description>&lt;P&gt;Why is this search not returning the iplocation of the ip addresses. It is not the most efficient search, but right now I am just trying to get it to work for iplocation lookup. This search would run every 5 minutes for the last 5 minutes and alert on any country that does not = United States. I do not have that in the search string because right now I am just trying to get a result. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="wineventlog" sourcetype="WinEventLog:Security" host=adfs*
    (EventCode=299 OR EventCode=410 OR EventCode=403 OR EventCode=500 OR EventCode=501) 
| rex field=_raw "Activity ID: (?&amp;lt;Activity_ID&amp;gt;[^\ ]+)" 
| rex field=Message "More information for the event entry with Instance ID (?&amp;lt;Instance_ID&amp;gt;[^\.]+)\." 
| transaction Activity_ID Instance_ID maxpause=10s 
| rex field=Message "SAIF\\\(?&amp;lt;domain_uid&amp;gt;.*).*" 
| search domain_uid=* 
| rex field=Message "(?&amp;lt;clientip&amp;gt;\s\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\s)" 
| dedup clientip 
| dedup X_MS_Forwarded_Client_IP 
| makemv delim="," X_MS_Forwarded_Client_IP
| eval alltheips=mvappend(clientip, x_ms_forwarded_client_ip) 
| mvexpand alltheips
| iplocation alltheips
| stats values(Keywords),values(City),values(Region) ,values(Country),values(alltheips),values(ip_count),values(Activity_ID),values(Instance_ID),values(X_MS_Client_User_Agent),values(User_Agent),values(_time) by domain_uid,_time
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;suggestions would be helpful. This is very similar to what the following two posts are trying to do. &lt;BR /&gt;
&lt;A href="https://answers.splunk.com/answers/454144/is-there-a-splunk-app-or-add-on-that-will-help-rea.html"&gt;https://answers.splunk.com/answers/454144/is-there-a-splunk-app-or-add-on-that-will-help-rea.html&lt;/A&gt;&lt;BR /&gt;
&lt;A href="https://answers.splunk.com/answers/215994/how-do-i-find-active-directory-usernames-logging-i.html"&gt;https://answers.splunk.com/answers/215994/how-do-i-find-active-directory-usernames-logging-i.html&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 05 Jan 2018 16:35:30 GMT</pubDate>
    <dc:creator>nathig</dc:creator>
    <dc:date>2018-01-05T16:35:30Z</dc:date>
    <item>
      <title>How to get ADFS Location Login Lookup based on IP address with iplocation region country and time?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-ADFS-Location-Login-Lookup-based-on-IP-address-with/m-p/363899#M107429</link>
      <description>&lt;P&gt;Why is this search not returning the iplocation of the ip addresses. It is not the most efficient search, but right now I am just trying to get it to work for iplocation lookup. This search would run every 5 minutes for the last 5 minutes and alert on any country that does not = United States. I do not have that in the search string because right now I am just trying to get a result. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="wineventlog" sourcetype="WinEventLog:Security" host=adfs*
    (EventCode=299 OR EventCode=410 OR EventCode=403 OR EventCode=500 OR EventCode=501) 
| rex field=_raw "Activity ID: (?&amp;lt;Activity_ID&amp;gt;[^\ ]+)" 
| rex field=Message "More information for the event entry with Instance ID (?&amp;lt;Instance_ID&amp;gt;[^\.]+)\." 
| transaction Activity_ID Instance_ID maxpause=10s 
| rex field=Message "SAIF\\\(?&amp;lt;domain_uid&amp;gt;.*).*" 
| search domain_uid=* 
| rex field=Message "(?&amp;lt;clientip&amp;gt;\s\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\s)" 
| dedup clientip 
| dedup X_MS_Forwarded_Client_IP 
| makemv delim="," X_MS_Forwarded_Client_IP
| eval alltheips=mvappend(clientip, x_ms_forwarded_client_ip) 
| mvexpand alltheips
| iplocation alltheips
| stats values(Keywords),values(City),values(Region) ,values(Country),values(alltheips),values(ip_count),values(Activity_ID),values(Instance_ID),values(X_MS_Client_User_Agent),values(User_Agent),values(_time) by domain_uid,_time
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;suggestions would be helpful. This is very similar to what the following two posts are trying to do. &lt;BR /&gt;
&lt;A href="https://answers.splunk.com/answers/454144/is-there-a-splunk-app-or-add-on-that-will-help-rea.html"&gt;https://answers.splunk.com/answers/454144/is-there-a-splunk-app-or-add-on-that-will-help-rea.html&lt;/A&gt;&lt;BR /&gt;
&lt;A href="https://answers.splunk.com/answers/215994/how-do-i-find-active-directory-usernames-logging-i.html"&gt;https://answers.splunk.com/answers/215994/how-do-i-find-active-directory-usernames-logging-i.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Jan 2018 16:35:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-ADFS-Location-Login-Lookup-based-on-IP-address-with/m-p/363899#M107429</guid>
      <dc:creator>nathig</dc:creator>
      <dc:date>2018-01-05T16:35:30Z</dc:date>
    </item>
    <item>
      <title>Re: How to get ADFS Location Login Lookup based on IP address with iplocation region country and time?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-ADFS-Location-Login-Lookup-based-on-IP-address-with/m-p/363900#M107430</link>
      <description>&lt;P&gt;Hey,if you want to troubleshoot this search I would suggest not to run entire search instead run single single query and add queries thereafter and see where you do not get results. It would be very helpful&lt;/P&gt;

&lt;P&gt;for eg.&lt;BR /&gt;
run this search see if everything is extracted properly or not&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="wineventlog" sourcetype="WinEventLog:Security" host=adfs*
     (EventCode=299 OR EventCode=410 OR EventCode=403 OR EventCode=500 OR EventCode=501) 
 | rex field=_raw "Activity ID: (?&amp;lt;Activity_ID&amp;gt;[^\ ]+)" 
 | rex field=Message "More information for the event entry with Instance ID (?&amp;lt;Instance_ID&amp;gt;[^\.]+)\." 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;and then add further query one by one&lt;/P&gt;</description>
      <pubDate>Fri, 05 Jan 2018 18:17:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-ADFS-Location-Login-Lookup-based-on-IP-address-with/m-p/363900#M107430</guid>
      <dc:creator>mayurr98</dc:creator>
      <dc:date>2018-01-05T18:17:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to get ADFS Location Login Lookup based on IP address with iplocation region country and time?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-ADFS-Location-Login-Lookup-based-on-IP-address-with/m-p/363901#M107431</link>
      <description>&lt;P&gt;For me it returns results up to line 7, were you able to figure this out?&lt;/P&gt;</description>
      <pubDate>Fri, 02 Mar 2018 01:17:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-ADFS-Location-Login-Lookup-based-on-IP-address-with/m-p/363901#M107431</guid>
      <dc:creator>jmjssplunkthing</dc:creator>
      <dc:date>2018-03-02T01:17:12Z</dc:date>
    </item>
    <item>
      <title>Re: How to get ADFS Location Login Lookup based on IP address with iplocation region country and time?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-ADFS-Location-Login-Lookup-based-on-IP-address-with/m-p/363902#M107432</link>
      <description>&lt;P&gt;why does some people not using google maps? check this &lt;A href="https://ipdetectives.io/"&gt;https://ipdetectives.io/&lt;/A&gt; is there a problem with google?&lt;/P&gt;</description>
      <pubDate>Thu, 09 May 2019 12:29:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-ADFS-Location-Login-Lookup-based-on-IP-address-with/m-p/363902#M107432</guid>
      <dc:creator>rektdata</dc:creator>
      <dc:date>2019-05-09T12:29:42Z</dc:date>
    </item>
  </channel>
</rss>

