Splunk Search

If I have a search that returns a list of IP addresses, what would be the syntax to check if IPs in a second list do not appear in this result set?

alexl1
Path Finder

hi,

Say I have a search that returns a list of IP addresses. What is the syntax to check if IPs in a second list do not appear in this result set?

Tags (2)
0 Karma

yannK
Splunk Employee
Splunk Employee

First, if you have a field that contains several IPs you can split the events
- you may want to define a multivalue field (see makemv)
- and split each event in one event per IP (see mvexpand) .
see http://docs.splunk.com/Documentation/Splunk/6.2.2/Search/Parsemultivaluefields

Second, to do the matching between the results and the second list.
You can use several methods like :
- use JOIN command (only if you have less than 10000 lines in the list)
- use a lookup, and maybe add a command to mark the matching/non matching events.

0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...