Problem is, the httpModule doesn't get called because http://testserver/SomeApplication doesn't exist. I assume this is because
IIS is spitting it back, but I am not sure. Can someone help me figure out a
decent way of getting that to work? Do I need an ISAPI filter instead?
Because the file does not exist the worker process never gets a chance
to play in the web request. Well the directory surely doesn't exist so
you don't even get the default mapped file. IIS just throughs back the
404 error. Note that that error is a htm page. You can configure this
to use your own code. So I will bet that you can map the 404 error in
IIS "Custom Errors" tab to your HttpModule code. But you will have to
implement your HttpModule as a .ashx file. Now I haven't done this
specifically I think this will work. Tell me if this works for you.
Make sure that you check the url string and still send back the normal
404 error content when a visitor hits a web site not in the url of interest.