s

azure ad authentication the reply URL specified does not match the reply URLs configured http instead of https in redirect uri edit button Edit

author
Murugan Andezuthu Dharmaratnam | calendar 16 August 2021 | 2008

azure ad authentication the reply URL specified in the request does not match the reply URLs configured for the application http instead of https in redirect_uri.

Sign in
Sorry, but we're having trouble signing you in.

AADSTS50011: The reply URL specified in the request does not match the reply URLs configured for the application: 'f6f5ab30-547b-409d-8266-d6c785b*****'.

Solution

make changes to Startup.cs

Add the below code to ConfigureServices(IServiceCollection services)

services.Configure(options =>
{
    options.ForwardedHeaders = ForwardedHeaders.XForwardedFor |
                  ForwardedHeaders.XForwardedProto;
    options.KnownNetworks.Clear();
    options.KnownProxies.Clear();
});
Add the below code to Configure(IApplicationBuilder app, IWebHostEnvironment env)

app.UseForwardedHeaders();

You can find the solution from the below link

https://seankilleen.com/2020/06/solved-net-core-azure-ad-in-docker-container-incorrectly-uses-an-non-https-redirect-uri/