Security

CLI command to login: Is there a way to add the -auth parameter or does login not have that feature?

ben_leung
Builder

Tried to run

./splunk login -auth admin:password

Cannot seem to execute a one liner command to authenticate local user session.

Is there a way to add the -auth parameter or does login not have that feature?

Tags (3)
1 Solution

musskopf
Builder

I don't think you could send user and pass for the login command. As alternative you could use a search to login and create the session:

./splunk search 'index=_internal | fields _time | head 1 ' -auth 'admin:password'

After that you have your session and don't have to send user/pass anymore.

Cheers

View solution in original post

musskopf
Builder

I don't think you could send user and pass for the login command. As alternative you could use a search to login and create the session:

./splunk search 'index=_internal | fields _time | head 1 ' -auth 'admin:password'

After that you have your session and don't have to send user/pass anymore.

Cheers

Get Updates on the Splunk Community!

Dashboards: Hiding charts while search is being executed and other uses for tokens

There are a couple of features of SimpleXML / Classic dashboards that can be used to enhance the user ...

Splunk Observability Cloud's AI Assistant in Action Series: Explaining Metrics and ...

This is the fourth post in the Splunk Observability Cloud’s AI Assistant in Action series that digs into how ...

Brains, Bytes, and Boston: Learn from the Best at .conf25

When you think of Boston, you might picture colonial charm, world-class universities, or even the crack of a ...