Splunk Search

Search events for multiple samaccountnames

papa
Explorer

Hello 

Cam someone assist on how to do a search like below for multiple samaccountnames ? 

ideally from a txt file or CSV ? so to reference the file in the search . 

 

 

 

<SamAccountName> EventCode=4624 | table _time,EventCode,src,user,Logon_Type

 

 

Labels (1)

inventsekar
SplunkTrust
SplunkTrust

Hi @papa , As @renjith_nair suggested, the lookup is one idea. or if you already ingested the 
multiple samaccountnames csv files to splunk, then, you can simply query the multiple files altogether.  my apologies if you already know this method. 

index=indexName <multiple-SamAccountNames> EventCode=4624 | table _time,EventCode,src,user,Logon_Type
thanks and best regards,
Sekar

PS - If this or any post helped you in any way, pls consider upvoting, thanks for reading !
0 Karma

renjith_nair
Legend

Try

index="your index" EventCode=4624 [|inputlookup SamAccountName.csv|fields SamAccountName] 

This should create an OR'd list of SamAccountName

---
What goes around comes around. If it helps, hit it with Karma 🙂
Get Updates on the Splunk Community!

Index This | When is October more than just the tenth month?

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

Observe and Secure All Apps with Splunk

  Join Us for Our Next Tech Talk: Observe and Secure All Apps with SplunkAs organizations continue to innovate ...

What’s New & Next in Splunk SOAR

 Security teams today are dealing with more alerts, more tools, and more pressure than ever.  Join us for an ...