-
Notifications
You must be signed in to change notification settings - Fork 14.8k
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 Password in Log table when using the CLI #11468
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's also possible to do --password=foobar
(but not -p=foobar
) which this PR won't catch.
Fixed in 40b1c04 I tested with Example:
So I have handled that case too and added test for it |
Should we add And for bonus points the password part of the URI style? |
Added
Looks like it works fine though In [1]: from airflow.cli.cli_parser import get_parser
In [2]: parser = get_parser()
In [8]: parser.parse_args(["users", "create","-e" ,"airflow" , "-p=10", "-r", "Admin", "-f", "as", "-l", "asd", "-u", "as"])
Out[8]: Namespace(email='airflow', firstname='as', func=<function lazy_load_command.<locals>.command at 0x7fd196603dd0>, lastname='asd', password='10', role='Admin', subcommand='create', use_random_password=False, username='as') |
(cherry picked from commit 4e32546)
(cherry picked from commit 4e32546)
Before:
After:
^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code change, Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in UPDATING.md.