web.config ipSecurity的内部服务器错误 [英] Internal Server Error with web.config ipSecurity

查看:192
本文介绍了web.config ipSecurity的内部服务器错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我的web.config,其中包含一些用于阻止Ipaddress的标签

This is my web.config which has some tags for blocking Ipaddress

<configuration>
 <connectionStrings>
    ...
 </connectionStrings>
 <appSettings>
  ....
 </appSettings> 
 <runtime>
   ....
 </runtime>
  <system.webServer>
    <security> 
        <ipSecurity allowUnlisted="false"> 
            <clear/> 
             <add ipAddress="127.0.0.1" allowed="true"/>
             <add ipAddress="83.116.19.53" allowed="true"/> 
        </ipSecurity>  
    </security>
</system.webServer> 
</configuration>

我的目的是阻止除上述之外的任何其他IP。以上是我希望从中访问网站的唯一IP地址。但是使用ipSecurity标签我总是得到
500 - 内部服务器错误,没有它就可以正常运行。

My intention is to block any other IP except the above. The above is the only Ip address I want the website to be accessible from . But with "ipSecurity" tag I am always getting 500 - Internal server error and the site runs fine without it.

我确保IP和域限制已安装在服务器上。
如果我遗漏任何东西,请告诉我。
谢谢。

I have made sure that "IP and Domains Restrictions" are installed on the server. Please let me know if I am missing anything. Thank you.

推荐答案

您是手动编辑配置还是通过IIS管理器编辑?

Are you editing the config by hand or through IIS manager?

查看有关该错误消息的帖子,因为您可能没有启用功能委派

See this post about that error message as you may not have that feature delegation enabled

http://forums.asp.net/t/1220987.aspx

这篇关于web.config ipSecurity的内部服务器错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆