Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@hilariocoelho
Copy link
Contributor

This pull request intends to censor suspicious found environment variables.

Previously any suspicious environment variable found was being leaked during CIS-DI-0010 checkpoint assessment as seen below:

FATAL   - CIS-DI-0010: Do not store credential in environment variables/files
        * Suspicious ENV key found : GITLAB_TOKEN on /bin/sh -c #(nop)  ENV GITLAB_TOKEN=y5V1xiW5eTwq34jasRqFBD (You can suppress it with --accept-key)

With this PR the same finding would be:

FATAL   - CIS-DI-0010: Do not store credential in environment variables/files
        * Suspicious ENV key found : GITLAB_TOKEN on /bin/sh -c #(nop)  ENV GITLAB_TOKEN=******* (You can suppress it with --accept-key)

Notice that the environment variable now isn't leaked on the output to stdout. This also applies to any other export format.

This is important since Dockle might inadvertently leak production (or other environment) credentials on a CI/CD pipeline

@tomoyamachi tomoyamachi merged commit d8e1572 into goodwithtech:master Jan 6, 2025
@tomoyamachi
Copy link
Collaborator

@hilariocoelho Thank you for your contribution!

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.

2 participants