Skip to content

feat(auth): first-party generic OIDC auth-provider plugin (SDK contract already supports it) #905

Closed

Description

@Tobechukwu-Njoku

Request

A first-party generic OIDC auth-provider plugin, alongside the existing first-party metadata, marker and watch-provider plugins.

Not a core feature — as far as I can tell the host and SDK already support this and only the plugin itself is missing.

What already exists

proto/silo/plugin/v1/auth_provider.proto in silo-plugin-sdk describes the flow explicitly:

// InitAuthorize starts an OAuth/OIDC authorization-code flow. The plugin
// returns the URL to redirect the user agent to, plus opaque provider_state
// (e.g., PKCE verifier) the host stores and round-trips on the callback.
rpc InitAuthorize(InitAuthorizeRequest) returns (InitAuthorizeResponse);

// ExchangeCode exchanges the authorization code for tokens, decodes the
// user identity, and returns the same shape as Authenticate.
rpc ExchangeCode(ExchangeCodeRequest) returns (AuthenticateResponse);

rpc RefreshSession(RefreshSessionRequest) returns (AuthenticateResponse);

AuthenticateResponse already carries external_subject, display_name, email and a claims struct. Manifests already accept "auth_modes": ["oauth2"] on a capability. On the host side, internal/auth/ has oauth_handler.go, oauth_state.go and oauth_store.go — whose comment names the "PKCE verifier, OIDC nonce" it round-trips — plus plugin_provider.go with CompleteOAuth, identity linking by external_subject, and autoProvisionUser.

So a plugin can own discovery, the authorization-code exchange, id_token verification against JWKS, and claim decoding, returning the identity in the existing shape. Nothing in the contract appears to be missing for that.

What does not exist is any auth plugin: the org ships first-party plugins for TMDB, TVDB, manga, audiobook, ebook, sportarr metadata, TheIntroDB markers, arr-autoscan and the Floppy watch provider, but none for authentication. #554 mentions an LDAP provider in production against Active Directory, so third-party auth plugins are clearly viable — there is just nothing an operator can install for OIDC.

Why generic rather than vendor-specific

A single generic OIDC provider covers Authentik, Keycloak, Zitadel, Pocket ID, Authelia, Auth0 and anything else that publishes .well-known/openid-configuration. Per-vendor plugins would multiply for no benefit, since the differences are configuration rather than protocol.

I would suggest Authentik as the reference deployment to validate against — it is very common in self-hosted setups and exercises the parts most likely to be got wrong (group claims, custom scopes, non-standard username claims). I run it and am happy to test builds and contribute the configuration documentation for it. That is a testing bias, not a request to special-case it.

Suggested configuration surface

Nothing exotic; the usual fields:

  • Issuer URL (discovery via .well-known/openid-configuration)
  • Client ID, client secret
  • Scopes, defaulting to openid profile email
  • Claim mapping for username, email, display name, groups
  • Optional: PKCE toggle, allowed-groups restriction

Dependency on #554

The one genuinely missing host capability is role assignment. A plugin can return group claims today, but the host owns Silo's user/admin roles and has no way to consume them. That is exactly what #554 asks for under "managed role claims", raised from the same practical angle by an LDAP deployment.

An OIDC plugin is useful without #554 — SSO login and auto-provisioning alone are worth having, with roles assigned in Silo afterwards. But the two together are what makes an external IdP actually authoritative, so #554 is the natural companion rather than a blocker.

What I can offer

I can test against Authentik, write the operator-facing configuration guide for it, and report back on the claim shapes it emits. Happy to take a first pass at the plugin itself if that would be useful and someone can confirm the intended shape — particularly whether discovery and id_token verification are expected to live wholly in the plugin, or whether any of it belongs in the host.

Activity

  1. added
    triaged
    and removed
    triaged
    on Sep 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions