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

The default charset for the basic http authentication is utf-8. #1325

merged 2 commits into from Nov 13, 2018


None yet
3 participants
Copy link

commented Jun 11, 2018

@@ -505,8 +506,8 @@ def parse_authorization_header(value):
username, password = base64.b64decode(auth_info).split(b':', 1)
except Exception:
return Authorization('basic', {'username': bytes_to_wsgi(username),
'password': bytes_to_wsgi(password)})
return Authorization('basic', {'username': to_unicode(username, _basic_auth_charset),

This comment has been minimized.

Copy link

edk0 Jul 5, 2018


I think this needs to use to_native

Flyguy and others added some commits Jun 11, 2018

@davidism davidism force-pushed the Flyguy:master branch from 2269181 to 0a748a2 Nov 13, 2018


This comment has been minimized.

Copy link

commented Nov 13, 2018

Rebased, added changelog. Changed this to use to_unicode, as username and password could only contain ASCII anyway, and string operations on unicode that only contains ASCII should still work in Python 2.

@davidism davidism added this to the 0.15 milestone Nov 13, 2018

@davidism davidism merged commit 6e83117 into pallets:master Nov 13, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed

nicolaiarocci added a commit to pyeve/eve that referenced this pull request Mar 20, 2019

Pin werkzeug to 0.14.1
With v0.15 the test suite breaks our auth tests. Culprit appears to be:

Pinning the dependency until I have time to look into it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.