Answered by:
validateIntegratedModeConfiguration=false?

Question
-
User-1398449107 posted
After migrating an ASP.NET application to IIS7, I found that I needed to add this line to <system.webServer>
Is this safe? How else is the application affected if I set it to 'false'?
Monday, July 7, 2008 9:23 AM
Answers
-
User-47214744 posted
That flag will not alter the behavior of the application in any way, it will only tell IIS to not flag an error when one of the three typical configuration issues are identified:
Basically we knew that some problems might be overseen while moving an application from classic mode to integrated mode, most importantly the fact that modules in system.web/httpModules would no longer be used and only the system.webServer/modules would. If any of those modules in system.web was used as a security feature or added any interesting behavior it could be that developers didn't realized it was no longer running and potentially introduce issues in the application.
That is the reason this flag was introduced so that by default any of this potential issues are flagged as errors (500.23 if I remember correctly), but once a developer looks into their settings and verify they know that even though modules are in the system.web settings, they know that is the right configuration (probably duplicating the modules in system.webServer) then they can turn off that warning and allow the application to run in both modes.
See the above link for more information on the three configuration flags we raise errors.
Hope this helps a bit
- Marked as answer by Anonymous Tuesday, September 28, 2021 12:00 AM
Monday, July 7, 2008 3:18 PM
All replies
-
User-47214744 posted
That flag will not alter the behavior of the application in any way, it will only tell IIS to not flag an error when one of the three typical configuration issues are identified:
Basically we knew that some problems might be overseen while moving an application from classic mode to integrated mode, most importantly the fact that modules in system.web/httpModules would no longer be used and only the system.webServer/modules would. If any of those modules in system.web was used as a security feature or added any interesting behavior it could be that developers didn't realized it was no longer running and potentially introduce issues in the application.
That is the reason this flag was introduced so that by default any of this potential issues are flagged as errors (500.23 if I remember correctly), but once a developer looks into their settings and verify they know that even though modules are in the system.web settings, they know that is the right configuration (probably duplicating the modules in system.webServer) then they can turn off that warning and allow the application to run in both modes.
See the above link for more information on the three configuration flags we raise errors.
Hope this helps a bit
- Marked as answer by Anonymous Tuesday, September 28, 2021 12:00 AM
Monday, July 7, 2008 3:18 PM -
User-1398449107 posted
Thanks Carlos, that was most helpful.
So before I can use this switch I must ensure that the application does not use system.web?
Will I need to make any modifications to the ASP page itself or the web.config file?
Tuesday, July 8, 2008 4:23 AM -
User-47214744 posted
Not necesarilly, I guess the main message is:
1) If you want your application to only run in Integrated Mode, then move all the modules and handlers from system.web/httpHandler and httpModules. And if you dont use ASP.NET Impersonation then you should be able to remove the validateIntegratedModeConfiguration flag.
2) If you want your application only in Classic Mode, then you can get rid of validateIntegratedModeConfiguration and not have locally in your web.config any managed modules/handlers in system.webServer
3) If you want your application to potentially be used in both modes, then you need to keep the modules and handlers in system.webServer and system.web in sync as well and configure the preCondition's correctly and keep the flag so that we dont flag it in Integrated mode.
Also should mention that "AppCmd migrate config" will help with some of these tasks,
Tuesday, July 8, 2008 12:49 PM -
User-1398449107 posted
Hi Carlos,
I would like the application to run in Classic Mode (scenario 2). However if I switch the application pool to Classic ASP.NET, the page hangs and never loads. The page only works if I add validateIntegratedModeConfiguration and set it to false. This is what raised concerns in the first place. I just want to ensure that the application has been migrated smoothly with minimal changes, and is still secure.
I will have a look at 'Appcmd migrate config', thanks.
EDIT: I have tried appcmd which updated web.config however the page still fails to load in Classic ASP.NET application pool. It also still added validateIntegratedModeConfiguration=false.
Wednesday, July 9, 2008 4:57 AM