简体   繁体   中英

Integrated Windows Authentication not working for MVC .NET web app on IIS

I'm working on a .NET MVC web app, and I'm using Windows authentication. My IE has "Integrated Windows Authentication" enabled, and it works when I navigate to other sites hosted on the same IIS server (aka I am not prompted for login). However when I go to this one page and call an API method, base.isAuthorized(actionContext) evaluates to false in the C# code, resulting in me being shown the login dialog. Correct me if I'm wrong, but I thought Windows Authentication would authenticate me right when I enter the webpage... why am I still prompted for credentials?

Authentication settings can be different for each web site on the server. Check your IIS settings for this particular web site. Make sure that Windows Authentication is enabled, and that Anonymous Authentication is disabled .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM