mirror of
https://github.com/mealie-recipes/mealie.git
synced 2025-08-05 05:25:26 +02:00
fix: Add cacertfile to client args when provided (#4451)
This commit is contained in:
parent
f7e595b404
commit
ea0d2ece6a
1 changed files with 5 additions and 1 deletions
|
@ -30,12 +30,16 @@ if settings.OIDC_READY:
|
||||||
oauth = OAuth()
|
oauth = OAuth()
|
||||||
groups_claim = settings.OIDC_GROUPS_CLAIM if settings.OIDC_REQUIRES_GROUP_CLAIM else ""
|
groups_claim = settings.OIDC_GROUPS_CLAIM if settings.OIDC_REQUIRES_GROUP_CLAIM else ""
|
||||||
scope = f"openid email profile {groups_claim}"
|
scope = f"openid email profile {groups_claim}"
|
||||||
|
client_args = {"scope": scope.rstrip()}
|
||||||
|
if settings.OIDC_TLS_CACERTFILE:
|
||||||
|
client_args["verify"] = settings.OIDC_TLS_CACERTFILE
|
||||||
|
|
||||||
oauth.register(
|
oauth.register(
|
||||||
"oidc",
|
"oidc",
|
||||||
client_id=settings.OIDC_CLIENT_ID,
|
client_id=settings.OIDC_CLIENT_ID,
|
||||||
client_secret=settings.OIDC_CLIENT_SECRET,
|
client_secret=settings.OIDC_CLIENT_SECRET,
|
||||||
server_metadata_url=settings.OIDC_CONFIGURATION_URL,
|
server_metadata_url=settings.OIDC_CONFIGURATION_URL,
|
||||||
client_kwargs={"scope": scope.rstrip()},
|
client_kwargs=client_args,
|
||||||
code_challenge_method="S256",
|
code_challenge_method="S256",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue