Configure OpenID Connect (OIDC)¶
Replace the single-user fallback with real single sign-on against your identity provider (IdP).
Prerequisites¶
- An OIDC provider (Keycloak, Entra ID, Auth0, and so on)
- Your Stegflow public URL, for example
https://stegflow.example.com
Step 1: Register a client in your IdP¶
Create a confidential client and note its client ID and secret. Configure:
- Redirect URI:
https://<your-host>/signin-oidc - Post-logout redirect URI:
https://<your-host>/signout-callback-oidc - Scopes:
openid,profile,email
Step 2: Set the OIDC settings¶
STEGFLOW_OIDC__AUTHORITY=https://id.example.com/realms/stegflow
STEGFLOW_OIDC__CLIENTID=stegflow
STEGFLOW_OIDC__CLIENTSECRET=...
STEGFLOW_ENGINE__ADMINEMAILS__0=you@example.com
Setting an authority disables single-user mode. Setting an administrator email makes you global admin; without one, nobody is.
Variations¶
- Authenticate with a certificate instead of a secret:
- Leave
STEGFLOW_OIDC__CLIENTSECRETempty. - Set
STEGFLOW_OIDC__CERTIFICATE__PATHto a PFX or PEM file. - Set
STEGFLOW_OIDC__CERTIFICATE__PASSWORDfor a protected PFX.
- Leave
- Different claim names: if your IdP names the
name,email,timezoneoravatarclaims differently, remap them with theSTEGFLOW_OIDC__CLAIMS__*variables.
Result¶
Opening the console now redirects to your IdP to sign in. After login you come back authenticated, and your email identifies your account.
Warning
Accounts are keyed on the email claim, so make sure your IdP sends a
verified email.
See the configuration reference for the full list of OIDC options, including claim mapping, the certificate and the HTTPS metadata setting.