Splunk Search

Brute force detection

rahul_mckc_splu
Loves-to-Learn

This is my search for detecting brute force behavior-
index="wineventlog" sourcetype=wineventlog:security | stats dc(action) as Attempts, earliest(_time) as FirstAppearance
count(eval(match(action,"failure"))) as Failed,
count(eval(match(action,"success"))) as Success
max(eval(case(match(action,"failure"),_time))) as lastFailed
max(eval(case(match(action,"success"),_time))) as lastSuccess
values(src) as src by user
| where Attempts>1 AND Failed>100 AND Success>0
| where lastFailed < lastSuccess

Now what is happening it is taking cumulative of 100 as failures and if there is 1 success then it is triggering....
My question is how can i restrict it to 100 failures consecutive prior to 1-success i mean 1st event should not be success.

Tags (1)
0 Karma

adonio
Ultra Champion
Get Updates on the Splunk Community!

Data Management Digest – December 2025

Welcome to the December edition of Data Management Digest! As we continue our journey of data innovation, the ...

Index This | What is broken 80% of the time by February?

December 2025 Edition   Hayyy Splunk Education Enthusiasts and the Eternally Curious!    We’re back with this ...

Unlock Faster Time-to-Value on Edge and Ingest Processor with New SPL2 Pipeline ...

Hello Splunk Community,   We're thrilled to share an exciting update that will help you manage your data more ...