我发布了一个 ClickOnce
应用程序。
应用程序从 MyApplication/MyApplication.application
下载并正确安装。
但是,如果他们访问 MyApplication/setup.exe
以自动安装先决条件然后运行该应用程序,他们将收到 403
。
403 - Forbidden: Access is denied. You do not have permission to view this directory or page using the credentials that you supplied.
在处理程序映射中,cgi-exe
被禁用。我添加了一个模块映射,如下所示:
Name: setup.exe
Path: setup.exe
State: Enabled
Path type: unspecified
Handler: StaticFileModule
Entry type: Local
Access required by the handler: Script
Specify verbs to be handled: all verbs
[Unchecked] Invoke handler only if request is mapped to...
应用程序池对该文件夹具有完全控制
,并在Application Pool Identity
上运行。
我错过了什么?
最佳答案
您可以在IIS日志中找到原因。
感谢 IIS 论坛上的 Lex Li。
关于c# - 为什么我会收到 403?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41788521/