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

Can't authenticate when using a password with percent symbol #7

Closed
hmcgonig opened this issue Feb 14, 2017 · 4 comments
Closed

Can't authenticate when using a password with percent symbol #7

hmcgonig opened this issue Feb 14, 2017 · 4 comments
Labels

Comments

@hmcgonig
Copy link

hmcgonig commented Feb 14, 2017

Hey, first of all, thank you for writing this! The supply of bearer-auth supporting registry UIs is pretty lacking...

Okay, so I use the docker-auth project to handle token generation for me and the password for one of my users happens to have a "%" symbol in it. I found that I get an error when fetching things from this registry using the supplied password.

In this example my username/ password was testuser examplepassword!%#$#$%

Seems like usernames and passwords might just need to be URL encoded before sending the request. Alternatively, an even better solution would be to base64 encode the <username>:<password> and throw it into a header like so:

Authorization: Basic <base 64 encoded username password string>

[ Tue, 14 Feb 2017 22:05:40 UTC ][ L1 ] CheckManifests Daemon: started work
[ Tue, 14 Feb 2017 22:05:40 UTC ][ L3 ] parse https://testuser:examplepassword!%: invalid URL escape "%"
[ Tue, 14 Feb 2017 22:05:40 UTC ][ L3 ] CheckRepos Daemon: cannot recieve response from registry, stopping work
@hmcgonig hmcgonig changed the title Panic when attempting to authenticate Can't authenticate when using a password with percent symbol Feb 14, 2017
@Evedel
Copy link
Owner

Evedel commented Feb 15, 2017

Hi!
Pleasure to hear, that it is useful =)
And thanks for the detailed description of the bug, I'm looking at it soon, probably in this weekend.

@Evedel
Copy link
Owner

Evedel commented Feb 15, 2017

@Evedel
Copy link
Owner

Evedel commented Feb 18, 2017

Hi again @hmcgonig!

Latest version on dockerhub should be fixed for now.

@Evedel Evedel closed this as completed Feb 18, 2017
@Evedel Evedel added the bug label Feb 18, 2017
@hmcgonig
Copy link
Author

Awesome 👍

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

No branches or pull requests

2 participants