Is it possible to predetermine the order of HttpModule calls or implement filter chaining in ASP.Ne

J

Joe Bloggs

Hi people,

I am wondering if it is possible to pretermine the order of the
HttpModules being executed. If not, how can one implement interceptor
filter chaining with HttpModule in ASP.Net?

Why do I want to do this?

It is because I have a HttpModule that will perform some sort of
authentication, another to perform Url rewriting. I would like the
authentication filter to execute first before the Url rewriting.

Thanks in advanced.
 
B

Brock Allen

The order tends to go by the order they're configured in the <httpModules>
section. So there are times when you want yours to fire before a built-in
one, so you have to use <remove /> in web.config sometimes then <add /> yours,
then <add /> back in the one that you had previously removed.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,020
Latest member
GenesisGai

Latest Threads

Top