1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Fixes #11977: Multiple remote authentication backends (#12012)

* Add suppport for REMOTE_AUTH_BACKEND as iterable

* Closes #11977: Support for multiple auth backends

* Tweak list casting

---------

Co-authored-by: jeremystretch <jstretch@netboxlabs.com>
This commit is contained in:
Austin de Coup-Crank
2023-03-28 07:44:24 -05:00
committed by Jeremy Stretch
parent 35af1d7b61
commit 2eedcac383
2 changed files with 4 additions and 2 deletions

View File

@@ -396,8 +396,10 @@ TEMPLATES = [
]
# Set up authentication backends
if type(REMOTE_AUTH_BACKEND) not in (list, tuple):
REMOTE_AUTH_BACKEND = [REMOTE_AUTH_BACKEND]
AUTHENTICATION_BACKENDS = [
REMOTE_AUTH_BACKEND,
*REMOTE_AUTH_BACKEND,
'netbox.authentication.ObjectPermissionBackend',
]