Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a new setting to redirect unknown URLs to either the SSO portal or a 404 page #212

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

Salamandar
Copy link

My company would like to disable the automatic "unknown url -> SSO portal" redirection. We would prefer a standard 404 web page.

/!\ UNTESTED /!\

@Salamandar Salamandar force-pushed the portal_404 branch 5 times, most recently from 32bc4c6 to 22ec0c2 Compare March 10, 2023 13:14
---
--- 5. REDIRECT TO 404 PAGE IF UNKNOWN URL -> PORTAL IS DISABLED
---
if not conf["err404_to_portal"] and longest_url_match == "" then
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah that's interesting because URL which do match a permission in the SSOwat conf will still redirect to the portal

Dunno if that was the intent but to me that's indeed the behavior we want ;)

Copy link
Author

@Salamandar Salamandar Mar 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmmmm.
Yeah, I think that is. Although… That could very well be configurable too. Do you want the public to know you have a mydomain.tld/very_secret_app_with_a_well_known_name_in_the_url ?

For now, an existing app and a non-existing one will have the same behaviour. Maybe some people will want to keep that.
There would be 2 settings :

  • Redirect unknown urls to 404 -> default should be true
  • Redirect known URLs to 404 instead of login page -> default should be false

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants