我安装了 IIS URL Rewrite 2.0
并添加了一个规则将所有的http链接重定向到https。下面是我的 Web.Config
代码:
<rewrite>
<rules>
<rule name="REdirect To HTTPS" stopProcessing="true">
<match url="(.*)" />
<conditions>
<add input="{HTTPS}" pattern="^OFF$" />
</conditions>
<action type="Redirect" url="https://{HTTP_HOST}/{R:1}" redirectType="SeeOther" />
</rule>
</rules>
</rewrite>
一切看起来都很好。但是当我使用http访问我的网站时,它会抛出403错误。
403 - Forbidden: Access is denied.
You do not have permission to view this directory or page using the credentials that you supplied.
在 IIS 7.5 中启用了 TLS 1.0。
我在哪里可以获取关于403错误的更多信息?
redirectType = "Found"
或"Permanent"
。 - techspider