<?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: Geographically Improbable Access in All Apps and Add-ons</title>
    <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/518307#M63336</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/222918"&gt;@moogmusic&lt;/a&gt;,&amp;nbsp;thanks for sharing the details. Sounds like sorting working incorrectly on data coming from tstats by _time can be a big problem.&lt;/P&gt;&lt;P&gt;Could you share more details or DM me with any obfuscated data sample that can be used to reproduce the issue with sorting by _time? I assume that all the original events' timestamps are good and something else is going on.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 07 Sep 2020 23:10:28 GMT</pubDate>
    <dc:creator>igifrin_splunk</dc:creator>
    <dc:date>2020-09-07T23:10:28Z</dc:date>
    <item>
      <title>Geographically Improbable Access</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/515397#M63107</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hi, I'm having a bit of an issue with the Geographically Improbable Access panel in the Access Anomalies dashboard of the InfoSec app. Basically, if I add a "search user=username" into the search powering it, I get a hit but without it I don't so for a given time period, I'm getting two results for the specified user if I search explicitly for them which look to be genuine but I don't see them on the general search. This is the search (I've mark my additional&amp;nbsp;username search in bold):&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;| tstats summariesonly=true allow_old_summaries=true values(Authentication.app) as app from datamodel=Authentication.Authentication where Authentication.action=success by Authentication.user, Authentication.src _time span=1s&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| rename "Authentication.*" as "*"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| eventstats dc(src) as src_count by user&lt;/SPAN&gt;&lt;BR /&gt;&lt;STRONG&gt;| search user=username&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;| search src_count&amp;gt;1&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| sort 0 + _time&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| iplocation src&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| where isnotnull(lat) AND isnotnull(lon)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| streamstats window=2 earliest(lat) as prev_lat, earliest(lon) as prev_lon, earliest(_time) as prev_time, earliest(src) as prev_src, earliest(City) as prev_city, earliest(Country) as prev_country, earliest(app) as prev_app by user&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| where (src != prev_src)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| eval lat1_r=((lat * 3.14159265358) / 180), lat2_r=((prev_lat * 3.14159265358) / 180), delta=(((prev_lon - lon) * 3.14159265358) / 180), distance=(3959 * acos(((sin(lat1_r) * sin(lat2_r)) + ((cos(lat1_r) * cos(lat2_r)) * cos(delta))))), distance=round(distance,2)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| fields - lat1_r, lat2_r, long1_r, long2_r, delta&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| eval time_diff=if((('_time' - prev_time) == 0),1,('_time' - prev_time)), speed=round(((distance * 3600) / time_diff),2)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| where (speed &amp;gt; 500)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| eval prev_time=strftime(prev_time,"%Y-%m-%d %H:%M:%S")&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;| table user, src, _time, City, Country, app, prev_src, prev_time, prev_city, prev_country, prev_app, distance, speed&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Anyone got any ideas what's going on?&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/186098"&gt;@igifrin_splunk&lt;/a&gt;&amp;nbsp; Thanks&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 21 Aug 2020 08:38:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/515397#M63107</guid>
      <dc:creator>moogmusic</dc:creator>
      <dc:date>2020-08-21T08:38:52Z</dc:date>
    </item>
    <item>
      <title>Re: Geographically Improbable Access</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/515540#M63117</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/222918"&gt;@moogmusic&lt;/a&gt;,&amp;nbsp;this seems to be an issue with streamstats portion of the search (good catch by the way; thanks!).&amp;nbsp;&lt;/P&gt;&lt;P&gt;Adding global=false to streamstats should show your missing user.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The search will look like this:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" size="2"&gt;| tstats summariesonly=true allow_old_summaries=true values(Authentication.app) as app from datamodel=Authentication.Authentication where Authentication.action=success by Authentication.user, Authentication.src _time span=1s &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| rename "Authentication.*" as "*"&amp;nbsp;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| eventstats dc(src) as src_count by user &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| search src_count&amp;gt;1 &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| sort 0 + _time &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| iplocation src &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| where isnotnull(lat) AND isnotnull(lon) &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| streamstats window=2 &lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;global=false&lt;/FONT&gt;&lt;/STRONG&gt; earliest(lat) as prev_lat, earliest(lon) as prev_lon, earliest(_time) as prev_time, earliest(src) as prev_src, earliest(City) as prev_city, earliest(Country) as prev_country, earliest(app) as prev_app by user &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| where (src != prev_src) &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| eval lat1_r=((lat * 3.14159265358) / 180), lat2_r=((prev_lat * 3.14159265358) / 180), delta=(((prev_lon - lon) * 3.14159265358) / 180), distance=(3959 * acos(((sin(lat1_r) * sin(lat2_r)) + ((cos(lat1_r) * cos(lat2_r)) * cos(delta))))), distance=round(distance,2) &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| fields - lat1_r, lat2_r, long1_r, long2_r, delta &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| eval time_diff=if(((_time - prev_time) == 0),1,(_time - prev_time)), speed=round(((distance * 3600) / time_diff),2) &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| where (speed &amp;gt; 500) &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| eval prev_time=strftime(prev_time,"%Y-%m-%d %H:%M:%S")&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="2"&gt;| table user, src, _time, City, Country, app, prev_src, prev_time, prev_city, prev_country, prev_app, distance, speed&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="arial,helvetica,sans-serif" size="3"&gt;This fix will go into the next InfoSec app update.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 21 Aug 2020 19:42:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/515540#M63117</guid>
      <dc:creator>igifrin_splunk</dc:creator>
      <dc:date>2020-08-21T19:42:50Z</dc:date>
    </item>
    <item>
      <title>Re: Geographically Improbable Access</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/517201#M63251</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/186098"&gt;@igifrin_splunk&lt;/a&gt;&amp;nbsp; - I added in the "global=false" argument but it did not fix the whole problem. I'd been experimenting with adding a "sort 0 user _time" before streamstats which was looking pretty good but it looks like tstats does not return the results ordered by _time consistently. The "global=false" argument negates the need to sort by user as they perform the same function (not sure which would be more computationally efficient) but the sort by _time is still needed to pick up all the hits I was getting before. Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 01 Sep 2020 09:49:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/517201#M63251</guid>
      <dc:creator>moogmusic</dc:creator>
      <dc:date>2020-09-01T09:49:35Z</dc:date>
    </item>
    <item>
      <title>Re: Geographically Improbable Access</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/518307#M63336</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/222918"&gt;@moogmusic&lt;/a&gt;,&amp;nbsp;thanks for sharing the details. Sounds like sorting working incorrectly on data coming from tstats by _time can be a big problem.&lt;/P&gt;&lt;P&gt;Could you share more details or DM me with any obfuscated data sample that can be used to reproduce the issue with sorting by _time? I assume that all the original events' timestamps are good and something else is going on.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Sep 2020 23:10:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/518307#M63336</guid>
      <dc:creator>igifrin_splunk</dc:creator>
      <dc:date>2020-09-07T23:10:28Z</dc:date>
    </item>
    <item>
      <title>Re: Geographically Improbable Access</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/518396#M63342</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/186098"&gt;@igifrin_splunk&lt;/a&gt;, sorry I wasn't clear in my last message. What I was saying was that tstats is not always return the events in time order so just adding in "global=false" wasn't enough on our system, it still need to be sorted by _time. The sort function is working as expected though.&lt;/P&gt;&lt;P&gt;Happy to have a chat and prep some anonymised data to go through it in more detail though. Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 08 Sep 2020 09:40:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/Geographically-Improbable-Access/m-p/518396#M63342</guid>
      <dc:creator>moogmusic</dc:creator>
      <dc:date>2020-09-08T09:40:17Z</dc:date>
    </item>
  </channel>
</rss>

