教程集 www.jiaochengji.com
教程集 >  脚本编程  >  Asp.net  >  正文 net 权限问题

net 权限问题

发布时间:2018-10-04   编辑:jiaochengji.com
教程集为您提供net 权限问题等资源,欢迎您收藏本站,我们将为您提供最新的net 权限问题资源

<authentication mode="Forms">
<forms name=".ASPXAUTHBBBCCCC" loginUrl="~/Default.aspx" defaultUrl="~/Main/default.aspx" protection="All" timeout="216000" path="/" requireSSL="false" slidingExpiration="true">
</forms>
</authentication>

  <authorization>
  <allow users="?"/>
  </authorization>


  <location path="main" allowOverride="false">
<system.web>
<authorization>
<allow roles="dealer,accessor,agent,admin"/>
        <deny users="*"/>
</authorization>
</system.web>
</location>
<location path="main/dealer" allowOverride="false">
<system.web>
<authorization>
<allow roles="dealer"/>
<deny users="*" />
</authorization>
</system.web>
</location>
<location path="main/accessor" allowOverride="false">
<system.web>
<authorization>
<allow roles="accessor"/>
<deny users="*"/>
      </authorization>
    </system.web>
  </location>
  <location path="main/agent" allowOverride="false">
    <system.web>
      <authorization>
        <allow roles="agent"/>
        <deny users="*" />
</authorization>
</system.web>
</location>
<location path="main/admin" allowOverride="false">
<system.web>
<authorization>
<allow roles="admin"/>
<deny users="*"/>
</authorization>
</system.web>
</location>

和Rolesmanager一起使用,当用户登录后都可以入各自目录并可以访问aspx页面,但如果要访问的页面是其他文件类型,比如: html,txt 文件就不受目录的限制,可以在没有身份验证的情况下,可以直接输入地址打开文件而不会返回到登录页面.  请问是不是目录权限只对aspx页面起作用,其他文件不起作用. 有什么好的解决方法,控制目录?

您可能感兴趣的文章:
解决服务器应用程序不可用,错误:0x80070005拒绝访问的错误
asp.net 服务器应用程序不可用的解决办法
asp.net无法加载oci.dll的解决方法
.NET框架中基于角色的安全性(3)
创建ASP.NET数据存储层(1)
生产环境中遇到的IIS启用GZip的问题
iis运行.net提示System.Data.OleDb.OleDbException: 操作必须使用一个可更新的查询
win2003安全设置教程(伪装篇)
php5的安全问题讲解[新手必读]
golang http client 使用gzip_一次gRPC使用不当导致goroutine泄漏排查记录

[关闭]
~ ~