Splunk Enterprise Security

issue : unable to see how to hide password in S3 example script

su_kumar
New Member

Hi ,
I am new and trying to write setup page through modular input where we need to communicate with server .for userid/password
Referring S3 example from below splunk document.
https://docs.splunk.com/Documentation/Splunk/7.2.5/AdvancedDev/ModInputsExample

Need help to understand the procedure how we are hiding password in this S3 example .
want to avoid displaying text password..

0 Karma

LukeMurphey
Champion

You can use the secure storage endpoint to store passwords securely. See the following blog post: https://www.splunk.com/blog/2011/03/15/storing-encrypted-credentials.html

This is a little tricky because to make it work you need to:

  1. Change the modular input to load the password from secure storage
  2. Change the UI so that it loads and saves the password from/to secure storage

Change the modular input to load the password from secure storage

I wrote a modular input wrapper library that includes functions for accessing secure storage (see https://bit.ly/2GK0VQv). I use this in the Website Input app (see the use of get_secure_password in https://github.com/LukeMurphey/splunk-web-input/blob/master/src/bin/web_input.py).

Change the UI so that it loads and saves the password from/to secure storage

I wrote some modules that make this a little easier, see https://bit.ly/2J57v6X. That project includes a module named secure_password_storage which helps users make a custom manager page which loads and saves the password securely.

See an example here: https://github.com/LukeMurphey/splunk-web-input/blob/master/src/default/data/ui/manager/data_inputs_...

Unfortunately, apps with a custom input page will be rejected by app-inspect and thus cannot be installed on Splunk Cloud (since app-inspect incorrectly thinks that a custom input page is a deprecated technology called advanced XML). Of course, your app will be rejected if you store passwords without secure storage and thus you are stuck either way.

0 Karma

su_kumar
New Member

I am unable to open this link ( error page not found )
https://github.com/LukeMurphey/splunk-web-input/blob/master/src/bin/web_input.py).
where we can get web_input.py ?

0 Karma

LukeMurphey
Champion

The links should all work now.

0 Karma
Get Updates on the Splunk Community!

Introducing Splunk Enterprise 9.2

WATCH HERE! Watch this Tech Talk to learn about the latest features and enhancements shipped in the new Splunk ...

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...