MongoDB Password leaked to Log #848
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What I'm trying to do and why
when configuring the mongodb Backup like this:
The Password is logged in cleartext
Steps to reproduce
No response
Actual behavior
DEBUG mongodump --host 127.0.0.1 --port 27018 --username mongoadmin --password test --authenticationDatabase admin --db test --archive
Expected behavior
Password should be not logged
Other notes / implementation ideas
maybe like in this answer https://stackoverflow.com/a/63568946/10966928
store the pw in a tempfile and pipe it to mongodump
borgmatic version
1.8.2
borgmatic installation method
Debian package
Borg version
No response
Python version
No response
Database version (if applicable)
No response
Operating system and version
No response
Thanks for taking the time to file this! Avoiding the logging of the password makes sense to me, and I like the idea of passing it to
mongodump
via file instead of command-line. Other borgmatic database hooks pass passwords via environment variable, but that doesn't seem to be an option here.I couldn't get the temporary password file working, so I ended up just masking the command-line password value as it's logged. Implemented in main and soon to be released.
Thanks again!
Released in 1.8.10!