Table of Contents
  • Home
  • /
  • Blog
  • /
  • Managing Local and LDAP Users in Splunk
May 13, 2024

Managing Local and LDAP Users in Splunk

Managing Local and LDAP Users in Splunk

As a Splunk administrator, one of your key responsibilities is managing user access to ensure the security and integrity of your Splunk environment. In this blog post, we'll dive into the world of user management in Splunk, exploring how to effectively handle both local and LDAP users. Whether you're a seasoned Splunk professional or just starting out, understanding user management is crucial for maintaining a secure and well-organized Splunk deployment.

User accounts are at the heart of access control in Splunk. As a security professional, you're well aware of the importance of authentication, authorization, and accounting (AAA). Splunk provides a robust user management system that allows you to create users, assign roles, and define capabilities. By mastering these concepts, you'll be able to grant appropriate access to users while safeguarding your Splunk environment from unauthorized access.

In this article, we'll answer common questions related to user management in Splunk. You'll learn how to create local users, assign authorizations through roles, and integrate Splunk with LDAP for centralized user authentication. We'll also explore the differences between configuring LDAP via the web interface and the command line. Finally, we'll discuss troubleshooting techniques and best practices for managing Splunk authentication methods in an enterprise environment.

So, let's embark on this journey together and unlock the secrets of effective user management in Splunk!

Understanding Users, Roles, and Capabilities in Splunk

To understand how Splunk manage Users and Roles, it isrequired to clear some of the key concepts: users, roles, capabilities, authentication methods and password management for local or native Splunk users.


In Splunk, a user is an entity that represents an individual who interacts with the Splunk platform. Each user is identified by a unique username and authenticated using a password or other authentication methods. Splunk comes with a few default users preconfigured out of the box:

- admin: The default administrator account with full access to all Splunk features and functions.

- nobody: A special user that represents unauthenticated users or guest access.


Roles in Splunk define a set of permissions and capabilities that determine what actions a user can perform within the platform. Splunk provides five preconfigured roles. They are:

- admin: The most privileged role, granting full access to all Splunk features and functions.

- power: A role with elevated privileges, allowing users to perform most administrative tasks but with some restrictions compared to the admin role.

- user: The default role assigned to new users, providing basic access to search, reporting, and dashboarding capabilities.

- can_delete: A special role that grants the ability to delete indexed data.

- splunk-system-role: A special role used by Splunk system services and processes. It allows actions to be performed on behalf of the system without a specific user context.

Additionally, Splunk allows you to create custom roles tailored to your organization's specific needs.


Capabilities are the granular permissions that define what actions a role can perform. Splunk is preloaded with hundreds of capabilities. Some examples include:

- edit_user: Allows a role to edit user accounts.

- search: Enables a role to perform searches and view results.

- schedule_search: Grants the ability to schedule saved searches.

By assigning capabilities to roles, you can fine-tune the permissions and control what users can do within Splunk. Note: You can't create custom Capabilities. You are only allowed to utilize the given Capabilities.

Authentication Methods

Splunk supports three authentication methods to validate user credentials. They are:

  1. Splunk Authentication: The default authentication method where user credentials are stored and managed within Splunk itself.

  2. LDAP Authentication: Allows Splunk to integrate with an external LDAP directory, such as Active Directory, for centralized user authentication. We'll explore LDAP integration in more detail later in this article.

  3. SAML Authentication: Enables Single Sign-On (SSO) using the Security Assertion Markup Language (SAML) standard. SAML allows users to authenticate using their existing corporate credentials.

Password Policy Management

Splunk also allows let administrators to manage password policies like password complexity, minimum password length, password expiration, and account lockout settings. However, the password policies are applicable only to the local users.

Creating and Managing Users and Roles from Splunk Web UI

Now that you have a solid understanding of users, roles, and capabilities in Splunk, It's time to explore how to create and manage them using the Splunk Web UI. The Web UI provides a user-friendly interface for performing user management tasks, making it easy for you to administer your Splunk environment.

Creating and Deleting a New User

Creating a new user in Splunk is a very simple and straightforward process. You can create a user in a few clicks. follow these step-by-step instructions:

1. Log in to the Splunk Web UI with an account that has admin privileges.

2. Navigate to the "Settings" menu and click on "Users".

3. In the "Users" section, click on the "New User" button.

4. Fill in the required information for the new user:

- Username: Enter a unique username for the user.

- Full name (optional): Provide the user's full name.

- Email address (optional): Enter the user's email address.

- Password: Set a password for the user account.

- Confirm password: Re-enter the password to confirm it.

5. Assign roles to the user by selecting the appropriate roles from the available options. You can choose from the preconfigured roles or any custom roles you've created.

6. Click the "Save" button to create the new user account.

Congratulations! You have successfully created a new user in Splunk.

I don't want to explain the deleting procedure. You should go to the "Settings" menu and click on "Users". locate the user you want to delete. Click on the "Edit", a dropdown appears, select "Delete" to remove the user account. Confirm the deletion by clicking "OK" in the confirmation dialog. That's it. The user account will be permanently deleted from Splunk.

Creating a Custom Role

As for Users, creating roles is also a simple and straightforward procedure. Preconfigured Roles are enough to manage in our opinion. If you want you can do a few modifications to the preconfigured Roles. Anyways, if you want to create a custom Role, follow here:

1. Log in to the Splunk Web UI with an admin account.

2. Navigate to the "Settings" menu and click on "Roles".

3. Click the "New Role" button to create a new custom role.

4. Provide a name for the custom role and select the capabilities you want to assign to it. You can choose from a wide range of capabilities, such as search, edit_user, schedule_search, and more. Or, alternatively, you can inherit the capabilities from the existing Roles.

5. Click the "Create" button to create the custom role.

Your newly created custom role will now be available for assigning to users.

Assigning a Role to a User

You can assign any Role to any User. You need to edit the User you want to add/remove the Roles, select the Role from the list "Available Items", and the selected Role will get added to the User. 

The users and roles you add are local or native users. On the file structure these uses live in $SPLUNK_HOME/etc/passwd file.

Integrating Splunk with LDAP for Centralised User Authentication

As we said in the earlier sections of this article, Splunk supports other two authentication methods. The one which is the most prevalent in enterprise environments is LDAP authentication. Let's see how LDAP authentication works and a little bit about the pre-requisites before integrating LDAP with Splunk.

How Do Splunk and LDAP Integration Work?

When a user enters their username and password, the Splunk instance sends a bind request to the LDAP server and authenticates with it via the Bind DN user. The LDAP server locates the user and returns it to the Splunk instance. Splunk then sends the entered username and password to the LDAP server for validation. If the user is found and the password matches, authentication succeeds, granting access to the Splunk web interface. Otherwise, authentication fails.


1. LDAP server details:

a. Hostname or IP address

b. Port number (default: 389 for non-SSL, 636 for SSL)

2. LDAP bind account:

a. Username and password with sufficient privileges for LDAP searches

b. Avoid using the LDAP administrator account for security reasons

3. LDAP attribute mappings:

a. Identify the LDAP attributes that map to Splunk user properties (e.g., username, email, full name)

b. Determine the LDAP attribute for group membership (e.g., memberOf)

How to Integrate Splunk with LDAP?

Follow these simple steps with prerequisite details in hand.

  1. Log in to Splunk Web UI as an admin.

  2. Go to "Settings" > "Authentication" > "LDAP" > "Configure Splunk to use LDAP".

  3. Click "New LDAP" to create a new LDAP configuration.

1. Provide a unique name for the LDAP configuration.

2. Enter the hostname or IP address of your LDAP server in the "Host" field.

3. Specify the port number in the "Port" field (default: 389 for non-SSL, 636 for SSL).

4. If using SSL, check the "Use SSL" checkbox.

5. Enter the Base DN for user searches in the "User Base DN" field. This is the starting point in the LDAP directory where Splunk will search for user accounts.

6. Provide the LDAP bind account username and password in the "Bind DN" and "Bind Password" fields, respectively. This account should have sufficient privileges to perform LDAP searches.

7. Map the LDAP attributes to Splunk user properties in the "User Attribute Mappings" section. For example, map the LDAP attribute for the username (e.g., sAMAccountName) to the Splunk "Username" field.

8. Enter the Base DN for group searches in the "Group Base DN" field. This is the starting point in the LDAP directory where Splunk will search for groups.

9. Specify the LDAP attribute for group membership (e.g., memberOf) in the "Group Membership Attribute" field.

10. Click the "Save" button to create the LDAP configuration.

Splunk will now attempt to connect to the LDAP server and validate the configuration. If successful, LDAP authentication will be enabled.

Mapping LDAP Groups to Splunk Roles:

  1. Click the "New Mapping" button to create a new LDAP group to Splunk role mapping.

  2. Specify the LDAP group DN in the "Group DN" field.

  3. Select the Splunk role to assign to members of the LDAP group in the "Role" dropdown.

  4. Click the "Save" button to create the mapping.

  5. Repeat these steps for each LDAP group you want to map to a Splunk role.

Integrating Splunk with LDAP from the Command Line Interface (CLI)

While the Splunk Web UI provides a user-friendly way to configure LDAP integration, you can also set up LDAP authentication using the Splunk Command Line Interface (CLI). This method offers more flexibility and allows you to directly edit the configuration files. Let's walk through the step-by-step process of integrating Splunk with LDAP from the CLI.

Step 1: Access the Splunk Server

Connect to your Splunk server using SSH or a terminal. Make sure you have the necessary permissions to access and modify the Splunk configuration files.

Step 2: Navigate to the Splunk Configuration Directory

Once logged in, navigate to the Splunk configuration directory. By default, the directory is located at $SPLUNK_HOME/etc/system/local. Use the following command:

cd $SPLUNK_HOME/etc/system/local

Step 3: Create or Edit the LDAP Configuration File

In the Splunk configuration directory, you'll find the authentication.conf file. This file is used to configure authentication settings, including LDAP integration. Open the file using a text editor such as vi or nano:

sudo vi authentication.conf

If the file doesn't exist, create a new file with the same name.

Step 4: Configure LDAP Settings

Inside the authentication.conf file, add the following stanzas and properties to configure LDAP integration:

authType = LDAP
authSettings = my_ldap_config

host =
port = 389
SSLEnabled = 0
userBaseDN = ou=Users,dc=example,dc=com
userNameAttribute = sAMAccountName
realNameAttribute = displayName
groupMappingAttribute = memberOf
groupBaseDN = ou=Groups,dc=example,dc=com

Modify the values according to your LDAP server configuration:

- host: The hostname or IP address of your LDAP server.

- port: The port number for LDAP communication (default: 389 for non-SSL, 636 for SSL).

- SSLEnabled: Set to 1 if using SSL, 0 otherwise.

- userBaseDN: The base Distinguished Name (DN) for user searches.

- userNameAttribute: The LDAP attribute that maps to the Splunk username.

- realNameAttribute: The LDAP attribute for the user's real name.

- groupMappingAttribute: The LDAP attribute that indicates group membership.

- groupBaseDN: The base DN for group searches.

Save the changes to the authentication.conf file.

Step 5: Restart Splunk

For the LDAP configuration changes to take effect, you need to restart Splunk. Run the following command:

$SPLUNK_HOME/bin/splunk restart

Splunk will restart and load the updated configuration.

Step 6: Test LDAP Authentication

After restarting Splunk, open a web browser and access the Splunk Web UI. Try logging in using an LDAP username and password. If the configuration is correct, Splunk will authenticate the user against the LDAP server and grant access based on the mapped roles and permissions.

Troubleshooting and Best Practices for Managing Splunk Authentication

When managing Splunk authentication in an enterprise environment, you may encounter various challenges. To ensure a smooth and secure user management experience, here are some troubleshooting techniques and best practices to keep in mind.

Troubleshooting Techniques

  1. Check LDAP Connection: If LDAP authentication fails, verify the connectivity between Splunk and the LDAP server. Ensure that the LDAP server is reachable and the firewall allows communication on the specified port.

  2. Validate LDAP Configuration: Double-check the LDAP configuration settings in Splunk, such as the server hostname, port, bind DN, and search base. Ensure that the attribute mappings for username, real name, and group membership are correct.

  3. Test LDAP Queries: Use LDAP query tools or the Splunk CLI to test LDAP searches and validate that the expected user and group information is being retrieved correctly.

  4. Review Splunk Logs: Check the Splunk logs for any error messages or warnings related to LDAP authentication. The logs can provide valuable insights into the cause of authentication issues.

  5. Verify User and Group Mappings: Ensure that the LDAP user and group mappings are correctly configured in Splunk. Test the mappings by logging in with different LDAP users and verifying that they are assigned the appropriate roles and permissions.

Best Practices

  1. Implement Secure LDAP (LDAPS): Use LDAP over SSL/TLS (LDAPS) to encrypt the communication between Splunk and the LDAP server. This helps protect sensitive user credentials and prevents eavesdropping.

  2. Use Dedicated LDAP Bind Account: Create a dedicated LDAP bind account with minimal privileges for Splunk authentication. Avoid using generic or administrator accounts to reduce the risk of unauthorized access.

  3. Regularly Update and Patch: Keep your Splunk instance and LDAP server up to date with the latest security patches and updates. Regularly monitor for any vulnerabilities and apply the necessary fixes promptly.

  4. Implement Strong Password Policies: Enforce strong password policies for Splunk users, including minimum length, complexity requirements, and regular password expiration. Encourage users to use unique and secure passwords.

  5. Regularly Review and Audit Access: Conduct regular audits of user access and permissions in Splunk. Remove inactive or unnecessary user accounts and ensure that user roles and permissions align with their job responsibilities.

  6. Implement Multifactor Authentication (MFA): Consider implementing MFA for an additional layer of security. Splunk supports various MFA methods, such as time-based one-time passwords (TOTP) or integration with third-party MFA providers.

  7. Educate and Train Users: Provide training and awareness programs to educate users about security best practices, including password management, phishing prevention, and safe browsing habits.

  8. Monitor and Alert on Suspicious Activities: Utilize Splunk's monitoring and alerting capabilities to detect and respond to suspicious authentication attempts, brute-force attacks, or unauthorized access.

Wrap Up

We hope this article helps understand how to create a user, how to assign authorization to the users by creating roles, how to integrate Splunk with LDAP for centralized user authentication, what the difference between configuring LDAP in Splunk via web interface vs command line, and finally, some troubleshooting and best practices for managing Splunk user accounts and roles in an enterprise environment.

We are going to end this article for now, we will cover more information about Splunk in the upcoming articles. Please keep visiting for more such technical information. Visit our social media page on Facebook, Instagram,  LinkedInTwitterTelegramTumblr, & Medium and subscribe to receive information like this. 

Arun KL

Arun KL is a cybersecurity professional with 15+ years of experience in IT infrastructure, cloud security, vulnerability management, Penetration Testing, security operations, and incident response. He is adept at designing and implementing robust security solutions to safeguard systems and data. Arun holds multiple industry certifications including CCNA, CCNA Security, RHCE, CEH, and AWS Security.

Recently added

Cloud & OS Platforms

View All

Learn More About Cyber Security Security & Technology

“Knowledge Arsenal: Empowering Your Security Journey through Continuous Learning”

Cybersecurity All-in-One For Dummies - 1st Edition

"Cybersecurity All-in-One For Dummies" offers a comprehensive guide to securing personal and business digital assets from cyber threats, with actionable insights from industry experts.



View All

Learn Something New with Free Email subscription