<?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: Edit authentication.conf via CLI in Security</title>
    <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375576#M9272</link>
    <description>&lt;P&gt;Also, &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/194012"&gt;@saranya_fmr&lt;/a&gt;, please be aware that the conf file does not HAVE to live in &lt;CODE&gt;$SPLUNK_HOME/system/local/&lt;/CODE&gt;. Your config can (and should) live in an app so it can be centrally controlled and deployed.&lt;/P&gt;

&lt;P&gt;This is a great page on the topic: &lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/Admin/Wheretofindtheconfigurationfiles" target="_blank"&gt;http://docs.splunk.com/Documentation/Splunk/latest/Admin/Wheretofindtheconfigurationfiles&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;If you want to learn more, the Admin and Clustering edu classes should be great.&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 14:57:31 GMT</pubDate>
    <dc:creator>sloshburch</dc:creator>
    <dc:date>2020-09-29T14:57:31Z</dc:date>
    <item>
      <title>Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375568#M9264</link>
      <description>&lt;P&gt;I want to change the ldap account adn its password on all the SHs via CLI.&lt;/P&gt;

&lt;P&gt;I tried changing the ldap account and password via a script to edit/relace the account and password , and then restarted Splunk.&lt;/P&gt;

&lt;P&gt;But this doesn't seem to work.&lt;/P&gt;

&lt;P&gt;After I did that , I see that there's no Authentication method at all in the Splunk SH UI like below:&lt;BR /&gt;
&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/3147i1EC5232AF4502AFE/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;After I select LDAP method I see the two accounts without any AD  accounts mapped&lt;/P&gt;

&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/3148iD4923D81572B61E6/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;How do I to edit the authentication.conf file with new ldap account and password without any breakage like above??&lt;/P&gt;</description>
      <pubDate>Mon, 03 Jul 2017 13:38:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375568#M9264</guid>
      <dc:creator>saranya_fmr</dc:creator>
      <dc:date>2017-07-03T13:38:14Z</dc:date>
    </item>
    <item>
      <title>Re: Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375569#M9265</link>
      <description>&lt;P&gt;This seems .. unlikely .. I would suspect something unanticipated in your editing of the file.&lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt; I have edited authentication.conf many times directly via the CLI and had no issues like this, especially after a restart.  (It is possible to reload most authentication.props properties w/o a restart via the REST API but that is a little off topic for here)&lt;/LI&gt;
&lt;LI&gt;Authentication.conf (like all other conf files) is subject to btool's merging rules across apps.  Make certain you are editing the right authentication.conf file(s) to affect your change.&lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;I think more information is needed (like a before and after of the file itself) before we can give great guidance on what went wrong.&lt;/P&gt;</description>
      <pubDate>Mon, 03 Jul 2017 13:47:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375569#M9265</guid>
      <dc:creator>dwaddle</dc:creator>
      <dc:date>2017-07-03T13:47:55Z</dc:date>
    </item>
    <item>
      <title>Re: Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375570#M9266</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/278"&gt;@dwaddle&lt;/a&gt; &lt;/P&gt;

&lt;P&gt;All I did was a script to replace the ldap account and its password.&lt;/P&gt;

&lt;P&gt;The file has got replaced with accountname and password but the password has not got encrypted after the splunk restart:&lt;/P&gt;

&lt;P&gt;auth.conf Before&lt;BR /&gt;
[lassie_np_ldap]&lt;BR /&gt;
sslenabled = 1&lt;BR /&gt;
anonymous_referrals = 1&lt;BR /&gt;
binddn = cn=ezp_splunk_ldap,OU=ServiceAccounts,DC=im,DC=tcsco,DC=com&lt;BR /&gt;
binddnpassword = $1$Hx+uKRbWP/f3&lt;BR /&gt;
charset = utf8&lt;BR /&gt;
emailattribute = mail&lt;BR /&gt;
groupbasedn = OU=FIMT_Managed,OU=Groups,DC=im,DC=tcsco,DC=com&lt;BR /&gt;
groupbasefilter = (|(cn=FIMT-LASSIE-&lt;EM&gt;) (cn=FIMTMON_&lt;/EM&gt;))&lt;BR /&gt;
groupmappingattribute = dn&lt;BR /&gt;
groupmemberattribute = member&lt;BR /&gt;
groupnameattribute = cn&lt;BR /&gt;
host = ldapserver.tcsco.com&lt;BR /&gt;
nestedgroups = 0&lt;BR /&gt;
network_timeout = 20&lt;BR /&gt;
port = 636&lt;BR /&gt;
realnameattribute = displayname&lt;BR /&gt;
sizelimit = 1000&lt;BR /&gt;
timelimit = 15&lt;BR /&gt;
userbasedn = DC=im,DC=tcsco,DC=com&lt;BR /&gt;
userbasefilter = (objectclass=*)&lt;BR /&gt;
usernameattribute = samaccountname&lt;/P&gt;

&lt;P&gt;auth.conf After:&lt;BR /&gt;
[lassie_np_ldap]&lt;BR /&gt;
sslenabled = 1&lt;BR /&gt;
anonymous_referrals = 1&lt;BR /&gt;
binddn = cn=ezp_splunk_ldap_dev,OU=ServiceAccounts,DC=im,DC=tcsco,DC=com&lt;BR /&gt;
binddnpassword = N3F1vSvt&lt;BR /&gt;
charset = utf8&lt;BR /&gt;
emailattribute = mail&lt;BR /&gt;
groupbasedn = OU=FIMT_Managed,OU=Groups,DC=im,DC=tcsco,DC=com&lt;BR /&gt;
groupbasefilter = (|(cn=FIMT-LASSIE-&lt;EM&gt;) (cn=FIMTMON_&lt;/EM&gt;))&lt;BR /&gt;
groupmappingattribute = dn&lt;BR /&gt;
groupmemberattribute = member&lt;BR /&gt;
groupnameattribute = cn&lt;BR /&gt;
host = ldapserver.tcsco.com&lt;BR /&gt;
nestedgroups = 0&lt;BR /&gt;
network_timeout = 20&lt;BR /&gt;
port = 636&lt;BR /&gt;
realnameattribute = displayname&lt;BR /&gt;
sizelimit = 1000&lt;BR /&gt;
timelimit = 15&lt;BR /&gt;
userbasedn = DC=im,DC=tcsco,DC=com&lt;BR /&gt;
userbasefilter = (objectclass=*)&lt;BR /&gt;
usernameattribute = samaccountname&lt;/P&gt;

&lt;P&gt;Im using $SPLUNK_HOME/splunk/etc/system/local/authentication.conf" on all the SHs to make the changes.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 14:42:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375570#M9266</guid>
      <dc:creator>saranya_fmr</dc:creator>
      <dc:date>2020-09-29T14:42:25Z</dc:date>
    </item>
    <item>
      <title>Re: Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375571#M9267</link>
      <description>&lt;P&gt;Please check you have proper file read/write permission on authentication.conf&lt;/P&gt;</description>
      <pubDate>Mon, 03 Jul 2017 14:35:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375571#M9267</guid>
      <dc:creator>sbbadri</dc:creator>
      <dc:date>2017-07-03T14:35:55Z</dc:date>
    </item>
    <item>
      <title>Re: Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375572#M9268</link>
      <description>&lt;P&gt;"On all Search Heads" is this in a Search Head Cluster? Directly editing the conf files in a SHC could break the cluster.&lt;/P&gt;

&lt;P&gt;I agree that you need to check with btool, not the conf file, to see what's up. Sometimes the hashed version of the password ends up getting stored in another conf file and you wouldn't see it until you comment out the one being loaded and see what else is potentially loaded.&lt;/P&gt;</description>
      <pubDate>Thu, 06 Jul 2017 17:16:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375572#M9268</guid>
      <dc:creator>sloshburch</dc:creator>
      <dc:date>2017-07-06T17:16:19Z</dc:date>
    </item>
    <item>
      <title>Re: Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375573#M9269</link>
      <description>&lt;P&gt;So, are the above your whole authentication.conf?  There's some things missing.  Like I would expect to see:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[authentication]
authSettings = lassie_np_ldap
authType = LDAP
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Or something similar ..  also a &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[rolemap_lassie_np_ldap]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;section that specifies the role mappings.   As @SloshBurch said prior, "use btool"  &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 07 Jul 2017 13:26:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375573#M9269</guid>
      <dc:creator>dwaddle</dc:creator>
      <dc:date>2017-07-07T13:26:33Z</dc:date>
    </item>
    <item>
      <title>Re: Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375574#M9270</link>
      <description>&lt;P&gt;Hi @dwaddle ,&lt;/P&gt;

&lt;P&gt;I figured out that it was my python script that was causing the problem. It was modifying the file in a fashion that we couldnt figure out all although the contents looked fine.&lt;BR /&gt;
Thankyou for your support.&lt;/P&gt;

&lt;P&gt;However I had another query,&lt;BR /&gt;
how do we push the config changes for the authentication.file via the deployer to the SHs?&lt;/P&gt;

&lt;P&gt;Doesn't shcluster apply bundle push the changes from $SPLUNK_HOME/splunk/etc/shcluster to the SHs?&lt;/P&gt;

&lt;P&gt;However the authentication.file is located at $SPLUNK_HOME/splunk/etc/system/local right?&lt;/P&gt;</description>
      <pubDate>Wed, 12 Jul 2017 16:58:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375574#M9270</guid>
      <dc:creator>saranya_fmr</dc:creator>
      <dc:date>2017-07-12T16:58:49Z</dc:date>
    </item>
    <item>
      <title>Re: Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375575#M9271</link>
      <description>&lt;P&gt;Your need to create a separate app for Authentication say all_auth.&lt;/P&gt;

&lt;P&gt;Deployer:&lt;/P&gt;

&lt;P&gt;$SPLUNK_HOME/etc/shcluster/apps/all_auth/local&lt;/P&gt;

&lt;P&gt;authentication.conf  - only your role mapping like below&lt;BR /&gt;
[roleMap_ldap_sssd]&lt;BR /&gt;
role_user_group = ad_group1&lt;/P&gt;

&lt;P&gt;authorize.conf - copy authorize.conf from $SPLUNK_HOME/etc/system/local/authorize.conf from one of  search head from the cluster.&lt;/P&gt;

&lt;P&gt;Search head:&lt;/P&gt;

&lt;P&gt;$SPLUNK_HOME/etc/system/local&lt;/P&gt;

&lt;P&gt;authentication.conf - only ldap configuration settings.&lt;BR /&gt;
authorize.conf - there should not be any  authorize.conf. Rename authorize.conf to something else&lt;/P&gt;

&lt;P&gt;Go to deployer's $SPLUNK_HOME/bin and execute this command ./splunk apply shcluster-bundle -target &lt;A href="https://search_head_captain's-ip:8089" target="_blank"&gt;https://search_head_captain's-ip:8089&lt;/A&gt; -preserve-lookups true&lt;/P&gt;

&lt;P&gt;Once pushed check all search head in the cluster should all_auth folder. Then go to GUI splunk instance under settings-&amp;gt;access control-&amp;gt; ldap settings-&amp;gt;map groups-&amp;gt; all role you have created should be present.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 14:51:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375575#M9271</guid>
      <dc:creator>sbbadri</dc:creator>
      <dc:date>2020-09-29T14:51:07Z</dc:date>
    </item>
    <item>
      <title>Re: Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375576#M9272</link>
      <description>&lt;P&gt;Also, &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/194012"&gt;@saranya_fmr&lt;/a&gt;, please be aware that the conf file does not HAVE to live in &lt;CODE&gt;$SPLUNK_HOME/system/local/&lt;/CODE&gt;. Your config can (and should) live in an app so it can be centrally controlled and deployed.&lt;/P&gt;

&lt;P&gt;This is a great page on the topic: &lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/Admin/Wheretofindtheconfigurationfiles" target="_blank"&gt;http://docs.splunk.com/Documentation/Splunk/latest/Admin/Wheretofindtheconfigurationfiles&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;If you want to learn more, the Admin and Clustering edu classes should be great.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 14:57:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375576#M9272</guid>
      <dc:creator>sloshburch</dc:creator>
      <dc:date>2020-09-29T14:57:31Z</dc:date>
    </item>
    <item>
      <title>Re: Edit authentication.conf via CLI</title>
      <link>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375577#M9273</link>
      <description>&lt;P&gt;our need to create a separate app for Authentication say all_auth.&lt;/P&gt;

&lt;P&gt;Deployer:&lt;/P&gt;

&lt;P&gt;$SPLUNK_HOME/etc/shcluster/apps/all_auth/local&lt;/P&gt;

&lt;P&gt;authentication.conf - only your role mapping like below&lt;BR /&gt;
[roleMap_ldap_sssd]&lt;BR /&gt;
role_user_group = ad_group1&lt;/P&gt;

&lt;P&gt;authorize.conf - copy authorize.conf from $SPLUNK_HOME/etc/system/local/authorize.conf from one of search head from the cluster.&lt;/P&gt;

&lt;P&gt;Search head:&lt;/P&gt;

&lt;P&gt;$SPLUNK_HOME/etc/system/local&lt;/P&gt;

&lt;P&gt;authentication.conf - only ldap configuration settings.&lt;BR /&gt;
authorize.conf - there should not be any authorize.conf. Rename authorize.conf to something else&lt;/P&gt;

&lt;P&gt;Go to deployer's $SPLUNK_HOME/bin and execute this command ./splunk apply shcluster-bundle -target &lt;A href="https://search_head_captain's-ip:8089" target="_blank"&gt;https://search_head_captain's-ip:8089&lt;/A&gt; -preserve-lookups true&lt;/P&gt;

&lt;P&gt;Once pushed check all search head in the cluster should all_auth folder. Then go to GUI splunk instance under settings-&amp;gt;access control-&amp;gt; ldap settings-&amp;gt;map groups-&amp;gt; all role you have created should be present.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 14:55:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Security/Edit-authentication-conf-via-CLI/m-p/375577#M9273</guid>
      <dc:creator>sbbadri</dc:creator>
      <dc:date>2020-09-29T14:55:45Z</dc:date>
    </item>
  </channel>
</rss>

