I have ASP.NET Core MVC hosted in IIS. I have already enabled the Windows authentication in IIS.
I have looked at this: https://docs.microsoft.com/en-us/aspnet/core/security/authentication/windowsauth?view=aspnetcore-3.1&tabs=visual-studio
In my Startup, I already have this:
services.AddAuthentication(IISDefaults.AuthenticationScheme);
In my Login button, I call:
Challenge("Windows")
But I'm getting the
InvalidOperationError: No authentication handlers are registered. Did you forget to call AddAuthentication().AddSomeAuthHandler?
It seems like I need an authentication handler to be used for Windows, I'm guessing something similar to this:
services.AddAuthentication() .AddOpenIdConnect("oidc", o => { // Lots of options here});
But I can't find any Nuget package for Windows authentication handler. What am I missing?
2.1m questions
2.1m answers
60 comments
57.0k users