<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Need to search IP address in a list of IP/CIDR list and if matched need to return the Name associated with it. in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Need-to-search-IP-address-in-a-list-of-IP-CIDR-list-and-if/m-p/678544#M232032</link>
    <description>&lt;P&gt;I think you have to make all IP values CIDR (1.2.3.4/32, for example).&lt;/P&gt;</description>
    <pubDate>Fri, 23 Feb 2024 21:40:00 GMT</pubDate>
    <dc:creator>richgalloway</dc:creator>
    <dc:date>2024-02-23T21:40:00Z</dc:date>
    <item>
      <title>Need to search IP address in a list of IP/CIDR list and if matched need to return the Name associated with it.</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-to-search-IP-address-in-a-list-of-IP-CIDR-list-and-if/m-p/678525#M232023</link>
      <description>&lt;P&gt;I have a lookup table with 2 fields IP and Name&lt;/P&gt;&lt;P&gt;IP Name&lt;/P&gt;&lt;P&gt;['1.2.3.4', '2.3.5.0/24'] -&amp;gt; name1&lt;/P&gt;&lt;P&gt;['1.2.3.4',.6.7.8.9/31, 4.5.6.7,1.1.1.1] -&amp;gt; name2&lt;/P&gt;&lt;P&gt;[3.3.3.3/31, 4.4.4.4] -&amp;gt; name3&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a list of IPs like "1.2.3.4, 2.3.5.1"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This should give me result of lookup table names where the IPs are present.&lt;/P&gt;&lt;P&gt;So in the above example result would be as the&amp;nbsp;"1.2.3.4, 2.3.5.1" are present in first 2 rows.&lt;/P&gt;&lt;P&gt;name1&lt;/P&gt;&lt;P&gt;name2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Feb 2024 18:02:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-to-search-IP-address-in-a-list-of-IP-CIDR-list-and-if/m-p/678525#M232023</guid>
      <dc:creator>sahastrabuddhe</dc:creator>
      <dc:date>2024-02-23T18:02:55Z</dc:date>
    </item>
    <item>
      <title>Re: Need to search IP address in a list of IP/CIDR list and if matched need to return the Name associated with it.</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-to-search-IP-address-in-a-list-of-IP-CIDR-list-and-if/m-p/678534#M232027</link>
      <description>&lt;P&gt;Unless the lookup is defined with the &lt;FONT face="courier new,courier"&gt;CIDR&lt;/FONT&gt;, &lt;FONT face="courier new,courier"&gt;WILDCARD&lt;/FONT&gt;, or case-insensitive option, it will do exact string matching.&amp;nbsp; Even with those options, there is no way to get "1.2.3.4" to match "['1.2.3.4', '2.3.5.0/24']".&amp;nbsp; The multiple IP addresses in each line should be put on separate lines.&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="50%"&gt;IP&lt;/TD&gt;&lt;TD width="50%"&gt;Name&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;1.2.3.4&lt;/TD&gt;&lt;TD width="50%"&gt;name1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;2.3.5.0/24&lt;/TD&gt;&lt;TD width="50%"&gt;name1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;1.2.3.4&lt;/TD&gt;&lt;TD width="50%"&gt;name2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;6.7.8.9/31&lt;/TD&gt;&lt;TD width="50%"&gt;name2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;4.5.6.7&lt;/TD&gt;&lt;TD width="50%"&gt;name2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;1.1.1.1&lt;/TD&gt;&lt;TD width="50%"&gt;name2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;3.3.3.3/31&lt;/TD&gt;&lt;TD width="50%"&gt;name3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;4.4.4.4&lt;/TD&gt;&lt;TD width="50%"&gt;name3&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Note that the IP field is ambiguous because both name1 and name2 share an IP address.&amp;nbsp; The &lt;FONT face="courier new,courier"&gt;lookup&lt;/FONT&gt; command will return only the first matching IP.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Feb 2024 20:24:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-to-search-IP-address-in-a-list-of-IP-CIDR-list-and-if/m-p/678534#M232027</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2024-02-23T20:24:10Z</dc:date>
    </item>
    <item>
      <title>Re: Need to search IP address in a list of IP/CIDR list and if matched need to return the Name associated with it.</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-to-search-IP-address-in-a-list-of-IP-CIDR-list-and-if/m-p/678536#M232029</link>
      <description>&lt;P&gt;How should I format the lookup definition so that it takes both CIDR match and indivisual IP match&lt;BR /&gt;What I mean to say is if I go to advance settings and change the match criteria to CIDR(IP) its not matching the elements where the IP is single IP and not a CIDR&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Feb 2024 20:30:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-to-search-IP-address-in-a-list-of-IP-CIDR-list-and-if/m-p/678536#M232029</guid>
      <dc:creator>sahastrabuddhe</dc:creator>
      <dc:date>2024-02-23T20:30:22Z</dc:date>
    </item>
    <item>
      <title>Re: Need to search IP address in a list of IP/CIDR list and if matched need to return the Name associated with it.</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-to-search-IP-address-in-a-list-of-IP-CIDR-list-and-if/m-p/678544#M232032</link>
      <description>&lt;P&gt;I think you have to make all IP values CIDR (1.2.3.4/32, for example).&lt;/P&gt;</description>
      <pubDate>Fri, 23 Feb 2024 21:40:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-to-search-IP-address-in-a-list-of-IP-CIDR-list-and-if/m-p/678544#M232032</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2024-02-23T21:40:00Z</dc:date>
    </item>
  </channel>
</rss>

