- **Closed in this fork (11 phases, all reviewed):** JAR, CIBA poll mode, automatic key management, DPoP, JWT introspection responses, dynamic providers, BFF, templates, admin API, SAML 2.0 IdP (MVP, ASP.NET Core + OWIN).
- **Every phase not blocked on upstream is done.** Last test runs had 0 failures (§4.1).
- **Largest remaining gaps:** logout and sessions (back-channel logout, session management, SAML SLO) and dynamic client registration. No server-side `backchannel_logout`/`registration_endpoint` support exists in `src/`.
- **Upstream owns two of them:** back-channel logout (#2175) and DCR (#2404), so the fork waits.
## 2. Gap matrix
| Feature | Duende 8 | OpenIddict | Status / next step |
| DCR management (RFC 7592) | ❌ | ❌ | Included in P9 |
| Automatic key management | ✅ signing keys (90 d rotate / 14 d announce / 14 d retain) | 🟢 signing + encryption | Done (P10) |
| Dynamic external providers (OIDC/SAML) | ✅ | 🟢 OIDC via `IOpenIddictClientRegistrationProvider` (no store entity) | Done (P11.2); SAML SP side not planned |
| P6 JAR | `d5c9bff7` | Server: `EnableRequestObjectSupport()`, `RequireSignedRequestObjects()`, per-client `ft:jar`, discovery metadata. Client: `UseSignedRequestObjects`. | Parameters outside the object are ignored (RFC 9101). Objects are validated with the client JWKS. |
| P8 CIBA (server) | `bbd52cbf` | Backchannel endpoint and pass-through, `urn:openid:params:grant-type:ciba`, `OpenIddictServerService` (list / approve / reject), discovery metadata. | Requires `SetIssuer`, token storage and non-degraded mode. **Device flow now returns `interval` and enforces `slow_down`**; disable with `SetPollingInterval(null)`. |
| P8b CIBA (client) | `b67cf1f3` | `AllowClientInitiatedBackchannelAuthenticationFlow()`, `OpenIddictClientService.ChallengeUsingBackchannelAsync` / `AuthenticateWithBackchannelAsync`, discovery extraction. | Poll mode only. PAR requirement now enforced only for interactive flows. |
| P5 DPoP | `0dae3a9d``0a732595``dbc144f5``27de4821``19d36ea3` | Server: `EnableDPoPSupport()`, `RequireDPoP()`, `RequireDPoPNonces()`, per-client `ft:dpop`, `dpop_jkt`, discovery `dpop_signing_alg_values_supported`. Validation: `DPoP` scheme, optional `IDistributedCache` replay cache. Client: `EnableDPoPTokenBinding()`, `DPoPSigningCredentials`, `CreateDPoPProofAsync`. | Opt-in. `cnf.jkt` on access tokens and public-client refresh tokens; `token_type=DPoP`. Server replay check writes one token entry per proof (token storage only). Proof signature checked against a minimal JWK (`x5c`/`x5u` ignored); `alg` must match `kty`/`crv`. Client skips the PAR proof when mTLS binding can be negotiated. |
| P12 JWT introspection | `f1ff44d8``811b913a``a2c44c5a``9d913f9a``0152298e``f1a9a312` | Server: `EnableJsonWebTokenIntrospectionResponses()`, `application/token-introspection+jwt` in ASP.NET Core/OWIN, discovery `introspection_signing_alg_values_supported` / `introspection_encryption_*`. Client: `OpenIddictClientRegistration.RequireJsonWebTokenIntrospectionResponses`. Validation: `RequireJsonWebTokenIntrospectionResponses()`. | Opt-in. Errors, anonymous and public clients get JSON. Encrypted only if the application sets `intr_rsp:enc_alg` (`RSA-OAEP`; `intr_rsp:enc_enc` default `A128CBC-HS256`); missing RSA `enc` key or bad setting → exception (ID0552/ID0553). Client/validation trim the JWT body. |
| P11.2 dynamic providers | `ad43bd3a``5315d310``776c7ca1` | Client: `IOpenIddictClientRegistrationProvider`, `AddRegistrationProvider<T>()`, `SetDynamicRegistrationCacheLifetime()`; all registration lookups go through the providers. ASP.NET Core: decorated `IAuthenticationSchemeProvider`. OWIN: dynamic forwarded authentication types. | No persistence entity (custom providers). Dynamic registrations must use redirect URIs declared in options; cached by id (30 min default); cached copy replaced when issuer/provider name/client id change. |
| P11.3 BFF | `6e1aca1f``36a6a9b2` | New package `OpenIddict.Client.AspNetCore.Bff` (YARP 2.3.0): `UseBff()`, cookie auto-refresh, `MapOpenIddictBffEndpoints()` (login, logout, user, callbacks, back-channel logout), `UseOpenIddictBff()` antiforgery middleware, `AddOpenIddictBff*AccessTokenHandler()`, `AddOpenIddictBffTransforms()`, `IOpenIddictClientAspNetCoreBffSessionStore`. Client hosts store `backchannel_access_token_type`. | `UseBff()` enables redirection/post-logout passthrough and adds `/bff/callback/*` URIs. Refresh single-flight and replay caches are in-memory (per instance). Back-channel logout removes sessions only with a BFF-aware ticket store. Antiforgery enforced fail-closed by API endpoints and YARP transform; logout tokens without `exp` must have a recent `iat`. |
| P11.4 templates | `56cd9786``1cb254e1` | New template pack `templates/OpenIddict.Templates.csproj`: `openiddict-server-identity` (Identity UI + EF Core, MVC authorization/device/end session/userinfo), `openiddict-server-empty` (minimal APIs, pass-through), `openiddict-bff` (client + BFF + YARP). `templates/verify.sh`. | Default OpenIddict version checked at pack time. Empty server login is a development-only placeholder; `prompt=none` without login → `login_required`. Bootstrap CDN link pinned with SRI. |
| P11.5 admin API | `e4cc3771``6a0d72b7` | `Server.AspNetCore`: `MapOpenIddictAdminApi(policy, prefix)` — applications/scopes CRUD, authorizations (list/get/create/delete/revoke), tokens (list/get/delete/revoke), keys (list/get/revoke). | Policy required; JSON content type required for POST/PATCH; secrets, token payloads, key material and private JWK parameters never returned; authorization revoke cascades to tokens. No UI. |
| P11.6 SAML IdP | `b6ba3f30``814f25f8``3c25b4d4` | New packages `OpenIddict.Server.Saml` (net48 + net10.0): `UseSaml()`, `OpenIddictServerSamlService`, `IOpenIddictServerSamlServiceProviderStore`, `IOpenIddictServerSamlAssertionProvider`; `OpenIddict.Server.Saml.AspNetCore`: `UseAspNetCore()`, `MapOpenIddictSamlEndpoints()` (`/saml/metadata`, `/saml/sso`); `OpenIddict.Server.Saml.Owin`: `UseOwin()`, `app.UseOpenIddictSaml()`. | Signed AuthnRequests required by default; single root signature, RSA-SHA2 only, no DTD; ACS allow-list; challenge/callback with a data-protected state (full AuthnRequest, SP/ACS re-checked); OWIN requires `SetAuthenticationType()`; timezone-less `IssueInstant` read as UTC; no SLO/encryption/artifact binding. |
| P10 automatic key management | `4d19d539` | New **Key** entity (EF Core `OpenIddictKeys` table, EF6, MongoDB `openiddict.keys`), `IOpenIddictKeyManager`. Server: `EnableAutomaticKeyManagement()`, `OpenIddictServerKeyRing`, `IOpenIddictServerKeyProtector` (in `OpenIddict.Server`; Data Protection implementation via `UseDataProtection()`). Local validation follows rotation. Quartz: `EnableKeyPruning()`. | Schema change for every EF user. Static keys still used, after the active auto key. `UseDataProtection()` also switches token formats unless `PreferDefaultTokenFormat()`. |
**Latest test runs (0 failures).** Each count is from the last branch that ran the suite; ASP.NET Core suites on net10.0, OWIN on net48.
| Suite | Passed | Branch |
| P6 JAR | `d5c9bff7` | Server: `EnableRequestObjectSupport()`, `RequireSignedRequestObjects()`, per-client `ft:jar`, discovery. Client: `OpenIddictClientRegistration.UseSignedRequestObjects`. | Parameters outside the object ignored; object validated with the client JWKS. |
| P8b CIBA client | `b67cf1f3` | `AllowClientInitiatedBackchannelAuthenticationFlow()`, `ChallengeUsingBackchannelAsync`, `AuthenticateWithBackchannelAsync`. | Poll only. PAR requirement enforced only for interactive flows. |
| P10 key management | `4d19d539` | **Key** entity (EF Core `OpenIddictKeys`, EF6, MongoDB `openiddict.keys`), `IOpenIddictKeyManager`, `EnableAutomaticKeyManagement()`, `OpenIddictServerKeyRing`, `IOpenIddictServerKeyProtector` (Data Protection impl via `UseDataProtection()`), Quartz `EnableKeyPruning()`. | Schema change for EF users. Static keys used after the active auto key. Local validation follows rotation. `UseDataProtection()` also switches token formats unless `PreferDefaultTokenFormat()`. |
| P5 DPoP | `0dae3a9d``0a732595``dbc144f5``27de4821``19d36ea3` | Server: `EnableDPoPSupport()`, `RequireDPoP()`, `RequireDPoPNonces()`, `ft:dpop`, `dpop_jkt`, discovery. Validation: `DPoP` scheme, optional `IDistributedCache` replay cache. Client: `EnableDPoPTokenBinding()`, `CreateDPoPProofAsync`. | Opt-in. `cnf.jkt` on access and public-client refresh tokens. Server replay check = one token entry per proof. `x5c`/`x5u` ignored; `alg` must match `kty`/`crv`. No PAR proof when mTLS binding can be negotiated. |
| P11.2 dynamic providers | `ad43bd3a``5315d310``776c7ca1` | `IOpenIddictClientRegistrationProvider`, `AddRegistrationProvider<T>()`, `SetDynamicRegistrationCacheLifetime()`. ASP.NET Core: decorated `IAuthenticationSchemeProvider`; OWIN: dynamic authentication types. | No store entity. Redirect URIs must be declared in options. Cached by id (30 min); replaced when issuer/provider name/client id change. |
| P11.3 BFF | `6e1aca1f``36a6a9b2` | `OpenIddict.Client.AspNetCore.Bff` (YARP 2.3.0): `UseBff()`, `MapOpenIddictBffEndpoints()` (login, logout, user, callbacks, back-channel logout), `UseOpenIddictBff()`, `AddOpenIddictBff{User,Client}AccessTokenHandler()`, `AddOpenIddictBffTransforms()`, `IOpenIddictClientAspNetCoreBffSessionStore`. | Cookie auto-refresh. `UseBff()` adds `/bff/callback/*` and passthroughs. Single-flight/replay caches in-memory. Antiforgery fail-closed in API endpoints and YARP. Logout tokens without `exp` need a recent `iat`. |
| P11.4 templates | `56cd9786``1cb254e1` | `templates/OpenIddict.Templates.csproj`: `openiddict-server-identity`, `openiddict-server-empty`, `openiddict-bff`; `templates/verify.sh`. | OpenIddict version checked at pack. Empty-server login is dev-only; `prompt=none` without login → `login_required`. Bootstrap pinned with SRI. |
| P11.5 admin API | `e4cc3771``6a0d72b7` | `MapOpenIddictAdminApi(policy, prefix)`: applications/scopes CRUD; authorizations list/get/create/delete/revoke; tokens list/get/delete/revoke; keys list/get/revoke. | Policy required; JSON body required for POST/PATCH; secrets, payloads, key material, private JWK parameters never returned; authorization revoke cascades. |
| P11.6 SAML IdP | `b6ba3f30``814f25f8``3c25b4d4` | `OpenIddict.Server.Saml` (net48 + net10.0): `UseSaml()`, `OpenIddictServerSamlService`, `IOpenIddictServerSamlServiceProviderStore`, `IOpenIddictServerSamlAssertionProvider`. `.AspNetCore`: `MapOpenIddictSamlEndpoints()` (`/saml/metadata`, `/saml/sso`). `.Owin`: `UseOwin()`, `app.UseOpenIddictSaml()`. | Signed AuthnRequests required by default; single root signature, RSA-SHA2, no DTD; ACS allow-list; data-protected state (SP/ACS re-checked); OWIN requires `SetAuthenticationType()`; timezone-less `IssueInstant` = UTC; no SLO/encryption/artifact binding. |
### 4.1 Latest test runs (0 failures)
Counts come from the last run of each suite, at the commit shown. None were re-run after the merge into `dev`. ASP.NET Core suites ran on net10.0, OWIN on net48.
| Suite | Passed | Run at |
|---|---|---|
| Server unit | 706 | `feature/jwt-introspection` |
| Server ASP.NET Core / OWIN integration | 1,620 (30 admin API) / 1,560 | `feature/templates-admin-api` |
- **Divergence from upstream:**keep fork-only features isolated per branch; rebase when preview.5 ships.
- **Schema changes** (sessions, keys, provider registrations): batch them into one preview.
- **Behaviour changes** needing release notes:
- **Divergence from upstream:**46 fork-only commits on `dev`; rebase on each upstream preview.
- **Schema changes** (keys now; sessions, registrations later): ship in one preview.
- **Behaviour changes needing release notes:**
| Area | Change |
|---|---|
| Device flow / PAR | `interval`/`slow_down` returned/enforced; PAR requirement limited to interactive flows |
| EF | `OpenIddictKeys` table appears in migrations even when key management is off |
| Client ASP.NET Core | `IAuthenticationSchemeProvider` decorated by `UseAspNetCore()` (replacing it afterwards disables dynamic schemes) |
| DPoP | Proofs relying on `x5c`/`x5u` or with `alg` not matching `kty`/`crv` rejected; client sends no PAR proof when mTLS binding can be negotiated |
| JWT introspection | Encryption only on `intr_rsp:enc_alg` opt-in; default `A128CBC-HS256`; exception instead of plaintext on misconfiguration |
| EF | `OpenIddictKeys` table in migrations even with key management off |
| Client ASP.NET Core | `IAuthenticationSchemeProvider` decorated by `UseAspNetCore()` (replacing it later disables dynamic schemes) |
| DPoP | `x5c`/`x5u`-only or `alg`/`kty` mismatched proofs rejected; no PAR proof when mTLS binding negotiable |
| JWT introspection | Encryption only on `intr_rsp:enc_alg`; exception instead of plaintext on misconfiguration |
| Dynamic providers | Cached registration replaced when issuer/provider name/client id change |
| BFF | API endpoints/YARP return 401 without antiforgery header even without `UseOpenIddictBff()`; `User` routes not proxied without a token; stale/future `iat` logout tokens rejected; malformed → 400 |
| Admin API | Private/symmetric JWK values stripped (a PATCH echoing them stores the stripped set); authorization revoke cascades to tokens |
- **Security residuals:** DPoP replay race on EF6 (no unique `ReferenceId`) and MongoDB (user-created index); in-memory per-instance BFF caches break rolling refresh tokens without sticky sessions; SAML request state reusable until expiry (1 h, not session-bound); IdP-initiated SSO carries login-CSRF risk (opt-in); SAML metadata `WantAuthnRequestsSigned` ignores custom stores; SAML `Destination` check needs forwarded headers behind proxies.
- **Key management:** losing the Data Protection key ring makes stored keys unreadable (they are skipped, new ones are created); concurrent first start on several instances can create extra keys (all published, same active key chosen).
- **Scope:** every phase is independently shippable, and P11.4–P11.6 can be dropped.
| BFF | 401 without antiforgery header even without `UseOpenIddictBff()`; `User` routes not proxied without a token; stale/future `iat` logout tokens rejected; malformed → 400 |
| Admin API | Private/symmetric JWK values stripped (PATCH echoing them stores stripped set); authorization revoke cascades |
| SAML | Callback state rejected (400) if SP/ACS/issuer/signature/IdP-initiated settings changed; per-SP `AssertionLifetime` ≤ 0 invalid |
- **Security residuals:**
- DPoP replay race on EF6 (no unique `ReferenceId`) and MongoDB (user-created index).
- In-memory BFF caches break rolling refresh tokens without sticky sessions.
- SAML request state reusable until expiry (1 h, not session-bound).
- **Key management:** lost Data Protection key ring → stored keys skipped, new ones created; concurrent first start can create extra keys (all published, same active key).
- **Scope:** every phase is independently shippable; P11.4–P11.6 can be dropped.