Splunk Search

how do i query all events with ID4738 for a specific user?

tksre
New Member

how do i query all events with windows ID 4738 for a specific user

Tags (1)
0 Karma

stakor
Path Finder

If you do not have the windows TA installed, you can do something quick and dirty, like:
"EventCode=4738"
That will find your event ID, but to get the user name, you will need a fairly complex regex query using the rex command, because there are two "Account Name:"'s in the log, and you are probably looking for the second one. If you can use the Windows TA, it would probably be best to use that. Or follow gpradeepkumarreddy's advice, and just use:

index=<your_index> "EventCode=4738" "Account Name:*?<user_name>"
  • edited to insert "?", typo-ed it.
0 Karma

pradeepkumarg
Influencer

can you paste some sample events ? It might be as simple as below provided you have all the fields extracted

index=your_index user="your_user" ID="4738" 
0 Karma

adonio
Ultra Champion

index = your_index EventCode = 4738 user = yourUniqueUser
do you use the Windows TA?

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 ...