尝试两级身份验证

本文关键字:两级 身份验证 | 更新日期: 2023-09-27 18:37:18

使用 ASP.NET - 尝试使用表单身份验证和 Windows 身份验证添加两级身份验证。

只是跟随迈克在http://mvolo.com/iis-70-twolevel-authentication-with-forms-authentication-and-windows-authentication/工作

他要求我们做的第一件事:

1. Unlock the <anonymousAuthentication> and <windowsAuthentication> configuration sections before you can use them in web.config:
> %windir%system32inetsrvappcmd unlock config /section:anonymousAuthentication
> %windir%system32inetsrvappcmd unlock config /section:windowsAuthentication

我似乎找不到这样做的地方。他指的是web.config文件吗?还是编辑 machine.config 文件?在Windows/Microsoft.NET/Framework64/etc...文件夹

请告知

尝试两级身份验证

这些是命令,因此您可以在命令提示符下运行它们。点击键盘上的 Win R,然后输入cmd并单击确定。这将打开命令提示符。然后输入第一个命令并按回车键,然后输入第二个命令并按回车键。

也许这是一个复制/粘贴错误,但您似乎缺少目录路径之间的反斜杠。请确保在运行命令时包含这些内容。