将 IIS Web 限制到本地组

将 IIS Web 限制到本地组

我无法让 Windows 7 上的 IIS 7.5 服务器获得我想要的安全性。

我想要一个任何人都可以访问的门户页面,并且在该页面上我将提供虚拟目录的链接。我希望每个虚拟目录都与可以访问该 Web 应用程序的特定本地用户组绑定。

根据我在网上找到的信息以及这篇文章:将 IIS 站点的访问限制为 AD 组,我按如下方式配置了我的 web.config。我通过添加/删除功能启用了 Windows 身份验证,并且已设置 Web 应用程序目录的 NTFS 权限以允许访问本地组。

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.web>
         <authorization>
            <allow users="computer\SITE Read"/>
            <!-- <deny users="*"/> -->
         </authorization>
      </system.web>
</configuration> 

尽管如此,我仍然收到以下错误:

Error message 401.3: You do not have permission to view this directory or page using the credentials you supplied (access denied due to Access Control Lists). Ask the Web server's administrator to give you access to 

答案1

我找到了解决办法。

如果您要指定本地组,则需要说“角色”而不是“用户”

<allow roles="computer\SITE Read"/>

相关内容