Splunk Search

Searching subnets

bengridley
New Member

I noticed with splunk you can search subnets now. However I would like to search for all communications via my internal network to my external network. When doing something like this however it does not work.

src_ip=10.10.0.0/16 dest_ip!=10.10.0.0/16

This does not work. How would I correctly search for what I am seeking?

0 Karma

rtadams89
Contributor

Perhaps make use of the cidrmatch function: * | where NOT cidrmatch("10.10.0.0/16", dest_ip) AND cidrmatch("10.10.0.0/16",src_ip)

Ayn
Legend

That should work. What you could try is specify NOT dest_ip=10.10.0.0/16 instead, but that's rather for covering the case when no dest_ip exists at all.

Get Updates on the Splunk Community!

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...