Wednesday, July 11, 2007

Handler "$HANDLER" has a bad module "IsapiModule" in its module list

If you've seen this error when trying to get a CGI handler working in IIS7 on Windows Vista, check your applicationHost.config file (in c:\windows\system32\inetserv\config). Specifically, look in the <modules> list to make sure you have an entry specifying:

<add name="IsapiModule" type="" precondition="" />

I was beating my head against the wall with this error message until I added this. (In my case it was within <location path="My Website"><system.webserver><modules>, just to be specific.)

I already had an entry for IsapiModule in globalModules, mind you. I have no idea why this is required, so far the IIS7 configuration system leaves a lot to be desired.

Microsoft, when providing a gun that can shoot you in the foot, it might help to add some safeties. How about making it really easy to configure common CGI modules like Perl, PHP, Python, Ruby, etc?

No comments: