[英]RequestFiltering value for http verbs in applicationhost.config can be overridden in my websites?
What will happen to my website when configure http [OPTIONS=true] in web.conig if http OPTIONS is already configured in applicationhost.config as [OPTIONS=false]?如果 http OPTIONS 已经在 applicationhost.config 中配置为 [OPTIONS=false],那么在 web.conig 中配置 http [OPTIONS=true] 时,我的网站会发生什么?
ApplicationHostFile => added http OPTIONS = false My website level web.config => adding http OPTIONS = true ApplicationHostFile => 添加 http OPTIONS = false 我的网站级别 web.config => 添加 http OPTIONS = true
Which one will take priority?哪一个会优先? & will get any issue [server error] while launching my website? & 在启动我的网站时会遇到任何问题 [服务器错误]?
[Ex: We will get error saying that "duplicate' not allowed if add http response header in applicationhost.config. So something like we will get any error for RequestFiltering http verbs when both file have same headers?] [例如:如果在 applicationhost.config 中添加 http 响应标头,我们将收到错误消息,提示“不允许重复”。因此,当两个文件具有相同的标头时,我们会收到 RequestFiltering http 动词的任何错误?]
If HTTP verbs configured in Applicatiohost.config file like,如果在 Applicatiohost.config 文件中配置了 HTTP 动词,例如,
<system.webServer>
<security>
<requestFiltering>
<verbs allowUnlisted="true" applyToWebDAV="true">
<add verb="OPTIONS" allowed="false" />
</verbs>
</requestFiltering>
</security>
</system.webServer>
this can be overridden in our website web.config section by configuring like,这可以在我们的网站 web.config 部分中通过配置来覆盖,
<system.webServer>
<security>
<requestFiltering>
<verbs>
<remove verb="OPTIONS" />
<add verb="OPTIONS" allowed="false" />
</verbs>
</requestFiltering>
</security>
</system.webServer>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.