Skip to content

Commit 5c3b89a

Browse files
committed
Revert "Revert "Update IdentityServer4 -> Duende (#33590)" (#34317)"
This reverts commit c9c9a9e.
1 parent e1d240e commit 5c3b89a

File tree

45 files changed

+498
-97
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+498
-97
lines changed

eng/Dependencies.props

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -160,17 +160,17 @@ and are generated based on the last package release.
160160
<LatestPackageReference Include="AngleSharp" />
161161
<LatestPackageReference Include="BenchmarkDotNet" />
162162
<LatestPackageReference Include="CommandLineParser" />
163+
<LatestPackageReference Include="Duende.IdentityServer" />
164+
<LatestPackageReference Include="Duende.IdentityServer.AspNetIdentity" />
165+
<LatestPackageReference Include="Duende.IdentityServer.EntityFramework" />
166+
<LatestPackageReference Include="Duende.IdentityServer.EntityFramework.Storage" />
167+
<LatestPackageReference Include="Duende.IdentityServer.Storage" />
163168
<LatestPackageReference Include="FSharp.Core" />
164169
<LatestPackageReference Include="Google.Protobuf" />
165170
<LatestPackageReference Include="Grpc.AspNetCore" />
166171
<LatestPackageReference Include="Grpc.Auth" />
167172
<LatestPackageReference Include="Grpc.Net.Client" />
168173
<LatestPackageReference Include="Grpc.Tools" />
169-
<LatestPackageReference Include="IdentityServer4" />
170-
<LatestPackageReference Include="IdentityServer4.AspNetIdentity" />
171-
<LatestPackageReference Include="IdentityServer4.EntityFramework" />
172-
<LatestPackageReference Include="IdentityServer4.EntityFramework.Storage" />
173-
<LatestPackageReference Include="IdentityServer4.Storage" />
174174
<LatestPackageReference Include="Libuv" />
175175
<LatestPackageReference Include="MessagePack" />
176176
<LatestPackageReference Include="MessagePackAnalyzer" />

eng/Versions.props

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -229,11 +229,11 @@
229229
<GrpcAuthVersion>2.32.0</GrpcAuthVersion>
230230
<GrpcNetClientVersion>2.32.0</GrpcNetClientVersion>
231231
<GrpcToolsVersion>2.32.0</GrpcToolsVersion>
232-
<IdentityServer4AspNetIdentityVersion>4.1.0</IdentityServer4AspNetIdentityVersion>
233-
<IdentityServer4EntityFrameworkVersion>4.1.0</IdentityServer4EntityFrameworkVersion>
234-
<IdentityServer4Version>4.1.0</IdentityServer4Version>
235-
<IdentityServer4StorageVersion>4.1.0</IdentityServer4StorageVersion>
236-
<IdentityServer4EntityFrameworkStorageVersion>4.1.0</IdentityServer4EntityFrameworkStorageVersion>
232+
<DuendeIdentityServerAspNetIdentityVersion>5.2.0</DuendeIdentityServerAspNetIdentityVersion>
233+
<DuendeIdentityServerEntityFrameworkVersion>5.2.0</DuendeIdentityServerEntityFrameworkVersion>
234+
<DuendeIdentityServerVersion>5.2.0</DuendeIdentityServerVersion>
235+
<DuendeIdentityServerStorageVersion>5.2.0</DuendeIdentityServerStorageVersion>
236+
<DuendeIdentityServerEntityFrameworkStorageVersion>5.2.0</DuendeIdentityServerEntityFrameworkStorageVersion>
237237
<MessagePackVersion>2.1.90</MessagePackVersion>
238238
<MicrosoftIdentityWebVersion>1.1.0</MicrosoftIdentityWebVersion>
239239
<MicrosoftIdentityWebMicrosoftGraphVersion>1.1.0</MicrosoftIdentityWebMicrosoftGraphVersion>

src/Components/WebAssembly/testassets/Wasm.Authentication.Server/Data/ApplicationDbContext.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
using Wasm.Authentication.Server.Models;
2-
using IdentityServer4.EntityFramework.Options;
2+
using Duende.IdentityServer.EntityFramework.Options;
33
using Microsoft.AspNetCore.ApiAuthorization.IdentityServer;
44
using Microsoft.EntityFrameworkCore;
55
using Microsoft.Extensions.Options;

src/Components/WebAssembly/testassets/Wasm.Authentication.Server/Data/Migrations/20200324213904_Initial.Designer.cs

Lines changed: 38 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/Components/WebAssembly/testassets/Wasm.Authentication.Server/Data/Migrations/20200324213904_Initial.cs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,24 @@ protected override void Up(MigrationBuilder migrationBuilder)
6363
table.PrimaryKey("PK_DeviceCodes", x => x.UserCode);
6464
});
6565

66+
migrationBuilder.CreateTable(
67+
name: "Keys",
68+
columns: table => new
69+
{
70+
Id = table.Column<string>(nullable: false),
71+
Version = table.Column<int>(nullable: false),
72+
Created = table.Column<DateTime>(nullable: false),
73+
Use = table.Column<string>(nullable: true),
74+
Algorithm = table.Column<string>(maxLength: 100, nullable: false),
75+
IsX509Certificate = table.Column<bool>(nullable: false),
76+
DataProtected = table.Column<bool>(nullable: false),
77+
Data = table.Column<string>(nullable: false)
78+
},
79+
constraints: table =>
80+
{
81+
table.PrimaryKey("PK_Keys", x => x.Id);
82+
});
83+
6684
migrationBuilder.CreateTable(
6785
name: "PersistedGrants",
6886
columns: table => new
@@ -290,6 +308,9 @@ protected override void Down(MigrationBuilder migrationBuilder)
290308
migrationBuilder.DropTable(
291309
name: "DeviceCodes");
292310

311+
migrationBuilder.DropTable(
312+
name: "Keys");
313+
293314
migrationBuilder.DropTable(
294315
name: "PersistedGrants");
295316

src/Components/WebAssembly/testassets/Wasm.Authentication.Server/Data/Migrations/ApplicationDbContextModelSnapshot.cs

Lines changed: 41 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ protected override void BuildModel(ModelBuilder modelBuilder)
1616
modelBuilder
1717
.HasAnnotation("ProductVersion", "5.0.0-rc.1.20416.1");
1818

19-
modelBuilder.Entity("IdentityServer4.EntityFramework.Entities.DeviceFlowCodes", b =>
19+
modelBuilder.Entity("Duende.IdentityServer.EntityFramework.Entities.DeviceFlowCodes", b =>
2020
{
2121
b.Property<string>("UserCode")
2222
.HasMaxLength(200)
@@ -66,7 +66,46 @@ protected override void BuildModel(ModelBuilder modelBuilder)
6666
b.ToTable("DeviceCodes");
6767
});
6868

69-
modelBuilder.Entity("IdentityServer4.EntityFramework.Entities.PersistedGrant", b =>
69+
modelBuilder.Entity("Duende.IdentityServer.EntityFramework.Entities.Key", b =>
70+
{
71+
b.Property<string>("Id")
72+
.HasMaxLength(450)
73+
.HasColumnType("TEXT");
74+
75+
b.Property<string>("Algorithm")
76+
.IsRequired()
77+
.HasMaxLength(100)
78+
.HasColumnType("TEXT");
79+
80+
b.Property<DateTime>("Created")
81+
.HasColumnType("TEXT");
82+
83+
b.Property<string>("Data")
84+
.IsRequired()
85+
.HasColumnType("TEXT")
86+
.HasMaxLength(50000);
87+
88+
b.Property<bool>("DataProtected")
89+
.HasColumnType("bit");
90+
91+
b.Property<bool>("IsX509Certificate")
92+
.HasColumnType("bit");
93+
94+
b.Property<string>("Use")
95+
.HasMaxLength(450)
96+
.HasColumnType("TEXT");
97+
98+
b.Property<int>("Version")
99+
.HasColumnType("int");
100+
101+
b.HasKey("Id");
102+
103+
b.HasIndex("Use");
104+
105+
b.ToTable("Keys");
106+
});
107+
108+
modelBuilder.Entity("Duende.IdentityServer.EntityFramework.Entities.PersistedGrant", b =>
70109
{
71110
b.Property<string>("Key")
72111
.HasMaxLength(200)

src/Components/WebAssembly/testassets/Wasm.Authentication.Server/Wasm.Authentication.Server.csproj

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
<PropertyGroup>
44
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
55

6+
<!-- IdentityServer packages are not signed -->
7+
<NoWarn>CS8002</NoWarn>
68
<!-- This project references the shared framework transitively. Prevent restore errors by setting this flag. -->
79
<GenerateErrorForMissingTargetingPacks>false</GenerateErrorForMissingTargetingPacks>
810
</PropertyGroup>

src/Identity/ApiAuthorization.IdentityServer/samples/ApiAuthSample/ApiAuthSample.csproj

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,15 @@
33
<PropertyGroup>
44
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
55
<UserSecretsId>aspnet-ApiAuthSample-12ED8ECC-9EF1-4D31-87B4-1405B3198E5E</UserSecretsId>
6+
<!-- IdentityServer packages are not strong named -->
7+
<NoWarn>CS8002</NoWarn>
68
<!-- We are a package that depends on the shared framework, this allows us to
79
avoid errors during restore -->
810
<GenerateErrorForMissingTargetingPacks>false</GenerateErrorForMissingTargetingPacks>
911
</PropertyGroup>
1012

1113
<ItemGroup>
12-
<!-- Remove the reference to Microsoft.AspNetCore.App from IdentityServer4 -->
14+
<!-- Remove the reference to Microsoft.AspNetCore.App from Duende.IdentityServer -->
1315
<FrameworkReference Remove="Microsoft.AspNetCore.App" />
1416
<Reference Include="Microsoft.AspNetCore.ApiAuthorization.IdentityServer" />
1517
<Reference Include="Microsoft.AspNetCore.CookiePolicy" />

src/Identity/ApiAuthorization.IdentityServer/samples/ApiAuthSample/Data/ApplicationDbContext.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using IdentityServer4.EntityFramework.Options;
1+
using Duende.IdentityServer.EntityFramework.Options;
22
using Microsoft.AspNetCore.ApiAuthorization.IdentityServer;
33
using Microsoft.EntityFrameworkCore;
44
using Microsoft.Extensions.Options;

src/Identity/ApiAuthorization.IdentityServer/samples/ApiAuthSample/Data/Migrations/20180919224505_InitialMigration.Designer.cs

Lines changed: 90 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/Identity/ApiAuthorization.IdentityServer/samples/ApiAuthSample/Data/Migrations/20180919224505_InitialMigration.cs

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,41 @@ protected override void Up(MigrationBuilder migrationBuilder)
4646
table.PrimaryKey("PK_AspNetUsers", x => x.Id);
4747
});
4848

49+
migrationBuilder.CreateTable(
50+
name: "DeviceCodes",
51+
columns: table => new
52+
{
53+
UserCode = table.Column<string>(maxLength: 200, nullable: false),
54+
DeviceCode = table.Column<string>(maxLength: 200, nullable: false),
55+
SubjectId = table.Column<string>(maxLength: 200, nullable: true),
56+
ClientId = table.Column<string>(maxLength: 200, nullable: false),
57+
CreationTime = table.Column<DateTime>(nullable: false),
58+
Expiration = table.Column<DateTime>(nullable: false),
59+
Data = table.Column<string>(maxLength: 50000, nullable: false)
60+
},
61+
constraints: table =>
62+
{
63+
table.PrimaryKey("PK_DeviceCodes", x => x.UserCode);
64+
});
65+
66+
migrationBuilder.CreateTable(
67+
name: "Keys",
68+
columns: table => new
69+
{
70+
Id = table.Column<string>(nullable: false),
71+
Version = table.Column<int>(nullable: false),
72+
Created = table.Column<DateTime>(nullable: false),
73+
Use = table.Column<string>(nullable: true),
74+
Algorithm = table.Column<string>(maxLength: 100, nullable: false),
75+
IsX509Certificate = table.Column<bool>(nullable: false),
76+
DataProtected = table.Column<bool>(nullable: false),
77+
Data = table.Column<string>(nullable: false)
78+
},
79+
constraints: table =>
80+
{
81+
table.PrimaryKey("PK_Keys", x => x.Id);
82+
});
83+
4984
migrationBuilder.CreateTable(
5085
name: "PersistedGrants",
5186
columns: table => new

0 commit comments

Comments
 (0)