简体   繁体   中英

HttpModules

In my application's Web.Config, i have 3 custom HttpModules configured

<httpModules>
  <add name="1" />
  <add name="2" />
  <add name="3" />
</httpModules>

As part of my application tuning exercise, i have to get rid of these modules. So

  1. What are the best ways to replace it or any other solution?
  2. Built - in modules like FormsAuthentication/Windows etc are not mentioned in my config file. does this mean they won't get trigerred?
  1. Without knowing what the modules are actually doing, it's hard to say how you'd want to replace them. Actually, it's even hard to say if it's a good thing to do. If a job is best suited by a module, it should be done by a module. There's nothing inherently bad about it.

  2. They are not mentioned by the config file. ASP.NET engine itself knows about them intimately. They can be enabled and disabled by altering their respective config section (if it has one), like:

    <authentication mode="None" />

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM