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

Allow use of the preferred_username OIDC claim. #1287

Closed
wants to merge 5 commits into from

Commits on Apr 24, 2023

  1. Allow use of the preferred_username OIDC claim.

    Previously, Headscale would only use the `email` OIDC
    claim to set the Headscale user. In certain cases
    (self-hosted SSO), it may be useful to instead use the
    `preferred_username` to set the Headscale username.
    This also closes juanfont#938.
    
    This adds a config setting to use this claim instead.
    The OIDC docs have been updated to include this entry as well.
    In addition, this adds an Authelia OIDC example to the docs.
    meson800 committed Apr 24, 2023
    Configuration menu
    Copy the full SHA
    0b138a7 View commit details
    Browse the repository at this point in the history
  2. Added OIDC claim integration tests.

    Updated the MockOIDC wrapper to take an environment variable that
    lets you set the username/email claims to return.
    
    Added two integration tests, TestOIDCEmailGrant and
    TestOIDCUsernameGrant, which check the username by checking the FQDN of
    clients.
    
    Updated the HTML template shown after OIDC login to show whatever
    username is used, based on the Headscale settings.
    meson800 committed Apr 24, 2023
    Configuration menu
    Copy the full SHA
    64f94e8 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    c65587e View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    a642383 View commit details
    Browse the repository at this point in the history

Commits on May 17, 2023

  1. Configuration menu
    Copy the full SHA
    b561002 View commit details
    Browse the repository at this point in the history