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

Set environment before exec in chef-server-ctl psql #991

Merged
merged 1 commit into from
Nov 1, 2016

Conversation

stevendanna
Copy link
Contributor

Setting the environment as part of the command leads to the password
being revealed in ps output. Since this command exec's we can set the
environment for the current process before exec.

Signed-off-by: Steven Danna [email protected]

Copy link
Contributor

@srenatus srenatus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍
Probably also safer than whatever could have happened in PGPASSWORD=#{db_password} with random ($!%!#) passwords

Setting the environment as part of the command leads to the password
being revealed in ps output.  Since this command exec's we can set the
environment for the current process before exec.

Signed-off-by: Steven Danna <[email protected]>
@stevendanna stevendanna force-pushed the ssd/psql-no-password-in-ps branch from e5b3f56 to 9387965 Compare November 1, 2016 12:45
@stevendanna stevendanna merged commit 23a9a16 into master Nov 1, 2016
@stevendanna stevendanna deleted the ssd/psql-no-password-in-ps branch November 1, 2016 13:40
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