From cdfaae75a99c0443462484f9d9cb189cd49bdc9f Mon Sep 17 00:00:00 2001 From: jennyf19 Date: Fri, 10 Feb 2023 16:08:32 -0800 Subject: [PATCH] update owin side (#2078) --- src/Microsoft.Identity.Web.OWIN/AppBuilderExtension.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Microsoft.Identity.Web.OWIN/AppBuilderExtension.cs b/src/Microsoft.Identity.Web.OWIN/AppBuilderExtension.cs index b58d650a0..228c1a8ca 100644 --- a/src/Microsoft.Identity.Web.OWIN/AppBuilderExtension.cs +++ b/src/Microsoft.Identity.Web.OWIN/AppBuilderExtension.cs @@ -190,12 +190,14 @@ public static IAppBuilder AddMicrosoftIdentityWebApp( var tokenAcquisition = tokenAcquirerFactory?.ServiceProvider?.GetRequiredService(); var msIdentityOptions = tokenAcquirerFactory?.ServiceProvider?.GetRequiredService>(); var result = await (tokenAcquisition!.AddAccountToCacheFromAuthorizationCodeAsync( + new AuthCodeRedemptionParameters( new string[] { options.Scope }, context.Code, string.Empty, context.ProtocolMessage.GetParameter(ClaimConstants.ClientInfo), codeVerifier, - msIdentityOptions?.Value.DefaultUserFlow)).ConfigureAwait(false); + msIdentityOptions?.Value.DefaultUserFlow, + context.ProtocolMessage.DomainHint))).ConfigureAwait(false); HttpContextBase httpContext = context.OwinContext.Get(typeof(HttpContextBase).FullName); httpContext.Session.Add(ClaimConstants.ClientInfo, context.ProtocolMessage.GetParameter(ClaimConstants.ClientInfo)); context.HandleCodeRedemption(result.AccessToken, result.IdToken);