You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/content/docs/identityserver/diagnostics/data.mdx
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@ Diagnostics data is [written to logs periodically](/identityserver/reference/opt
20
20
your operations team to help analyze your IdentityServer configuration.
21
21
22
22
Diagnostics information is never automatically shared with Duende. In support scenarios, you can choose to manually share
23
-
this diagnostics data with [Duende priority support](/general/support-and-issues.md/#priority-support) to provide additional context. If needed, you can redact/remove
23
+
this diagnostics data with [Duende priority support](/general/support-and-issues#priority-support) to provide additional context. If needed, you can redact/remove
@@ -17,20 +17,20 @@ You can determine the version of IdentityServer4 by running the `dotnet list` co
17
17
18
18
{/* prettier-ignore */}
19
19
<TabssyncKey="operatingSystem">
20
-
<TabItemlabel="Windows">
21
-
<Code
22
-
code={'dotnet list package | sls "IdentityServer4"'}
23
-
lang="bash"
24
-
title="Terminal"
25
-
/>
26
-
</TabItem>
27
-
<TabItemlabel="macOS / Linux">
28
-
<Code
29
-
code={"dotnet list package | grep IdentityServer4"}
30
-
lang="bash"
31
-
title="Terminal"
32
-
/>
33
-
</TabItem>
20
+
<TabItemlabel="Windows">
21
+
<Code
22
+
code={'dotnet list package | sls "IdentityServer4"'}
23
+
lang="bash"
24
+
title="Terminal"
25
+
/>
26
+
</TabItem>
27
+
<TabItemlabel="macOS / Linux">
28
+
<Code
29
+
code={"dotnet list package | grep IdentityServer4"}
30
+
lang="bash"
31
+
title="Terminal"
32
+
/>
33
+
</TabItem>
34
34
</Tabs>
35
35
36
36
This command will print a list of packages you are using in your solution, along with their version.
@@ -57,11 +57,11 @@ Between IdentityServer4 v3.x and v4.x, the configuration object model was update
57
57
58
58
- The relation between `ApiResources` and `ApiScopes` was changed from parent-child to many-to-many.
59
59
- A number of configuration types were renamed:
60
-
-`ApiProperties` to `ApiResourceProperties`
61
-
-`ApiSecrets` to `ApiResourceSecrets`
62
-
-`IdentityClaims` to `IdentityResourceClaims`
63
-
-`IdentityProperties` to `IdentityResourceProperties`
64
-
-`ApiScopes` to `ApiResourceScopes`
60
+
-`ApiProperties` to `ApiResourceProperties`
61
+
-`ApiSecrets` to `ApiResourceSecrets`
62
+
-`IdentityClaims` to `IdentityResourceClaims`
63
+
-`IdentityProperties` to `IdentityResourceProperties`
64
+
-`ApiScopes` to `ApiResourceScopes`
65
65
66
66
IdentityServer4 projects that use the `IdentityServer4.EntityFramework` package or implement their own stores will need to update their code and/or database to reflect these changes.
67
67
@@ -94,63 +94,63 @@ A couple of compilation errors and required changes you may encounter:
94
94
- The `IIdentityServerInteractionService.GetAllUserConsentsAsync` method was renamed to `IIdentityServerInteractionService.GetAllUserGrantsAsync`
95
95
-`ConsentResponse.Denied` was removed. Use the `DenyAuthorizationAsync` instead:
*`ConsentResponse` does not contain a definition for `ScopesConsented`:
146
146
147
-
```diff lang="csharp" title="*.cs"
148
-
grantedConsent = new ConsentResponse
149
-
{
150
-
RememberConsent = model.RememberConsent,
151
-
- ScopesConsented = scopes.ToArray()
152
-
+ ScopesValuesConsented = scopes.ToArray()
153
-
};
147
+
```diff lang="csharp" title="*.cs"
148
+
grantedConsent = new ConsentResponse
149
+
{
150
+
RememberConsent = model.RememberConsent,
151
+
- ScopesConsented = scopes.ToArray()
152
+
+ ScopesValuesConsented = scopes.ToArray()
153
+
};
154
154
```
155
155
156
156
### Step 3: Update Database Schema
@@ -168,17 +168,17 @@ For the operational data, you can create and apply an Entity Framework Core migr
168
168
{/* prettier-ignore */}
169
169
<Steps>
170
170
171
-
1. Create the migration:
171
+
1. Create the migration:
172
172
173
-
```bash title="Terminal"
174
-
dotnet ef migrations add Grants_v4 -c PersistedGrantDbContext -o Migrations/PersistedGrantDb
175
-
```
173
+
```bash title="Terminal"
174
+
dotnet ef migrations add Grants_v4 -c PersistedGrantDbContext -o Migrations/PersistedGrantDb
175
+
```
176
176
177
-
2. Apply the migration to your database:
177
+
2. Apply the migration to your database:
178
178
179
-
```bash title="Terminal"
180
-
dotnet ef database update -c PersistedGrantDbContext
181
-
```
179
+
```bash title="Terminal"
180
+
dotnet ef database update -c PersistedGrantDbContext
181
+
```
182
182
183
183
</Steps>
184
184
@@ -188,66 +188,66 @@ We'll start with creating a migration that targets the `ConfigurationDbContext`
188
188
{/* prettier-ignore */}
189
189
<Steps>
190
190
191
-
1. Create the migration:
191
+
1. Create the migration:
192
192
193
-
```bash title="Terminal"
194
-
dotnet ef migrations add Config_v4 -c ConfigurationDbContext -o Migrations/ConfigurationDb
195
-
```
193
+
```bash title="Terminal"
194
+
dotnet ef migrations add Config_v4 -c ConfigurationDbContext -o Migrations/ConfigurationDb
195
+
```
196
196
197
-
You will see a message _"An operation was scaffolded that may result in the loss of data. Please review the migration for accuracy."_ in the output.
198
-
To avoid data loss, the migration will need to be updated.
197
+
You will see a message _"An operation was scaffolded that may result in the loss of data. Please review the migration for accuracy."_ in the output.
198
+
To avoid data loss, the migration will need to be updated.
199
199
200
-
2. To ensure no data is lost, make sure to include the [`ConfigurationDb_v4_delta.sql`](https://github.com/DuendeArchive/UpgradeSample-IdentityServer4-v3/blob/main/IdentityServerMigrationSample/ConfigurationDb_v4_delta.sql)
201
-
script in your project.
200
+
2. To ensure no data is lost, make sure to include the [`ConfigurationDb_v4_delta.sql`](https://github.com/DuendeArchive/UpgradeSample-IdentityServer4-v3/blob/main/IdentityServerMigrationSample/ConfigurationDb_v4_delta.sql)
201
+
script in your project.
202
202
203
-
You can add the script as an embedded resource by updating the `.csproj` file:
203
+
You can add the script as an embedded resource by updating the `.csproj` file:
:::note[Update the SQL script for your database type]
212
-
The `ConfigurationDb_v4_delta.sql` file assumes you are using SQL Server. If a different database server type is used for your IdentityServer host, you'll need to update the SQL script to use the correct syntax.
213
-
:::
214
-
215
-
3. Modify the migration class that was just created and replace it with the following code:
:::note[Update the SQL script for your database type]
212
+
The `ConfigurationDb_v4_delta.sql` file assumes you are using SQL Server. If a different database server type is used for your IdentityServer host, you'll need to update the SQL script to use the correct syntax.
213
+
:::
245
214
246
-
4. Apply the migration to your database:
215
+
3. Modify the migration class that was just created and replace it with the following code:
247
216
248
-
```bash title="Terminal"
249
-
dotnet ef database update -c ConfigurationDbContext
dotnet ef database update -c ConfigurationDbContext
250
+
```
251
251
252
252
</Steps>
253
253
@@ -405,15 +405,15 @@ In this section, we'll look at updating the database schema based on the stores
405
405
- Improve primary keys on the persisted grants table ([more details](https://github.com/DuendeSoftware/products/pull/793)).
406
406
- Add new properties to the [`Duende.IdentityServer.Models.Client` model](/identityserver/reference/models/client):
407
407
408
-
-`InitiateLoginUri` is a nullable string used for Third Party Initiated Login.
409
-
-`RequireDPoP` is a non-nullable boolean flag that controls if a client is required to use [DPoP](../../tokens/pop).
410
-
-`DPoPValidationMode` is a non-nullable column that controls the DPoP validation mechanism. Existing clients that are not using DPoP can set its value to `0`.
411
-
-`DPoPClockSkew` is a non-nullable timespan that controls how much clock skew is allowed for a particular DPoP client. Existing clients that are not using DPoP can set its value to a timespan of length ``0.
408
+
-`InitiateLoginUri` is a nullable string used for Third Party Initiated Login.
409
+
-`RequireDPoP` is a non-nullable boolean flag that controls if a client is required to use [DPoP](../../tokens/pop).
410
+
-`DPoPValidationMode` is a non-nullable column that controls the DPoP validation mechanism. Existing clients that are not using DPoP can set its value to `0`.
411
+
-`DPoPClockSkew` is a non-nullable timespan that controls how much clock skew is allowed for a particular DPoP client. Existing clients that are not using DPoP can set its value to a timespan of length ``0.
412
412
413
413
- Two new properties have been added to the `Client` model:
414
-
-`Client.RequirePushedAuthorization` is a new boolean property that controls if this client requires [pushed authorization requests (PAR)](../../tokens/par). It is safe to initialize this column to `false` for existing clients, which will mean that the global PAR configuration will be used.
415
-
-`Client.PushedAuthorizationLifetime` is a new nullable integer property that controls the lifetime of pushed
416
-
authorization requests (in seconds) for a client. It is safe to initialize this column to `null` for existing clients, which means the global value is used.
414
+
-`Client.RequirePushedAuthorization` is a new boolean property that controls if this client requires [pushed authorization requests (PAR)](../../tokens/par). It is safe to initialize this column to `false` for existing clients, which will mean that the global PAR configuration will be used.
415
+
-`Client.PushedAuthorizationLifetime` is a new nullable integer property that controls the lifetime of pushed
416
+
authorization requests (in seconds) for a client. It is safe to initialize this column to `null` for existing clients, which means the global value is used.
417
417
- A new `PushedAuthorizationRequest` table has been added to store pushed authorization requests.
418
418
419
419
You'll need to create two database migrations that update the database schema: one that targets the `PersistedGrantDbContext` (for operational data), and one that targets the `ConfigurationDbContext` (for configuration data).
@@ -422,25 +422,25 @@ Note that you may want to change the database migration paths in the examples be
422
422
{/* prettier-ignore */}
423
423
<Steps>
424
424
425
-
1. Create the migrations for the operational and configuration database context:
425
+
1. Create the migrations for the operational and configuration database context:
426
426
427
-
```bash title="Terminal"
428
-
dotnet ef migrations add UpdateToDuende_v7_0 -c PersistedGrantDbContext -o Data/Migrations/IdentityServer/PersistedGrantDb
429
-
dotnet ef migrations add UpdateToDuende_v7_0 -c ConfigurationDbContext -o Data/Migrations/IdentityServer/ConfigurationDb
430
-
```
427
+
```bash title="Terminal"
428
+
dotnet ef migrations add UpdateToDuende_v7_0 -c PersistedGrantDbContext -o Data/Migrations/IdentityServer/PersistedGrantDb
429
+
dotnet ef migrations add UpdateToDuende_v7_0 -c ConfigurationDbContext -o Data/Migrations/IdentityServer/ConfigurationDb
430
+
```
431
431
432
-
:::note
433
-
You may see a warning _"An operation was scaffolded that may result in the loss of data. Please review the migration for accuracy."_.
434
-
The column length for redirect URIs (for both login and logout) was reduced from 2000 to 400 to overcome database index size limits.
435
-
Unless you are using redirect URIs greater than 400 characters, this should not affect you.
436
-
:::
432
+
:::note
433
+
You may see a warning _"An operation was scaffolded that may result in the loss of data. Please review the migration for accuracy."_.
434
+
The column length for redirect URIs (for both login and logout) was reduced from 2000 to 400 to overcome database index size limits.
435
+
Unless you are using redirect URIs greater than 400 characters, this should not affect you.
436
+
:::
437
437
438
-
2. Apply the migrations to your database:
438
+
2. Apply the migrations to your database:
439
439
440
-
```bash title="Terminal"
441
-
dotnet ef database update -c PersistedGrantDbContext
442
-
dotnet ef database update -c ConfigurationDbContext
443
-
```
440
+
```bash title="Terminal"
441
+
dotnet ef database update -c PersistedGrantDbContext
442
+
dotnet ef database update -c ConfigurationDbContext
0 commit comments