canaille-globuzma/tests/__init__.py

10 lines
210 B
Python
Raw Normal View History

2020-08-19 08:28:28 +00:00
import base64
def client_credentials(client):
return base64.b64encode(
client.oauthClientID.encode("utf-8")
+ b":"
+ client.oauthClientSecret.encode("utf-8")
).decode("utf-8")