The aud in a json web token can be a string or an array -- so also deal with the case that it is an array
This commit is contained in:
parent
735e7f726c
commit
c8a83f80b6
|
@ -169,10 +169,8 @@ class AuthenticationService:
|
||||||
iat = decoded_token["iat"]
|
iat = decoded_token["iat"]
|
||||||
if iss != cls.server_url():
|
if iss != cls.server_url():
|
||||||
valid = False
|
valid = False
|
||||||
elif aud not in (
|
elif aud not in (cls.client_id(), "account") and\
|
||||||
cls.client_id(),
|
aud != [cls.client_id(), "account"]:
|
||||||
"account",
|
|
||||||
):
|
|
||||||
valid = False
|
valid = False
|
||||||
elif azp and azp not in (
|
elif azp and azp not in (
|
||||||
cls.client_id(),
|
cls.client_id(),
|
||||||
|
|
Loading…
Reference in New Issue