Skip to content

Commit

Permalink
fix: add missing values for openbanking (#939)
Browse files Browse the repository at this point in the history
  • Loading branch information
iromli authored Mar 2, 2022
1 parent 087b88d commit b140892
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 7 deletions.
27 changes: 21 additions & 6 deletions docker-jans-persistence-loader/scripts/upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,27 @@ def __init__(self):
def _transform_auth_dynamic_config(conf):
should_update = False

if all([
os.environ.get("CN_DISTRIBUTION", "default") == "openbanking",
"dcrAuthorizationWithMTLS" not in conf,
]):
conf["dcrAuthorizationWithMTLS"] = False
should_update = True
if os.environ.get("CN_DISTRIBUTION", "default") == "openbanking":
if "dcrAuthorizationWithMTLS" not in conf:
conf["dcrAuthorizationWithMTLS"] = False
should_update = True

if "scopesSupported" not in conf:
conf["scopesSupported"] = [
"openid",
"consents",
"accounts",
"resources",
]
should_update = True

if "jwt" not in conf["responseModesSupported"]:
conf["responseModesSupported"].append("jwt")
should_update = True

if "private_key_jwt" not in conf["tokenEndpointAuthMethodsSupported"]:
conf["tokenEndpointAuthMethodsSupported"].append("private_key_jwt")
should_update = True

if "grantTypesAndResponseTypesAutofixEnabled" not in conf:
conf["grantTypesAndResponseTypesAutofixEnabled"] = False
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,18 @@
"tls_client_certificate_bound_access_tokens",
"mtls_endpoint_aliases"
],
"scopesSupported":[
"openid",
"consents",
"accounts",
"resources"
],
"responseTypesSupported":[
["code", "id_token"]
],
"responseModesSupported":[
"fragment"
"fragment",
"jwt"
],
"grantTypesSupported":[
"client_credentials",
Expand Down Expand Up @@ -133,6 +140,7 @@
],
"tokenEndpointAuthMethodsSupported":[
"client_secret_post",
"private_key_jwt",
"tls_client_auth"
],
"tokenEndpointAuthSigningAlgValuesSupported":[
Expand Down

0 comments on commit b140892

Please sign in to comment.