From a1fa9bb665e4c7ba96ae21da7de35e4369f16fa5 Mon Sep 17 00:00:00 2001 From: Wiktor Przybylski Date: Fri, 26 Apr 2024 18:12:32 +0200 Subject: [PATCH] herp derp --- auth/views.py | 2 +- spejstore/settings.py | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/auth/views.py b/auth/views.py index 4309b3b..be2a427 100644 --- a/auth/views.py +++ b/auth/views.py @@ -2,4 +2,4 @@ def auth_redirect(request): - return redirect("social:begin", "hswaw") + return redirect("social:begin", "oidc") diff --git a/spejstore/settings.py b/spejstore/settings.py index bf4095a..f625a95 100644 --- a/spejstore/settings.py +++ b/spejstore/settings.py @@ -137,9 +137,13 @@ def env(name, default=None): }, ] +SOCIAL_AUTH_OIDC_OIDC_ENDPOINT = 'https://auth.apps.hskrk.pl/application/o/spejstore/' # endpoint without /.well-known/openid-configuration +SOCIAL_AUTH_OIDC_KEY = env("CLIENT_ID") +SOCIAL_AUTH_OIDC_SECRET = env("SECRET") + AUTHENTICATION_BACKENDS = ( - "auth.backend.HSWawOAuth2", + "social_core.backends.open_id_connect.OpenIdConnectAuth", "django.contrib.auth.backends.ModelBackend", )