Projet

Général

Profil

0001-python3-oidc-idp-test-client-authn-header-encoding-3.patch

Paul Marillonnet, 18 avril 2019 14:08

Télécharger (1,01 ko)

Voir les différences:

Subject: [PATCH] python3: oidc idp test client authn header encoding (#32446)

 tests/test_idp_oidc.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
tests/test_idp_oidc.py
145 145

  
146 146

  
147 147
def client_authentication_headers(oidc_client):
148
    token = base64.b64encode('%s:%s' % (oidc_client.client_id, oidc_client.client_secret))
149
    return {'Authorization': 'Basic %s' % token}
148
    client_creds = '%s:%s' % (oidc_client.client_id, oidc_client.client_secret)
149
    token = base64.b64encode(client_creds.encode('ascii'))
150
    return {'Authorization': 'Basic %s' % str(token.decode('ascii'))}
150 151

  
151 152

  
152 153
def bearer_authentication_headers(access_token):
153
-