Add ability to configure OIDC internal auth engine via superuser panel
This commit is contained in:
parent
e724125459
commit
bc82edb2d1
7 changed files with 103 additions and 14 deletions
|
@ -9,6 +9,10 @@ from util.security.jwtutil import InvalidTokenError
|
|||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class UnknownServiceException(Exception):
|
||||
pass
|
||||
|
||||
|
||||
class OIDCInternalAuth(FederatedUsers):
|
||||
""" Handles authentication by delegating authentication to a signed OIDC JWT produced by the
|
||||
configured OIDC service.
|
||||
|
@ -18,7 +22,7 @@ class OIDCInternalAuth(FederatedUsers):
|
|||
login_manager = OAuthLoginManager(config)
|
||||
self.login_service = login_manager.get_service(login_service_id)
|
||||
if self.login_service is None:
|
||||
raise Exception('Unknown OIDC login service %s' % login_service_id)
|
||||
raise UnknownServiceException('Unknown OIDC login service %s' % login_service_id)
|
||||
|
||||
@property
|
||||
def supports_encrypted_credentials(self):
|
||||
|
|
Reference in a new issue