简体   繁体   中英

IIS complaining about Identity Impersonation using LDAP Authentication

I followed a tutorial to implement LDAP authentication in an ASP.NET/C# 4.0 web application. I did so in Visual Studio 2010. The site runs fine in debug mode through Visual Studio, but when I publish this site in IIS7, it is failing with the following error:

HTTP Error 500.24 - Internal Server Error An ASP.NET setting has been detected that does not apply in Integrated managed pipeline mode.

Most likely causes:

  • system.web/identity@impersonate is set to true.

In fact, part of the tutorial required that I add this to the config file...

<identity impersonate="true"/>

So why would I be getting this error and how do I fix it?

Try changing your application pool's pipeline mode to 'Classic'

You do this by opening IIS -> Application Pools -> Right-click your application pool and select Basic Settings -> Managed pipline mode, change to Classic

Restart your app pool and site (shouldn't need to but never hurts to try) and try again.

Another thing you can try, instead of the above, is to put the following in your web.config file, inside the <system.webServer> node:

       <validation validateIntegratedModeConfiguration="false" />

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