mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
FIxes #7972: Standardize name of RemoteUserBackend logger
This commit is contained in:
@ -10,6 +10,7 @@
|
|||||||
|
|
||||||
* [#7246](https://github.com/netbox-community/netbox/issues/7246) - Don't attempt to URL-decode NAPALM response payloads
|
* [#7246](https://github.com/netbox-community/netbox/issues/7246) - Don't attempt to URL-decode NAPALM response payloads
|
||||||
* [#7962](https://github.com/netbox-community/netbox/issues/7962) - Fix user menu under report/script result view
|
* [#7962](https://github.com/netbox-community/netbox/issues/7962) - Fix user menu under report/script result view
|
||||||
|
* [#7972](https://github.com/netbox-community/netbox/issues/7972) - Standardize name of `RemoteUserBackend` logger
|
||||||
* [#8097](https://github.com/netbox-community/netbox/issues/8097) - Fix styling of Markdown tables
|
* [#8097](https://github.com/netbox-community/netbox/issues/8097) - Fix styling of Markdown tables
|
||||||
* [#8127](https://github.com/netbox-community/netbox/issues/8127) - Fix disassociation of interface under IP address edit view
|
* [#8127](https://github.com/netbox-community/netbox/issues/8127) - Fix disassociation of interface under IP address edit view
|
||||||
* [#8131](https://github.com/netbox-community/netbox/issues/8131) - Restore annotation of available IPs under prefix IPs view
|
* [#8131](https://github.com/netbox-community/netbox/issues/8131) - Restore annotation of available IPs under prefix IPs view
|
||||||
|
@ -105,7 +105,7 @@ class RemoteUserBackend(_RemoteUserBackend):
|
|||||||
return settings.REMOTE_AUTH_AUTO_CREATE_USER
|
return settings.REMOTE_AUTH_AUTO_CREATE_USER
|
||||||
|
|
||||||
def configure_groups(self, user, remote_groups):
|
def configure_groups(self, user, remote_groups):
|
||||||
logger = logging.getLogger('netbox.authentication.RemoteUserBackend')
|
logger = logging.getLogger('netbox.auth.RemoteUserBackend')
|
||||||
|
|
||||||
# Assign default groups to the user
|
# Assign default groups to the user
|
||||||
group_list = []
|
group_list = []
|
||||||
@ -141,7 +141,7 @@ class RemoteUserBackend(_RemoteUserBackend):
|
|||||||
Return None if ``create_unknown_user`` is ``False`` and a ``User``
|
Return None if ``create_unknown_user`` is ``False`` and a ``User``
|
||||||
object with the given username is not found in the database.
|
object with the given username is not found in the database.
|
||||||
"""
|
"""
|
||||||
logger = logging.getLogger('netbox.authentication.RemoteUserBackend')
|
logger = logging.getLogger('netbox.auth.RemoteUserBackend')
|
||||||
logger.debug(
|
logger.debug(
|
||||||
f"trying to authenticate {remote_user} with groups {remote_groups}")
|
f"trying to authenticate {remote_user} with groups {remote_groups}")
|
||||||
if not remote_user:
|
if not remote_user:
|
||||||
@ -173,7 +173,7 @@ class RemoteUserBackend(_RemoteUserBackend):
|
|||||||
return None
|
return None
|
||||||
|
|
||||||
def _is_superuser(self, user):
|
def _is_superuser(self, user):
|
||||||
logger = logging.getLogger('netbox.authentication.RemoteUserBackend')
|
logger = logging.getLogger('netbox.auth.RemoteUserBackend')
|
||||||
superuser_groups = settings.REMOTE_AUTH_SUPERUSER_GROUPS
|
superuser_groups = settings.REMOTE_AUTH_SUPERUSER_GROUPS
|
||||||
logger.debug(f"Superuser Groups: {superuser_groups}")
|
logger.debug(f"Superuser Groups: {superuser_groups}")
|
||||||
superusers = settings.REMOTE_AUTH_SUPERUSERS
|
superusers = settings.REMOTE_AUTH_SUPERUSERS
|
||||||
@ -189,7 +189,7 @@ class RemoteUserBackend(_RemoteUserBackend):
|
|||||||
return bool(result)
|
return bool(result)
|
||||||
|
|
||||||
def _is_staff(self, user):
|
def _is_staff(self, user):
|
||||||
logger = logging.getLogger('netbox.authentication.RemoteUserBackend')
|
logger = logging.getLogger('netbox.auth.RemoteUserBackend')
|
||||||
staff_groups = settings.REMOTE_AUTH_STAFF_GROUPS
|
staff_groups = settings.REMOTE_AUTH_STAFF_GROUPS
|
||||||
logger.debug(f"Superuser Groups: {staff_groups}")
|
logger.debug(f"Superuser Groups: {staff_groups}")
|
||||||
staff_users = settings.REMOTE_AUTH_STAFF_USERS
|
staff_users = settings.REMOTE_AUTH_STAFF_USERS
|
||||||
@ -204,7 +204,7 @@ class RemoteUserBackend(_RemoteUserBackend):
|
|||||||
return bool(result)
|
return bool(result)
|
||||||
|
|
||||||
def configure_user(self, request, user):
|
def configure_user(self, request, user):
|
||||||
logger = logging.getLogger('netbox.authentication.RemoteUserBackend')
|
logger = logging.getLogger('netbox.auth.RemoteUserBackend')
|
||||||
if not settings.REMOTE_AUTH_GROUP_SYNC_ENABLED:
|
if not settings.REMOTE_AUTH_GROUP_SYNC_ENABLED:
|
||||||
# Assign default groups to the user
|
# Assign default groups to the user
|
||||||
group_list = []
|
group_list = []
|
||||||
|
Reference in New Issue
Block a user