0
votes

we have a website which runs under v4.0 , Classic Mode. We have recently created new httphandler and when we request to this handler we receive 500.21 internal serve error - bad module has a bad module "ManagedPipelineHandler" in its module list.

WebSite works fine with no issues. I have tried all possible solution given in google like regiis & add entry of handler to system.webserver but nothing has worked for me.

Can someone give some idea on the same?

1
Looks like you have set preCondition of handler as managedHandler in web.config. Instead you should set it as ISAPIMode as you are running app pool in clasic mode.Pankaj Kapare
@PankajKapare I didnt set precondition for my handler. Btw how do I set as ISAPI Mode?.Punit
In web.config file search for your handler and add attribute preCondition="ISAPIMode" there in handler configuration.Pankaj Kapare
@PankajKapare No it doesnt works. here is how my handler looks -<add name="LockAutomationCallback" verb="POST" path="callbackservice.lockautomationapi" type="Handlers.LockAutomationHandler" preCondition="ISAPIMode" />Punit
@PankajKapare it got worked when I change precondition for ISAPIModule to 4.0 from 2.0.Punit

1 Answers

1
votes

Run the following command, which will install and register ASP.NET 4.5 in IIS:

dism /online /enable-feature /featurename:IIS-ASPNET45 /all