Skip to content
SHC Docs

SSO auto-redirect: skip the app login page when a Keycloak plug is connected

Status: open design. The redirect mechanisms are built. One operator flag that arms them is not.

  • Implementations B and C are built: the ce renderer plus the response injector. Implementation C shipped 2026-08-07. There are seven catalogue declarations of sso_redirect: today: affine, affine-rs, frappe, huly, journiv, kutt, windmill.
  • Implementation A is built too, across SIXTEEN apps, rollout steps 1, 2 AND 3. It was wired to a DIFFERENT operator surface from the one this document designs. That gap is CLOSED as of the 2026-08-11 ce pin bump to v0.0.51-0.20260811020521-079659588c59: the catalogue gate landed 2026-08-10 and the daemon-side publication it reads reached this tree a day later, so the scoped key now arms A and B alike. Read Rollout sketch: MEASURED STATE 2026-08-10, RE-MEASURED 2026-08-11 before acting on the rollout list, in particular, the key arms a given stack from its NEXT install or update, not from the daemon roll.
  • The audit table below is as of 2026-08-02 and is a survey, not a build log.

With -i sso=<stack> connected, a logged-out browser hitting an app should, as an opt-in, be 302’d straight into the OIDC authorization flow instead of being shown the app’s own login page with a “Sign in with SSO” button on it. (SP-side “auto-login” / “immediate SSO”; the IdP-initiated SAML flow is the same UX by a different mechanism.)

Three tiers already exist in the platform, and the audit confirms the posture between them is right:

  1. Full forward-auth gate (access: gated): unauthenticated browsers are already auto-redirected to Keycloak. Design center: apps with no auth of their own. It must NOT front native-OIDC apps; it 401s non-HTML app traffic, mangles WebSocket upgrades, and intercepts Huly’s ?token= class (render.go:122-127, hel1 handoff §E1).
  2. Native app knobs: some apps can do this themselves, per app, with config SHC already renders.
  3. Nothing (today’s default): logged-out users see the app’s login page and click the SSO button.

Audit verdicts (32 apps as of 2026-08-02, verified at pinned versions)

Section titled “Audit verdicts (32 apps as of 2026-08-02, verified at pinned versions)”

★ This heading used to read “all 32 sso-plugged apps”. It was not “all”, and the word did real damage; see Audit coverage below. The corpus was the apps carrying an oidc.plug.yaml, at one moment in time. SonarQube plugs SSO through saml.plug.yaml and was never in it, so it was never audited; seven more apps have joined the catalogue since. TestEverySSOPluggedAppIsNamedInTheAutoRedirectAudit (tests/unit/catalog/sso_redirect_audit_test.go) now makes the completeness claim checkable instead of asserted.

Native knob, wireable from the compose/config template (“just set it”):

★ Every row in this table is now WIRED, plus ciso-assistant, windmill and immich, twelve apps in all. They read --var keycloak.autoRedirect, not the ssoAutoRedirect key this document designs. See Rollout sketch: MEASURED STATE 2026-08-10.

appknoblocal-login escape hatch
gitlabomniauth_auto_sign_in_with_provider: openid_connect/users/sign_in?auto_sign_in=false
immichoauth.autoLaunch (system config / IMMICH_CONFIG_FILE)/auth/login?autoLaunch=0
paperlessPAPERLESS_REDIRECT_LOGIN_TO_SSO (+DISABLE_REGULAR_LOGIN)/accounts/login/?loggedout=1
defectdojo (2.x)DD_SOCIAL_LOGIN_AUTO_REDIRECT + DD_SOCIAL_AUTH_SHOW_LOGIN_FORM=false/login?force_login_form
librechatOPENID_AUTO_REDIRECT (+OPENID_USE_END_SESSION_ENDPOINT or logout loops)/login?redirect=false
nextclouduser_oidc allow_multiple_user_backends=0, occ post-install job, not env/login?direct=1
matrixelement sso_redirect_options.immediate + MAS passwords.enabled: falseNONE
wazuhdashboard auth.type: openid as sole typeNONE
wordpressOIDC_LOGIN_TYPE='auto' wp-config constant (overrides DB option)plugin alternate-login param
giteaderived: single oauth source + password/openid/passkey forms disabledNONE at 1.27.1

Already auto-redirecting whenever the plug is connected: netbird (no local accounts exist) and mautic (SAML configured ⇒ MainEntryPoint fires unconditionally; escape /s/login).

★ mautic’s residual (the direct /s/login hit) closed 2026-08-14. MainEntryPoint never covered the typed/bookmarked login page itself, and that is exactly what the flagship audit measured as its gap. The package now declares the static form (login_path ^/s/login/?$, sso_start /saml/discovery, measured live at the 7.1 pin: discovery 302s to /s/saml/login?idp=<realm> which serves LightSAML’s auto-submitting SAMLRequest POST page, the gitlab-shape 200). The escape moves to the fleet spelling /s/login?sso=false; the logout re-entry trade is recorded in ssoLogoutTradeAccepted. Guarded by tests/unit/catalog/mautic_sso_redirect_test.go.

★ goalert (2026-08-21): added to the catalogue, edge auto-redirect NOT yet audited; the native answer is measured. GoAlert binds the oidc plug (native OIDC configured zero-touch via GraphQL setConfig). Its login page renders a local form plus the OIDC provider button; config/config.go at v0.34.1 exposes OIDC.{Enable,NewUsers,OverrideName,IssuerURL,ClientID, ClientSecret,Scopes} and Auth.DisableBasic, but NO auto-redirect / skip-login setting, so there is no native knob to arm at this pin, and the package declares no edge sso_redirect. Re-measure config/config.go at the next pin.

★ goalert (2026-08-22): DECLARED, on the CLICK grade. The paragraph above stays true of the EDGE grades and the native knob; what it did not weigh is the fourth grade, which is exactly this class. The entry is POST-only (GET /api/v2/identity/providers/oidc → 404, POST → the flow, measured live 2026-08-21) and the login card is client-rendered (<RequireAuth fallback={<Login />}>, web/src/app/index.tsx), so sso_start: and sso_selector: are both structurally refused, and the package now declares login_path: ^/$ + sso_click_selector: form#auth-oidc button + exclude_query: [login_error] + launcher: auto. The selector is source-derived from the v0.34.1 pin (Login.tsx renders <form id={'auth-'+id}> per provider; initauth.go registers the provider as the literal "oidc"); the failed- login landing /?login_error=… is excluded by key; logout is a reload-in-place with no end-session call, recorded in ssoLogoutTradeAccepted. Ledgered in tests/unit/catalog/sso_click_selector_test.go; the checks live in the package’s app.yaml.

Partial (SSO-only login page or one-click, not a 302): mailcow (force_sso, now WIRED, and still partial; see mailcow below), peertube (redirect_on_single_external_auth), windmill (auto_login_provider, DB global setting, escape ?no_sso=1), openobserve (flag is compiled into the SaaS build only).

No knob at pinned version (verified absent, not assumed): affine, affine-rs, huly, vaultwarden (SSO_ONLY rejects password grants but still renders the page), supabase, penpot, minio, postiz, journiv, kutt, frappe, monica, highlight, ivatar, matomo, dependency-track, blockscout.

★ “NO KNOB” IS NOT “CANNOT”, and the two got collapsed. This row is a statement about CONFIGURATION, and it is right about every app in it. A later summary hardened it into “affine and huly structurally cannot auto-redirect”, which is a statement about MECHANISM, and it is only right about huly. The whole reason Implementation B exists is the app that has no knob and does have a GET-able SSO entry; kutt was the worked example, and affine + affine-rs are the same shape: /oauth/login?provider=OIDC&flow=redirect is a plain client route that the app’s own SSO button navigates to. Both now declare sso_redirect: (2026-08-09, measured against the running images on both estates: ghcr.io/toeverything/affine:0.27.3 and the house fork at affine/affine-rs:b8a8343a; the guards are tests/unit/catalog/affine_sso_redirect_test.go).

AFFiNE is nonetheless the case that needs BOTH halves, and it is the reason the launcher’s client-side payload was built: its shell is served at / and it CLIENT-ROUTES to /sign-in, so the visitor who simply types the hostname (the owner’s actual path) never sends a login request for any Traefik rule to match. The server-side router covers a direct navigation or a hard reload; the launcher: auto payload covers the rest.

A consequence worth stating plainly, because it bounds what any test or report may claim: an anonymous curl -L can never witness AFFiNE auto-redirecting. The app’s entire OAuth controller is two POST routes (/api/oauth/preflight, /api/oauth/callback); the Keycloak authorize URL is minted by a POST the browser makes, and /oauth/login serves the same SPA shell as /. There is no server-side GET at any pin that 302s to the IdP, so a redirect chain terminates on the app’s own host by construction, before and after. Proof is a browser navigation. Anyone reading a curl trace here should read it as “no evidence”, never as “not working”.

★★ AND THE SAME COLLAPSE HAPPENED TO HULY, ONE PARAGRAPH LATER. This passage used to end “Huly’s verdict is unchanged and remains correct: … /_accounts is POST-only, no knob AND no stable GET entry, which is what ‘structurally cannot’ actually looks like.” Every clause of that is a CONFIGURATION statement except the last one, and the last one is false. Corrected 2026-08-11.

What is still true: huly has no config key and the shipped bundle contains zero autoRedirect/autoSelectProvider strings. What is not: /_accounts is not POST-only. Read out of the shipped hardcoreeng/account:v0.7.426 bundle (docs/proposals/2026-08-11-sso-redirect-clickthrough-feasibility.md §1.2):

router.get("/auth/openid", async (ctx, next) => {
const state = encodeState(ctx, brandings);
await passport.authenticate("oidc", { scope: "…", state })(ctx, next);
});

A plain GET at a fixed URL, with state and the PKCE verifier minted and held server-side by openid-client. That is author checks 2 and 3 passing (the exact shape Implementation B was built for) and apps/management/huly/app.yaml has declared it since the catalogue landing. The fleet-wide path table at the end of this document has recorded /login/ → 302 for huly since 2026-08-10, so this file contained both the claim and its refutation.

huly is a solved case. Strike it from any statement of the excluded class. What is genuinely hard about huly is its CLIENT route (/login:component:LoginApp, which a browser hands back percent-encoded; see the %3A alternative in its login_path: and tests/unit/catalog/spa_login_pattern_encoding_test.go), and that is covered by the launcher: auto payload, not by an exclusion.

★ 2026-08-22: RE-MEASURED POST-RENAME, AND THE SOLVED CASE HELD, WITH TWO ADDITIONS. The stack is projects now (hostname projects.corp.bitspur.com; the catalog app stays huly). Live that day, logged out: /login, /login/ and /login%3Acomponent%3ALoginApp each answered a real 302 → /_accounts/auth/openid at the edge; the only client-side hop left is the pushState route, which is the payload’s job by construction. The CLICK grade was weighed and refused as a downgrade (huly’s entry is a stable GET; click exists for apps the edge cannot 302 into). Addition one: exclude_query: [localLogin]; the account service authenticates with failureRedirect=…/login?localLogin=true and the front’s login chunk reads the same key as its native local-login escape, and the rendered rule was 302ing that landing back into the IdP (the sonarqube authorizationError shape; measured before the fix: GET /login?localLogin=true → 302 into sso_start). Addition two: the “no knob” row above is now STALE at the deployed pin; the front (VERSION 0.7.432 live) ships login.metadata.AutoLoginProvider, a client-side native auto-redirect whose escape is the same ?localLogin=true; it is dormant on this estate (config.json carries no such key), so the two SHC halves remain what arms the app. Guarded by the huly rows of spa_shell_sso_redirect_test.go (TestSPAShellExcludesTheAppsOwnQueryLandings).

Bugs surfaced by the audit (tracked separately from this proposal):

  • blockscout’s sso plug is inert at the pin: ACCOUNT_KEYCLOAK_* exists upstream only from backend v10.1.0; the pinned 9.0.2 is Auth0-only and the frontend never receives the account-support flag.
  • monica has no SSO at 4.1.2: the keycloak vars are reserved for the unreleased v5 rewrite.

One opt-in surface, two implementations chosen per app by capability.

A scoped config key ssoAutoRedirect resolved exactly like auth.EffectiveLauncher (deployment > stack > environment > tenant > global), with the app.yaml default false everywhere. shc config set --deployment <d> ssoAutoRedirect true is the operator surface.

Implementation A: native knob (preferred, per the table above)

Section titled “Implementation A: native knob (preferred, per the table above)”

Status of this section: BUILT for sixteen apps, and UNIFIED with the scoped key 2026-08-10. Read the correction below before the design.

The app’s compose/config template consumes the resolved flag: env vars (paperless, librechat, defectdojo), rendered config files (matrix, both files are already ours), gitlab.rb (gitlab), a wp-config constant (wordpress), or a post-install occ/API job (nextcloud, immich, windmill, mailcow). Each app’s caveats live in its own template comment.

★ THE CORRECTION: this section described a flag the templates could not read

Section titled “★ THE CORRECTION: this section described a flag the templates could not read”

The paragraph above says “the app’s compose/config template consumes the resolved flag”, and §2 below says the flag is the scoped ssoAutoRedirect config key. Those two sentences were never both true. What each app shipped was a per-app var (keycloak.autoRedirect, keycloak.makeDefault, oidcOnly, ssoOnly) set with shc install/update --var. The scoped key reached Implementation B’s ingress router and nothing else.

It could not have been otherwise, and this is the part worth recording: ce’s compose render context (install_runner.go’s renderCtx) carried vars, integrations, stack, environment, tenant, hosts, tls, url / host / port / path / paths, shc and connections, and no config value of any kind. A template could not read a scoped config key even in principle. core/config/default.yaml meanwhile described the key as taking the “native knob” form and named the apps, which is why the gap survived an audit: the documentation asserted the wiring existed.

So shc config set --deployment <d> ssoAutoRedirect true armed none of the sixteen native-knob apps, and said nothing about it. There was no error, no warning, and no diagnostic; the operator’s only evidence was that the login page did not change.

ce resolves the decision once (modules/app/launcher.go, ssoAutoRedirectForDeployment: the scoped ssoAutoRedirect row at whichever scope is set, else the app.yaml sso_auto_redirect: per-app default, else false) and publishes the resolved boolean into the two render surfaces an app package can reach:

surfacebuilt inreaches
renderCtxmodules/app/install_runner.gocompose.yaml, *.job.yaml hook jobs
tmplCtxmodules/app/plug_jobs.goconsumer <plug>.plug.yaml post_deployment jobs

★ AND THERE IS A THIRD SURFACE A PACKAGE CAN REACH THAT IS NOT ON THAT LIST, which this table’s earlier wording (“the two render surfaces an app package can reach”) quietly denied: a plug’s or socket’s data: block, built in modules/app/integration_render.go. Its socketRenderCtx carries vars/stack/environment/tenant plus the bound connections, and its plugCtx adds the host callables; no config-derived value of any kind. A gate written there reads sso_auto_redirect as an UNDEFINED name, which is falsy, which a {% if %} drops without collecting a miss: the package reads as fleet-armable, the surface guard reads as green (it publishes the name itself), and the operator’s command does nothing. apps/flagship/mailcow shipped that way and was measured inert on bitspur corp/prod on 2026-08-15; dropping the per-deployment --var with the global key true restored the credential form. The fix was to move the decision to the plug JOB env, where the name is published; tests/unit/catalog/sso_fleet_key_render_surface_test.go now refuses any fleet-key gate on a data: block, catalogue-wide.

Publishing the key into data: would be the wrong repair: data: is what PersistedEdgeState freezes at bind time, and a config row that must be re-resolved on every reconcile has no business in frozen state.

The name is sso_auto_redirect, and it is deliberately a decision, not a config namespace. The rejected alternative (exposing config.* the way vars and integrations are exposed) is a secret disclosure: the config tree holds backup.password (the restic repo password), backup.aws_secret_access_key, vault.providers.*.token, smtp.password and per-provider DNS tokens, and app packages are registry artifacts re-rendered by whatever daemon installs them. An allow-list of keys is the same door with a smaller gap. It sits beside tls because it is the same kind of thing as tls: a posture this deployment resolved.

Each qualifying app gates on vars.<knob> or sso_auto_redirect:

{% if (vars.keycloak.autoRedirect or sso_auto_redirect) and integrations.oidc is defined %}

Additive. Either surface arms; neither turns the other off.

The tempting rule (“the scoped key is fleet-wide intent, the per-app var overrides it”) is unimplementable, and the reason is measurable rather than aesthetic: every catalogue vars.yaml ships its knob at false, so at render time a var an operator explicitly set to false is byte-identical to one nobody has ever touched. “Var overrides key” therefore means the packaged default beats the operator’s fleet-wide intent, always, and the config key is inert again, the defect, re-adopted as a design.

Exempting one deployment from a fleet-wide flip belongs on the axis that can express it:

Terminal window
shc config set ssoAutoRedirect true # estate
shc config set --deployment <d> ssoAutoRedirect false # this one, not

Why or <new name> and not just the new name

Section titled “Why or <new name> and not just the new name”

A jinja {% if %} over an undefined name drops its branch and does not collect a miss. A template gating on sso_auto_redirect alone would therefore render “off”, silently, on any daemon older than the seam, and since the registry keeps ten versions of every app and re-renders them on the installing daemon, that means unarmable by any surface: strictly worse than the defect. The or form is byte-identical to the pre-change output there, which is what let the catalogue change ship without waiting on a ce pin. (ce modules/app/sso_autoredirect_render_surface_test.go proves it; the catalogue guard re-proves it per app.)

★ What the scoped key does NOT arm, and why

Section titled “★ What the scoped key does NOT arm, and why”

The key is a redirect preference (where does a login attempt land) and it must never make a lockout decision fleet-wide. Five apps carry a switch that removes the credential login form outright, and each declares it in app.yaml’s local_login.closed_by:, the same declaration ce’s post-restore usable-login check (modules/app/login_path_postcheck.go, X200042NOLOGIN) already reads:

appknobwhy it is not a redirect preference
giteakeycloak.autoRedirectthe redirect IS ENABLE_PASSWORD_SIGNIN_FORM: false; no bypass URL exists at 1.27.1
wazuhkeycloak.autoRedirectnaming openid the dashboard’s sole auth type deletes the password form; the software offers no third state
matrixkeycloak.autoRedirectswitches MAS password login off alongside the immediate redirect; Synapse’s own password auth is already force-closed for MAS delegation
journivoidcOnlyOIDC_ONLY renders unconditionally (gated_on_edge: false), closes the door with or without a bound IdP
vaultwardenssoOnlySSO_ONLY likewise; a global flip would be a lockout provable without a single packet

Those five keep requiring the explicit per-app --var. oidcOnly and ssoOnly in particular are not redirect knobs at all: vaultwarden renders its SSO button whether or not an edge is bound; the var’s entire effect is removing the password form, so collapsing them would have made ssoAutoRedirect mean two different things depending on which app read it.

The split is derived, not listed: the catalogue guard reads each app’s own local_login.closed_by: and asserts the templates agree, in both directions. An app becomes armable fleet-wide only by dropping its own lockout declaration, which is a review that has to happen in front of the app.

guardproves
ce modules/app/sso_autoredirect_render_surface_test.gothe key reaches a compose template end-to-end through ExecuteCompose; the cascade and the deployment-scope exemption; the --var surface unbroken; the or form inert on an older daemon; and an exact-set pin on what each render context publishes, so adding a config namespace fails in the suite
shc tests/unit/catalog/sso_unified_surface_test.goper app, differentially: key-armed and var-armed renders are IDENTICAL; the old-daemon render is unchanged; and a closed_by-declaring app does not move under the key while still moving under its var

Both assert a non-empty corpus with a floor, and both are mutation-proven: including against the exact trap above (gating on the new name alone).

Nothing in this change arms anything. Every knob’s default is false, no app.yaml declares sso_auto_redirect: true, and the shipped ssoAutoRedirect default is false. This work makes the switch work; flipping it is an operator decision.

Implementation B: Traefik narrow redirect (apps with a GET-able

Section titled “Implementation B: Traefik narrow redirect (apps with a GET-able”

OIDC start but no knob)

New app.yaml catalog field, beside access:/self_auth::

sso_redirect:
login_path: /users/sign_in # server-visible login page path
target: /auth/oidc/login # the app's GET OIDC-initiation URL

When the flag is on and sso_redirect: is declared, ce’s WriteIngressRouteFile emits a sibling router per host (the _authcb priority-90000 pattern):

rule: Host(`h`) && Path(`/users/sign_in`) && !Query(`sso`,`false`)
middleware: redirectRegex -> https://h/auth/oidc/login

Traefik v3 rule negation carries the local-login bypass (?sso=false) at the rule level, no RE2 lookahead contortions. The resolution rides IngressIntent.AppName (the reconcile already re-reads app.yaml defaults from it), so no schema migration. Apps that declare no sso_redirect get no router, which correctly excludes the POST-only-initiation class (vaultwarden mints PKCE in the browser; penpot’s entry is POST-only and answers JSON for the SPA to navigate itself). ★ minio used to be named in that parenthetical and no longer belongs there; the verdict was taken against an embedded console this app no longer ships. See the cannot-bucket, re-measured at the end of this document.

★ CORRECTED 2026-08-11. This paragraph used to name “the SPA-shell class (huly and affine both client-route their login…)” as a second excluded class. It is not an exclusion, it is a COVERAGE GAP that has since been closed from the other side. Both apps client-route their login AND have a server-visible entry, so the router covers a direct navigation or a hard reload while the launcher: auto client payload covers the visitor who simply types the hostname. Both declare sso_redirect: today. An app is excluded by having no GET-able entry at all, not by having a shell in front of one.

The authoring contract (how an app opts in)

Section titled “The authoring contract (how an app opts in)”

Three pieces of knowledge, three different homes, chosen by who knows the answer:

knowledgelives inwhy
where the login page and the SSO entry areapp.yamla property of the software; the app packager knows it, an operator cannot
whether to auto-redirect this deploymentscoped config keyan operator decision, per deployment/stack/tenant
who the IdP is (realm, client, callback)sso.plug.yaml data:already there; unchanged by this feature
sso_redirect:
login_path: "{{ path('kutt') }}/login"
sso_start: "{{ url('kutt') }}/login/oidc"
bypass_query: sso # optional; defaults to `sso`

★★ CORRECTED 2026-08-11: THIS SECTION SAID THESE VALUES ARE JINJA-RENDERED. THEY ARE NOT, AND ITS WORKED EXAMPLE SHIPPED A 302 TO A URL WITH LITERAL BRACES IN IT.

The removed text read: “Both values are rendered through the normal jinja context”, and offered, for provider-shaped entry URLs, "{{ url('x') }}/accounts/{{ integrations.sso.plug.data.providerSlug }}/login/".

There is no jinja context on this path at all. ce’s ReadSSORedirect os.ReadFiles the catalogue app.yaml (detailAppDir, not a rendered deployment tree) and yaml.Unmarshals it; resolvePath then runs exactly ONE regexp substitution, over the two literal {{ url('svc') }} / {{ path('svc') }} forms. Every other expression survives verbatim.

Measured: that example rendered a complete, loadable router whose middleware was replacement: https://<host>/accounts/{{ integrations.sso.plug.data.providerSlug }}/login/${1}. On login_path: it is quieter and worse: looksLikeRegexp sees the {, RE2 compiles {{ as a literal brace, the rule loads and never matches for the life of the deployment, and there is no compile error for the pattern validator to catch.

ce now REFUSES both (X201008SSOTPL, ce d144d4f+) and the catalogue lint refuses them at authoring time (tests/unit/catalog/sso_redirect_declaration_lint_test.go). A provider-shaped entry URL cannot be expressed in sso_redirect: at all; if an app needs one, that is a reason not to declare, and §3’s “the only case where the plug needs a new field” no longer follows from anything.

The two authoring prefixes are the whole of what is substituted, and they matter for one reason:

  • Path-routed installs. --host example.com/kutt means the login page is at /kutt/login, not /login. Hardcoding /login produces a router that never matches. Always compose with path('<service>') / url('<service>').

Two further constraints follow from how they are substituted, and both are enforced rather than advisory:

  • Do not write any other {{ … }} expression. Nothing resolves it; see the correction above.
  • ★ Both halves must name the SAME service, and neither may carry a literal origin. The service name inside url()/path() is matched by a regexp and thrown away; only the route’s own base path is substituted, and the origin is re-attached per route from the host the request arrived on (that is the multi-host trap guard, and it is correct). So a declaration naming two services renders a 302 to the login page’s host carrying the other service’s path: a 404, or an SPA shell answering 200 forever. Measured 2026-08-10 on ghcr.io/highlight/highlight-frontend:docker-v0.5.6, the one live member of the class. There is no cross-host mechanism and none is being built; see docs/proposals/2026-08-11-sso-autoredirect-arming-plan.md, bucket C. path() on one half and url() on the other of the same service is fine, and is what kutt ships.
Terminal window
shc config set --deployment <d> ssoAutoRedirect true

★ This section describes the INTENT, which took until 2026-08-10 to become true of Implementation A: the key governed the ingress router only, and each native-knob app answered to its own --var. Both surfaces now resolve the same decision and either arms an app, except for the five whose knob closes the credential form, which stay on --var deliberately. See the correction under “Implementation A” for the precedence rule and the exclusions.

Resolved through the 5-level cascade (deployment > stack > environment > tenant > global) exactly like auth.EffectiveLauncher already does for the launcher flag, with the app.yaml default being off. It is deliberately not a vars. entry: vars are template inputs for rendering the app, and this decision governs the ingress router, which is rendered by a different subsystem from the same intent record. Putting it in vars would also make it invisible to the Traefik-host reconcile, which rebuilds routes from IngressIntent and re-resolves app.yaml defaults via IngressIntent.AppName.

The plug already mints realm, clientId, clientSecret, issuer and redirectUris. Auto-redirect enters the app’s own OIDC flow, so the callback is the one the plug already registered, no new client, no new redirect URI. This is the coupling that makes the whole thing safe: if the plug’s redirectUris did not already cover the app’s callback, the app’s own SSO button would be broken too, redirect or no redirect.

Add one field only when the entry URL embeds a provider name:

data:
# ... existing realm/clientId/clientSecret/redirectUris ...
# The slug this app uses to name the provider in its OWN routes. Consumed
# by app.yaml's sso_redirect.sso_start, NOT by keycloak.
providerSlug: "keycloak"

4. The five checks before declaring sso_redirect

Section titled “4. The five checks before declaring sso_redirect”

An app author must verify all five; failing any one means do not declare it (and the app simply gets no router, a clean no-op, not a broken login):

  1. login_path is server-visible. The browser must actually request it. For an SPA this is true on a fresh load or bookmark, and false for in-app client-side navigation, which is why an SPA gets partial, not yes.
  2. sso_start is a plain GET, and mints state/nonce/PKCE server-side. If the browser mints the verifier (vaultwarden) or the server returns JSON for the SPA to navigate itself (penpot), a 302 cannot enter the flow; it can build the URL but not the browser-side half of the pair, and the flow dies at the callback. ★ These are two different failures and they are not equally final. “The browser holds a secret we cannot create” is structural. “The server answers JSON instead of a 302” is a response shape, and an app can grow a fixed entry that fixes it without changing anything else, which is exactly what happened to the minio console. Ask who holds the secret before filing an app under either.
  3. sso_start is a stable URL. frappe fails here in a subtle way: its SSO link is a GET anchor, but the href is a per-render Keycloak authorize URL carrying a single-use state token. There is no fixed URL to redirect to.
  4. The bypass reaches the local login form, so a broken IdP cannot lock out a local admin.
  5. Logout does not land on login_path, or honours the bypass when it does. Otherwise “log out” 302s straight back into the IdP session and logs the user back in.

4a. Two matcher rules the renderer must get right

Section titled “4a. Two matcher rules the renderer must get right”

Both were found by measurement, and both fail silently: the router simply never fires, or fires and is trivially evaded.

Match case-insensitively when the app’s router is. Traefik’s Path() matcher is case-SENSITIVE; most SPA routers are not. AFFiNE declares both /sign-In and /signIn and React Router matches either casing, so Path('/sign-in') is bypassed by simply typing /signIn, which renders the same page. Prefer:

PathRegexp(`(?i)^/sign-?in$`)

Any app whose framework matches paths loosely (trailing slash, casing, optional segments) needs the regexp form, and the app author is the one who knows. Treat login_path as a pattern, not a literal.

The prefix goes in opposite directions for the two URLs. On a path-routed install (--host example.com/affine):

  • sso_start keeps the prefix; the app’s own router is mounted at basename: subPath, so the entry is https://example.com/affine/oauth/login. Build it from url('<service>').
  • the OIDC redirect_uri in the plug drops it, because the app resolves the callback against the origin only, which is exactly why affine’s sso.plug.yaml strips path() from redirectUris. (kutt registers {{ url('kutt') }}/*; the wildcard already spans the prefix, so it never needed the strip.)

Getting these backwards produces a 404 on entry or an invalid-redirect-uri refusal at the IdP, neither of which points at the router that caused it.

5. Worked example: kutt (the one clean yes in the catalogue)

Section titled “5. Worked example: kutt (the one clean yes in the catalogue)”
apps/kutt/app.yaml
sso_redirect:
login_path: "{{ path('kutt') }}/login"
sso_start: "{{ url('kutt') }}/login/oidc"

Renders to this router beside the app’s existing ones:

kutt_loginredir:
rule: Host(`links.example.com`) && Path(`/login`) && !Query(`sso`,`false`)
priority: 90000
middlewares: [kutt_loginredir_mw]
service: kutt
kutt_loginredir_mw:
redirectRegex:
regex: ".*"
replacement: "https://links.example.com/login/oidc"

Flow: logged-out browser asks for /login → Traefik 302s to /login/oidc → kutt’s own handler mints state and 302s to Keycloak → Keycloak returns to the callback the plug already registered → session established. An admin needing the password form visits /login?sso=false, which the !Query guard excludes from the router.

Audit coverage: what the 2026-08-02 sweep never looked at

Section titled “Audit coverage: what the 2026-08-02 sweep never looked at”

The sweep enumerated apps carrying an oidc.plug.yaml. Two things fell outside that corpus, and neither left a trace in this document:

  1. SAML-plugged apps. Two existed when this was written: mautic (audited anyway, because it turned up on another axis) and sonarqube (never audited). (Three as of 2026-08-11, fleet joined, and is audited below. The number moving is the point: a corpus definition that omits a whole SSO transport gets quietly wronger every week, which is why TestSSOPlugCorpusIsWhatWeThinkItIs enumerates the plug FILENAMES rather than trusting this sentence.)
  2. Apps added to the catalogue after 2026-08-02.

An app that is absent from a completeness claim is indistinguishable from an app that was examined and found uninteresting. That is the same defect class the rest of this document warns about, a report that is confidently silent about what it did not look at, and it is why the audit is now guarded by a test rather than by this sentence.

sonarqube: MEASURED 2026-08-08, and REFUSED

Section titled “sonarqube: MEASURED 2026-08-08, and REFUSED”

★ THE VERDICT BELOW WAS OVERTAKEN 2026-08-14; THE MEASUREMENTS STAND. docs/decisions/2026-08-14-flagship-autoredirect-corp-prod.md ruled (#2) that an SSO-capable flagship whose package cannot be armed is a gap to fix, and the ruling chain behind it (see the overrule banner in docs/handoff/2026-08-10-ssoautoredirect-arming-audit.md) chose the post-logout behaviour check 5 measures as the DESIRED one. sonarqube now DECLARES the static form: login_path ^/sessions/new/?$, sso_start /sessions/init/saml (proven far-side on promanager corp/prod the same day: 302 → …/realms/corp/protocol/saml), with exclude_query: [authorizationError] carving out check 6 exactly as §“who else does exclude_query unblock” said it could. Check 5 is not fixed; it is TAKEN, the windmill/frappe trade, recorded in ssoLogoutTradeAccepted and argued in the package. Pinned by TestSonarQubeDeclaresTheRuledStaticForm and tests/unit/catalog/sonarqube_sso_redirect_test.go. Every measurement below is unchanged and still the evidence base; the “do not declare” sentences read on.

Pin sonarqube:26.7.0.124771-community. Measured against the live quality.corp.bitspur.com (read-only) and against the pinned image run locally and driven with a real browser over CDP.

checkverdictevidence
1. login_path server-visiblepass (not “partial”)anonymous GET / serves the 1620-byte SPA shell, then the bundle’s gi() runs window.location.replace(baseUrl + "/sessions/new?return_to=…"), a real navigation. CDP recorded it as a Document request: GET /sessions/new?return_to=%2F [200]. Traefik sees the login path.
2. sso_start is a plain GET, state minted server-sidepassGET /sessions/init/saml → 302 to …/realms/corp/protocol/saml?SAMLRequest=…&RelayState=…, both minted by SonarQube.
3. sso_start is stablepassfixed path, no per-render token.
4. bypass reaches the local formpassGET /sessions/new?sso=false → 200, password form (SonarQube ignores unknown query params).
5. logout does not land on login_path★★ FAILsee below

Check 5, measured. “Log out” in the nav menu is a link to the client-side route /sessions/logout, whose component POSTs /api/authentication/logout and then runs window.location.replace(getBaseUrl() + "/"). The full sequence of server-visible document requests after clicking it, recorded over CDP against the pinned image:

GET /sessions/logout
GET /
GET /sessions/new?return_to=%2F <-- login_path, no bypass query
GET /sessions/new?return_to=%2F

The third hop is a top-level request for the declared login_path carrying return_to=%2F and not sso=false. The rule this proposal would render (Host(`h`) && PathRegexp(`^/sessions/new$`) && !Query(`sso`,`false`)) matches it. So with ssoAutoRedirect armed, logging out 302s the browser into /sessions/init/saml, Keycloak’s still-live SSO cookie answers, and the user is signed straight back in.

And nothing mitigates it. GET /api/settings/list_definitions against the pinned image returns exactly 13 sonar.auth.saml.* settings and zero keys matching logout or slo anywhere in the definition set. SonarQube Community Build has no SAML single-logout: it never ends the Keycloak session, so the re-entry always succeeds.

This is worse than the frappe and gitlab cases, which take the same trade knowingly. There, the loop is the cost of a knob whose benefit is a skipped login page. Here it would be introduced by a declaration that buys the same benefit, on an app whose entire content is source code and a list of where it is broken, and an operator who cannot log out of that is a materially worse outcome than one extra click. ?sso=false remains an escape, but an escape you must know about is not a logout.

Check 6, measured 2026-08-09: a SIXTH check this document did not have, and it is now the binding one. SonarQube routes ordinary authorization failures through the same login path, with a query key the bypass cannot carve out. From the shipped bundle (web/js/startReactApp-*.js):

function gy(){ …new URLSearchParams({return_to:e, authorizationError:"true"});
window.location.replace(Zn()+"/sessions/new?"+t) }

and the login form renders the message from it (const f = !!n.query.authorizationError). Its callers are routine:

if(!e.canAdmin){ gy(); return } // non-admin opens an admin page
catch(L){ if(L.status===Forbidden) gy() } // ANY 403 loading a component
checkPermissions = () => !isProjectAdmin() && gy()

So a user who opens a project they lack permission on lands on /sessions/new?return_to=…&authorizationError=true: the declared login path, without sso=false. The router matches → /sessions/init/saml → keycloak’s live session answers → signed in again → same 403 → gy() again. ERR_TOO_MANY_REDIRECTS, and the “not authorized” message never renders. This fires in ordinary multi-user use, not only on a logout click, which makes it worse than check 5.

At the pin this was measured on it could not be carved out: ce rendered exactly one exclusion, !Query(<bypass>,`false`), already spent on sso=false (the break-glass admin’s only door), and login_path is a PATH regexp that never sees the query string.

★ That is no longer true, and this document said it was. ce main 40ddc883 adds SSORedirect.ExcludeQuery (exclude_query:), rendering !QueryRegexp(`<key>`,`.*`), presence at any value, including empty, and ships TestExcludeQueryTakesTheRequestOutRegardlessOfValue against this exact key. It is in the tree now: go.mod pins ce v0.0.50-0.20260810224626-6a3dcc5d3596, and 40ddc883 is an ancestor of it, so exclude_query: [authorizationError] is writable today rather than at some future pin bump.

It does not reopen sonarqube. Check 5 is untouched, and check 5 alone is disqualifying. ce’s own comment on the field says so: ”★ THIS DOES NOT REOPEN SONARQUBE. That refusal has TWO blockers and this addresses one.”

★★ RE-EXAMINED 2026-08-11, because the constraint the refusal rested on had been removed

Section titled “★★ RE-EXAMINED 2026-08-11, because the constraint the refusal rested on had been removed”

The refusal above was argued as an arithmetic: three conditions funnel into one URL, and ce could carve out only one query, already spent on ?sso=false. exclude_query is a list, so that arithmetic is obsolete and the refusal was re-opened on purpose and re-measured, on a locally-run sonarqube:26.7.0.124771-community driven over CDP, with a real non-admin account and a private project.

#conditionmeasured server-visible URLquery keys
1cold visit, logged out, to /GET /sessions/new?return_to=%2Freturn_to
2logout from an authenticated sessionGET /sessions/new?return_to=%2Freturn_to
3permission denial (non-admin GETs /admin/settings)GET /sessions/new?return_to=%2Fadmin%2Fsettings&authorizationError=truereturn_to, authorizationError
4break-glass adminGET /sessions/new?sso=false → 200, local password formsso

Condition 3 is admissible; condition 2 is not, and the reason is sharper than before. Conditions 1 and 2 are not two URLs that need telling apart; they are one request. Compared on the wire (CDP requestWillBeSentExtraInfo, which is where Cookie and Accept appear) they are identical: same query, same header keys, same header values, Referer: <base>/ on both, and no Cookie on either (the logout POST clears the JWT before the hop). Zero headers differed.

And the return_to VALUE is not a discriminator either, which forecloses the obvious next feature request, “let exclude_query match a key’s value, not just its presence”. SonarQube’s logout component runs window.location.replace(getBaseUrl() + "/") unconditionally, so logout is always return_to=%2F, including when clicked from a deep page (measured from /project/issues?id=…). Meanwhile a cold visit carries whatever was asked for, %2F included:

cold GET / -> ?return_to=%2F
cold GET /projects -> ?return_to=%2Fprojects
cold GET /coding_rules -> ?return_to=%2Fcoding_rules

A value matcher would have to say “redirect unless return_to=%2F”, which disables the redirect for a cold visit to the app root, the launcher tile, and every bookmark of the bare host. It would break the feature in exactly the case the feature exists to serve and still not fix logout. Do not file that feature request on sonarqube’s evidence: this app refutes it rather than motivating it.

The SAML surface was re-confirmed at the same time: GET /api/settings/list_definitions still returns exactly 13 sonar.auth.saml.* keys with no logout/slo among them.

Verdict: unchanged; do not declare sso_redirect for sonarqube, but at a new and narrower constraint. Pinned by TestSonarQubeDoesNotDeclareSSORedirect. (b) is answered: exclude_query: [authorizationError] is writable today and would take the permission-denial bounce out. (a), LOGOUT, is the sole remaining blocker and it is an upstream one: nothing ce can ship resolves it, because there is no discriminator in the request to build a rule from. Reopen when SonarQube adds SAML SLO, moves the post-logout landing off /sessions/new, or gives that hop a key of its own (paperless’s /accounts/login/?loggedout=1 is the shape to look for), not on a ce release note.

Who else does exclude_query unblock? Today: nobody. The lead is elsewhere.

Section titled “Who else does exclude_query unblock? Today: nobody. The lead is elsewhere.”

The same 2026-08-11 pass swept the catalogue for apps refused on check 5 alone, since those are the ones a working exclude_query could newly admit. The set has exactly one member and it is sonarqube. Every other refusal on record fails an earlier check, which no query exclusion touches:

appwhy it is refuseddoes exclude_query help?
sonarqubecheck 5, logout, and check 6check 6 yes, check 5 no (measured above)
dependency-trackbrowser-minted PKCE verifier; no server-visible login pathno, fails checks 1 and 2
penpotlogin page is the SPA fragment /#/auth/login; login-with-oidc is POST-only (405)no EDGE grade, fails checks 1 and 2, permanently. CLICK grade declared 2026-08-22
vaultwarden, minio, minio-classiccheck 2: the flow is minted browser-side or returned as JSONno

★ The real opportunity is the opposite population: the apps that DECLARED and ate the logout loop knowingly. huly, windmill, affine, affine-rs and frappe each accept a documented logout trade with ?sso=false as the escape, and sso_logout_declaration_test.go records affine, affine-rs, huly, journiv, vaultwarden and windmill as logout debt owed, not accepted. If any of their post-logout hops carries a distinguishing query key, the way authorizationError does here, or loggedout does on paperless, then exclude_query retires that debt outright rather than merely capping it.

This is UNMEASURED and must not be written up as a finding. None of those packages records a concrete post-logout URL with its query string; they describe the landing qualitatively (“returns the browser to its login route”). The work is one CDP pass per app asking the single question this section asked of sonarqube: does the logout hop carry a query key the cold visit does not? Note the two-sided answer sonarqube gives, one condition did, one did not, so the question has to be asked per condition, per app, and cannot be inferred from the landing path alone.

Proof trap. With the router armed, curl -L https://quality.<domain>/ still ends on the app’s own host: / is a 200 SPA shell and the hop to /sessions/new is client-side JS. The only honest server-side probe is curl -L https://quality.<domain>/sessions/new.

Two notes for whoever reopens it:

  • resolveLauncherAuto (ce modules/app/sso_redirect.go) requires DeclaredStatic(): login_path and sso_start both non-empty. SonarQube’s pair would satisfy it (/sessions/new ≠ /sessions/init/saml, and ^/sessions/new$ does not match the entry, so neither the self-loop refusal nor the pattern-matches-entry refusal fires). The launcher: auto client payload was not the blocker.
  • Check 1 is not partial for this app. The measurement above is the correction: SonarQube’s SPA reaches its login page by window.location.replace, not history.pushState, so the server sees it on every entry, which is exactly why check 5 fails.

affine-rs: one constraint MEASURED, and the redirect question SINCE ANSWERED

Section titled “affine-rs: one constraint MEASURED, and the redirect question SINCE ANSWERED”

★★ THIS SECTION IS DATED 2026-08-08 AND WAS OVERTAKEN ON 2026-08-09. Read the correction before the analysis below it. Everything from “It has never been deployed to production” onward was written while the package was unlanded and the redirect question open. It is kept, rather than deleted, because its tier-1 finding (RULING T-1b) is still live and is the only place it is argued at length. But its tier-2 conclusion has been superseded, and leaving it to be read as current is the failure this whole document is about.

What changed. affine-rs is on main. It declares sso_redirect:, login_path: "(?i)^{{ path('affine-rs') }}/sign-?in/?$", sso_start: "{{ path('affine-rs') }}/oauth/login?provider=OIDC&flow=redirect", measured 2026-08-09 against the house fork affine/affine-rs:b8a8343a, guarded by tests/unit/catalog/affine_sso_redirect_test.go, and the fleet-wide path table at the end of this document records /sign-in/ and /signIn both 302-ing. The passage below that says it “would inherit affine’s exclusion” was written when affine was believed excluded; affine is not excluded either (see the correction in What exists today), so neither is this.

What did NOT change, and is the reason the section stays. RULING T-1b is unaffected: affine-rs owns its own session, so its route must never carry shc-oidc@file. That is a tier-1 fact about gating, not an answer to the tier-2 redirect question, and the two were conflated once already. So is check 5; end_session appears in neither the 0.27.3 bundle nor the affine-rs server, so this app carries the logout debt knowingly, exactly as affine and huly do.

affine-rs (apps/knowledge-base/affine-rs, app version 1.0) was packaged 2026-08-08 on feat/affine-rs-catalog: the seat-cap-free Rust AFFiNE server, the same MIT AFFiNE v0.27.3 client bundle the affine package ships, on a from-scratch back end. It sits alongside affine rather than replacing it. It carries an oidc.plug.yaml, so it is in this audit’s corpus, and TestEverySSOPluggedAppIsNamedInTheAutoRedirectAudit caught its absence here before the package could be published, the guard working as intended, for the second time.

As of 2026-08-08 it had never been deployed to production; both estates (knowledge.corp.bitspur.com, knowledge.corp.promanager.vip) still ran the upstream affine package, so nothing in the rest of this section was a live-estate measurement, and it was listed in Not yet audited rather than given a verdict. The 2026-08-09 measurement in the box above is what closed that.

What IS measured, and it constrains tier 1, not this proposal. affine-rs owns its Keycloak flow end to end. The client navigates to /oauth/login?provider=OIDC; that page POSTs /api/oauth/preflight (route 15), where the server mints state and the PKCE verifier and stores them with a TTL; Keycloak returns to POST /api/oauth/callback (route 16), which sets this server’s own sid cookie. That session is the app’s, not SHC’s, so its route must never carry the shc-oidc@file forward-auth middleware. EMP-A (affine repo docs/emp-a-results.md, run against the production traefik b631ee75, forward-auth 4bc366d6 and keycloak ad8e8366 images) drove a real RFC6455 upgrade through both route shapes:

credential on the upgradeungated routegated route (shc-oidc@file)
Cookie101, survived401
Sec-WebSocket-Protocol101, survived401
query string101, survived401
Authorization101, survived401

Every upgrade through the gated route was refused before it reached the backend, because forward-auth demands an SHC SSO session the app’s own flow never creates. This is RULING T-1b, and it is why apps/knowledge-base/affine-rs/app.yaml pins access: open explicitly instead of leaving it to its identical default. The failure is silent: the symptom is not a login page, it is an app that loads, signs in, renders the workspace and then never syncs: WebSocket closed immediately, no server-side log line, because the request never reached the server. That is the first bullet of What exists today (“it must NOT front native-OIDC apps”) with a number attached, and it is the reason “just gate it” is not an available answer for this app.

What is NOT established, and must not be declared on inference. The five author checks have not been run against this package. The reading from its source and its frozen contract is:

  • check 1 (login_path server-visible): expected to FAIL, unverified. Its RULING H-1 serves selfhost.html as both the SPA entry and the SPA fallback, so the server registers one shell for every path, and the client is the same 0.27.3 bundle whose /sign-in is reached by history.pushState, the blocker already recorded for affine below. Its default posture tightens this rather than loosening it: with LocalWorkspace absent from serverConfig.features (SHC_AFFINE_ENABLE_LOCAL_WORKSPACE defaults false), a signed-out browser at / is jumpToSignIn()d client-side and no editor mounts, so the server still sees only GET /.
  • check 2 (plain GET entry, state minted server-side): expected to PASS, by the same correction recorded for affine below, and more strongly: /oauth/login is a declared route that self-starts the flow, and the PKCE verifier is minted and stored server-side under vars.keycloak.flowTtlMs.
  • check 5 (logout): expected to FAIL. end_session appears nowhere in the 0.27.3 bundle and nowhere in the affine-rs server: neither side has RP-initiated logout, so auto-redirect plus a live Keycloak cookie means sign-out is undone by the next hard reload. Identical to the affine finding, and it is listed under Non-goals and guard rails below.

On that reading affine-rs would inherit affine’s exclusion. It was recorded as not audited rather than as excluded, for three reasons: the reading was inference from source and contract, not measurement; the package ships a forked client whose divergence from stock had not been checked against check 1 specifically; and the entire subject of this document is the difference between “examined” and “assumed”.

★ AND THE MEASUREMENT WENT THE OTHER WAY. Held to its own standard, this paragraph was right to refuse the inference: affine turned out not to be excluded, so the exclusion affine-rs was expected to inherit does not exist. It declared on 2026-08-09. Check 5 still fails on both; that is the logout debt, carried knowingly and recorded under Non-goals and guard rails, and check 1 is answered by the pair, server-side router plus launcher: auto payload, not by either half alone.

One thing that does not carry over: affine’s flags.allowGuestDemoWorkspace=false (recorded below as the reason the redirect buys little there) is a var of the affine package only. affine-rs has no such knob; the comparable effect comes from the LocalWorkspace default above, which is a server default and not an operator surface. Whoever audits this should not assume the UX argument transfers unexamined.

mailcow: MEASURED 2026-08-10, WIRED, and deliberately still PARTIAL

Section titled “mailcow: MEASURED 2026-08-10, WIRED, and deliberately still PARTIAL”

Rollout step 2’s last unbuilt app. Read out of the pinned mailcow tree (2026-07a, the tag mailcow-config-init clones), not from upstream documentation, and not from a browser: nothing below is a live-estate measurement.

force_sso is not what its name suggests, and the difference is the whole verdict. It is one key in a JSON blob at the redis key CUSTOM_LOGIN (functions.customize.inc.php:207-221), not a database row, not an env var, and its only two readers are two custom_login.force_sso != 1 guards in data/web/templates/user_index.twig (line 45 wraps the username/password form, line 74 the FIDO2 button). It hides a form. It issues no redirect at any value, so mailcow gets no sso_redirect: block, and TestMailcowDoesNotDeclareSSORedirect pins that.

checkverdictevidence
1. login_path server-visiblepass, and it is /index.php:51-59 renders the login card inline on the bare host, the row already in the fleet-wide path table below
2/3. GET entry, stablen/anothing is redirected from or to; the SSO entry is the link /?iam_sso=1 (triggers.user.inc.php:4) and is never made a rule’s target
4. bypass reaches the local formpass, /adminforce_sso appears NOWHERE in admin/index.php or templates/admin_index.twig; the admin login page renders login_user+pass_user unconditionally, as does domainadmin_index.twig. Only the MAILBOX page is touched
5. logout does not land in a looppass, for the reason the knob is partialsessions.inc.php:97-128 destroys the PHP session and 302s to /, /admin or /domainadmin. The Keycloak session survives (the vendored stevenmaguire getLogoutUrl() is called from nowhere in data/web) but with no redirect in play the browser STOPS on a login page instead of re-entering the flow

Check 4 is why mailcow is recorded in local_login_declaration_test.go’s lockoutBypasses and does not declare local_login.closed_by: a confident “nobody can log in” that is false teaches operators to ignore the true ones. Check 5 is recorded as a trade in sso_logout_declaration_test.go.

Two properties of the write that the other Implementation-A apps do not have. /api/v1/get/ at this pin routes identity-provider and ~40 other objects and not custom_login, so:

  • the settings-row read-back the sibling identity-provider write performs is structurally unavailable, and the job reads the login page back instead, asserting the credential form is gone, that an SSO entry is present, and (before it writes at all) that /admin still serves a form. It rolls the flag back and exits non-zero on any of those. This is the windmill lesson applied: a stored row read true on a live estate while the feature was dead;
  • the write cannot preserve what it does not send, and the handler coerces every absent key to 0, so a write resets the three cosmetic hide_*_quicklink preferences. The job therefore reads first and writes only when there is something to change, which keeps the default (off) path from touching anything at all.

Observability. This work is in the oidc plug’s jobs.post_deployment, not in a post_install hook. ce logs a failing plug job through corelog.Error with a coded error (modules/app/plug_jobs.go), where a failing post_install hook is corelog.Warn and the CLI still exits 0 (install_runner.go, the X500908HKFAIL site). Same non-fatal posture, strictly louder record.

Owed: a live-estate proof. Nothing here has been driven in a browser, and the flag ships off.

fleet gained a saml.plug.yaml on 2026-08-11 and so entered this audit’s corpus on that day. It is refused, on three findings; the third is the interesting one because no other app in the catalogue has it.

Check 1 fails: no server-visible login path. GET /login returns HTTP 200 and 8585 bytes, but those bytes are an SPA shell: one CSS bundle, one JS bundle, a mount point. The rendered DOM after settle is Welcome to Fleet / Email / Password / Log in / Forgot password?, all client-side. A Traefik PathRegexp router cannot see a form that the server never sends. This is already the verdict in the fleet-wide path table below; it is repeated here so the row and the verdict are not two separate facts a reader has to join.

Check 5 fails: no SAML single logout. Fleet registers exactly three SSO routes at v4.90.0 (server/service/handler.go): POST /api/v1/fleet/sso, POST /api/v1/fleet/sso/callback, GET /api/v1/fleet/sso. /api/_version_/fleet/logout is fleet’s own session teardown, not a SAML SLO ACS, and the sso_settings struct (recovered verbatim from the pinned binary’s type metadata) carries no logout field of any kind. Fleet therefore never ends the keycloak session, so a login-path redirect would sign a just-logged-out user straight back in. Same shape as sonarqube’s refusal.

★ And the one that is specific to fleet: SSO-vs-password is PER USER, so an auto-redirect would take the break-glass away. Every other app in this document has an org-wide switch: turn SSO on and everyone uses it; add a ?bypass=1 query and the local form comes back. Fleet does not work that way. User.SSOEnabled is a per-user column: Login() refuses a password only for a user carrying it, and LoginSSOUser() symmetrically refuses SSO for a user without it (“user not configured to use sso”). Enabling org SSO converts nobody, and JIT provisioning (the only thing that would) is Premium.

So on any real fleet deployment the population is mixed, and the majority are password users. A router that redirected the login path into POST /api/v1/fleet/sso would send every one of them into a flow that refuses them by design, including the bootstrap admin the package creates, which is the deployment’s only local login. On Fleet Free there is no way back from that: the documented break-glass (an account with email 2FA) is Premium, an SSO account cannot authenticate with fleetctl either, and recovery is direct MySQL surgery. The refusal is recorded as a guarded invariant in apps/integrated/fleet/saml.plug.yaml and tests/unit/catalog/fleet_break_glass_test.go, not only as a verdict here.

Reopen only if upstream adds SAML SLO and a server-rendered login path and an org-wide SSO-only mode with a documented bypass, and re-measure all three.

Carrying an SSO plug, absent from the verdicts above, and not measured, listed so the gap is visible rather than silent. Nothing here may be declared until it is measured:

appplugversionstatus
affine-rsoidc1.0★ AUDITED AND DECLARED, 2026-08-09; this row said “not audited” and is corrected 2026-08-11. It declares sso_redirect: (Implementation B + launcher: auto), measured against affine/affine-rs:b8a8343a and guarded by tests/unit/catalog/affine_sso_redirect_test.go; the fleet-wide path table records /sign-in/ and /signIn both 302-ing. Two things from the earlier reading survive unchanged: RULING T-1b (its route must never carry shc-oidc@file; EMP-A measured 401 on every WebSocket-upgrade credential through a gated route) is a tier-1 fact and still binding, and check 5 still FAILS on the absent end_session, the logout debt, carried knowingly. See the subsection above.
supersetoidc6.1.0★ MEASURED AND DECLARED, 2026-08-17; this row said “not audited” for nine days while the app was live on bitspur, and the operator found it before the catalogue did (“why isn’t this auto sso login redirect?”). Superset is access: open, so nothing was fronting it; measured on the live corp/prod deployment, GET / -> 302 /superset/welcome/ -> 302 /login/ -> 200, a sign-in card with one “Sign in with Keycloak” button. Implementation A does not exist at this version and that is read off the image, not guessed: SupersetSecurityManager.authoauthview evaluates to flask_appbuilder.security.views.AuthOAuthView, and FAB 5.0.2 renders the provider page whenever provider is None: no single-provider shortcut, no config key that adds one. It takes Implementation B: login_path: ^…/login/?$ (the /? is load-bearing; GET /login is a 308 to /login/), sso_start: …/login/keycloak (measured a plain GET -> 302 to the realm with state and nonce minted server-side by FAB/authlib). Check 5 needed its own answer: logout walks /logout/ -> / -> /superset/welcome/ -> /login/?next=…, back onto the declared path, and exclude_query: cannot help because that ?next= is byte-identical to a first-time visitor’s. Answered with the app’s OWN config: FAB 5.0.2’s AuthView.logout honours LOGOUT_REDIRECT_URL, pointed at the realm’s end_session endpoint with client_id and a percent-encoded post_logout_redirect_uri back to /login/?sso=false, so this app does not join the paperless/kutt/mailcow “IdP session survives” trade; it ends the session. Both directions measured against the live realm: the superset origin -> 302 to the bypass, a foreign origin -> “Invalid redirect uri”. Guarded by tests/unit/catalog/superset_sso_redirect_test.go.
glitchtipoidc6.2.5★ MEASURED AND REFUSED, 2026-08-14; this row said “inconclusive; needs a local bring-up” and the follow-up happened against the LIVE corp/prod deployment (bitspur) once the backend was actually routable: allauth HEADLESS is the whole story. The one provider entry is POST /_allauth/browser/v1/auth/provider/redirect (GET 405; POST without the SPA-held CSRF pair 403), the classic /accounts/<provider>/login/ GET URLs are NOT mounted (404), /login is a path-routed Angular shell with no server-rendered anchor, and settings.py has no auto-redirect knob. Fails check 2 structurally, the penpot/dependency-track class. Refusal argued in the package, pinned by ssoRedirectRefusals in getable_sso_redirect_test.go; an open gap under the 2026-08-14 ruling, owed upstream work.
openreplayoidc1.27★ MEASURED AND DECLARED, 2026-08-21, the first row of the gated sweep below, and the only app in that sweep with no native knob at all, so an unarmed edge here means a real click. It runs a first-party soft-fork of chalice whose oidc_login handler mints state, nonce and a PKCE verifier server-side, seals them into the httponly orOidcTx cookie and returns a 302, checks 2 and 3, answered on the server side. /login is a real document request (nginx rewrites every non-asset path to /index.html), so check 1 passes the huly/librechat way and both halves are needed. login_path: (?i)^…/login/?$, sso_start: …/api/sso/oidc/login. ★ exclude_query: [jwt, error] is not optional: the callback lands a SUCCESSFUL login on /login?jwt=…, whose path matches, so an unexcluded rule 302s the sign-in back into the IdP and throws the token away. Check 5 is the windmill/mailcow trade (no RP-initiated logout in the fork; recorded in ssoLogoutTradeAccepted). ★ Image-conditional, uniquely: point vars.images.chalice back at upstream’s community build and these routes 404.
ciso-assistantoidc3.20.8★ MEASURED AND REFUSED, 2026-08-21, a shape no other refusal in the catalogue has. Check 1 passes (/login is real SvelteKit SSR), and check 2 fails because the SSO entry is the login page itself with a query parameter: measured through caddy, GET /login → 302 /login?sso → 200 whose server-rendered body is the “Login with SSO…” spinner, while /login?local=1 → 200 with the password form. A Traefik rule matches on PATH, so /login and /login?sso are the same target and any anchored router 302s itself; ce refuses it from the other end too (resolveLauncherAuto strips the query and returns false when the remainder matches login_path). The classic allauth GET entry is genuinely absent; /api/accounts/oidc/openid_connect/login/ → 404 while the callback → 302. The app’s own keycloak.autoRedirect is that caddy 302, so nothing is lost.
defectdojo-classicoidc2.58not audited, but defectdojo has a NATIVE knob (DD_SOCIAL_LOGIN_AUTO_REDIRECT), so this is an Implementation A question, not an sso_redirect one
midpointoidc4.10★ MEASURED AND REFUSED, 2026-08-21, and the refusal is about the ARMING TOPOLOGY, not the app, which makes it the odd one out. Checks 1-3 all pass: /midpoint/login is server-rendered Wicket (measured with a cookie jar: /midpoint/auth/default lands on /midpoint/login?0, 200, carrying name="username" and a spring_security_login form action), and GET /midpoint/auth/sso → 302 → …/authorization/shc-keycloak → 302 → the realm with state and nonce minted server-side. It refuses anyway because one key arms both surfaces: ce renders the router only when ssoAutoRedirect resolves true, and compose.yaml gates the OIDC sequence’s <default>true</default> on vars.keycloak.makeDefault or sso_auto_redirect, the same scoped key. So true makes midPoint 302 its own login page before any rule is consulted (measured on the armed live deployment) and false renders no router; there is no configuration where the router does anything new. ★ And it would cost the way back in: the documented lockout escape /midpoint/auth/default LANDS on /midpoint/login, minted by midPoint, so no ?sso=false rides along and exclude_query has nothing to name but Wicket’s page-id.
midpoint-classicoidc4.8not audited
planeoidc1.4not audited, and there is a PRIOR question: the plug (landed 2026-08-22) binds the Commercial God Mode OIDC surface, while the pinned images are Community v1.4.1, which ships no OIDC at all (the plug’s reconciler measures the live key list and refuses on Community). Nothing to auto-redirect exists until a deployment runs a paid image set; measure checks 1–5 against that build, not this one. ★ 2026-08-22: DECLARED, on the CLICK grade, and the prior question was answered sideways: the GitLab chain (plane-set-god-mode-gitlab.job.yaml, Plane → GitLab → Keycloak) put a real SSO button on Community’s login page with no paid image set, so the audit ran against THIS build after all. The entry PASSES and the rule is refused: GET /auth/gitlab/ → 302 to GitLab’s authorize with server-minted state (measured live), but the only server-visible login document is /, which is also the signed-in SPA’s boot path and the bare post-logout landing, so no path-keyed 302 may exist (penpot’s lesson); the served / is a Vite shell with zero gitlab bytes for the edge scrape, and the closed instance-configuration key list has no auto-redirect knob. Declared login_path: ^/$ + sso_click_selector: button img[alt="GitLab Logo"] + exclude_query: [error_code, error_message] (the pair every failed authentication lands on / with, OAuth and credential) + launcher: auto. Ledgered in tests/unit/catalog/sso_click_selector_test.go; the checks live in the package’s app.yaml. The Commercial-OIDC half of this row is unchanged.
nextcloud-pickeroidc0.1not audited. Landed 2026-08-08 and was caught by TestEverySSOPluggedAppIsNamedInTheAutoRedirectAudit on its first run against main, the guard working as intended. Note it is an embeddable iframe bridge, not a destination app; auto-redirecting an iframe’s login into a top-level IdP flow is a different question from the one this proposal answers, and needs deciding before it is measured.
identity-brokeroidc0.1N/A: no login surface, by design. publicUrl is published EMPTY (identityBroker.socket.yaml) because the broker normally has no public route at all: it is an in-cluster sidecar mapping Keycloak sub to per-platform local ids. Its oidc edge is not a sign-on edge; it validates tokens minted elsewhere and, when seeding is enabled, exchanges a token the CALLER already holds. No browser ever lands on a login page it serves, so there is nothing to auto-redirect. Listed because the guard is right that silence and “examined, uninteresting” look identical.
mailbox-reconcileroidc1.0N/A: no login surface exists. It is a headless daemon: no ingress, no HTTP listener, no browser ever reaches it. Its oidc plug is not a sign-on edge at all; oidc.socket.yaml is simply the only socket carrying Keycloak’s adminUrl/adminUser/adminPassword, which the reconcile loop uses to enumerate realm users server-side. There is nothing to auto-redirect, and there never will be while it stays headless. Listed here because the guard is right that silence and “examined, uninteresting” look identical; this is the latter.
mailbox-reconciler-ffxoidc1.2N/A: no login surface exists. Same headless reconcile loop as mailbox-reconciler. The oidc plug is client_credentials with a 127.0.0.1 sentinel redirect. No browser ever reaches it.
drover-relayoidc1.1N/A: no login page to skip. The relay is a bearer-token API; the Drover app runs the PKCE sign-in against drover-public itself (phone, desktop shell, and the web export at the relay’s origin, which only starts one when the person picks it) and hands the relay the ID token on POST /v1/auth/oidc (FZ-8235). Nothing the relay serves is a login form a redirect could replace.
cisooidc3.20.8not yet audited on this package. The sibling ciso-assistant row above is the measured refusal (caddy 302 on a bare GET /login). This package ships that same sidecar. Not re-measured here.
ffxoidc15.118not yet audited on a live ffx site. The package declares the same frappe selector form: login_path is /login only, because the site root is the public website, and the Keycloak button’s href is minted per render.
minio-classicoidc2025.4.22not audited, expected to inherit minio’s verdict, unverified MEASURED 2026-08-11 and it does NOT inherit it; the inheritance guess was wrong in both directions. See the cannot-bucket, re-measured.
fizzyoidc0.1not audited. Landed 2026-09-26 (SHC-977) as the selfhostedcloud.org soft fork of basecamp/fizzy carrying upstream PR #2370’s OIDC login. Read in the fork, not measured on a deployment: the login page /session/new is server-rendered, and its one SSO entry /auth/oidc is the omniauth request phase, which the fork allows on GET and which mints state, nonce and a PKCE verifier server-side, so checks 1-3 look passable. Checks 4 and 5 are open: there is no RP-initiated logout, so a signed-out user who is bounced back to the IdP is signed straight in again. Measure before declaring.
multiplatformoidc0.1not audited. Landed 2026-08-13 (the generic multiplatform.one product deployment; caught by the guard on its first run, as designed). Auto-redirect is unlikely to ever be the right default here: the app fronts a product whose ROOT surface is commonly anonymous by design (storefronts, ordering) while staff sign in under /app (frappe) or through the product web app’s own /api/auth better-auth routes; a blanket 302-to-IdP would turn customers away at the door. Needs measuring per product before any declaration.

penpot stays excluded on the measurement already recorded here: GET /api/rpc/command/login-with-oidc → 405 (POST-only, failing check 2) and its login page is the SPA fragment /#/auth/login, which a Traefik PathRegexp structurally cannot see (failing check 1).

★ penpot stays excluded, but the endpoint named above is the wrong artefact, re-measured 2026-08-11 at penpotapp/*:2.17.0. The verdict is unchanged and the fragment half is exactly right; the check-2 evidence is not. See the cannot-bucket, re-measured.

Catalogue reality check (measured 2026-08-03)

Section titled “Catalogue reality check (measured 2026-08-03)”

Of the 16 apps with no native knob, exactly one is a clean yes (kutt), two are partial (journiv, GET, server-side state, but its own button uses the same URL; affine; see the correction below), and the rest fail check 2 or 3. (★ Both partials later became declarations: affine on 2026-08-09, journiv on 2026-08-10. The journiv row above is confirmed by measurement: its button target and the entry a 302 would use are the same URL, and that is a reason to declare, not a reason not to. See The no-knob row, re-measured below, which also records the six that stay refused.) So this mechanism is worth building for the pattern, not for the volume: it converts “impossible” into “declare two paths” for whichever apps qualify now and in future versions.

Correction to an earlier claim in this document’s audit. AFFiNE was recorded as structurally unreachable because its sign-in button POSTs to /api/oauth/preflight. That is wrong at the pinned 0.27.3, and the detail matters because it is the difference between “never possible” and “possible but not worth it”. The button does not call preflight; it builds a URL and navigates (location.href = baseUrl + '/oauth/login?provider=OIDC&flow=redirect'); /oauth/login is a declared route whose loader self-starts the flow, and the preflight POST is an internal step of that page. PKCE is minted server-side. So a 302 there is byte-identical to a human clicking the button; check 2 passes.

AFFiNE’s real blocker is check 1: the server registers one SPA shell for every path and the app reaches /sign-in via history.pushState, so a logged-out visitor produces exactly one server-visible request (GET /) and Traefik never sees the login path on the default entry. Redirecting / instead is not an escape; / is also the logged-in landing, and /oauth/login deliberately signs the user out first, so a / router would log active users out on every root visit.

Two further reasons it stays excluded even as partial: AFFiNE has no RP-initiated logout at all (end_session appears nowhere in the 0.27.3 bundle), so auto-redirect plus a live Keycloak cookie means sign-out is undone by the next hard reload; and because the post-logout hop to /sign-in is client-side, the router would fire only sometimes, inconsistent behaviour is worse to support than none. It is also the one app where the flags.allowGuestDemoWorkspace=false default already delivers most of the intended UX.

  • This is UX sugar, NOT enforcement. Access stays open; ShouldWarnUngated must not treat a redirect-decorated app as gated.

  • Not built into the shcinject Traefik plugin; enforcement lives there; a redirect is plain dynamic config the file provider owns.

  • Apps with no escape hatch (gitea, matrix, wazuh) get a loud warning in their app.yaml var description: flipping the flag with a broken Keycloak locks every human out, including admins. Since 2026-08-10 they also declare local_login.closed_by: and are excluded from the fleet-wide scoped key on the strength of that declaration, a redirect preference set estate-wide must not strand an estate’s admins. Same for journiv (oidcOnly) and vaultwarden (ssoOnly), whose switches are not redirect knobs at all.

  • Logout loops: enabling auto-redirect where the app lacks RP-initiated logout (affine and blockscout never call end_session) means “log out” silently re-enters. Where a companion knob exists (librechat’s OPENID_USE_END_SESSION_ENDPOINT) the template sets it together with the flag. tests/unit/catalog/sso_logout_declaration_test.go is the guard, and its ssoLogoutTradeAccepted map is the record of which apps take the trade knowingly.

    ★ windmill’s row in that map was a DEBT and is now a measurement (2026-08-10). It read “OWED, NOT ACCEPTED, windmill’s OIDC logout support at 1.776.0 has not been read”. It has been, at the tag, and there is nothing to wire: windmill-common/src/global_settings.rs declares the complete instance-settings key set and contains zero keys matching logout (the only login match is auto_login_provider); the OSS custom-SSO config object is auth/token/userinfo URL + scopes + extra params + req_body_auth, with no end-session field; and the logout route calls clearUser() then navigates to /user/login, with isValidLogoutRedirect confining any rd to the same origin. So the loop windmill’s app.yaml documents beside its sso_redirect: is real and unavoidable at this pin; ?sso=false is the escape.

★★ STALE AS WRITTEN: steps 1-3 ARE DONE, on a DIFFERENT SURFACE. Read Rollout sketch: MEASURED STATE 2026-08-10 immediately below before acting on any of the four items. The list survives unedited because what it asked for and what was built differ in exactly one respect, and that difference is the live defect.

  1. Wire Implementation A for the four cheapest env-only apps (paperless, librechat, defectdojo, gitlab) + bats assertions that the rendered env/config carries the knob only when the flag is on.

  2. nextcloud/immich/windmill/mailcow via their existing post-install job surfaces. DONE. All four arm from a var their app.yaml declares @boolean: keycloak.autoRedirect for the first three, ssoOnly for mailcow, whose knob is not a redirect, written by the oidc plug’s jobs.post_deployment (nextcloud’s occ, immich’s system-config PUT, mailcow’s custom_login POST) or, for windmill, by windmill-init plus a compose-side binary patch because the native setting is inert at 1.776.0. Every one of them ships OFF, and every one of them ACTIVELY disarms when the var goes back to false: these all persist in the app’s own store, so re-rendering without the knob does not undo it.

    ★ The flag is a vars. entry here, and that is not a drift from “one scoped key”. ssoAutoRedirect governs the INGRESS ROUTER: ce resolves it in modules/app/launcher.go and spends it in ingress_materialize.go, and it is reachable from nothing an app template or a plug job renders. Implementation A configures the APP, from the app’s own template inputs, which is what vars are for. The two mechanisms share a campaign, not a switch, and an app can carry both (windmill does).

    ★ @boolean is load-bearing on every one of those vars. --var x=false arrives as the STRING “false”, which jinja calls TRUE; ce retypes it only for a var the app declares @boolean (modules/app/var_types.go, whose own worked example is mailcow). Undeclared, the operator’s disarm arms the knob instead. TestEveryLockoutShapedVarIsDeclaredBoolean now pins the pairing catalogue-wide.

  3. matrix/wazuh/gitea last, each with the no-escape-hatch warning. DONE; see “Step 3, and the coverage hole it exposes” below.

  4. The ce pin bump that makes the fleet-wide key reach Implementation A. DONE 2026-08-11, pinned to v0.0.51-0.20260811020521-079659588c59, a descendant of ce 7112971. The marker above is yes and the guard measures it rather than trusting it.

  5. Implementation B (renderer change in ce) as its own change, first consumer being whichever catalog app actually needs it; none of the no-knob apps currently qualifies (they are SPA-shell or POST-only), so B may stay dormant until one does. That is a fine outcome: the catalog field costs nothing until declared.

Step 3, and the coverage hole it exposes (2026-08-10)

Section titled “Step 3, and the coverage hole it exposes (2026-08-10)”

Rollout step 3, the no-escape-hatch class, is wired in all three packages, each on its own vars.keycloak.autoRedirect, each shipping false, each declaring local_login.closed_by: [keycloak.autoRedirect] with gated_on_edge: true, each carrying the loud warning:

appwhat the var actually closeslogout companion
wazuhthe one line that makes openid the SOLE opensearch_security.auth.type (the basicauth+openid pair is the default)opensearch_security.openid.logout_url
matrixBOTH halves at once: element sso_redirect_options.immediate and MAS passwords.enabled: false; Synapse’s own password auth is already force-closed for MAS delegationlogout_redirect_url, armed by the INTEGRATION and deliberately not by this var
giteathe three-key conjunction ENABLE_PASSWORD_SIGNIN_FORM + ENABLE_OPENID_SIGNIN + ENABLE_PASSKEY_AUTHENTICATION, which leaves /user/login nothing to drawnone, recorded in ssoLogoutTradeAccepted

Every one renders under the two-term interlock vars.keycloak.autoRedirect and integrations.oidc is defined, so the var alone can never close a door with no IdP behind it.

gitea’s “NO ESCAPE HATCH AT 1.27.1”: re-measured, not inherited

Section titled “gitea’s “NO ESCAPE HATCH AT 1.27.1”: re-measured, not inherited”

Driven against the pinned docker.gitea.com/gitea:1.27.1 (digest sha256:34e3f6b7…) with exactly one enabled OAuth2 source and the three closure keys set. The inference holds, and the closure is stronger than the packages claimed:

GET /user/login 303 -> /user/oauth2/keycloak (armed)
GET /user/login/ 303 -> /user/oauth2/keycloak (armed)
GET /user/oauth2/keycloak 307 -> <issuer>/auth?client_id=…
GET /user/login 200, user_name + password inputs (default)

Author check 4 answered NO, eleven ways: ?sso=false, ?force_login_form, ?local=1, ?password=1, ?auto_sign_in=false, ?redirect_to=/, ?autoLaunch=0, ?no_sso=1, ?direct=1, ?loggedout=1 and the trailing-slash form all returned the same 303. And the door is shut in the HANDLER, not merely in the template: a hand-crafted POST /user/login carrying credentials (no form needed) answers 403, and 403 again with ?sso=false. There is no HTML-form trick either. The declaration is correct.

★ The coverage hole: ssoAutoRedirect cannot reach Implementation A

Section titled “★ The coverage hole: ssoAutoRedirect cannot reach Implementation A”

shc config set --deployment <d> ssoAutoRedirect true arms Implementations B and C only. In ce the key is read in exactly one place: scopedSSOAutoRedirect in modules/app/inject_traefik.go, called from SSORedirectForApp, which decides whether the edge renders a redirect router. The compose render context (renderCtx, modules/app/install_runner.go) carries vars, integrations, stack, environment, tenant, hosts, tls, the url/host/port/paths callables, shc and connections, and no config namespace at all. No app.yaml or compose.yaml can read the flag, so every native-knob app in the table at the top of this document is armed per-app with --var, and there is no single fleet-wide switch that covers both mechanisms.

Verdict for this class: they stay var-only, deliberately. Three reasons, in increasing order of how binding they are:

  1. The semantics would not match. The edge router re-reads the scoped key every reconcile sweep, so flipping it is LIVE. A compose template is rendered at install/update only. A config-fed native knob would appear to arm the app and change nothing until the next deploy.
  2. Disarming is the recovery path, and it must not be the slow half. Every warning in this class says “re-deploy with --var keycloak.autoRedirect=false”. An arming surface whose disarm needs a deploy anyway is strictly more dangerous than one that is honest about needing a deploy in both directions.
  3. ★ It would silently disable X200042NOLOGIN for exactly the three apps it exists for. ce’s post-restore usable-login check reads “the deployment’s own effective app/vars.yaml, the file the restore just replayed, PROVIDED the app says which var closes its door” (modules/app/login_path_postcheck.go). local_login.closed_by names a var. Move the arming to a scoped config key and the check looks up a var that is no longer the switch, finds it false, and reports every locked-out restore of gitea, matrix and wazuh as fine. That is the exact failure the declaration was built to end.

If a fleet-wide surface is wanted, the honest shape is a seed, not a read. Have the install/update path resolve ssoAutoRedirect through the cascade and use it as the DEFAULT for an arming var the package names (a sso_arming_var: field beside local_login:), leaving vars.yaml as the single source of truth the restore audit reads, and leaving an explicit --var an override rather than a competitor. That is a ce change and a posture decision; it is not taken here.

What is guarded, so this cannot rot quietly

Section titled “What is guarded, so this cannot rot quietly”
  • tests/unit/catalog/no_escape_hatch_warning_test.go: new. The warning itself: every app that DECLARES a lockout must state the consequence in the var description and name --var <key>=false, the same string X200042NOLOGIN hands back. journiv and vaultwarden are recorded as OWED rather than silently passing.
  • per-app bats, both legs: gitea (the three keys must sit in ONE guarded block, and the default install must still serve the credential form), wazuh (the sole-openid line must ride the interlock; the logout companion must exist), matrix (both halves on one var; logout_redirect_url must stay OUTSIDE the arming guard).

Rollout sketch: MEASURED STATE 2026-08-10, RE-MEASURED 2026-08-11

Section titled “Rollout sketch: MEASURED STATE 2026-08-10, RE-MEASURED 2026-08-11”

Steps 1, 2 and 3 above are built. Sixteen catalogue apps render their own native auto-login knob today. The question this section exists to answer is whether the key this document designed reaches any of them.

designed built
operator surface shc config set shc update <stack>
ssoAutoRedirect true --var keycloak.autoRedirect=true
resolution 5-level scoped cascade per-deployment var merge
reaches Impl A (intended) see below, HALF-WIRED
reaches Impl B/C YES YES

★★ THE SPLIT IS HALF CLOSED, AND THE HALF THAT IS MISSING IS THE HALF NOTHING REPORTS. This is worth reading slowly, because the document above already describes the fix as shipped and the catalogue already spells the gate.

  • The shc half LANDED. All sixteen packages now gate on vars.<knob> or sso_auto_redirect, and tests/unit/catalog/sso_unified_surface_test.go renders each of them four ways to prove the templates respond to the name.
  • The ce half LANDED, AND THIS TREE NOW SEES IT (2026-08-11). ce main publishes sso_auto_redirect into both render surfaces (install_runner.go renderCtx, plug_jobs.go tmplCtx, guarded by modules/app/sso_autoredirect_render_surface_test.go), landed as ce 7112971. That commit was newer than the pin this tree used to carry (v0.0.50-0.20260810224626-6a3dcc5d3596, ce 6a3dcc5), where the only occurrence of the string in the whole ce module was launcher.go:266, READING sso_auto_redirect: as an app.yaml field name, not as a context key. The pin has moved past it. TestCEPublishesTheUnified SurfaceName measures the ce this tree builds against and now agrees with the marker above, so shc config set ssoAutoRedirect true reaches all sixteen native-knob apps and --var is no longer the only surface.

    ★ “THE SPLIT IS CLOSED” IS NOT “THE ESTATES ARE ARMED”, and reading it that way repeats this section’s own defect in miniature. The publication is a RENDER INPUT: a stack picks it up on its NEXT install or update, not when the daemon carrying the new pin starts. So the fleet-wide key arms nothing that has not been re-rendered at this pin or later, and the evidence of that is, once again, nothing visible at all.

    ★ A CORRECTION, RECORDED RATHER THAN QUIETLY FIXED (2026-08-11). An earlier revision of this section said the ce half was “not merged into ce main” and named branch feat/sso-autoredirect-unified-surface (6f45262) as where it lived. That was measured by grepping the ce working tree on this box, which was checked out AT THE PIN, so the reading was true of the pin and asserted of main. 6f45262 is a stale duplicate of 7112971: identical on all four source files, but based far enough back that merging it would DELETE ten files ce main has since gained. Do not land that branch. The lesson is the cheap one: git grep <rev>, never a working tree, when the claim is about a branch.

The split is CLOSED. It is recorded rather than deleted because the failure shape is the transferable part: a {% if %} over a name the daemon never publishes drops its branch without collecting a miss, which is why, for the several days the pin lagged, the catalogue gate read as armed, the guard read as green, and the operator’s only evidence was that the login page did not change. The or spelling is what made that failure SAFE (the per-app var still worked, and the render stayed byte-identical to the pre-change output) and it is also what made it SILENT.

★ AND THE GUARD COULD NOT HAVE CAUGHT IT, which is the transferable lesson. sso_unified_surface_test.go builds its own context and sets ctx["sso_auto_redirect"] itself, so it proves the templates WOULD respond to a daemon that publishes the name, never that one does. It is the recorded #1 defect class wearing a differential render: a corpus floor and a mutation proof do not help when the input under test is supplied by the test. TestCEPublishesTheUnifiedSurfaceName was added 2026-08-11 to close exactly that. It reads the ce this tree BUILDS AGAINST (SHC_CE_DIR, else go list -m) and holds that measurement against the marker above, so it is GREEN at this pin (the marker says no and the pin is silent) and goes RED the moment the pin moves past ce 7112971, with the doc edits to make in the failure message.

Owed: one pin bump. DONE 2026-08-11. The pin moved to ce 4b8d471 (v0.0.51-0.20260811015134-4b8d471f7c22) with the launcher-redesign landing, the marker is flipped, and the catalogue gates are green at it. shc config set ssoAutoRedirect true is a working surface for Implementation A. It remains true, and is a separate statement, that the key deliberately does not arm the five lockout apps (gitea, matrix, wazuh, journiv, vaultwarden), which stay on an explicit per-app --var.

default.yaml describes the key as reaching native knobs. ★ That correction cannot land in this repo: shc’s root default.yaml is a generated MIRROR of ce’s core/config/default.yaml, byte-compared by tests/unit/core/config/TestDefaultYAMLMatchesRepoRoot against the copy the binary embeds AT THE PIN, and re-derived by make ce/sync-defaults when the pin moves. Editing the mirror alone reds that gate, verified, not assumed. ce 7112971 carries the core/config/default.yaml change too, so the mirror came right with the same pin bump that made the claim true, which is the better outcome than the earlier plan (ce branch fix/sso-auto-redirect-key-doc-claim, still unmerged and now pointless) of softening the documentation to match a surface that did not work. Re-synced 2026-08-11 by make ce/sync-defaults as part of that bump.

Where each renders, and the bypass for each

Section titled “Where each renders, and the bypass for each”

Twelve were tabulated in this pass. The corpus has since grown to sixteen: sso_unified_surface_test.go’s discoverKnobApps is the live count and this table is a snapshot, not the register.

appknobrendered inbypass
paperlessPAPERLESS_REDIRECT_LOGIN_TO_SSOcompose env/accounts/login/?loggedout=1
librechatOPENID_AUTO_REDIRECT (+OPENID_USE_END_SESSION_ENDPOINT)compose env/login?redirect=false
defectdojo-classicDD_SOCIAL_LOGIN_AUTO_REDIRECT + DD_SOCIAL_AUTH_SHOW_LOGIN_FORMcompose env/login?force_login_form
gitlabomniauth_auto_sign_in_with_providerGITLAB_OMNIBUS_CONFIG/users/sign_in?auto_sign_in=false
wordpressOIDC_LOGIN_TYPEWORDPRESS_CONFIG_EXTRA/wp-login.php?login-error=1 (JS-off only)
nextclouduser_oidc single-backendoidc.plug.yaml occ job<basePath>/login?direct=1
immichOIDC_AUTO_LAUNCHoidc.plug.yaml job env/auth/login?autoLaunch=0
windmillauto_login_provider + a frontend-bundle patchinit job and compose/user/login?sso=false
ciso-assistantcaddy 302 on a bare GET /logincompose sidecarany query string, e.g. /login?local=1
giteaoauth-only logincompose envNONE (local_login.closed_by)
wazuhauth.type: openid sole typecompose config heredocNONE (local_login.closed_by)
matrixMAS passwords.enabled: falsecompose configNONE (local_login.closed_by)

defectdojo (the name the rollout list uses) is not among them: the catalogue moved that package to 3.2.0, whose open-source build has no single sign-on at all (zero SOCIAL_AUTH settings in settings.dist.py, oidc.plug.yaml deleted, an -i oidc= edge REFUSED at render time). The knob lives on in defectdojo-classic at 2.58.4.

Re-measured at the pins (2026-08-10), not assumed

Section titled “Re-measured at the pins (2026-08-10), not assumed”

The five env/config-knob apps, against the versions the catalogue pins:

  • paperless-ngx 3.0.5: settings/__init__.py:355 maps the env to REDIRECT_LOGIN_TO_SSO; documents/templates/account/login.html:68 gates the auto-submit on REDIRECT_LOGIN_TO_SSO and forloop.counter0 == 0 and request.GET.loggedout != '1'; settings/custom.py:22-25 defaults LOGOUT_REDIRECT_URL to …/accounts/login/?loggedout=1. Check 5 passes on the app’s own default; logout lands ON the bypass.
  • LibreChat v0.8.7: api/server/routes/config.js:81 publishes openidAutoRedirect from OPENID_AUTO_REDIRECT; client/src/components/Auth/Login.tsx:25,63 honours ?redirect=false; LogoutController.js:54,64 reads OPENID_USE_END_SESSION_ENDPOINT and redirects to the issuer’s end_session_endpoint. Check 5 passes when the companion is set, and the package sets it on the INTEGRATION, not on the preference, which is stricter than this document asked for and correct: a user who signed in by clicking the button has the same un-loggable-out session.
  • DefectDojo 2.58.4: settings.dist.py:149-150,480-481; dojo/sso/views.py gates on not SHOW_LOGIN_FORM and SOCIAL_LOGIN_AUTO_REDIRECT and exactly one provider and "force_login_form" not in request.GET. ★ Check 5 FAILS, measured: dojo/user/views.py:139 logout_view() calls login_view(request) when SHOW_LOGIN_FORM is off, and that path has no force_login_form marker, so logout re-enters the flow. Knowing trade, same shape as gitlab and frappe; documented in the var description.
  • GitLab CE 18.11.7: omnibus gitlab.rb.template:624 carries omniauth_auto_sign_in_with_provider; gitlab-foss v18.11.7 sessions_controller.rb:34,316-324 runs it only: [:new] and returns early when params[:auto_sign_in] is falsy. Check 5 passes: the package sets after_sign_out_path = '/users/auth/openid_connect/logout' on the integration, which ends the Keycloak session.
  • daggerhart-openid-connect-generic 3.11.3 (the latest wordpress resolves; the plugin is deliberately unpinned), openid-connect-generic.php:427 prefers the OIDC_LOGIN_TYPE constant over the DB option and settings-page.php:238 disables the field when it is defined, confirming this document’s “overrides the DB option”; login-form.php:85-95 exempts action=logout/action=postpass and login-error, and :197 shows the login-error recovery strips the form in JavaScript, so it is walkable only with JS off. Check 5 passes: client-wrapper.php:379 sends an auto-mode logout to home_url() rather than back to the IdP.

What is owed: re-stated 2026-08-11, because two of these are DONE and one was decided the other way

Section titled “What is owed: re-stated 2026-08-11, because two of these are DONE and one was decided the other way”
  1. ce, on fix/sso-auto-redirect-key-doc-claim: the key’s own documentation stops claiming it reaches native knobs. SUPERSEDED, and deliberately not landed. That branch softened the DOCUMENTATION to match a surface that did not work. The wiring was built instead, so the claim becomes true rather than smaller, and ce 7112971 carries the core/config/default.yaml change in the same commit. Landing both would be landing a correction and its own reversal.
  2. ce: DONE, LANDED ON ce main AS 7112971. Expose the resolved ssoAutoRedirect in the render contexts, beside tls. In two places and not one: install_runner.go’s renderCtx for compose and hook jobs, and plug_jobs.go’s tmplCtx for consumer plug post_deployment jobs: nextcloud, immich and mailcow apply their knob from a plug job, so publishing to compose alone would have unified thirteen apps and left three answering only to --var. Note the ACTIVATION difference it creates: the ingress router re-resolves every sweep, an env var does not, so arming a native-knob app is a redeploy however it is spelled. ★ Do NOT land ce feat/sso-autoredirect-unified-surface (6f45262): it is a stale duplicate of 7112971, identical on the four source files but based far enough back that merging it deletes ten files ce main has since gained.
  3. shc: move the templates off vars.keycloak.autoRedirect to the resolved flag and delete the var (clean break, no dual surface). DECIDED THE OTHER WAY, 2026-08-10; see “The precedence rule” above. The two surfaces are ADDITIVE: every catalogue vars.yaml ships its knob false, so a var an operator set to false is byte-identical to one nobody touched, and “var overrides key” would hand the packaged default a permanent win over the operator’s fleet-wide intent. The gate is vars.<knob> or sso_auto_redirect in all sixteen packages, which is also what makes the catalogue safe to ship ahead of the ce pin.
  4. Update lockoutBypasses / local_login.closed_by in step with the rename. MOOT; there is no rename. The declarations stand as they are, and TestEveryLockoutShapedVarIsDeclaredBoolean pins them.
  5. ★ NEW. Bump the shc ce pin once (1) lands, then re-run tests/unit/catalog. TestCEPublishesTheUnifiedSurfaceName is RED until that happens and is the thing that says so out loud.

Guarded meanwhile by tests/unit/catalog/sso_auto_redirect_native_knob_test.go, which renders each of the five env/config-knob apps through ce’s own gonja and asserts the knob at three legs (unarmed, armed, and armed-with-no-IdP) plus the ratchet that a further app carrying the var cannot arrive unguarded; and by sso_unified_surface_test.go for the two-surface equivalence. Neither of those can see whether ce publishes the name, which is why (4) exists.


Implementation C: the CSS selector (SHIPPED 2026-08-07)

Section titled “Implementation C: the CSS selector (SHIPPED 2026-08-07)”

Status of this section: BUILT, in both repos, with one catalogue consumer. It closes rollout step 4’s open question (“B may stay dormant until an app needs it”) by answering it: frappe needed it, and it needed something B could not give.

The case a static path structurally cannot cover

Section titled “The case a static path structurally cannot cover”

Author check 3 above says sso_start must be a stable URL, and names frappe as the app that fails it. That failure is not a packaging accident, it is arithmetic:

frappe/www/login.html <a href="{{ provider.auth_url }}"
class="… btn-login-option btn-{{ provider.name }}">
frappe/utils/oauth.py get_oauth2_authorize_url()
→ create_oauth_state()
→ frappe.generate_hash(length=32)
→ cache.set_value(…, expires_in_sec=600)
consume_oauth_state() DELETES the key at the callback

The href is a full Keycloak authorize URL carrying a single-use, per-render state. It does not exist until the page renders, so no app.yaml value can express it, at any value, ever.

A third, optional field beside the two that already exist:

sso_redirect:
login_path: "{{ path('frappe-web') }}/login"
sso_selector: "a.btn-keycloak"

Static wins when present. A declaration carrying sso_start renders today’s pure redirect router: zero buffering, zero parsing, a 302 Traefik answers itself. The selector is reached only when there is no static URL to write. Declaring both is legal and means “prefer the static one”; a catalogue test flags it as dead weight.

The operator opt-in is unchanged: ssoAutoRedirect, off by default, at any scope. Two opt-ins stay two opt-ins.

ce renders the SAME narrow router, at priority 90000, with the app itself as the service:

Host(`h`) && PathRegexp(`<login pattern>`) && !Query(`<bypass>`,`false`)

and chains the SHC Traefik image’s response injector on it with an ssoSelector block instead of a redirectRegex (ce modules/app/sso_redirect.go → auth.SSOSelectorMiddleware; shc traefik/plugin/ssoselect.go). The plugin finds the element, reads its href, resolves it, and 302s there.

It is a second consumer of a buffer the plugin already knows how to take: not a parallel machine. The injector communicates its decision through a new RequestContext.Redirect field and never touches the body.

guaranteeenforced by
only the declared login path is ever parsedthe router rule (structural) and the injector re-checking loginPattern against the request URI (so a hand-written route file cannot widen it)
a miss serves the page byte-identicallythe injector returns its input slice unchanged, always; the middleware then ships the ORIGINAL bytes (the original compressed bytes on a gzip response) with the original headers
no infinite bouncefour independent guards: the !Query rule; the target path may not match loginPattern; the target may not equal this request; and every 302 sets a 90-second shc_ssosel cookie carrying a bounce count, capped at ssoSelectorMaxBounces (3) per window; see below
no open redirectsame-origin always; anything else must be on allowOrigins, which ce renders from the estate’s own system Keycloak origin and nothing else. Protocol-relative and non-http(s) hrefs are refused outright
bounded worktext/html + 2xx only (the middleware’s existing shouldBuffer), then a 1 MiB scan cap (3x the largest HTML the estate serves) over which the page is served untouched
gzip actually worksproved on a gzipped body, because the sibling feature shipped inert for exactly that reason

Every refusal logs a coded warning (SSOSEL-NOMATCH, -REFUSED, -LOOPCAP, -SELFLOOP, -TOOBIG, -NOHREF, -CONFIG), throttled to one line a minute. The codes deliberately sit outside ce’s X###### registry: the plugin is interpreted Go inside Traefik with no access to core/coded, and scripts/coded-registry-guard.sh does not scan traefik/, so an X-code minted there would be the “constructed but unregistered” defect the guard exists to catch, in the one place it cannot see.

Loop guard 4 counts; it does not blanket-suppress

Section titled “Loop guard 4 counts; it does not blanket-suppress”

It first shipped as “any request carrying shc_ssosel is never redirected again”, and that reading cannot tell two different events apart:

eventshapewants
a looplogin page → 302 → … → login page, over and over, machine-fast, unboundedto stop
a return triplogin page → 302 → IdP → app → the human uses the app → the human logs out → login pagethe redirect, again

Presence-suppression served the plain form for the whole 90-second window after either, so a human who signed in and signed out inside that window was handed the login form and a button to click, the exact thing this feature exists to remove. It was measured on the estate (docs/handoff/2026-08-10-ssoautoredirect-arming-audit.md §“the post-logout loop-guard window”: redirect at 21:22:19, logout at 21:22:49, the plain form until 21:23:49) and the owner ruled against it: “Logout should just be kind of dumb… when I go back to the login page, it should behave like auto redirect SSO.”

So the cookie’s value is a decimal bounce count, and the injector refuses only at ssoSelectorMaxBounces (3). A return trip is arrival number two and still gets its 302; a loop reaches the cap in a few hundred milliseconds and renders the form.

Three properties hold it together:

  • The cap is hard and never reset by elapsed time. Termination is therefore trivial to state: at most 3 redirects per browser per window, whatever the timing of the arrivals. A guard that reset its count on a slow arrival would let a loop with slow legs run forever, and an unreachable app is far worse than a login form with a button.
  • Every doubt reads as at-cap. A cookie value this build cannot parse (a future format, a hand-set value, anything ≤ 0) is still evidence a redirect went out, so it stops the bounce rather than arming another. Zero is reserved for “no cookie at all”.
  • Uncounted redirects fail closed. ssoSelectorSetCookie clamps a caller that passes no count to the cap, so a future injector that forgets to count makes the guard stricter, never inert.

No logout special case, deliberately. Nothing in the proxy knows what a logout is and nothing asks the app to say so; the owner’s framing is that logout should be dumb. A post-logout visit is just “a browser arrived at the login page and is not in a loop”, and it gets the ordinary answer. The window (ssoSelectorCookieMaxAge, 90 s) stays where it was: now that the cookie counts, the window is a memory length rather than a suppression length, and a longer memory makes the cap stricter while costing an ordinary visitor nothing.

The selector flavour’s 90 s and the redirectRegex flavour’s shc_ssoredir at 10 s were, for one release, different kinds of number: the static flavour’s guard was a Traefik router-rule clause (!HeaderRegexp(Cookie, shc_ssoredir=)) which cannot count, so its window had to double as its suppression and had to stay short. Ruling S11 (2026-08-14) ended the split: the static flavour’s 302 moved into the plugin (traefik/plugin/ssoredirect.go) and both flavours now count against the one shc_ssosel budget: cap 3, 90 s window, one budget per browser whichever flavour served it. The shc_ssoredir presence cookie is retired.

Deliberately tiny and stdlib-only (the plugin has zero dependencies by construction): type, *, #id, .class, [attr] with the six standard operators, compounds, and the descendant / child combinators. Pseudo-classes, sibling combinators and selector lists are refused at parse time; the feature goes inert rather than approximating. See traefik/plugin/cssselect.go.

Author check 5 (logout) fails for frappe. LoginManager.logout() clears the frappe session and never calls the IdP’s end_session, so with a live Keycloak SSO cookie a logout that returns the browser to /login signs the user straight back in. The escape is /login?sso=false. This is the same trade gitlab’s omniauth_auto_sign_in_with_provider makes, and the reason that knob ships with ?auto_sign_in=false. It is documented in apps/platform/frappe/app.yaml beside the declaration, and it is why the flag stays off by default.

Check 7: WHERE the login surface is, measured path by path (2026-08-10)

Section titled “Check 7: WHERE the login surface is, measured path by path (2026-08-10)”

Every check above asks something about the login page. None of them asked how many URLs the login page answers on, and that is the check the estate failed: hq.corp.bitspur.com had sso_redirect armed, correct, and anchored to /login, while the page an operator actually lands on is /.

hq.corp.bitspur.com, frappe/erpnext:v15.118.2, rule armed at ^/login$
GET / 200 <title>Login</title> a.btn-keycloak present
GET /index 200 byte-identical
GET /index.html 200 byte-identical
GET /login/ 200 byte-identical
GET /login 302 -> keycloak <-- the only match

frappe/website/path_resolver.py:resolve_path maps an empty path to index and index to get_home_page(); frappe/website/utils.py:get_home_page falls through Role → Portal Settings → hooks → Website Settings and ends home_page = "login" if frappe.session.user == "Guest" else "me". So with Website Settings.home_page unset, a Guest’s / is the login template, rendered in place, no redirect, no distinguishable URL.

There is no Frappe-side fix, and that was checked before the edge one was written. The Website Settings doctype’s full field list (read from the pinned image) contains home_page and route_redirects and nothing that routes anonymous users to /login. Website Route Redirect (the one native mechanism that could) is disqualified four ways: it is applied by resolve_redirect() before any session check, so it redirects authenticated users too; it defaults to 301, which browsers cache permanently; it is a row in the tenant’s own application database, invisible to shc config, not reconciled, and NOT undone when ssoAutoRedirect is set back to false; and it would have to be conditional per site (see below), which is not something a package-shipped job can honestly decide.

Whether / is a login page is runtime data in the site’s own database, not a property of the package. Same image, same app.yaml, three live sites:

siteWebsite Settings.home_pagewhat / serves
hq.corp.bitspur.com(unset)the login card, a.btn-keycloak present
erp.corp.bitspur.com(unset)the login card, a.btn-keycloak present
hq.flyingfoxlabs.inhomea 339 KiB public marketing page, no button

A static sso_start: router matching / would 302 every anonymous visitor of flyingfoxlabs.in into Keycloak and destroy the public website. The selector form asks the page that was rendered: button present → 302 to the href frappe minted; button absent → bytes returned untouched. An authenticated visitor is safe by the same mechanism; their / resolves to me (or their Role’s home page), which carries no a.btn-keycloak. The injector cannot see sessions and does not need to.

Cost, stated: / is now buffered and tag-walked on every GET that says it wants HTML: 354 KiB on hq/erp, 339 KiB on the flyingfoxlabs home. Under the 1 MiB parse cap, and paid only on an ARMED deployment.

Measured 2026-08-10 with a browser-shaped Accept against every routed host on both estates; ↳ = the app’s own server-side redirect.

appdeclared login_path/ servesverdict
frappe^…(/|/login/?|/index|/index[.]html)?$ (was …/login)login card (or a website page)FIXED, this section
kutt^…/login/?$ (was …/login)public shortenerFIXED, /login/ evaded the rule
affine / affine-rs(?i)^…/sign-?in/?$SPA shellok, /sign-in/ and /signIn both measured, both 302
windmill^…/user/login/?$ (was …/user/login)SPA shellFIXED, /user/login/ evaded the rule on BOTH estates
huly^…/login(:|/|$)SPA shellok, /login/ measured, 302. Re-measured 2026-08-22 post-rename (projects.corp.bitspur.com): still 302, all three spellings. exclude_query: [localLogin] added the same day; the app’s failureRedirect landing was being 302’d back into the IdP; see the huly correction block in §“No knob” above
superset^…/login/?$↳ /superset/welcome/ ↳ /login/?next=…★ ADDED 2026-08-17, not in this table when it was written, because it was not deployed yet. / funnels through two of its own 302s onto the declared path, so the rule catches the entry as well as a typed /login/. /login is a 308 to /login/, which is what the /? covers
gitlab(native knob)↳ /users/sign_inok, / funnels
nextcloud(native knob)↳ /loginok, / funnels
ciso-assistant(none)↳ /login?next=/ok, / funnels
wazuh(native knob)↳ /app/loginok, / funnels
mailcow(none, and none is coming)login form INLINE on /★ DECLARED 2026-08-18 on an owner ruling (check 5, an app-level logout that lands the user back inside the app is CORRECT). login_path: ^/?$, sso_start: /?iam_sso=1, exclude_query: [iam_sso, code, oauth, mobileconfig], the four §8.6 hops that answer on / and are not login navigations. force_sso still only hides the form; the EDGE is what redirects
sonarqube(REFUSED)SPA shell → /sessions/newleave alone, check 5 only, as of the 2026-08-11 re-examination (check 6 is answerable with exclude_query: [authorizationError]; check 5 is not answerable at all)
penpot(CLICK grade, 2026-08-22)SPA fragment /#/auth/loginunreachable by the EDGE, re-measured 2026-08-11, unchanged and permanent. The CLIENT payload reaches it with match_hash: true + sso_click_selector:
fleet(REFUSED)SPA shellleave alone, checks 1 and 5, and the per-user break-glass; see the subsection above
librechat(?i)^…/login/?$SPA shell★ ADDED 2026-08-17: this row was WRONG about librechat, and the error is instructive. “No server-visible login path” conflated the CLIENT route with the DOCUMENT request: a cold load, a bookmark or a typed /login is a real server round-trip (measured: 200, the 44 KB shell), which is check 1 passing, the same reading that admitted huly and windmill to this very table. What librechat lacked was a server-side redirect: its native knob (OPENID_AUTO_REDIRECT) bounces from inside the shell after /api/config loads, so the armed estate still painted the login card for a frame before navigating, the flash. Declared Implementation B (+ the launcherAuto client half): sso_start: /oauth/openid, measured a plain GET → 302 to the realm with server-held state. bypass_query: redirect, so the app’s own documented escape /login?redirect=false stops BOTH halves with one URL. Check 5 was already answered: OPENID_USE_END_SESSION_ENDPOINT rides outside the autoRedirect gate. Guarded by the librechat row of spa_shell_sso_redirect_test.go
dependency-track, matrix/element(none)SPA shellno server-visible login path, still true of these two: dependency-track’s login is an Angular route on a shell whose server half is the API, and Element’s login is homeserver-mediated. ★ 2026-08-22: the MAS host is a DIFFERENT surface from Element’s and now DECLARES the selector form (login_path: ^{{ path('mas') }}/$, sso_selector: a[href="/login"], measured at mas 1.22.0): its / is a server-rendered landing whose one anonymous control is a Sign-in anchor, and the selector form is what keeps the rule inert on Element’s /; ce renders the one declared pattern on every route of the deployment, so a static ^/$ would have 302’d the Element shell too (measured against the pinned ce). Element’s half of this row is unchanged
highlight(REFUSED)SPA shellcross-host as well, but the exclusion is moot: ruled replaced 2026-08-06

Not measured, because not deployed on either estate: blockscout, defectdojo-classic, gitea, glitchtip, identity-broker, journiv, mailbox-reconciler, matomo, mautic, midpoint, midpoint-classic, minio, minio-classic, monica, netbird, nextcloud-picker, openreplay, paperless, vaultwarden, wordpress.

★ ivatar was struck from that list on 2026-08-17, the same aging defect as the five names below: it is live on bitspur (avatar.corp.bitspur.com). Measured there: / serves the public Libravatar marketing homepage (200), /accounts/login/ serves the local form with the POST-only SSO button the package’s refusal documents, and /accounts/profile/ 302s a signed-out visitor to /accounts/login/?next=… server-side. The sso_redirect refusal is unchanged and unchangeable at this pin (@require_POST on social:begin); what changed is the LAUNCHER: the tile now lands on /accounts/profile/ via the app.yaml path: landing field, so selecting ivatar from the menu no longer drops the operator on the brochure. Landing is not an SSO mechanism and arms nothing, ivatar_landing_test.go keeps the two axes apart. None of them declares sso_redirect, so none can be anchored to the wrong path today, but “undeclared” is not “audited”, and the mailcow row is the warning: an app whose login form is inline on / looks identical, from the catalogue, to one whose login form is at /login.

★★ FIVE NAMES WERE STRUCK FROM THAT LIST ON 2026-08-17 (immich, peertube, postiz, supabase and superset) because they are all deployed on bitspur and have been for days. The list was written on 2026-08-10 and was accurate then; nothing re-derives it, so it aged into a claim that five live hosts had never been looked at and could not be. That is the same failure this document keeps catching in other forms: a completeness statement with no mechanism behind it. The re-sweep that corrects it is the next section, and it enumerates the routed hosts from the daemon rather than from this file.

★ Three of that list (minio, minio-classic and vaultwarden) are still not deployed on either estate but are no longer unmeasured: they were read off their pinned images on this box on 2026-08-11, which is enough to settle checks 1-3 and not enough to settle 4-5. See the cannot-bucket, re-measured.

The 2026-08-17 re-sweep: everything routed, diffed against the 08-10 table

Section titled “The 2026-08-17 re-sweep: everything routed, diffed against the 08-10 table”

★ WHY IT HAPPENED. The operator asked, of analytics.corp.bitspur.com, “why isn’t this auto sso login redirect?” and the answer was that superset was not in the 08-10 sweep at all, because it was deployed after the sweep ran. That is a general defect, not a superset one: the path table above is a snapshot with nothing that re-derives it, so every app deployed since is invisible to it AND invisible to the reader, who sees a table headed “every routed host” and stops looking.

So this pass starts from the daemon instead of from this file: shc ingress ls -o json on bitspur, deduplicated by host. 46 routed hosts, against a table that carried 15 rows.

The newcomers, measured signed-out (fresh browser profile, no cookies)

Section titled “The newcomers, measured signed-out (fresh browser profile, no cookies)”
hostappGET / lands onverdict
analytics.corp.bitspur.comsupersetown sign-in card, one Keycloak button★ FIXED, declares sso_redirect as of this change. See the superset row in Not yet audited above for the five checks and the RP-initiated logout.
photos.corp.bitspur.comimmichKeycloak, confirmed in a real browser, client_id=immich, no click★ ALREADY ZERO-CLICK, and nobody had checked. The native knob (oauth.autoLaunch) is armed by the fleet key, and the live system config reads "autoLaunch": true. A curl says 200 here and a curl is WRONG: the launch is client-side in the SvelteKit shell, so only a browser can see it. Recorded because “measured 200, therefore no redirect” is exactly how an app gets a false refusal.
video.corp.bitspur.compeertubeKeycloak, GET /login 302s to the plugin’s auth route, which 302s to the realm★ THIS ROW WAS WRONG, AND THE ARTEFACT IT RESTED ON WAS A URL THE APP NEVER MOUNTED. Corrected 2026-08-21; the superseded claim is quoted here rather than deleted, because the way it was reached is the lesson. It read “NO SSO EXISTS TO REDIRECT INTO … the blockscout class (an inert plug)” on the strength of /plugins/auth/oidc/router/login -> 400. The plugin is installed and registered (the app’s own public GET /api/v1/config answers registeredExternalAuths: [{npmName: peertube-plugin-auth-openid-connect, version: 1.2.0, authName: openid-connect, authDisplayName: "Sign in with SHC"}]) and that 400 is a malformed probe, not a missing route: PeerTube mounts /plugins/:pluginName/router and /plugins/:pluginName/:pluginVersion/router, so the cited URL parsed auth as the plugin NAME and oidc as the VERSION. The response says so in as many words: "detail":"Incorrect request parameters: pluginVersion", "invalid-params":{"pluginVersion":{"value":"oidc"}}. This is penpot’s 405 again: a refusal resting on a misidentified endpoint reads, to the next author, exactly like a refusal with no evidence at all. Measured live signed-out, Accept: text/html: GET /login -> 302 /plugins/auth-openid-connect/1.2.0/auth/openid-connect -> 302 auth.corp.bitspur.com/realms/corp/… carrying a server-minted state and a PKCE code_challenge, client_id=peertube, response_mode=form_post, callback /plugins/auth-openid-connect/router/code-cb. Checks 1, 2 and 3 all pass. Owed work is NOT a plugin install job and NOT a declaration; see The peertube declaration that is live and is not in the catalogue below.
social.corp.bitspur.compostiz307 to /auth, its own Sign-Up card with a “Sign in with Keycloak” button beside an email/password formREFUSED, and the refusal was already recorded: check 2, twice: @Get('/oauth/:provider') returns the authorize URL in a response body, and generateLink() emits no state and no PKCE at all. Confirmed live, in a browser: the button is there and there is no server-side half for a 302 to inherit.
backend.corp.bitspur.comsupabase404N/A: NO LOGIN SURFACE ON THE ROUTED EDGE. The route points at Kong, not at Studio: / is 404 and every API path is 401 without an apikey. The oidc binding is GOTRUE_EXTERNAL_KEYCLOAK_*, an identity provider for the applications built on this Supabase, not an operator sign-on, the identity-broker/mailbox-reconciler class. Worth one note for whoever routes Studio later: GET /auth/v1/authorize?provider=keycloak is a plain GET that 302s to the realm with a server-minted state, so checks 2 and 3 already pass; only check 1 is missing a page.

What else the 46-host enumeration turned up

Section titled “What else the 46-host enumeration turned up”

Nothing that changes a verdict, and two things worth writing down:

  • The forward-auth axis holds everywhere it applies. Every access: gated host (agents, artifacts, errors, glitchtip, idm, openreplay, status, docs) 302s to Keycloak on GET / with no app involvement, which is the axis this whole document rests on and is now re-measured rather than assumed.
  • quality.corp.bitspur.com (sonarqube) renders an _ssoredir router. The proposal text above still reads “REFUSED / leave alone” from the 2026-08-11 re-examination. The catalogue has moved on and this section is not the place to re-litigate it, flagged so the next reader does not take the older paragraph as current.

The peertube declaration that is live and is not in the catalogue

Section titled “The peertube declaration that is live and is not in the catalogue”

★ THE DRIFT AXIS THIS DOCUMENT HAS NO ROW FOR, FOUND 2026-08-21 WHILE CORRECTING THE PEERTUBE ROW ABOVE. Chasing why video.corp.bitspur.com auto-redirects when the catalogue says it cannot, read-only on compose01:

/var/lib/shc/system/traefik/dynamic/ingress-corp_prod_peertube.yaml
corp_prod_peertube_0_ssoredir
rule: Host(`video.corp.bitspur.com`) && PathRegexp(`^/login/?$`)
&& Method(`GET`) && HeaderRegexp(`Accept`,`(?i)text/html`)
&& !Query(`sso`,`false`) && !QueryRegexp(`externalAuthError`,`.*`)
ssoRedirect: {enabled: true, bypassQuery: sso,
loginPattern: ^/login/?$,
target: /plugins/auth-openid-connect/1.2.0/auth/openid-connect}

That is an ordinary Implementation-B render, and ce did nothing exotic to produce it. It read a perfectly normal block out of the materialised package:

/var/lib/shc/deployments/corp/peertube/prod/app/app.yaml:141
sso_redirect:
login_path: "^{{ path('peertube') }}/login/?$"
sso_start: "{{ path('peertube') }}/plugins/auth-openid-connect/1.2.0/auth/openid-connect"
exclude_query:
- externalAuthError

★ THAT BLOCK HAS NEVER EXISTED IN SHC GIT, ON ANY REF. git log --all -S over apps/flagship/peertube/app.yaml for both auth-openid-connect/1.2.0/auth/openid-connect and externalAuthError returns nothing. It is not an unmerged lane and it is not ce synthesising a router from an undocumented surface; it is authored work that reached the estate without ever reaching the repository. The materialised app.yaml is 12,224 bytes against main’s 9,350, carries prose main does not have (an explicit “THE VERSION IN THAT PATH IS COUPLED TO pluginVersion BELOW … a pluginVersion bump MUST be mirrored here or the redirect 404s”), and every file in that directory shares one mtime (2026-08-20 21:31), so it was materialised as a set rather than hand-patched after install.

THE COVERAGE GAP, NAMED PRECISELY. Every ratchet this document has built reads the REPOSITORY: sso_redirect_audit_test.go, ssoRedirectRefusals, and TestTheGatedEstateClassIsAccountedFor all resolve through catalog.AppDir(t, name) into apps/<bucket>/<app>/app.yaml. The daemon renders from /var/lib/shc/deployments/<tenant>/<app>/<env>/app/app.yaml. Nothing reconciles the two. A deployment can therefore carry a declaration the catalogue has never seen, or, worse and undetectably, a different declaration under the same name, while every repo-side test stays green. This is the defect this whole document exists to close (“absent is indistinguishable from examined”), reproduced one layer down: the catalogue says peertube has no SSO to redirect into, and the estate has been redirecting since 2026-08-20.

The bypass is intact on the live rule, so this is not an outage. Measured: ?sso=false -> 200 (PeerTube’s own username/password form), while ?sso=true, ?sso=FALSE and ?foo=bar all still 302, value-exact and case-sensitive, which is Traefik !Query and not the app.

Owed work, and it is two separate things:

  1. Land the peertube declaration in the catalogue, from the materialised file as the source of truth, with the pluginVersion coupling carried into vars.yaml’s prose. Until then main’s package and the running deployment disagree and only the deployment is right.
  2. Decide whether catalogue↔estate reconciliation is owed a check at all. A shc-side diff of every materialised app.yaml against the catalogue package it claims to be would have surfaced this in one command; no such command exists.

The two gated declarations are not live yet

Section titled “The two gated declarations are not live yet”

Also measured 2026-08-21 on compose01: ingress-corp_prod_wazuh.yaml and ingress-corp_prod_openreplay.yaml contain zero _ssoredir routers. The ce support for gated routes landed the same day, and neither stack has been re-rendered since, so the two declarations the gated sweep below produced are currently inert on the live estate, correct in the catalogue, absent at the edge. A shc update on each is what makes them real; a browser is what should confirm it, because these two are exactly the apps where “measured 200, therefore no redirect” would mislead.

The 2026-08-21 GATED sweep: the class this document never looked at

Section titled “The 2026-08-21 GATED sweep: the class this document never looked at”

★ WHY IT HAPPENED, AND IT IS THE SAME SHAPE AS THE SUPERSET ONE. This whole document is about OPEN routes, and ce discards a declaration on a gated one outright:

// ce modules/app/inject_traefik.go
if !(access == "gated" && !rt.Ungated) { … render the sibling router … }

with the stated reason that “a gated route is auto-redirected by the gate itself”. That reasoning is about the first login. It says nothing about the second one, the app’s own login form, rendered after the gate has already been satisfied, and that is what a human actually meets. On bitspur seventeen stacks chain shc-oidc@file, and until now not one of them had been asked the question, because a gated app’s declaration renders nothing and therefore produces no symptom either way. The owner found it the way this is always found: one app at a time, in a browser.

The class is now enumerated from the daemon and pinned in tests/unit/catalog/gated_login_sso_redirect_test.go (gatedEstateClass), together with an assertion that a declaration really is inert on a gated route, so when the sibling ce lane changes that predicate, it goes red on purpose.

★ THE HEADLINE FINDING: “no declaration” here mostly means “already solved”

Section titled “★ THE HEADLINE FINDING: “no declaration” here mostly means “already solved””

The premise was that most of the class would take the static form. Two did. Six refused, and only two of those six refused for a reason this document’s cannot-bucket predicts. Four already redirect themselves: the native knob exists, is wired, and on the live estate is armed. A future lane that reads the absent blocks as unfinished work will re-measure six apps to reach the same six answers.

apphostverdictwhy
wazuhsiem★ DECLAREDlogin_path: ^…/app/login/?$, sso_start: …/auth/openid/login. The entry is a plain GET that mints state itself and 302s; it doubles as the callback, so keeping it outside the pattern is load-bearing. No exclude_query needed; a failed SSO login never lands on /app/login (2.19.5.0 has no error query on that page at all), which is precisely what sonarqube needed one for. ★ The edge supplies the posture the app cannot: auth.type: "openid" deletes the password form (local_login.closed_by), the edge rule keeps it and ?sso=false is the door. /app/login is in the plugin’s ROUTES_TO_IGNORE, so it is never auth-intercepted and the bypass always reaches a real page.
openreplayopenreplay★ DECLAREDSee its row in Not yet audited above.
immichphotosREFUSEDcheck 2: POST /api/oauth/authorize returns the authorize URL as a body. GET → 404 while GET /api/oauth/mobile-redirect → 307, so the namespace is mounted and the method is declined. Already zero-click via oauth.autoLaunch.
paperlessdocsREFUSEDcheck 2: SOCIALACCOUNT_LOGIN_ON_GET is unset at 3.0.5 and allauth 65.16.1 defaults it False, so GET /accounts/oidc/keycloak/login/ renders a 200 interstitial needing JS + a CSRF POST. The ivatar @require_POST class, reached by a different route. paperless ships its own override of that interstitial whose only job is to auto-submit the POST, the package telling you the GET does not redirect. PAPERLESS_REDIRECT_LOGIN_TO_SSO is armed live.
ciso-assistantgrcREFUSEDSee its row above.
midpointidmREFUSEDSee its row above.
pulpartifactsREFUSEDcheck 2, in its purest form: the entry does not exist. pulp never speaks OIDC: with ui.sso its nginx runs an auth_request against forward-auth and pulpcore accepts the verdict through PulpRemoteUserAuthentication + Django’s RemoteUserBackend. The only 302 to Keycloak on that host is shc-oidc@file. It carries no oidc.plug.yaml, so the plug sweep never enumerated it and nothing else would ever have named it.
uptime-kumastatusREFUSEDcheck 2 fails before check 1 is asked: no SSO at any price, in either auth.disable posture. The blockscout/monica class.
penpotdesignEDGE REFUSED; form 3 DECLARED 2026-08-22next section.
dtrack, fleet, glitchtip, postizn/aREFUSED (unchanged)already recorded above; re-confirmed as class members.
nextcloud-pickernextcloud_pickerowned elsewheregated by ACCIDENT; it declares no access: and ce’s disposition default is gated. What it needs is access: open, not a redirect.

penpot and the third form: asked for by name, refused twice, then built

Section titled “penpot and the third form: asked for by name, refused twice, then built”

The owner hit design.corp.bitspur.com/#/auth/login and asked: “Can traefik see the hash /auth/login? If not, I guess this particular app needs that front end JS injection.” The premise is exactly right, and it is why forms 1 and 2 are impossible here rather than merely awkward: a URL fragment is never transmitted. For that URL Traefik receives GET / and nothing more.

Form 3 refuses too, and only one of the two reasons is a small fix:

  • The payload cannot see a fragment route. traefik/plugin/auto.go’s fire() derives p from location.pathname (plus the decoded copy the huly %3A defect added) and decides with RE.test(p)||RE.test(pd). The fragment IS read, into q = search + hash, but q reaches only the sticky ?sso=false bypass and the deny() error test, never the pattern. It does listen for hashchange, so the hook exists; the decision function has not been taught. Pinned from that side by TestAutoPayloadCannotSeeAFragmentRoute.
  • ★ And the only anchor available today is harmful. With the fragment invisible, penpot’s login route and its DASHBOARD share a pathname: /. ^/$ would 302 a signed-in user into a pointless IdP round trip on every load. Generalised into a lint (TestRootAnchoredDeclarationsAreDeliberate) which allows root-anchoring only where something other than the path separates the cases (mailcow’s query carve-out; frappe’s selector form).
  • And the entry would still be unusable. Form 3 navigates with l.replace(SS), a GET to a same-origin path. penpot’s entry is POST-only: GET /api/auth/oidc → 405, measured live 2026-08-21 anonymously through penpot’s own ungated /api/ prefix, which upgrades the jar reading above to a live measurement.

So penpot can be served by none of the three forms today. Closing it needs a plugin change and the upstream :get already named in its reopen clause, in that order; (a) alone buys nothing here.

★★ penpot (2026-08-22): DECLARED, on the CLICK grade, and the sequencing above was wrong in one place. Everything before this block stays true of forms 1 and 2, permanently: a fragment is never transmitted, so no login_path regexp can exist at any value. What moved is form 3, and both of its legs were answered rather than waited for.

  • Leg A: the payload could not see a fragment route. Answered by LauncherAutoConfig.MatchHash (match_hash: true in the declaration). The payload’s route string becomes location.pathname + location.hash, and because every client-side decision is taken on that one string, the login pattern, the deny() predicates and the PV/LO logout-transition latch all move together. It is opt-in and off by default, and the unarmed payload is byte-identical to the one that shipped before, which matters because the plugin claims a CSP hash over those exact bytes, so a default-on change would have re-hashed every armed route on the estate. Pinned by TestAutoMatchHashMovesExactlyOneLine and TestAutoIsPathnameOnlyUntilHashModeIsArmed; TestAutoPayloadCannotSee AFragmentRoute is what those two replaced, exactly as its own comment said it should be.
  • Leg B: “(a) alone buys nothing here” was true of the NAVIGATE grade and only of it. It rested on l.replace(SS) being a GET while penpot’s entry is a POST. The CLICK grade navigates nowhere: it waits for penpot’s own SSO control and presses it, and the page then issues POST /api/auth/oidc with penpot’s own 4h state. That grade did not exist when leg B was written, so the upstream :get is still owed to forms 1 and 2 and is no longer owed to this app’s auto-redirect.
  • The selector is the CSS-modules MANGLED class, a.main_ui_auth_login__btn-oidc-auth, extracted from penpotapp/frontend:2.17.0’s shipped bundle 2026-08-22. .btn-oidc-auth as authored in login.cljs never appears in the emitted JS or CSS, so the obvious selector would have been silently inert. The mangling carries no content hash (checked across all 5214 mangled classes in css/main.css), so it is stable at a pin and a re-pin re-measures it. The control is an <a> with no href, which is leg 4 of the package’s own refusal read from the other side: sso_selector: has nothing to read, .click() reaches the :on-click.
  • No exclude_query:, measured. penpot’s OIDC failure lands at #/auth/login?error=<code> (app/main/ui/auth.cljs reads (:error (:query-params route))), and the payload’s built-in deny tests
    /?&#=/
    against search + hash, so the fragment-borne ?error= already matches. This is the check sonarqube failed with authorizationError; penpot passes it on the built-in.
  • Check 5 is what the hash mode really buys. penpot’s logout is a client route from #/dashboard/… to #/auth/login with the pathname stuck at / on both sides, so a pathname-keyed PV/LO latch would have recorded / all session and declined every transition: a logout latch that never fires. Keyed on pathname + hash it classifies correctly, and the cold logged-out arrival still does not latch. Driven under node: TestAutoClickDoesNotFireAfterAHashLogout, TestAutoClickFollowsAHashchange.
  • Not measured: no armed end-to-end browser drive on a live estate. The button’s 1.6-5.1 s appearance race is inside the payload’s 12 s wait, and the first-interaction abort (measured on penpot) is what stops it hijacking a page someone is already typing into.

Ledgered in tests/unit/catalog/sso_click_selector_test.go; the ce key is match_hash:, which reaches the launcherAuto block and nothing else and is omitted entirely when false.

★ A trap worth naming: measured through the edge, GET /auth/login on penpot answers 302 to Keycloak, which looks like a real server path. It is the gate; / and /assets/ answer identically. A gated stack’s own routing is unobservable from outside, so the fragment finding rests on the shipped artefacts (setUseFragment(true), (assoc cf/public-uri :fragment path)) and not on a curl.

★ The fragment class has exactly one member. Swept 2026-08-21: penpot. That is why match_hash ships off by default and has exactly one caller. huly looks similar and is not: /login:component:LoginApp is a pathname route, which is why the percent-decoding fix was enough for it. dependency-track, fleet, glitchtip, openreplay and librechat all client-route their logins on real pathnames.

The sibling ce lane LANDED on 2026-08-21 (ce lane/sso-redirect-on-gated-routes, carried into shc by the same-day ce pin bump), so every declaration in this section is now LIVE, including the two new ones and the three that predate this sweep (frappe ×2 stacks, windmill). Until then their inertness was the sweep’s premise rather than a caveat on it, and it was asserted rather than described. The assertion survived the change by inverting: TestGatedDeclarationsAreInertOnAGatedRoute is now TestGatedDeclarationsAreLiveOnAGatedRoute, which additionally pins that the rendered router carries the app’s own declared SSO entry. Its comment carries the flip and the re-reading of the six refusals it required.

The no-knob row, re-measured app by app (2026-08-10)

Section titled “The no-knob row, re-measured app by app (2026-08-10)”

The correction above says “NO KNOB IS NOT CANNOT”. kutt, affine and affine-rs had already been recovered from that row. This is what re-measuring the rest of it produced: one more qualifying app and six refusals, each against the image pinned in the package’s own vars.yaml, each recorded in the package rather than only here.

None of these apps is deployed on either estate except highlight, so every measurement below names its probe. Nothing is armed: every declaration keeps ssoAutoRedirect defaulting to false.

appverdictthe check, and how it was measured
journiv★ DECLAREDsee below
matomoREFUSEDchecks 1 and 2. LoginOIDC is absent from the image (/usr/src/matomo/plugins holds Login and nothing else) and this package installs nothing, so there is no SSO entry at all. And Matomo routes entirely on the query string: the login page is /index.php?module=Login&action=login, the plugin’s entry is /index.php?module=LoginOIDC&action=signin, and every other page is that same path. login_path is a PathRegexp that never sees a query, so the narrowest rule expressible is ^/index.php$, which matches the whole product.
monicaREFUSEDcheck 2: 4.1.2 has no SSO of any shape: zero oidc/keycloak/openid routes across routes/web.php, routes/api.php, routes/oauth.php and config/auth.php (routes/oauth.php is Passport, monica as an OAuth server). Read out of monica:4.1.2-apache. ★ And a trap for whoever packages v5: monica’s login form is inline on / (Route::get('/', 'Auth\LoginController@showLoginOrRegister')), not at /login, the mailcow row of the check-7 table, in advance.
postizREFUSEDcheck 2, twice. auth.controller.ts declares @Get('/oauth/:provider') with no @Res and simply returns the authorize URL, a response body the SPA navigates itself, the penpot/minio class. And oauth.provider.ts’s generateLink() emits client_id, scope, response_type, redirect_uri and no state, no PKCE at all, so there is no server-side half for a 302 to inherit. (Worth flagging on its own axis: a stateless authorize request is a CSRF surface, and it is upstream’s, not this package’s.)
highlightREFUSEDcheck 1 and a class this document did not have. Check 1: the frontend nginx serves /index.html for every extension-less route, matching the estate row in the table above. ★ The binding one: the sign-in navigation is window.location.href = ${PRIVATE_GRAPH_URI}/oauth/login, and PRIVATE_GRAPH_URI is the backend host, a different host from the login page. ce strips any origin off sso_start and re-attaches each route’s own host (deliberately, so a multi-host deployment never bounces a visitor cross-origin mid-login), so a declaration here renders a redirect to https://<FRONTEND-host>/oauth/login, which that nginx answers with the SPA shell: 200, no IdP, no error, forever.
ivatarREFUSEDcheck 2: social-auth-app-django 6.0.0 (in the pinned image) decorates social:begin with @require_POST, so GET /auth/login/oidc/ answers 405, and the static form can only ever send a GET. The selector form does not rescue it either: ivatar’s SSO control is a <button form="oidc-login"> driving a sibling POST form, so there is no href to read. Already recorded at the package’s own login.html.
blockscoutREFUSEDcheck 2: ACCOUNT_KEYCLOAK_* appears nowhere in the 9.0.2 release and the only ueberauth strategy in /app/lib is ueberauth_auth0-2.1.0. This is the inert-plug bug already tracked above, stated as a redirect verdict.

★ A THIRD STRUCTURAL CLASS: the cross-host SSO entry

Section titled “★ A THIRD STRUCTURAL CLASS: the cross-host SSO entry”

The design section names two classes that get no router: the SPA shell and POST-only initiation. highlight is a third, and it is worse than both because it fails silently in the armed direction: a declaration renders, a router appears, and it redirects to a path on the wrong host that answers 200. The other two classes produce a visible nothing; this one produces a confident wrong thing.

It is not an authoring slip and cannot be fixed by a better sso_start:; resolvePath reduces the value to a PATH by design, and the replacement re-attaches the route’s own host by design, because the alternative (an author-supplied origin) is a cross-origin bounce mid-login. An app whose login page and OIDC entry live on different hosts is outside this mechanism at any declaration. Add it to the checklist before check 1: are the login page and the SSO entry on the same host?

Pin swalabtech/journiv-app:0.1.0-beta.23, brought up locally against postgres 16 + valkey 9 and a stub issuer serving only a discovery document; probed with curl and driven in a real Chromium over CDP.

checkverdictevidence
1. login_path server-visiblepartial, the affine/huly/windmill classevery path returns the same 8319-byte Flutter shell (main.py:serve_spa catch-all). In the browser a logged-out visitor at the bare host produced exactly one server-visible document request, GET /, then reached /login by pushState. The router covers a typed URL, bookmark or hard reload; the launcher: auto payload covers the client route.
2. plain GET, state minted server-sidepassGET /api/v1/auth/oidc/login → 302 to the realm’s authorization endpoint with state, nonce, code_challenge + S256. endpoints/oidc.py mints uuid4 state/nonce and build_pkce() and stores the pair in valkey under oidc:<state> for 180 s. ★ Clicking the app’s own “Sign in with OIDC” control produced the same two hops, so a 302 there is what a human click already is.
3. stable URLpassfixed path; the per-request state rides the 302’s Location.
4. bypass reaches the local formpass, conditional/login?sso=false renders Email + Password + “Sign In” beside the OIDC control, and journiv keeps the query in the address bar, so the payload’s per-tab latch stays set. ★ Conditional on vars.oidcOnly being false; with it true there is no local form at all, which is the lockout already declared in the package’s local_login.closed_by.
5. logout does not land on login_pathfails as-is; carved outGET /api/v1/auth/oidc/logout → 307 to <origin>/login?logout=success, the login path, without sso=false. The declaration therefore carries exclude_query: [logout], rendering !QueryRegexp(logout,.*).

Two residuals an operator inherits, both measured, neither hidden.

  • The logout hop is load-order dependent. oidc.py reads authlib’s cached server_metadata rather than awaiting a load, so on a worker that has not yet served a login the end_session endpoint is absent and the handler falls to its local-only branch: 307 to /login?logout=success with the Keycloak session still alive. After one login through that worker the identical request 307s to the issuer’s end-session endpoint. Measured both ways on one container; compose runs two uvicorn workers, so a browser can meet either.
  • exclude_query carves the rule, not the payload: resolveLauncherAuto returns (pattern, ssoStart, bypass) and nothing else. So on the cold-worker path a sign-out can be undone once, bounded by the payload’s own 60-second one-shot latch. This is the trade gitlab, frappe and huly take knowingly, in a narrower window, and it is the concrete reason arming waits on the anti-bounce latch reaching the estates.

oidc.plug.yaml registers only the callback, so Keycloak refuses …/login?logout=success as a post-logout redirect and stops on its own page. That is the safe direction: the session still ends and the browser never returns to the login path to be bounced. Registering it would be a separate, deliberate change.

The pattern is ^…/login/?$, exact, not (?i). /Login lands on /login in a browser, but so does /zzzznotaroute: the normalisation is the signed-out fallback, not case-insensitive routing, and widening on that evidence would be widening on nothing. /? is required because /login/ renders the same screen, the defect kutt and windmill both shipped.

Guarded by tests/unit/catalog/getable_sso_redirect_test.go, which pins the rendered router (match corpus, refusal corpus, both query terms, the per-route host, the path-routed prefix, the client half) and pins the six refusals above together with the token in each package that carries the evidence, because a refusal whose reasoning was deleted reads exactly like an app nobody examined.

The sso_redirect router chains auth.SSOSelectorMiddleware instead of the launcher middleware, and that block sets appsMenu.enabled: false and carries no rewrites, a byte-identity contract written when the router only ever matched a page the visitor was about to leave. Now that frappe’s router also matches /, an authenticated visitor’s home page loses the SHC apps launcher. The fix is in ce (chain the launcher middleware alongside, or fold its rewrite into the selector block); it is a missing button, not a broken login.

The cannot-bucket, re-measured: with an upstream outlook (2026-08-11)

Section titled “The cannot-bucket, re-measured: with an upstream outlook (2026-08-11)”

Every check in this document asks something about the app at the version we pin. None of them asked the question that decides whether an entry in the exclusion list is a fact or a snapshot: does a newer upstream release make it possible? “Structurally cannot” is a claim about mechanism, and mechanism is a property of a version. Without that question answered, an exclusion list and a stale exclusion list are the same document.

So the bucket was re-opened and re-measured; checks re-run against the pinned images on this box (bundles and binaries read directly, not inferred from upstream docs), then the upstream line walked forward to HEAD. Two of the entries below came back different from what the list said.

appartefact measuredfailing check(s)why the mechanism cannot reach itupstream outlook
penpotpenpotapp/{frontend,backend}:2.17.01 and 2login page is a URL fragment; OIDC entry is POST-only and answers 200 JSONPERMANENT for the EDGE. 2.17.0 is HEAD; both blockers unchanged on develop; POST-only since the first tagged release. Neither blocker stops the CLICK grade, which navigates nowhere, declared 2026-08-22
vaultwardenvaultwarden/server:1.37.1-alpine (Web-Vault 2026.6.4)1, 2, and a loophash-routed vault with no SPA fallback; browser mints the PKCE verifier and state; the callback lands on the same server-visible path as the login pagePERMANENT. 1.37.1 is HEAD, main has no pending SSO work, and the feature was refused upstream twice
minioghcr.io/georgmangold/console:v1.9.1 (sidecar)none proven, REOPENEDnothing structural blocks it: path-routed /login, a fixed /sso entry, and no browser-held secretALREADY FIXED, at the pin we run. Checks 4 and 5 unmeasured, so nothing is declared
minio-classicquay.io/minio/minio:RELEASE.2025-04-22T22-12-26Z.hotfix.c630804a12 and 3entry answers 200 JSON with an authorize URL minted per call, no 302, no stable URLPERMANENT, with nothing to upgrade to. Upstream archived; the next release deletes the console
highlightghcr.io/highlight/highlight-{backend,frontend}:docker-v0.5.61, plus cross-hostSPA shell, and the SSO entry is on a different host from the login pageMOOT, ruled replaced 2026-08-06 (GlitchTip for errors, OpenReplay for replay)

penpot: permanent, and the old evidence named the wrong artefact

Section titled “penpot: permanent, and the old evidence named the wrong artefact”

Both blockers hold, and the fragment one is fatal on its own. The shipped frontend’s app/main/router.cljs builds every route as (assoc cf/public-uri :fragment path) and reads it back from (.-hash globals/location); upstream’s browser_history.js constructs a Html5History and then calls setUseFragment(true), which is the switch that makes it hash-based despite the class name. Penpot’s own nginx closes the side door too: its template 301s any two-segment non-asset path to /404, so GET /auth/login is not merely unrouted.

★ The check-2 evidence in the older text was measured on something that is not penpot’s OIDC entry. The record said GET /api/rpc/command/login-with-oidc → 405. That 405 is real and it means nothing: app/rpc.clj raises :method-not-allowed for any GET/HEAD on /api/rpc/command/<name> whose name does not begin with get-, before the handler is looked up, so a command that does not exist answers 405 too, and login-with-oidc is not an RPC method at this pin. The real entry, from the shipped jar’s app/auth/oidc.clj:

["/api/auth/oidc" …
["" {:handler (partial auth-handler cfg) :allowed-methods #{:post}}]
["/callback" {:handler (partial callback-handler cfg) :allowed-methods #{:get}}]]

and auth-handler ends {::yres/status 200 ::yres/body {:redirect-uri uri}}.

The correction does not change the verdict, and that is precisely why it is worth writing down: a refusal is only as good as the artefact it names, and this one would have failed the first re-check by someone who trusted it. Two further doors are closed: a pre-baked static authorize URL is rejected, because auth-handler mints a signed 4h state with tokens/generate and the callback re-verifies it with tokens/verify; and the selector form is inert, because the SSO entry is a React on-click, not an <a href>.

Upstream: 2.17.0 (2026-07-22) is the newest release; the unreleased 2.17.1/2.18.0 RC changelogs carry no auth or routing work, and both blockers are unchanged on develop. The start endpoint has been POST-only in every tagged release since 0.1.0, so there is nothing to roll back to either. The feature request (upstream #1331, “configure an automatic redirect to the SSO log-in page”) has been open since 2021-11-09. What would have to change: allow :get on /api/auth/oidc and return a 302; the file already carries a redirect-response helper and already mints the state server-side, so it is a small change nobody has made.

vaultwarden: permanent, refused upstream, and the obvious declaration is the dangerous one

Section titled “vaultwarden: permanent, refused upstream, and the obvious declaration is the dangerous one”

The recorded reason (the browser mints the PKCE verifier) is correct and is now quoted rather than asserted: the shipped web vault stores ssoCodeVerifier and ssoState itself and builds the authorize URL with …&code_challenge=…&code_challenge_method=S256; upstream’s sso_client.rs forwards a parameter it literally names client_challenge to the IdP and never mints a pair of its own, and the token endpoint refuses without the browser’s verifier. SSO_PKCE only chooses what vaultwarden does with the browser’s pair; there is one pair and we do not hold it.

Two things are new, and both matter more than the confirmation.

Check 1 also fails, for penpot’s reason. The bundled vault boots with RouterModule.forRoot(routes,{useHash:!0,…}), measured in the shipped app/main.*.js and confirmed in upstream’s oss-routing.module.ts at both the pinned and the newest web-vault. Worse than penpot: the Rust server has no SPA fallback, so GET /login and GET /sso are 404 pages and GET / is the only server-visible entry that serves the vault at all.

★★ And / is also where the SSO callback lands, which turns the obvious declaration into an infinite loop. From the shipped connectors/sso.c4950d48540f84f41e7b.js:

location.href = o ? t+`/#${o}` : t+"/#/sso?code="+e+"&state="+n

The callback sends the browser to <base>/#/sso?code=…&state=…, which on the wire is a bare GET /, byte-identical to a first-time visitor, because the fragment is never transmitted. A router on / would overwrite the returning code/state and restart SSO forever, and the usual !Query(sso,false) carve-out cannot exclude it because the callback hop carries no query at all. This app’s only server-visible login path and its only server-visible callback landing path are the same path.

Upstream: 1.37.1 (2026-07-29) is the newest release, main carries no pending SSO work, and the newest web-vault still ships useHash: true. The feature was implemented in upstream PR #6949 and closed unmerged the same day; issue #6191 asking for it was closed and locked (“not possible without modifying the web-vault too much”). There is no SSO_FRONTEND and no SSO_AUTO_REDIRECT upstream at any tag; those exist only in third-party forks. SSO_ONLY remains what it was: it rejects the password grant and hides the credential fields (upstream even ships a generated stylesheet that does the hiding), and never redirects. That is partial, the mailcow class, not a redirect.

One fact recorded so it is not rediscovered as a new idea rather than as a known one: stock and unpatched, /#/sso?identifier=<anything> auto-submits, measured in the shipped bundle (identifier)return this.identifierFormControl.setValue(t.identifier), this.loggingIn=!0,void(yield this.submit())). That is a target for the client-side launcher payload, not for an edge 302, and it costs the 2FA “remember this device” flow, which upstream keys off the typed email. It is not endorsed here; it is written down so the next reader starts where this one finished.

minio: REOPENED, because the verdict was measured on an artefact this app no longer ships

Section titled “minio: REOPENED, because the verdict was measured on an artefact this app no longer ships”

This is the entry the whole exercise was worth running for.

The 2026-08-02 audit filed minio beside penpot (“returns JSON for the SPA to navigate itself”) and that was true of the server’s embedded console. That console is gone from this line (measured before the split: oauth_callback occurs 0 times in the current server bundle), and the console sidecar was packaged on 2026-08-06, four days after the audit. Nothing re-asked the question of the new artefact, so a verdict about a deleted component went on being read as a verdict about the app.

Measured at the pinned sidecar ghcr.io/georgmangold/console:v1.9.1:

  • Check 1 passes. The console is a react-router SPA on path routing (no fragment) and its file server answers the SPA shell for every unmatched path, so Traefik sees GET /login. On a 403 the SPA does a real document.location="/login" navigation. This is not the fragment class.
  • A fixed auto-redirect entry exists, added in fork release v1.9.0 (“New SSO URL /sso for auto redirect to OIDC Provider”) and present in this pin. Its component: if not logged in and loginStrategy === redirect, window.location.href = redirectRules[0].redirect. It is stable, check 3.
  • The browser holds nothing before the flow starts, which is what separates this from vaultwarden and dependency-track. The callback page reads code and state off window.location.search and POSTs them; the request body is exactly {state, code}. There is no PKCE and no nonce anywhere in the console codebase, and the state is a self-contained HMAC the server re-verifies statelessly.

So the outlook is not “fixable at a newer version”; it is “already fixed, at the version we run”. No bump, no fork-of-a-fork, no upstream ask.

Nothing is declared here anyway, and the reason is the standard this document exists to enforce. Two checks have not been run: check 4 (with an IdP configured the console reports loginStrategy: redirect; it is not established that /login still offers the access-key form; if it does not, this app joins the no-escape-hatch class and needs that class’s loud warning), and check 5 (the console’s logout POSTs /api/v1/logout, then navigates to /login and hard-reloads, a server-visible GET /login with no bypass query, i.e. exactly the hop that re-enters; CONSOLE_IDP_END_SESSION_ENDPOINT is set precisely so Keycloak’s session is ended first, but that has never been run). Beyond both, the console’s OIDC flow has never been live-verified against a Keycloak at all. A redirect into an unproven flow is a worse outcome than a button into one.

★ A trap for whoever finishes this: do not bake a static authorize URL into the router as a shortcut. It would appear to work, and the reason it works is a defect; on the standalone fork the state HMAC key is derived from an empty passphrase and an empty salt (the fork’s config builder never populates them, and our compose sets no CONSOLE_IDP_HMAC_* either), so the key is a public constant and a forged state is accepted. Route through /sso and let the server mint a fresh state per visit. The forgeable state is a login-CSRF weakness in its own right and is owed a separate fix, independent of this feature. The embedded console in minio-classic is not affected; it seeds the HMAC from the deployment id and the client id.

minio-classic: permanent, and there is no version to upgrade to

Section titled “minio-classic: permanent, and there is no version to upgrade to”

The sibling gets the opposite answer, from the same console project, and the difference is entirely the artefact. This release’s go.mod pins github.com/minio/console v1.7.6 and boots it in-process on :9001; the shipped binary agrees (loginStrategy, redirectRules, /api/v1/login/oauth2/auth, oauth_callback all present). v1.7.6 has no /sso route; that entry is a fork addition from v1.9.0, five months after this release was cut. Check 1 passes here too, but check 2 fails on response shape (GET /api/v1/login answers 200 JSON) and check 3 fails because the authorize URL is minted per call with a fresh random state. The selector form is inert; the button is client-rendered, so the served bytes carry no anchor.

Upstream: minio/minio is archived (“THIS REPOSITORY IS NO LONGER MAINTAINED”); minio/console and minio/object-browser are both deleted (404). Moving this app forward on its own line does not help, it makes it worse: the very next server release (RELEASE.2025-05-24T17-08-30Z) deletes the embedded console and the browser IDP login outright, which is the whole reason this sibling app exists. So this is a replacement decision, not an upgrade decision: the answer is to migrate consumers to minio + the fork sidecar, or to accept a click-through login here permanently. It reinforces the standing “MinIO is terminal” reading rather than arguing against it.

highlight: the exclusion is real and it is moot

Section titled “highlight: the exclusion is real and it is moot”

highlight is the cross-host instance: its SSO entry sits on the backend host while its login page is on the frontend host (compose.yaml builds both from hosts['highlight-backend'] and hosts['highlight-frontend']), and ce deliberately re-attaches each route’s own host to the target: ssoRedirectReplacement(rt.Host, ssoStart), guarded by the comment “the origin is THIS route’s host. A multi-host deployment therefore keeps every visitor on the host they arrived at.” Only the path of a declared entry survives into the router. So a cross-host pair is not expressible, by design, and that design is right: it is what stops a two-host deployment bouncing a visitor cross-origin mid-login.

No effort was spent looking for a newer highlight, and none should be. The owner ruled on 2026-08-06 that highlight is replaced (GlitchTip takes the errors league, OpenReplay takes replay) because highlight fails the maintained-upstream bar (LaunchDarkly acquired it; hosted sunset 2026-02-28). Its exclusion from this feature is therefore moot: the right action is replacement, not rescue. It stays named here only because an app that is absent from a completeness claim is indistinguishable from one nobody examined.

Whether dependency-track (sbom + sbom-api) is the second cross-host instance is a separate lane’s question and is not answered here. Its own refusal stands on a different and stronger footing (a browser-minted PKCE verifier) and is pinned by TestDependencyTrackStaysExcludedFromSSOAutoRedirect.

What this changes about how the bucket is read

Section titled “What this changes about how the bucket is read”
  1. “No knob” and “structurally cannot” were collapsed once before in this document; “cannot at the pin” and “cannot ever” is the same collapse one level down. Two of the five entries above were not what the list said: penpot’s stated evidence was the wrong endpoint, and minio’s verdict belonged to a component the app had already stopped shipping.
  2. Ask who holds the secret before filing anything as structural. A browser-held verifier (vaultwarden, dependency-track) is a fact about the protocol and does not improve with versions. A JSON response where a 302 was wanted is a fact about a handler, and an app can grow a fixed entry that routes around it without changing anything else, which is exactly what the minio console did.
  3. An exclusion must name the artefact it was measured on. Each package above now carries its refusal and the image tag, route, or bundle filename it was read from, guarded by tests/unit/catalog/sso_redirect_audit_test.go. The vaultwarden guard names the hashed connector bundle deliberately: a pin bump reds the test and forces the re-measurement, instead of letting a stale claim ride along under a new version.

Check 8: mailcow, measured end to end; REFUSED 2026-08-10, DECLARED 2026-08-18

Section titled “Check 8: mailcow, measured end to end; REFUSED 2026-08-10, DECLARED 2026-08-18”

★★ THE VERDICT AT THE FOOT OF THIS SECTION HAS BEEN OVERRULED. Read this before the measurement, because the measurement is still correct and the conclusion it reaches is not. §8.8 concluded “Can mailcow auto-redirect? No, by either implementation”, resting on check 5 (the post-logout hop is a bare GET /, indistinguishable from a cold visit, with no RP-initiated logout upstream to break the loop) and on the authenticated landing (§8.6).

The owner has ruled that outcome CORRECT: “logging out where it goes to the same place as the login page and then logs back in IS CORRECT. i don’t care about supporting logging out of apps. what you are supposed to do is add a logout button to the floating menu to logout of keycloak.” An app-level sign-out that lands the user back inside the app is the DESIRED behaviour; the only sign-out that matters is ending the Keycloak session, and that is a floating-menu control, not something any package can express. Check 5 is therefore TAKEN here (the windmill/sonarqube trade) not fixed and not excused.

What the ruling did NOT decide, and what actually had to be built: §8.6’s other rows and §8.7. The OIDC callback, mailcow’s own OAuth2 consent (/?oauth) and the mobileconfig flow all answer on / and are HAPPY-PATH breaks, not logout questions; they are answered by exclude_query: [iam_sso, code, oauth, mobileconfig]. §8.7’s self-match was the one thing that needed CODE: the plugin refused at construction any target whose path the login pattern matches, which turned the whole redirector nil (fail-open, so every rule-level probe would have reported the app armed while it served its login page forever). traefik/plugin/ssoredirect.go now RECOGNISES its own target instead of refusing the app.

mailcow declares in apps/flagship/mailcow/app.yaml, pinned by TestMailcowDeclaresTheRuledStaticForm. The authenticated-landing cost of §8.6 stands as a cost: a signed-in user’s bare-host visit spends one IdP round trip against a live Keycloak session before landing where they were going.

★ EVERYTHING BELOW THIS BANNER IS THE ORIGINAL MEASUREMENT AND IS KEPT VERBATIM. It is what the next pin bump has to re-check, and a document rewritten to agree with its own conclusion is a document that cannot be re-checked at all.

★ SUPERSEDED IN ONE RESPECT, AND ONLY ONE: read this first. This check was measured 2026-08-11 00:06 and concluded “nothing was ever wired, and nothing can be”. The first clause is now stale: 2e34dd60f (01:20, ~74 minutes later) wired mailcow’s force_sso behind the ssoOnly@boolean var: its own subject says it plainly, “force_sso wired, and it is still not a redirect”. The second clause STANDS, and is why this section is kept: mailcow has no auto-redirect at any pin. ssoOnly HIDES the credential form so only the SSO button remains; it emits no Location header anywhere. Everything below is the measurement behind that verdict.

The question that started this: “why is mail.corp.bitspur.com still not auto logging in like the rest of the stuff?” asked of a page showing an email/password form, a Single Sign-On button, a FIDO2/WebAuthn button, and at the foot “Log in as admin | Log in as domain admin”.

The short answer: because nothing was ever wired, and nothing can be. mailcow’s only native knob cannot 302, and the edge mechanism cannot be anchored to / without breaking logout.

Measured against mailcow-dockerized 2026-07a, the tag apps/email/mailcow/app.yaml’s version: tracks and compose.yaml’s mailcow-config-init clones, so the PHP read here is the PHP that runs, and against the live bitspur deployment.

8.1 Why the page looks like that: nothing is armed

Section titled “8.1 Why the page looks like that: nothing is armed”

grep -r over apps/email/mailcow/ returns zero hits for force_sso, custom_login, customize or CUSTOM_LOGIN. Rollout step 2 was never executed for mailcow. The live page confirms it: GET / renders name="login_user", name="pass_user", id="fido2-login", the /?iam_sso=1 button and both quicklinks, which is exactly the render for force_sso = 0.

8.2 force_sso narrows the page. It does not redirect.

Section titled “8.2 force_sso narrows the page. It does not redirect.”
storeda field of the Redis key CUSTOM_LOGIN, inc/functions.customize.inc.php:211-217
writtenPOST /api/v1/edit/custom_login (json_api.php:2038), admin role: an X-API-Key with rw gets mailcow_cc_role = 'admin' at inc/sessions.inc.php:62, so the package’s existing apiKey could set it
readexactly two lines: templates/user_index.twig:45 (the password <form>) and :74 (the FIDO2 button)
emitsno Location header anywhere in the tree

★ Two consequences the “SSO-only login page” phrasing hides: it also removes FIDO2 from /, and, because a custom_login write sends all four keys, it shares a write path with the hide_*_quicklink switches.

8.3 The three login contexts are three server paths, and only one is affected

Section titled “8.3 The three login contexts are three server paths, and only one is affected”
/ index.php -> user_index.twig force_sso APPLIES
/admin/ admin/index.php -> admin_index.twig force_sso IGNORED
/domainadmin/ domainadmin/index.php -> domainadmin_index.twig force_sso IGNORED

Live: /admin and /domainadmin 301 to their trailing-slash forms, both 200. admin_index.twig and domainadmin_index.twig never mention force_sso; they render their password form and their FIDO2 button unconditionally.

  • mailcow is NOT the gitea/wazuh no-bypass class. The bypass is https://<host>/admin/, password-capable with force_sso on. That is the URL that makes arming reversible during a Keycloak outage. ?sso=false on / is not it: with force_sso on, that page carries neither a credential form nor FIDO2.
  • The converse: iam_sso is handled only in inc/triggers.user.inc.php. triggers.admin.inc.php and triggers.domainadmin.inc.php carry no OIDC branch at all, so a Keycloak identity can never reach the admin or domain-admin role through the login page.

8.4 FIDO2 is a real third path, and it survives an IdP outage

Section titled “8.4 FIDO2 is a real third path, and it survives an IdP outage”

GET /api/v1/get/fido2-get-args needs no session (200 unauthenticated, measured live); templates/base.twig:488-525 does navigator.credentials.get and POSTs verify_fido2_login back to the page’s own URL; the POST is handled in all three trigger files. Zero Keycloak involvement; it is a WebAuthn assertion against mailcow’s own credential store. No other app in this fleet has a second local escape hatch. Worth recording, and worth not deleting with a force_sso write.

checkverdict
1. login path server-visibleyes, but it IS /. See 8.6
2. GET-able SSO start, state minted server-sidePASS. /?iam_sso=1 (user_index.twig:72) → triggers.user.inc.php:4-11 → identity_provider('get-redirect') (functions.inc.php:3073-3090) mints through league/oauth2-client and stores $_SESSION['oauth2state']
3. is that URL stablePASS, a literal in the template, no per-render nonce
4. does a bypass reach a local formPASS, but not on /, /admin/, per 8.3
5. does logout land on the login path★ FAIL, unmitigably. See below

Live proof of check 2, with nothing armed:

$ curl -sI 'https://mail.corp.bitspur.com/?iam_sso=1'
HTTP/2 302
location: https://auth.corp.bitspur.com/realms/corp/protocol/openid-connect/auth
?state=<fresh per call>&scope=profile%20email%20openid
&response_type=code&approval_prompt=auto
&redirect_uri=https%3A%2F%2Fmail.corp.bitspur.com&client_id=mailcow
set-cookie: MCSESSID=…; path=/; secure; HttpOnly; SameSite=Lax

Check 5, in full. templates/base.twig:145 is <form action="/" method="post" id="logout">, an explicit bare /, so no query string can ride the hop. inc/sessions.inc.php:97-128 destroys the local session and 302s a user role to /. And mailcow has no RP-initiated logout at any pin: end_session, getLogoutUrl and post_logout appear nowhere outside inc/lib/vendor/, and identity_provider() has no logout case. So the bare GET / that follows a logout is indistinguishable from a cold visit, and Keycloak’s live SSO cookie answers it without a prompt. This is the gitlab/frappe trade, except gitlab has ?auto_sign_in=false and frappe has ?sso=false on the URL the logout lands on, and mailcow’s logout lands on a URL that cannot carry one.

8.6 What else answers on /, and why the edge mechanism is disqualified

Section titled “8.6 What else answers on /, and why the edge mechanism is disqualified”

Every one of these is a real server-visible request whose path is /:

conditionsourcecarve-out available?
cold anonymous visitthe intended onenone
the OIDC callbackoidc.plug.yaml pins redirectUris to the bare origin, and the live authorize URL confirms redirect_uri=https://mail.corp.bitspur.com, so GET /?code=…&state=… has path /exclude_query: [code]
the logged-in landingindex.php:11-29 302s an authenticated visitor from / to /SOGo/so/, /user, /admin/dashboard or /domainadmin/mailbox★ none
the post-logout landingcheck 5★ none
mailcow’s own OAuth2 consentoauth/authorize.php:5-6 hands an unauthenticated client off to /?oauthexclude_query: [oauth]
the mobileconfig flow/?mobileconfigexclude_query
the password-login POSTuser_index.twig’s <form> has no actionce’s Method(GET)
the FIDO2 assertion POSTposts to window.location.hrefce’s Method(GET)

ce’s shipped Method(GET) && HeaderRegexp(Accept, text/html) matchers take the two POSTs out, and exclude_query: (present at shc’s ce pin 6a3dcc5) takes the callback and /?oauth out. Nothing takes the post-logout landing or the authenticated landing out; both are a bare GET / with a browser Accept and no distinguishing key.

The blast radius, quantified honestly. Everything else on a mailcow host lives on its own path and would never match an anchored ^/$ rule; /SOGo, /api/v1, /Microsoft-Server-ActiveSync, /autodiscover.php, /mail/config-v1.1.xml, /rspamd, /principals, /sogo-auth-verify, /reset-password, /admin/, /domainadmin/ (all probed live: 200/200/403/ 200/200/…). So the answer is not “a / rule breaks the whole host”. It breaks exactly two hops. Those two are logout and the authenticated home page, and that is enough. (Recorded so it is not re-litigated: the SOGo surface at /SOGo/ is a separate login, reached through mailcow’s own session via sogo-auth-verify, not through Keycloak, and per the prior session’s finding, its historical “email page” problem was asset 404s, never SSO.)

8.7 And the target would match its own rule

Section titled “8.7 And the target would match its own rule”

ce refuses to render only when login_path == sso_start as strings (modules/app/sso_redirect.go, ssoRedirectRouter). mailcow’s pair is / and /?iam_sso=1, which differ, but the rule is PathRegexp and never sees a query, so the redirect target matches the rule that produced it. The only thing between that and an unbounded bounce is the bounce cap, and ce’s own comment on the cap is the ruling: ”★ IT IS A CAP, NOT A CURE, and no app may be enabled on the strength of it.” (Since S11 the refusal was also STRUCTURAL: the plugin refused at construction any target whose path the login pattern matches (mailcow’s /?iam_sso=1 against a / pattern is exactly that shape) so the config never armed at all. ★ THAT IS NO LONGER TRUE, 2026-08-18. The refusal was too wide: it asked only about the PATH, and a target that carries a query of its own is one the redirector can RECOGNISE on the way back in. traefik/plugin/ssoredirect.go now passes its own target through instead of refusing to arm; the construction refusal is unchanged for a target with no query, which really is an instant loop.)

★ Worse than the usual cap argument, recorded against the 10 s presence cookie that guarded this flavour before S11: a user who spent more than 10 seconds at the Keycloak password/MFA screen returned to GET /?code=… with the cap expired, and the router discarded the authorization code. That was the normal case, not the edge case.

The selector form rescues nothing. The href it would read off the page is /?iam_sso=1, same path, same self-match, and it would additionally buffer and tag-walk / on every browser GET, including every authenticated landing.

8.8 Verdict (2026-08-10, OVERRULED 2026-08-18; see the banner at the head of Check 8)

Section titled “8.8 Verdict (2026-08-10, OVERRULED 2026-08-18; see the banner at the head of Check 8)”

Can mailcow auto-redirect? No, by either implementation.

  • Implementation A genuinely only narrows the page. force_sso is a two-line template guard and emits no Location. There is no value it can take that produces a 302.
  • Implementation B / C would have to be declared against /, and that is disqualifying, on check 5 (logout, with no query to carve out and no RP-initiated logout upstream to break the loop) and on the authenticated landing (8.6). Both are unmitigable at this pin.

Recorded as a measured refusal in apps/email/mailcow/app.yaml, pinned by TestMailcowDeclaresTheRuledStaticForm (the declared values, and BOTH halves of the exclusion by name) and TestMailcowSSORefusalKeepsItsMeasuredEvidence (the package still names force_sso, iam_sso, getLogoutUrl, sessions.inc.php, redirect_uri and the 2026-07a pin the measurement was taken on), both in tests/unit/catalog/mailcow_sso_only_test.go. ★ The two names this paragraph carried until 2026-08-18 (TestMailcowDoesNotDeclareSSORedirect and TestMailcowRefusalNamesWhatItWasMeasuredOn) never both existed; the second never did, and the first has been replaced.

What is left on the table, if the owner wants the click reduced anyway: force_sso = 1 turns / into a one-click SSO page, with /admin/ as the password bypass, at the cost of FIDO2 on /. That is a product decision, not an auto-redirect, and it is deliberately not wired here.

★ Proof trap, before promising anyone a curl. An anonymous curl -L https://mail.<domain>/ can never witness this either way: / is a 200 with the form inline, so there is no redirect chain to read. The only honest server-side probe of the SSO entry is curl -sI 'https://mail.<domain>/?iam_sso=1', which 302s to Keycloak today, with nothing armed, because that is the app’s own button.

8.8b Passing note: the two recorded mailcow leftovers do NOT touch this

Section titled “8.8b Passing note: the two recorded mailcow leftovers do NOT touch this”

Neither owed item interacts with the SSO surface, and neither was done here.

  • The socket-alias fix is a Docker-DNS collision: the engine attaches data.hostname as a network alias on dovecot-mailcow (imap.socket.yaml) and on postfix-mailcow (smtp.socket.yaml), so both A records answer the same name and a wrong-A connect refuses. In-fabric service naming, ports 587/993, nothing to do with the nginx-fronted web UI.
  • The imap → mailbox rename decision is a socket-stem naming question on the same capability socket.

The SSO surface is /, /admin/, /domainadmin/ and /api/v1 behind nginx; it shares no identifier, no port and no service with either.

The 2026-08-11 arming pass: nextcloud was proposed, measured, and REFUSED

Section titled “The 2026-08-11 arming pass: nextcloud was proposed, measured, and REFUSED”

A catalogue-wide sweep on 2026-08-11 produced exactly one proposed static sso_redirect: block, for nextcloud, and filed it as the only “can-arm-now” entry in the whole sweep. It was schema-checked against ce’s modules/app/sso_redirect.go and found well-formed: anchored, case-insensitive, no backticks, RE2-compiling at three base paths, same-host, correctly templated.

It is well-formed, and it is wrong. Nothing a schema check can reach would say so, because the defect is in the value of sso_start:

# PROPOSED: REJECTED
sso_redirect:
login_path: "(?i)^{{ path('nextcloud') }}/login/?$"
sso_start: "{{ path('nextcloud') }}/apps/sociallogin/custom_oidc/keycloak"
exclude_query: [direct]
  1. The target does not exist on a default install. sociallogin owns this app’s login only under keycloak.ssoSurface: adopt. The default is refuse (apps/nextcloud/vars.yaml), and under refuse, and under replace, the login belongs to user_oidc, with sociallogin absent. On a green-field deployment the rule 302s every logged-out visitor off a working login page onto a route Nextcloud does not serve, leaving ?direct=1 (which needs a local password no SSO-provisioned user has) as the only door.
  2. Both segments under /apps/sociallogin/ are per-deployment values. The provider TYPE is custom_oidc or custom_oauth2; the provider NAME is the uid anchor an operator may legitimately have chosen. oidc.plug.yaml says so where it builds Keycloak’s redirectUris, and wildcards that pattern for exactly this reason. There is no fixed URL to name, frappe’s check 3.
  3. Its own check-5 blocker lands where the block would work. The sweep also found sociallogin’s logoutUrl empty in production, so logout returns to a bare queryless /login that exclude_query cannot carve out, the sonarqube shape. But sociallogin is live only under adopt, the one posture in which that sso_start resolves. So the block is wrong in both postures for opposite reasons: refuse/replace 404s the target, adopt loops on logout. No deployment makes it correct.

★ And check 5 is already answered on the path that matters; the fact the sweep missed. nextcloud is an Implementation A app (keycloak.autoRedirect, this document’s own tables say so in three places), and the same if that sets allow_multiple_user_backends pins user_oidc single_logout as a mandatory companion, with the reason stated on the spot. user_oidc 8.10.1 additionally registers full back-channel logout via backchannelLogoutUrl. That is why nextcloud appears in neither ssoLogoutTradeAccepted nor the cannot-bucket.

Net result of the pass: zero sso_redirect: declarations landed. The refusal is recorded as prose in apps/nextcloud/app.yaml and pinned by TestNextcloudDeclaresNoStaticSSORedirect. The refusal is narrow and the block says so twice: it refuses the static edge form, not auto-redirect. nextcloud can and does auto-redirect through its native knob.

★ Live re-verification was NOT possible and the record should say so rather than imply a probe happened: the estate hosts complete a TLS handshake from the build box but return no HTTP response, so neither the login page nor the SSO entry could be fetched. The refusal above rests entirely on artefacts committed in this repository (vars.yaml, oidc.plug.yaml and the existing guards) which is sufficient for a refusal and would not have been sufficient to arm.

Named here so the sweep does not read silence as coverage. oidc.plug.yaml exists and binds, but the five author checks have not been run against a live deployment, and this app is a special case twice over.

The OIDC login is bitspur’s own fork patch, not an upstream feature; upstream community edition registers no SSO modules at all, so checks 2 and 3 (is the SSO entry a plain GET, is the URL stable) PASS by construction: /api/v1/authn/oidc/login is a literal route the patch defines.

And an auto-redirect is a weaker fit here than elsewhere. The login page keeps a working email/password form on purpose: it is how the FIRST admin is created on a fresh install, because the fork’s callback refuses to provision an identity when no platform exists yet (create_first_admin_via_form). Bouncing an anonymous visitor into Keycloak would hide the only path that bootstraps the instance.

Re-open when someone runs checks 1, 4 and 5 against a deployment.