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

Clear-text Logging of Sensitive Information in luigi/contrib/pai.py #3300

Closed
Ali-Razmjoo opened this issue Aug 24, 2024 · 0 comments · Fixed by #3310
Closed

Clear-text Logging of Sensitive Information in luigi/contrib/pai.py #3300

Ali-Razmjoo opened this issue Aug 24, 2024 · 0 comments · Fixed by #3310

Comments

@Ali-Razmjoo
Copy link
Contributor

Hi,

I am reporting a potential security issue has been identified in the file luigi/contrib/pai.py.

luigi/luigi/contrib/pai.py

Lines 240 to 242 in 9e0898e

request_json = json.dumps({'username': self.__openpai.username, 'password': self.__openpai.password,
'expiration': self.__openpai.expiration})
logger.debug('Get token request {0}'.format(request_json))

The code snippet logs sensitive information, specifically the username and password, in clear text. This can expose sensitive data if the logs are accessed by unauthorized parties.

Sensitive information like passwords should not be logged. Instead, consider logging non-sensitive parts of the request or obfuscating sensitive data before logging.

Thanks.

References

Ali-Razmjoo added a commit to Ali-Razmjoo/luigi that referenced this issue Sep 4, 2024
Fixes spotify#3300

Remove logging of sensitive information in `luigi/contrib/pai.py`.

* Remove the logging of the `request_json` variable in the `__init_token` method of the `PaiTask` class.
* Add a new logging statement in the `__init_token` method to indicate that a token request is being made, without including sensitive information.
Ali-Razmjoo added a commit to Ali-Razmjoo/luigi that referenced this issue Sep 5, 2024
Fixes spotify#3300

Remove logging of sensitive information in `luigi/contrib/pai.py`.

* Remove the logging of the `request_json` variable in the `__init_token` method of the `PaiTask` class.
* Add a new logging statement in the `__init_token` method to indicate that a token request is being made, without including sensitive information.
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 a pull request may close this issue.

1 participant