Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

changing type of SplunkToken from string to secret #427

Merged
merged 1 commit into from
Oct 19, 2022

Conversation

momoXD007
Copy link
Contributor

What this PR does / why we need it:

In my last PR I added support for Splunk as output type. I however missed the fact that the so called SplunkToken is an authentication-token and should therefore be treated as a secret.

Context:
A SplunkToken is a Splunk generated string that can be used by programs to access a Splunk-instance's api. It is therefore a sensitive secret and should be handled as such.

Which issue(s) this PR fixes:

I think no one raised this externally, but the underlying issue that this fixes is that this change will force users to supply the SplunkToken as secret reference and this way prevents leaking of this secret.

Does this PR introduced a user-facing change?

action-required: if you used Splunk as an output-type and supplied the splunkToken as string you will need to change your code and are now forced to supply the splunkToken as a secret-reference. In the example below the splunkToken is loaded from a secret called splunk-token and within that secret it the token is stored under the key "myToken".

output:
      splunk:
        host: https://my.splunk.instance.net
        port: 8089
        eventIndex:  "Event"
        splunkToken:
          valueFrom:
              secretKeyRef:
                name: splunk-token
                key: myToken

Additional documentation, usage docs, etc.:


Signed-off-by: Michael J. Wieneke <m.wieneke@sap.com>
@benjaminhuo benjaminhuo merged commit 91e1e98 into fluent:master Oct 19, 2022
@benjaminhuo
Copy link
Member

@momoXD007 Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants