Created
March 30, 2018 05:07
-
-
Save salrashid123/fac334f091111b7b7b4c917e436d2edf to your computer and use it in GitHub Desktop.
svc4.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
audience = 'SystemC' | |
id_scope='scope1 scope2' | |
now = int(time.time()) | |
exptime = now + 3600 | |
id_token_claim =('{"iss":"%s","scope":"%s", "aud":"%s","exp":%s,"iat":%s}') %(client_id,id_scope,audience,exptime,now) | |
slist = resource.serviceAccounts().signJwt(name='projects/mineral-minutia-820/serviceAccounts/' + client_id, | |
body={'payload': id_token_claim }) | |
resp = slist.execute() | |
signed_jwt = resp['signedJwt'] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment