Splunk Search

How can I search to show when consecutive events occur/ specific patterns apply?

nnimbe
Path Finder

Hi All,

I need the command for consecutive events which is triggered one after another out of multiple events( 3 consecutive events from 100 events)

for example if we receive any hits from external IP towards our web-server as accept,accept, deny or deny, deny accept or in windows if we receive the account successfully login, account created, change password attempt etc

The goal to get three or more consecutive events generated one after another out of 100 logs to identify specific pattern

Can anyone please help with Splunk command to achieve the same

0 Karma

nnimbe
Path Finder

Thanks @cusello, meanwhile | transaction startswith="logfail" endswith="login" will provide you the starting and ending event but if i want to capture three or four consecutive events as stated above, for exmaple accept,accept,deny or login,changepassword,logout then whether any command to achieve this, that's my query

if we use transaction command on first and last event we don't have control over the inbetween events and there is a chance it may vary with actual events which we are looking for

0 Karma

gcusello
SplunkTrust
SplunkTrust

Hi nnimbe,
try with transaction (isn't very performant!):

your_search
| transaction startswith="logfail" endswith="login"
| where eventcount> 5

obviously startswith and endswith must be customized for your searches and eventcount is the threeshold level that you like.
Bye.
Giuseppe

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...