Using a custom LOGIN_URL for SSO #8974

Closed
opened 2025-12-29 20:43:32 +01:00 by adam · 5 comments
Owner

Originally created by @CTV-2023 on GitHub (Dec 15, 2023).

NetBox version

v3.6.6

Feature type

New functionality

Proposed functionality

Hi,

Following this discussion https://github.com/netbox-community/netbox/discussions/14535

Provide a configuration option to modify the default login behaviour to redirect to a specific login by default while still maintaining the ability to access the old login via manually typing in the login URL or through other means (dropdown from the login button, etc)
Note : as saml logs user automatically, the login button won't be used, the login url might be easier

Use case

In our organization, we only use SSO for authentication to NetBox and would prefer for our users to be redirected directly to the SSO login page automatically to prevent attempts to login without SSO

Database changes

None I think

External dependencies

None I think

Originally created by @CTV-2023 on GitHub (Dec 15, 2023). ### NetBox version v3.6.6 ### Feature type New functionality ### Proposed functionality Hi, Following this discussion https://github.com/netbox-community/netbox/discussions/14535 Provide a configuration option to modify the default login behaviour to redirect to a specific login by default while still maintaining the ability to access the old login via manually typing in the login URL or through other means (dropdown from the login button, etc) Note : as saml logs user automatically, the login button won't be used, the login url might be easier ### Use case In our organization, we only use SSO for authentication to NetBox and would prefer for our users to be redirected directly to the SSO login page automatically to prevent attempts to login without SSO ### Database changes None I think ### External dependencies None I think
adam added the type: featurepending closurecomplexity: high labels 2025-12-29 20:43:32 +01:00
adam closed this issue 2025-12-29 20:43:32 +01:00
Author
Owner

@DanSheps commented on GitHub (Dec 15, 2023):

Hi,

Following this discussion #14535

I have a use case where my lazy users would like to be authenticated with SSO without the need to click on the link below "Or use a single sign-on (SSO) provider:".

For instance, it would be cool to be able to have a specific login page using the SSO /oauth/login/saml/?idp=MY-IDP

I understand from previous discussions you don't want to hide or disable the default login page : either by adding a specific parameter "?redirect=0" or by having 2 possible login pages

You should change your proposal to make it more clear, something like:

"Provide a configuration option to modify the default login behaviour to redirect to a specific login by default while still maintaining the ability to access the old login via manually typing in the login URL or through other means (dropdown from the login button, etc)"

Use case

Automatic connection of users using SSO.

Likewisie, you should change this to:

"In our organization, we only use SSO for authentication to NetBox and would prefer for our users to be redirected directly to the SSO login page automatically to prevent attempts to login without SSO".

I can see the need for this, in certain areas there may be security systems monitoring logs and invalid authentication attempts might trigger automated actions against the "attacker"

@DanSheps commented on GitHub (Dec 15, 2023): > Hi, > > Following this discussion #14535 > > I have a use case where my lazy users would like to be authenticated with SSO without the need to click on the link below "Or use a single sign-on (SSO) provider:". > > For instance, it would be cool to be able to have a specific login page using the SSO /oauth/login/saml/?idp=MY-IDP > > I understand from previous discussions you don't want to hide or disable the default login page : either by adding a specific parameter "?redirect=0" or by having 2 possible login pages You should change your proposal to make it more clear, something like: "Provide a configuration option to modify the default login behaviour to redirect to a specific login by default while still maintaining the ability to access the old login via manually typing in the login URL or through other means (dropdown from the login button, etc)" > ### Use case > Automatic connection of users using SSO. Likewisie, you should change this to: "In our organization, we only use SSO for authentication to NetBox and would prefer for our users to be redirected directly to the SSO login page automatically to prevent attempts to login without SSO". I can see the need for this, in certain areas there may be security systems monitoring logs and invalid authentication attempts might trigger automated actions against the "attacker"
Author
Owner

@llamafilm commented on GitHub (Jan 5, 2024):

It looks like there is already a PR for this: #13003.

@llamafilm commented on GitHub (Jan 5, 2024): It looks like there is already a PR for this: #13003.
Author
Owner

@CTV-2023 commented on GitHub (Jan 5, 2024):

It looks like there is already a PR for this: #13003.

Which might not work, see https://github.com/netbox-community/netbox/discussions/14535

@CTV-2023 commented on GitHub (Jan 5, 2024): > It looks like there is already a PR for this: #13003. Which might not work, see https://github.com/netbox-community/netbox/discussions/14535
Author
Owner

@github-actions[bot] commented on GitHub (May 15, 2024):

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. NetBox is governed by a small group of core maintainers which means not all opened issues may receive direct feedback. Do not attempt to circumvent this process by "bumping" the issue; doing so will result in its immediate closure and you may be barred from participating in any future discussions. Please see our contributing guide.

@github-actions[bot] commented on GitHub (May 15, 2024): This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. NetBox is governed by a small group of core maintainers which means not all opened issues may receive direct feedback. **Do not** attempt to circumvent this process by "bumping" the issue; doing so will result in its immediate closure and you may be barred from participating in any future discussions. Please see our [contributing guide](https://github.com/netbox-community/netbox/blob/develop/CONTRIBUTING.md).
Author
Owner

@github-actions[bot] commented on GitHub (Jun 22, 2024):

This issue has been automatically closed due to lack of activity. In an effort to reduce noise, please do not comment any further. Note that the core maintainers may elect to reopen this issue at a later date if deemed necessary.

@github-actions[bot] commented on GitHub (Jun 22, 2024): This issue has been automatically closed due to lack of activity. In an effort to reduce noise, please do not comment any further. Note that the core maintainers may elect to reopen this issue at a later date if deemed necessary.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#8974