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

Support paths in BASE during routing #451

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Commits on Nov 24, 2023

  1. ModuleRouter: support paths in BASE

    If Satosa is installed under a path which is not the root of the
    webserver (ie. "https://example.com/satosa"), then endpoint routing must
    take the base path into consideration.
    
    Some modules registered some of their endpoints with the base path
    included, but other times the base path was omitted, thus it made the
    routing fail. Now all endpoint registrations include the base path in
    their endpoint map.
    
    Provide a simple implementation for joining path components, since we
    don't want to add the separator for empty strings and when any of the
    path components already have it.
    
    Additionally, DEBUG logging was configured for the tests so that the
    debug logs are accessible during testing.
    bajnokk committed Nov 24, 2023
    Configuration menu
    Copy the full SHA
    be8f3d7 View commit details
    Browse the repository at this point in the history
  2. frontends/openid_connect: support issuer override via provider

    Even though the OIDC provider configuration has an element for setting
    the issuer, for some reason it was rewritten to BASE unconditionally,
    but this has broken provider endpoint discovery when multiple OIDC
    frontends were in use.
    bajnokk committed Nov 24, 2023
    Configuration menu
    Copy the full SHA
    b998db8 View commit details
    Browse the repository at this point in the history
  3. openid_connect_frontend.yaml.example: leverage <base_url> template

    Setting an alternative issuer should not be an encouraged setup,
    although provider discovery should work either way. The recommended
    setting is to use the BASE as the issuer, and we can leverage the
    agressive configuration value replacement logic, which rewrites all
    occurences of <base_url> to the value of BASE. The unit test was
    modified to guarantee this behaviour, though.
    bajnokk committed Nov 24, 2023
    Configuration menu
    Copy the full SHA
    4f0a9d4 View commit details
    Browse the repository at this point in the history