开发者

Problem Configuring "Location" Path Security on Machine.config

开发者 https://www.devze.com 2023-01-05 15:05 出处:网络
I\'m trying to add something like this in Machine.config: <location path=\"elmah.axd\"> <system.web>

I'm trying to add something like this in Machine.config:

<location path="elmah.axd">
    <system.web>
        <authorization>
            <allow users="domain\johnny" />
            <deny users="*"/>
        </authorization>
    &开发者_开发问答lt;/system.web>
</location>

This works great in the application-level web.config, but I can't get it to take any effect in machine.config. Basically, I'm trying to set security for the "elmah.axd" path in all applications. The security is not being applied when this code is placed in the machine.config or root/server-level web.config. It lets all users access "elmah.axd" no matter what I do.


Make sure your not overriding it in the web.config

0

精彩评论

暂无评论...
验证码 换一张
取 消