<?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: How to assign a Category and Priority for Splunk Enterprise Security using ldapsearch? in Splunk Enterprise Security</title>
    <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/How-to-assign-a-Category-and-Priority-for-Splunk-Enterprise/m-p/308236#M2793</link>
    <description>&lt;P&gt;ADSI Edit can help you here.  Run "ADSI Edit", drill down to the section where the right CN is (Enterprise Admins in this case), right-click on it and pick "properties" , then scroll down in there to find the various fields you need.  If you click the "view" button when you have the right value selected, you can copy and paste it out of there.&lt;/P&gt;</description>
    <pubDate>Mon, 20 Feb 2017 01:36:17 GMT</pubDate>
    <dc:creator>Richfez</dc:creator>
    <dc:date>2017-02-20T01:36:17Z</dc:date>
    <item>
      <title>How to assign a Category and Priority for Splunk Enterprise Security using ldapsearch?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/How-to-assign-a-Category-and-Priority-for-Splunk-Enterprise/m-p/308234#M2791</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;

&lt;P&gt;I'm trying to create a Identity Lookup for Splunk Enterprise Security. I have a users from Group and OU's which has to be critical, I'm using the below search, OU case is working but no the group one, is there anything I'm missing?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| ldapsearch domain="XXXXX" search="(&amp;amp;(objectClass=user)(!(objectClass=computer)))" attrs="sAMAccountName,displayName,givenName,sn,mail,telephoneNumber,manager,department,whenCreated,accountExpires, userAccountControl, distinguishedName,userPrincipalName,employeeID"
|search userAccountControl="NORMAL_ACCOUNT"
|eval suffix=""
| eval priority=case(       like(distinguishedName,"%OU=AdminAccounts,DC=XXXXXXX,DC=com"), "critical",
                            like(distinguishedName,"%OU=DomainAdmins,OU=AdminAccounts,DC=XXXXXX,DC=com"), "critical", 
                            like(sAMAccountName,"%CN=Enterprise Admins ,CN=Users,DC=XXXXXX,DC=com"), "critical",

                            1==1,"medium" )

 | eval category=case(      like(distinguishedName,"%OU=DomainAdmins,OU=AdminAccounts,DC=XXXXXX,DC=com"), "Domain Admins" ,
                            like(distinguishedName,"%OU=AdminAccounts,DC=XXXXXX,DC=com"), "Admin Accounts",
                            like(sAMAccountName,"%CN=Enterprise Admins ,CN=Users,DC=XXXXXX,DC=com"), "Enterprise Admins",
                             1==1,"normal" )
|eval endDate=""
|eval watchlist="false"
|table sAMAccountName ,personalTitle,displayName,givenName,sn,suffix,mail,telephoneNumber,mobile,manager,priority,department,category,watchlist,startDate,endDate
|rename sAMAccountName as identity,personalTitle as prefix, displayName as nick, givenName as first, sn as last, mail as email, telephoneNumber as phone, mobile as phone2, manager as managedBy, department as bunit 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Enterprise ADmins is not working here?&lt;/P&gt;</description>
      <pubDate>Fri, 17 Feb 2017 22:04:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/How-to-assign-a-Category-and-Priority-for-Splunk-Enterprise/m-p/308234#M2791</guid>
      <dc:creator>kiran331</dc:creator>
      <dc:date>2017-02-17T22:04:18Z</dc:date>
    </item>
    <item>
      <title>Re: How to assign a Category and Priority for Splunk Enterprise Security using ldapsearch?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/How-to-assign-a-Category-and-Priority-for-Splunk-Enterprise/m-p/308235#M2792</link>
      <description>&lt;P&gt;(EDIT: Found another issue)&lt;/P&gt;

&lt;P&gt;You have a space in your search that shouldn't be there, and I don't think samaccountname is going to work.  &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;like(sAMAccountName,"%CN=Enterprise Admins ,CN=Users,DC=XXXXXX,DC=com"), "critical",
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Should instead be&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;like(distinguishedName,"%CN=Enterprise Admins,CN=Users,DC=XXXXXX,DC=com"), "critical",
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;You probably could use sAMAccountName, but if you do so you need to match on just &lt;CODE&gt;Enterprise Admins&lt;/CODE&gt;.  (At which point you shouldn't need a &lt;CODE&gt;like&lt;/CODE&gt;.)&lt;/P&gt;

&lt;P&gt;Let us know if this works!  Happy Splunking!&lt;/P&gt;

&lt;P&gt;-Rich&lt;/P&gt;</description>
      <pubDate>Mon, 20 Feb 2017 01:26:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/How-to-assign-a-Category-and-Priority-for-Splunk-Enterprise/m-p/308235#M2792</guid>
      <dc:creator>Richfez</dc:creator>
      <dc:date>2017-02-20T01:26:23Z</dc:date>
    </item>
    <item>
      <title>Re: How to assign a Category and Priority for Splunk Enterprise Security using ldapsearch?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise-Security/How-to-assign-a-Category-and-Priority-for-Splunk-Enterprise/m-p/308236#M2793</link>
      <description>&lt;P&gt;ADSI Edit can help you here.  Run "ADSI Edit", drill down to the section where the right CN is (Enterprise Admins in this case), right-click on it and pick "properties" , then scroll down in there to find the various fields you need.  If you click the "view" button when you have the right value selected, you can copy and paste it out of there.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Feb 2017 01:36:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise-Security/How-to-assign-a-Category-and-Priority-for-Splunk-Enterprise/m-p/308236#M2793</guid>
      <dc:creator>Richfez</dc:creator>
      <dc:date>2017-02-20T01:36:17Z</dc:date>
    </item>
  </channel>
</rss>

