<?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 regex to pull cn fields in Security</title>
    <link>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661339#M17335</link>
    <description>&lt;P&gt;Hey everyone,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have this format -&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;cn=&amp;lt;name&amp;gt;,ou=&amp;lt;&amp;gt;,ou=people,dc=&amp;lt;&amp;gt;,dc=&amp;lt;&amp;gt;,dc=&amp;lt;&amp;gt; that i'm pulling that i need to use only the cn= field. how can i do it with the regex command? is that possible?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;thanks!!&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 19 Oct 2023 10:02:04 GMT</pubDate>
    <dc:creator>spluser1</dc:creator>
    <dc:date>2023-10-19T10:02:04Z</dc:date>
    <item>
      <title>regex to pull cn fields</title>
      <link>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661339#M17335</link>
      <description>&lt;P&gt;Hey everyone,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have this format -&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;cn=&amp;lt;name&amp;gt;,ou=&amp;lt;&amp;gt;,ou=people,dc=&amp;lt;&amp;gt;,dc=&amp;lt;&amp;gt;,dc=&amp;lt;&amp;gt; that i'm pulling that i need to use only the cn= field. how can i do it with the regex command? is that possible?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;thanks!!&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 19 Oct 2023 10:02:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661339#M17335</guid>
      <dc:creator>spluser1</dc:creator>
      <dc:date>2023-10-19T10:02:04Z</dc:date>
    </item>
    <item>
      <title>Re: regex to pull cn fields</title>
      <link>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661340#M17336</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;you could use this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;...
| rex field=&amp;lt;your existing field&amp;gt; "cn=(?&amp;lt;cn&amp;gt;[^,]+)"&lt;/LI-CODE&gt;&lt;P&gt;r. Ismo&lt;/P&gt;&lt;P&gt;PS. regex101.com is excellent place to test these!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 19 Oct 2023 10:15:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661340#M17336</guid>
      <dc:creator>isoutamo</dc:creator>
      <dc:date>2023-10-19T10:15:11Z</dc:date>
    </item>
    <item>
      <title>Re: regex to pull cn fields</title>
      <link>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661342#M17337</link>
      <description>&lt;P&gt;thanks for the info.&lt;/P&gt;&lt;P&gt;when saying your existing field you mean to put the actual field that contain the format? also is there a way to save that so i could do a stats to show the output only with the cn value?&lt;/P&gt;</description>
      <pubDate>Thu, 19 Oct 2023 10:20:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661342#M17337</guid>
      <dc:creator>spluser1</dc:creator>
      <dc:date>2023-10-19T10:20:30Z</dc:date>
    </item>
    <item>
      <title>Re: regex to pull cn fields</title>
      <link>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661344#M17338</link>
      <description>If you have extracted that whole value into some field (e.g. ldap_query) then use it. If that value is still in _raw then you could leave that field=xxxx part away. Just see &lt;A href="https://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Rex" target="_blank"&gt;https://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Rex&lt;/A&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 19 Oct 2023 10:25:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661344#M17338</guid>
      <dc:creator>isoutamo</dc:creator>
      <dc:date>2023-10-19T10:25:39Z</dc:date>
    </item>
    <item>
      <title>Re: regex to pull cn fields</title>
      <link>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661345#M17339</link>
      <description>&lt;P&gt;excellent, i see it now. works perfect. thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 19 Oct 2023 10:28:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661345#M17339</guid>
      <dc:creator>spluser1</dc:creator>
      <dc:date>2023-10-19T10:28:49Z</dc:date>
    </item>
    <item>
      <title>Re: regex to pull cn fields</title>
      <link>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661346#M17340</link>
      <description>As it solve you problem, please accept it as Solution so other can see it later.&lt;BR /&gt;Happy Splunking!</description>
      <pubDate>Thu, 19 Oct 2023 10:32:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/regex-to-pull-cn-fields/m-p/661346#M17340</guid>
      <dc:creator>isoutamo</dc:creator>
      <dc:date>2023-10-19T10:32:43Z</dc:date>
    </item>
  </channel>
</rss>

