<?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: Can you help me create a usecase that will alert when a string of failed logins is followed by a successful login? in Splunk Enterprise Security</title>
    <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446879#M6132</link>
    <description>&lt;P&gt;Here's the Brute Force Correlation search in ES, you would just need to ensure your data is in the CIM datamodel. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| from datamodel:"Authentication"."Authentication" | stats values(tag) as tag,values(app) as app,count(eval('action'=="failure")) as failure,count(eval('action'=="success")) as success by src | search success&amp;gt;0 | xswhere failure from failures_by_src_count_1h in authentication is above medium | `settags("access")`
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 28 Feb 2019 14:34:08 GMT</pubDate>
    <dc:creator>solarboyz1</dc:creator>
    <dc:date>2019-02-28T14:34:08Z</dc:date>
    <item>
      <title>Can you help me create a usecase that will alert when a string of failed logins is followed by a successful login?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446874#M6127</link>
      <description>&lt;P&gt;I'm trying to make a usecase where it will alert when there are several attempts of failed logins and one of them succeeded in the past 10 minutes.&lt;/P&gt;
&lt;P&gt;So it must do the following thing: &lt;BR /&gt;Alert when 10 failed logins are followed up by 1 successful log-in in the past 10 minutes.&lt;/P&gt;
&lt;P&gt;Is there a possible way to do this? I'm currently using a query of a datamodel that shows all logins in the timeframe given to the search. The query:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;| tstats summariesonly=true count from datamodel=Authentication by _time, "Authentication.src_user", "Authentication.action" 
| search (Authentication.src_user!="NULL SID" AND NOT Authentication.src_user="-" AND NOT Authentication.src_user="unknown")
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Thanks in advance everyone&lt;/P&gt;</description>
      <pubDate>Wed, 16 Mar 2022 14:12:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446874#M6127</guid>
      <dc:creator>kokanne</dc:creator>
      <dc:date>2022-03-16T14:12:35Z</dc:date>
    </item>
    <item>
      <title>Re: Can you help me create a usecase that will alert when a string of failed logins is followed by a successful login?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446875#M6128</link>
      <description>&lt;P&gt;I am not sure of where you are getiting your data... But maybe you could modify this snippet..&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=wineventlog sourcetype=WinEventLog:Security (EventCode="4624" OR EventCode="4625") user!="*$" 
| eval count_failure = if(action=="failure", 1, 0), count_success = if(action=="success", 1, 0)
| eval time_failure = if(action=="failure", _time, "-"), time_success = if(action=="success", _time, "-")
| stats min(time_failure) as first_fail, sum(count_failure) as count_failure, min(time_success) as first_success by user
| eval time_difference = first_success - first_fail
| where count_failure &amp;gt; 0
| search time_difference&amp;gt;400
| eval first_fail=strftime(first_fail,"%Y-%m-%d | %H:%M:%S"), first_success=strftime(first_success,"%Y-%m-%d | %H:%M:%S")
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 02 Nov 2018 18:36:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446875#M6128</guid>
      <dc:creator>rbreton</dc:creator>
      <dc:date>2018-11-02T18:36:06Z</dc:date>
    </item>
    <item>
      <title>Re: Can you help me create a usecase that will alert when a string of failed logins is followed by a successful login?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446876#M6129</link>
      <description>&lt;P&gt;Why not try with a subsearch, looking for failed logins. You can use a stats count by IP, computername or username and have where clause &amp;gt; 10. &lt;/P&gt;

&lt;P&gt;You give that field and the time to the search for looking to successful logins. To control when it is done, you need to play with earliest and latetst time values of the searches.&lt;/P&gt;</description>
      <pubDate>Wed, 07 Nov 2018 07:15:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446876#M6129</guid>
      <dc:creator>osakachan</dc:creator>
      <dc:date>2018-11-07T07:15:30Z</dc:date>
    </item>
    <item>
      <title>Re: Can you help me create a usecase that will alert when a string of failed logins is followed by a successful login?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446877#M6130</link>
      <description>&lt;P&gt;The OOTB Brute Force Behavior correlation rule with ES already does this. Why are you trying to create a custom one?&lt;/P&gt;</description>
      <pubDate>Wed, 07 Nov 2018 19:17:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446877#M6130</guid>
      <dc:creator>bcyates</dc:creator>
      <dc:date>2018-11-07T19:17:07Z</dc:date>
    </item>
    <item>
      <title>Re: Can you help me create a usecase that will alert when a string of failed logins is followed by a successful login?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446878#M6131</link>
      <description>&lt;P&gt;Like this (maybe put some of the last &lt;CODE&gt;| search&lt;/CODE&gt; stuff into the &lt;CODE&gt;WHERE&lt;/CODE&gt; clause of &lt;CODE&gt;tstats&lt;/CODE&gt;&lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| tstats summariesonly=true  count(eval('action'=="failure")) AS failure count(eval('action'=="success")) AS success
FROM datamodel=Authentication
WHERE index=*
BY _time span=10m "Authentication.src_user"
| search success&amp;gt;0 AND failure&amp;gt;=10 AND (Authentication.src_user!="NULL SID" AND NOT Authentication.src_user="-" AND NOT Authentication.src_user="unknown")
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 08 Nov 2018 02:11:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446878#M6131</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2018-11-08T02:11:04Z</dc:date>
    </item>
    <item>
      <title>Re: Can you help me create a usecase that will alert when a string of failed logins is followed by a successful login?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446879#M6132</link>
      <description>&lt;P&gt;Here's the Brute Force Correlation search in ES, you would just need to ensure your data is in the CIM datamodel. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| from datamodel:"Authentication"."Authentication" | stats values(tag) as tag,values(app) as app,count(eval('action'=="failure")) as failure,count(eval('action'=="success")) as success by src | search success&amp;gt;0 | xswhere failure from failures_by_src_count_1h in authentication is above medium | `settags("access")`
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 28 Feb 2019 14:34:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/446879#M6132</guid>
      <dc:creator>solarboyz1</dc:creator>
      <dc:date>2019-02-28T14:34:08Z</dc:date>
    </item>
    <item>
      <title>Re: Can you help me create a usecase that will alert when a string of failed logins is followed by a successful login?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/589261#M10676</link>
      <description>&lt;P&gt;Note:&amp;nbsp; 'TsidxStats': The tstats / mstats command cannot apply eval function to aggregation function.&lt;/P&gt;</description>
      <pubDate>Wed, 16 Mar 2022 10:40:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/Can-you-help-me-create-a-usecase-that-will-alert-when-a-string/m-p/589261#M10676</guid>
      <dc:creator>plaftaric</dc:creator>
      <dc:date>2022-03-16T10:40:02Z</dc:date>
    </item>
  </channel>
</rss>

