Skip to content

Commit 2f8ff53

Browse files
authored
Merge pull request #1025 from DuendeSoftware/dh/is8-docs
Add initial IdentityServer 8.0 documentation
2 parents 2fa1ec8 + aab04d7 commit 2f8ff53

29 files changed

Lines changed: 2032 additions & 534 deletions

astro/src/content/docs/bff/extensibility/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ Duende.BFF can be extended in the following areas
1616

1717
* custom logic at the session management endpoints
1818
* custom logic and configuration for HTTP forwarding
19-
* custom data storage for server-side sessions and access/refresh tokens
19+
* custom data storage for server-side sessions and access/refresh tokens

astro/src/content/docs/bff/fundamentals/options.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,16 +43,20 @@ builder.Services.AddBff(options =>
4343
The ASP.NET environment names that enable the diagnostics endpoint. Defaults to "Development".
4444

4545
* ***BackChannelHttpHandler***
46+
4647
A HTTP message handler that's used to configure backchannel communication. Typically used during testing. Configuring this will automatically configure the BackChannelHttpHandler property in _OpenIDConnectOptions_ and also set it as the primary http message handler for retrieving the index.html.
4748

4849
* ***AutomaticallyRegisterBffMiddleware*** (added in 4.0)
50+
4951
When applying BFF V4 multiple frontends, a lot of middlewares get automatically added to the pipeline. For example, the frontend selection middleware, the authentication handlers, etc. If you don't want this automatic behavior, then you can turn it off and register these middlewares manually.
5052

5153

5254
* ***StaticAssetsClientName***
55+
5356
If BFF is configured to automatically retrieve the `index.html`, or to proxy the static assets, it needs an HTTP client to do so. With this name, you can automatically configure this HTTP client in the `HttpClientFactory`.
5457

5558
* ***AllowedSilentLoginReferers***
59+
5660
For silent login to work, you normally need to have the BFF backend and the frontend on the same origin. If you have a split host scenario, meaning the backend on a different origin (but same site) as the frontend, then you can use the referer header to differentiate which browser window to post the silent login results to. This array must then contain the list of allowed referer header values.
5761

5862
## Paths
@@ -162,6 +166,7 @@ builder.Services.AddBlazorServer(opt =>
162166
The following options are available:
163167

164168
* ***ServerStateProviderPollingInterval***
169+
165170
The delay, in milliseconds, between polling requests by the
166171
BffServerAuthenticationStateProvider to the /bff/user endpoint. Defaults to 5000
167172
ms.
@@ -180,13 +185,16 @@ builder.Services.AddBffBlazorClient(opt =>
180185
The following options are available:
181186

182187
* ***RemoteApiPath***
188+
183189
The base path to use for remote APIs.
184190

185191
* ***RemoteApiBaseAddress***
192+
186193
The base address to use for remote APIs. If unset (the default), the
187194
blazor hosting environment's base address is used.
188195

189196
* ***StateProviderBaseAddress***
197+
190198
The base address to use for the state provider's calls to the /bff/user
191199
endpoint. If unset (the default), the blazor hosting environment's base
192200
address is used.
@@ -197,6 +205,7 @@ The following options are available:
197205
start polling the /bff/user endpoint. Defaults to 1000 ms.
198206

199207
* ***WebAssemblyStateProviderPollingInterval***
208+
200209
The delay, in milliseconds, between polling requests by the
201210
BffClientAuthenticationStateProvider to the /bff/user endpoint. Defaults to 5000
202211
ms.

astro/src/content/docs/identityserver/aspnet-identity/schemes.md

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ When a user logs in, their identity is established and persisted across requests
1616

1717
When using IdentityServer without ASP.NET Identity, the default cookie scheme is named `"idsrv"`, though we recommend using the constant `IdentityServerConstants.DefaultCookieAuthenticationScheme` in your code if you ever need it.
1818

19+
Starting in **v8.0**, the default cookie name (not the scheme name) has changed to `"__Host-idsrv"` to improve security. The scheme name remains `"idsrv"`. See [Cookie Name Migration (v8.0)](#cookie-name-migration-v80) below for upgrade instructions.
20+
1921
The default cookie scheme is configured by default in `AddIdentityServer()`, which sets up the cookie authentication handler with this scheme name. This cookie is essential for:
2022

2123
- maintaining the user's authenticated session
@@ -39,7 +41,7 @@ services.ConfigureApplicationCookie(options =>
3941
{
4042
// The default ("Identity.Application")
4143
options.Cookie.Name = IdentityConstants.ApplicationScheme;
42-
44+
4345
// Configure other options here...
4446
options.ExpireTimeSpan = TimeSpan.FromHours(1);
4547
options.SlidingExpiration = true;
@@ -57,6 +59,8 @@ This allows your login logic to read the claims from the external provider befor
5759

5860
IdentityServer always uses the `"idsrv.external"` scheme here, available in the `IdentityServerConstants.ExternalCookieAuthenticationScheme` constant.
5961

62+
Starting in **v8.0**, the default cookie _name_ for this scheme has changed to `"__Host-idsrv.external"` (previously `"idsrv.external"`). See [Cookie Name Migration (v8.0)](#cookie-name-migration-v80) below for upgrade instructions.
63+
6064
### Check Session Cookie
6165

6266
IdentityServer session management requires a separate cookie to monitor the session state without sending the large authentication cookie.
@@ -66,6 +70,24 @@ The [User Session Service](/identityserver/reference/services/user-session-servi
6670

6771
Note this cookie is not marked as `HttpOnly`, so it can be accessed in client-side code. The JavaScript code that is required to check user sessions in the background also requires access to this cookie, and needs it to be `HttpOnly`.
6872

73+
## Cookie Name Migration :badge[v8.0]
74+
75+
In IdentityServer v8.0, the default cookie **names** changed to use the `__Host-` prefix for
76+
improved security. The `__Host-` prefix restricts cookies to HTTPS-only, `Path=/`, and no `Domain`
77+
attribute — providing defense-in-depth against cookie theft and session fixation attacks.
78+
79+
| Cookie | Old name (v7.x) | New name (v8.0) |
80+
| -------------------- | ---------------- | ----------------------- |
81+
| Primary auth cookie | `idsrv` | `__Host-idsrv` |
82+
| External auth cookie | `idsrv.external` | `__Host-idsrv.external` |
83+
84+
The authentication **scheme names** (`"idsrv"` and `"idsrv.external"`) are unchanged.
85+
86+
A migration middleware is available to transparently re-issue old cookies under the new names,
87+
and the cookie names can be overridden via `AuthenticationOptions`. See the
88+
[upgrade guide](/identityserver/upgrades/v7_4-to-v8_0.md#cookie-names-changed-to-__host--prefix)
89+
for full migration instructions.
90+
6991
## Common Pitfalls
7092

7193
- **Mixing Schemes:** Attempting to `SignOutAsync("idsrv")` when ASP.NET Identity is in use will have no effect on the actual `"Identity.Application"` cookie, leaving the user logged in. Always use the constants or the helper services (like `SignInManager`) that match your configuration.
Lines changed: 163 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,163 @@
1+
---
2+
title: "Conformance Report"
3+
description: How to install, configure, and use the IdentityServer conformance report to assess OAuth 2.1 and FAPI 2.0 compliance.
4+
date: 2026-03-02
5+
sidebar:
6+
label: Conformance Report
7+
order: 60
8+
badge:
9+
text: v8.0
10+
variant: tip
11+
---
12+
13+
<span data-shb-badge data-shb-badge-variant="default">Added in 8.0 (prerelease)</span>
14+
15+
The conformance report assesses your IdentityServer deployment against
16+
[OAuth 2.1](https://datatracker.ietf.org/doc/html/draft-ietf-oauth-v2-1) and
17+
[FAPI 2.0 Security Profile](https://openid.net/specs/fapi-2_0-security-profile.html) specifications,
18+
generating an HTML report accessible via a protected endpoint.
19+
20+
## Installation
21+
22+
Install the NuGet package:
23+
24+
```bash title="Terminal"
25+
dotnet add package Duende.IdentityServer.ConformanceReport --prerelease
26+
```
27+
28+
## Setup
29+
30+
### 1. Register the Conformance Report
31+
32+
Call `AddConformanceReport()` on the IdentityServer builder:
33+
34+
```csharp
35+
// Program.cs
36+
builder.Services.AddIdentityServer()
37+
.AddConformanceReport(options =>
38+
{
39+
options.Enabled = true;
40+
});
41+
```
42+
43+
### 2. Map the Endpoint
44+
45+
Add the conformance report endpoint to your middleware pipeline:
46+
47+
```csharp
48+
// Program.cs
49+
app.MapConformanceReport();
50+
```
51+
52+
### 3. Access the Report
53+
54+
Navigate to: `https://your-server/_duende/conformance-report`
55+
56+
The endpoint requires an authenticated user by default (see [Authorization](#authorization) below).
57+
58+
## Configuration Options
59+
60+
`ConformanceReportOptions` controls the conformance report feature:
61+
62+
* **`Enabled`**
63+
Enable or disable the conformance report endpoint. Defaults to `false`.
64+
65+
* **`EnableOAuth21Assessment`**
66+
Include OAuth 2.1 profile assessment in the report. Defaults to `true`.
67+
68+
* **`EnableFapi2SecurityAssessment`**
69+
Include FAPI 2.0 Security Profile assessment in the report. Defaults to `true`.
70+
71+
* **`PathPrefix`**
72+
URL path prefix for the conformance endpoint (no leading slash). Defaults to `"_duende"`.
73+
74+
* **`ConfigureAuthorization`**
75+
Authorization policy for the HTML report endpoint. Defaults to require an authenticated user.
76+
77+
* **`AuthorizationPolicyName`**
78+
ASP.NET Core authorization policy name used internally. Defaults to `"ConformanceReport"`.
79+
80+
* **`HostCompanyName`**
81+
Optional company name shown in the report header. Defaults to `null`.
82+
83+
* **`HostCompanyLogoUrl`**
84+
Optional company logo URL shown in the report header. Defaults to `null`.
85+
86+
## Authorization
87+
88+
By default, the report endpoint requires an authenticated user. Customize the policy using
89+
`ConfigureAuthorization`:
90+
91+
```csharp
92+
// Program.cs
93+
builder.Services.AddIdentityServer()
94+
.AddConformanceReport(options =>
95+
{
96+
options.Enabled = true;
97+
98+
// Require a specific role
99+
options.ConfigureAuthorization = policy => policy.RequireRole("Admin");
100+
101+
// Or require multiple conditions
102+
// options.ConfigureAuthorization = policy => policy
103+
// .RequireRole("Admin")
104+
// .RequireClaim("department", "IT");
105+
106+
// Or allow anonymous (development/testing only)
107+
// options.ConfigureAuthorization = policy =>
108+
// policy.RequireAssertion(_ => builder.Environment.IsDevelopment());
109+
});
110+
```
111+
112+
:::caution
113+
If you set `ConfigureAuthorization = null`, you must manually register an ASP.NET Core authorization
114+
policy with the name specified in `AuthorizationPolicyName` (default: `"ConformanceReport"`).
115+
Otherwise, the endpoint will fail at runtime with a "policy not found" error.
116+
:::
117+
118+
## Understanding the Report
119+
120+
The HTML report displays:
121+
122+
* **Server Configuration** — a matrix of server-level conformance rules and their status
123+
* **Client Configurations** — a matrix of per-client conformance rules and their status
124+
* **Rule Legend** — explanation of each rule identifier
125+
* **Notes** — detailed messages for warnings and failures
126+
127+
### Status Indicators
128+
129+
| Symbol | Meaning |
130+
| ------- | -------------------------------------------------------- |
131+
| Pass | Requirement is met |
132+
| Fail | Requirement is not met (configuration is non-conformant) |
133+
| Warning | Recommended practice is not followed |
134+
| N/A | Rule is not applicable to this configuration |
135+
136+
## Requirements
137+
138+
The conformance report uses `IClientStore.GetAllClientsAsync` to enumerate all clients for
139+
assessment. Custom `IClientStore` implementations must implement this method (added in v8.0).
140+
See the [upgrade guide](/identityserver/upgrades/v7_4-to-v8_0/#iclientstoregettallclientsasync-now-required)
141+
for details.
142+
143+
## Full Example
144+
145+
```csharp
146+
// Program.cs
147+
148+
builder.Services.AddIdentityServer()
149+
.AddInMemoryClients(Config.Clients)
150+
.AddConformanceReport(options =>
151+
{
152+
options.Enabled = true;
153+
options.EnableOAuth21Assessment = true;
154+
options.EnableFapi2SecurityAssessment = true;
155+
options.HostCompanyName = "Acme Corp";
156+
options.ConfigureAuthorization = policy => policy.RequireRole("ComplianceTeam");
157+
});
158+
159+
// ...
160+
161+
app.MapConformanceReport();
162+
app.UseIdentityServer();
163+
```

astro/src/content/docs/identityserver/diagnostics/index.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,11 @@ systems (APM). They used to have their own different APIs so IdentityServer only
3333
that could be used to call the APM's APIs. Thanks to OpenTelemetry there is now a standardized
3434
way to emit diagnostic information from a process. The events may eventually be deprecated and removed.
3535

36-
[Read More](/identityserver/diagnostics/events.md)
36+
[Read More](/identityserver/diagnostics/events.md)
37+
38+
## Conformance Report
39+
40+
IdentityServer can generate a conformance report that assesses your configuration against OAuth 2.1
41+
and FAPI 2.0 specifications.
42+
43+
[Read More](/identityserver/diagnostics/conformance-report/)

0 commit comments

Comments
 (0)