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

GMS logs elasticsearch basic auth credentials straight to the console #2933

Closed
martimors opened this issue Jul 22, 2021 · 3 comments
Closed
Labels
bug Bug report

Comments

@martimors
Copy link

martimors commented Jul 22, 2021

Describe the bug
When using basicauth, and the request fails (in this case because it does not expect a port), GMS (and the elasticsearch setup job too) logs the credentials to the console, like so:

2021/07/22 15:14:44 Problem with request: Get https://myuser:mypassword@mydomain.eu-central-1.es.amazonaws.com:9200: dial tcp 00.11.22.33:9200: i/o timeout. Sleeping 1s

To Reproduce
Steps to reproduce the behavior:

  1. Start GMS pointed at elasticsearch with basic auth, but use the wrong uri
  2. Observe password in logs

Expected behavior
I think it should either mask the password or not log the uri at all.

@martimors martimors added the bug Bug report label Jul 22, 2021
@jjoyce0510
Copy link
Collaborator

Hi @dingobar. Thanks for reporting.

Agree this is concerning. We are triaging this on our side. Will report back soon.

Thanks
John

cc. @dexter-mh-lee

@claudio-benfatto
Copy link
Contributor

I opened this PR: #3241 to solve this issue for the elasticsearch-setup container. I think that similar changes to the gms container start script had already mitigated it in the gms case.

@anshbansal
Copy link
Collaborator

Should be fixed now. If still an issue please open a new issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug report
Projects
None yet
Development

No branches or pull requests

4 participants