added OpenID Connect support

This commit is contained in:
Tobias Kurze
2019-03-19 15:29:26 +01:00
parent bd9b6c61d3
commit 9d9c58d268
8 changed files with 289 additions and 16 deletions

11
auth/oidc.py Normal file
View File

@@ -0,0 +1,11 @@
# Copyright (c) 2019. Tobias Kurze
from flask_pyoidc.flask_pyoidc import OIDCAuthentication
from backend.auth.oidc_config import PROVIDER_NAME
def oidc_auth_default_provider(self):
return self.oidc_auth_orig(PROVIDER_NAME)
OIDCAuthentication.oidc_auth_orig = OIDCAuthentication.oidc_auth
OIDCAuthentication.oidc_auth = oidc_auth_default_provider