How to make sure we never log secrets
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 85
- Forks
- 26
- Avg merge
- 11h 49m
- Merged PRs (30d)
- 22
Description
What happened?
This came up in a code review: https://github.com/pulumi/pulumi-java/pull/597/files#r879651879
It would be nice to not log secrets even in debug/excessive mode, but still allow for rich debugging information to be available.
It is especially useful for a user that might want to report a bug and accidentally leak their secrets because they've attached logs in debug mode.
This might be inspiration for an approach: https://github.com/palantir/safe-logging
Steps to reproduce
Enable excessive mode and observe the secrets being printed.
Expected Behavior
Never log secrets.
Actual Behavior
Currently when logging in excessive mode secrets are displayed.
Versions used
No response
Additional context
No response
Contributing
Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by enabling excessive mode and tracing the logging paths that print secrets, using the linked code review and safe-logging project as context. Done means secrets are never emitted at any logging level while rich debugging information remains available.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- security
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100