| |
@@ -164,6 +164,8 @@
|
| |
if isinstance(trust_root, str):
|
| |
trust_root = trust_root.encode('utf-8')
|
| |
trust_root_b64 = b64encode(trust_root)
|
| |
+ if isinstance(trust_root_b64, bytes):
|
| |
+ trust_root_b64 = trust_root_b64.decode('utf-8')
|
| |
consentdata = user.get_consent('openid', trust_root_b64)
|
| |
if consentdata is not None:
|
| |
# Consent has already been granted
|
| |
The rest of the application expects the base64-encoded trust root to
be a string, and when it is bytes, it can fail with "incorrect padding" errors.
Fixes https://pagure.io/ipsilon/issue/332
Signed-off-by: Neal Gompa ngompa13@gmail.com