-
-
Notifications
You must be signed in to change notification settings - Fork 319
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
Mask passwords in VERBOSE logs when running Phing in debug mode? #1672
Comments
Hi, not sure I understand what you need. Do you want to change the log level of properties? Or mask some properties in all cases? For which tasks? In which situations? And why do you need to mask it? |
Hi. The last one. With VERBOSE all properties used in a task are shown in the log. This also shows password properties (for instance for the pdosqlexec task). This is not so good - it would be better to mark such properties always hidden or disguise the output as usual for passwords. |
This is not trivial. Tasks are not in control of the dumping of properties to console under Having a "do not dump properties" option while running phing in debug mode is also an option, but feels like a shortcut to fix a symptom. I'm not entirely sure we need this yet, interested to see what other users think. |
@siad007 WDYT? |
For my custom-tasks i do something like:
No idea how to do this globally, but per task we can hide sensitive data by this way. |
We could simply introduce a listener, which could hide by configuration either
Advantage of a listener instead of a logger: we could combine this with other listeners and/or a logger. |
I was reading this RFC Redacting parameters in back traces and I remembered this issue. Maybe it can be useful, at least as inspiration? |
* Added DisguiseLogger - related to #1672 * Fixed static code analysis * Added test * Added test
Is your feature request related to a problem? Please describe.
Right now all properties are logged with VERBOSE level on. This is critical in some situations, especially if passwords are involved (MySql for instance)
Describe the solution you'd like
It wolud be nice to add an attribute (hideoutput=true/false or disguiseoutput=true/false) to solve this problem.
The text was updated successfully, but these errors were encountered: