To avoid using the HttpModule for static files, configure it in web.config to use preCondition="managedHandler" .
In case this helps, event handlers in Global.asax are not called for static files.
Also, keep in mind that all HttpModules are called for all files when you test Cassini.
source share