idp_oidc: py3-compliant authn header encoding in tests (#32446)
This commit is contained in:
parent
9c9db933f6
commit
89f1a4fd76
|
@ -166,8 +166,9 @@ def normal_oidc_client(superuser, app, simple_user, media):
|
|||
|
||||
|
||||
def client_authentication_headers(oidc_client):
|
||||
token = base64.b64encode('%s:%s' % (oidc_client.client_id, oidc_client.client_secret))
|
||||
return {'Authorization': 'Basic %s' % token}
|
||||
client_creds = '%s:%s' % (oidc_client.client_id, oidc_client.client_secret)
|
||||
token = base64.b64encode(client_creds.encode('ascii'))
|
||||
return {'Authorization': 'Basic %s' % str(token.decode('ascii'))}
|
||||
|
||||
|
||||
def bearer_authentication_headers(access_token):
|
||||
|
|
Loading…
Reference in New Issue