diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index fc670e5c8fa7..68f3394b329d 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -189,9 +189,9 @@ https://github.com/dotnet/runtime 90b92bb265a412592c4c152983d7b30c92236dbe - + https://github.com/dotnet/source-build-externals - 1bc73adce07951fc0931ebd2b93492db78c538df + e3cc6c792114ebdfe6627742d2820dbe1ae5bc47 diff --git a/eng/Versions.props b/eng/Versions.props index 6f3f82fd0703..80ac7445ab2d 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -11,7 +11,7 @@ 0 2 true - 7.0.0-preview + 7.0.0-preview3 @@ -162,7 +162,7 @@ 8.0.0-beta.23419.1 8.0.0-beta.23419.1 - 8.0.0-alpha.1.23421.1 + 8.0.0-alpha.1.23424.1 8.0.0-alpha.1.23421.1 diff --git a/src/Security/Authentication/WsFederation/src/WsFederationHandler.cs b/src/Security/Authentication/WsFederation/src/WsFederationHandler.cs index d00103ddb26a..d336a8665a39 100644 --- a/src/Security/Authentication/WsFederation/src/WsFederationHandler.cs +++ b/src/Security/Authentication/WsFederation/src/WsFederationHandler.cs @@ -98,7 +98,7 @@ protected override async Task HandleChallengeAsync(AuthenticationProperties prop var wsFederationMessage = new WsFederationMessage() { IssuerAddress = _configuration.TokenEndpoint ?? string.Empty, - Wtrealm = Options.Wtrealm, + Wtrealm = Options.Wtrealm!, // TODO: https://github.com/dotnet/aspnetcore/issues/50242 Wa = WsFederationConstants.WsFederationActions.SignIn, }; @@ -195,7 +195,7 @@ protected override async Task HandleRemoteAuthenticateAsync { // Extract the user state from properties and reset. properties.Items.TryGetValue(WsFederationDefaults.UserstatePropertiesKey, out var userState); - wsFederationMessage.Wctx = userState; + wsFederationMessage.Wctx = userState!; // TODO: '!' can be removed with https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/issues/2240 } var messageReceivedContext = new MessageReceivedContext(Context, Scheme, Options, properties) @@ -425,7 +425,7 @@ public virtual async Task SignOutAsync(AuthenticationProperties? properties) var wsFederationMessage = new WsFederationMessage() { IssuerAddress = _configuration.TokenEndpoint ?? string.Empty, - Wtrealm = Options.Wtrealm, + Wtrealm = Options.Wtrealm!, // TODO: https://github.com/dotnet/aspnetcore/issues/50242 Wa = WsFederationConstants.WsFederationActions.SignOut, }; diff --git a/src/Security/Authentication/test/JwtBearerTests_Handler.cs b/src/Security/Authentication/test/JwtBearerTests_Handler.cs index 5e7c281ff2cd..0add4d39bb88 100644 --- a/src/Security/Authentication/test/JwtBearerTests_Handler.cs +++ b/src/Security/Authentication/test/JwtBearerTests_Handler.cs @@ -914,21 +914,23 @@ public async Task ExpirationAndIssuedSetOnAuthenticateResult() public async Task ExpirationAndIssuedWhenMinOrMaxValue() { var key = new SymmetricSecurityKey(Encoding.UTF8.GetBytes(new string('a', 128))); - var creds = new SigningCredentials(key, SecurityAlgorithms.HmacSha256); - - var claims = new[] - { - new Claim(ClaimTypes.NameIdentifier, "Bob") - }; - - var token = new JwtSecurityToken( - issuer: "issuer.contoso.com", - audience: "audience.contoso.com", - claims: claims, - expires: DateTime.MaxValue, - signingCredentials: creds); - - var tokenText = new JwtSecurityTokenHandler().WriteToken(token); + //var creds = new SigningCredentials(key, SecurityAlgorithms.HmacSha256); + + //var claims = new[] + //{ + // new Claim(ClaimTypes.NameIdentifier, "Bob") + //}; + + //var token = new JwtSecurityToken( + // issuer: "issuer.contoso.com", + // audience: "audience.contoso.com", + // claims: claims, + // expires: DateTime.MaxValue, + // signingCredentials: creds); + + //var tokenText = new JwtSecurityTokenHandler().WriteToken(token); + // TODO: when https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/issues/2261 is fixed, uncomment the above code and remove this hard-coded string + var tokenText = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1laWRlbnRpZmllciI6IkJvYiIsImV4cCI6MjUzNDAyMzAwODAwLCJpc3MiOiJpc3N1ZXIuY29udG9zby5jb20iLCJhdWQiOiJhdWRpZW5jZS5jb250b3NvLmNvbSJ9.0zvasyAh-GmjR_o46QSRCoQ9VaSXJjW5_YMcR6qy-jw"; using var host = await CreateHost(o => {