locked
Order of HttpModule and third-party isapi filter RRS feed

  • Question

  • User1449163449 posted

    Hello!

    I'm using an HttpModule to redirect certain pages on my site. But I have the problem that an existing third-party isapi filter is executed BEFORE my handler code. Is it possible to do the redirect in my handler BEFORE the isapi filter is run?

    Here are some details: on a specific folder on our webserver we have a PTA certificate. If a user requests a page in that folder using the http protocol, the PTA isapi filter redirects to an error page. What I want is that my own HttpModule checks every request to a page BEFORE the isapi filter, and if the user requests a page in the secured folder with the http protocol, I want the HttpModule to redirect to that same page, but with the https protocol. After that, the PTA isapi filter won't come up with an error page because the user used http instead of https, because my handler has changed the user request from http to https.

    Hope that someone can help me out of this!

    Kind regards,

    Jeroen

    Monday, June 26, 2006 12:04 PM

All replies

  • User-2001980297 posted
    It is impossible. The filter take effect in IIS stage while the httpmodule is in asp.net stage. Each asp.net request is first handled by IIS and then mapped to asp.net engine. So it is by IIS design.
    Tuesday, June 27, 2006 2:18 AM
  • User1449163449 posted

    But isn't it possible to include the ASP.NET process (executing the HttpModule) in the list of ISAPI filters in IIS, and then putting that process ABOVE the third-party ISAPI filter?

    Tuesday, June 27, 2006 3:46 AM
  • User-2001980297 posted
    Maybe you can. But I think it is not easy work. Sorry I have not much more knowledge on how to implement that..
    Thursday, June 29, 2006 3:51 AM