HttpModule only on specific MVC route

前端 未结 2 477
醉酒成梦
醉酒成梦 2021-01-21 01:45

I have a custom IHttpModule that I would like to only work on a specific route.

For example : http://example.com/HandleAzureTask

I want

2条回答
  •  离开以前
    2021-01-21 02:02

    Why not just create a ordinary folder namned /HandleAzureTask and put a seperate web.config inside that folder with the module registration.

    Then the module will run for all request in that folder.

    To get the authorization to work you can also set the authorization element in the web.config to disallow *

提交回复
热议问题