Group checks are case-sensitive #7408

Closed
opened 2025-12-29 20:23:03 +01:00 by adam · 1 comment
Owner

Originally created by @jschewebbn on GitHub (Dec 21, 2022).

NetBox version

v3.4.1

Python version

3.8

Steps to Reproduce

I'm getting back to testing https://github.com/netbox-community/netbox/issues/9640 with a stock version of netbox.

I am using the remote authentication backend. Configuration is as follows

# Remote authentication support
REMOTE_AUTH_ENABLED = True

REMOTE_AUTH_BACKEND = 'netbox.authentication.RemoteUserBackend'

REMOTE_AUTH_HEADER = 'HTTP_X_APP_USER'
REMOTE_AUTH_AUTO_CREATE_USER = True
REMOTE_AUTH_DEFAULT_GROUPS = []
REMOTE_AUTH_DEFAULT_PERMISSIONS = {}

REMOTE_AUTH_GROUP_HEADER = 'HTTP_OIDC_CLAIM_GROUPS'
REMOTE_AUTH_GROUP_SYNC_ENABLED = True
REMOTE_AUTH_GROUP_SEPARATOR = ','
REMOTE_AUTH_STAFF_GROUPS = ['IPAM-admins']
REMOTE_AUTH_SUPERUSER_GROUPS = ['ipam-admins']

Note that REMOTE_AUTH_STAFF_GROUPS has mixed case.

The HTTP header has the value 'Business_Infrastructure-All,All_Staff,ipam-admins'.

This can also be seen when one creates a group using the API, if the case of the created group doesn't match the case of the group in the header netbox treats this as 2 different groups.

Expected Behavior

I would not expect group names, or usernames (which I haven't tested), to be case sensitive.

Observed Behavior

Group names are case sensitive.

Originally created by @jschewebbn on GitHub (Dec 21, 2022). ### NetBox version v3.4.1 ### Python version 3.8 ### Steps to Reproduce I'm getting back to testing https://github.com/netbox-community/netbox/issues/9640 with a stock version of netbox. I am using the remote authentication backend. Configuration is as follows ``` # Remote authentication support REMOTE_AUTH_ENABLED = True REMOTE_AUTH_BACKEND = 'netbox.authentication.RemoteUserBackend' REMOTE_AUTH_HEADER = 'HTTP_X_APP_USER' REMOTE_AUTH_AUTO_CREATE_USER = True REMOTE_AUTH_DEFAULT_GROUPS = [] REMOTE_AUTH_DEFAULT_PERMISSIONS = {} REMOTE_AUTH_GROUP_HEADER = 'HTTP_OIDC_CLAIM_GROUPS' REMOTE_AUTH_GROUP_SYNC_ENABLED = True REMOTE_AUTH_GROUP_SEPARATOR = ',' REMOTE_AUTH_STAFF_GROUPS = ['IPAM-admins'] REMOTE_AUTH_SUPERUSER_GROUPS = ['ipam-admins'] ``` Note that `REMOTE_AUTH_STAFF_GROUPS` has mixed case. The HTTP header has the value 'Business_Infrastructure-All,All_Staff,ipam-admins'. This can also be seen when one creates a group using the API, if the case of the created group doesn't match the case of the group in the header netbox treats this as 2 different groups. ### Expected Behavior I would not expect group names, or usernames (which I haven't tested), to be case sensitive. ### Observed Behavior Group names are case sensitive.
adam closed this issue 2025-12-29 20:23:04 +01:00
Author
Owner

@jeremystretch commented on GitHub (Dec 22, 2022):

I would not expect group names, or usernames (which I haven't tested), to be case sensitive.

AFAICT there's nothing in the documentation to suggest that they would not be. You're welcome to submit a feature request proposing this change (including your use case), however we cannot change this arbitrarily as it would likely break existing deployments.

@jeremystretch commented on GitHub (Dec 22, 2022): > I would not expect group names, or usernames (which I haven't tested), to be case sensitive. AFAICT there's nothing in the documentation to suggest that they would not be. You're welcome to submit a feature request proposing this change (including your use case), however we cannot change this arbitrarily as it would likely break existing deployments.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#7408