删除服务器响应标头 IIS 8.0/8.5 [英] Remove Server Response Header IIS 8.0 / 8.5

查看:42
本文介绍了删除服务器响应标头 IIS 8.0/8.5的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在 IIS 8.0/8.5 中删除服务器标头响应?
我当前的服务器报告:Microsoft-IIS/8.0Microsoft-IIS/8.5
对于 IIS 7.0,我使用了 URLScan 3.1,但是这只支持 IIS 7.0 而不是 8.x

解决方案

还有另一种解决方案,我认为这个解决方案是最好和安全的.

您可以使用微软创建的UrlRewrite 模块.Url Rewrite 模块重定向您的 url,还可以在响应标头中更改您的 IIS 服务器名称.

您不必使用重定向属性.您可以使用仅更改服务器标头值.

步骤如下:

  1. 首先,从这个链接下载 UrlRewrite 模块:

PS:我对其进行了测试,它在 IIS 服务器上对我有用.Visual Studio 尚未创建临时 IIS 服务器.

How can we remove the server header response in IIS 8.0/8.5?
My current server report: Microsoft-IIS/8.0 Microsoft-IIS/8.5
For IIS 7.0 I used the URLScan 3.1 however this is only supported for IIS 7.0 and not 8.x

解决方案

There is another solution and in my opinion this solution is the best and safe.

You can use UrlRewrite module created by the Microsoft. The Url Rewrite module redirects your url and can also change your IIS server name in the response header.

You don't have to use redirect property. You can use just change the Server header value.

Here are the steps:

  1. First, download UrlRewrite module from this link: http://www.iis.net/downloads/microsoft/url-rewrite and install it on your IIS server. After that, restart IIS by this command on cmd console

    iisreset /restart
    

  2. Add the following item to the your web config file under the <system.WebServer> tag. You can write anything to the Value item as server name.

  3. Finally we changed the IIS version name on the data's header. Restart IIS again. via cmd console.

  4. Bonus: If you want to test your website to see if it is working or not... You can use "HttpRequester" mozilla firefox plugin. for this plugin: https://addons.mozilla.org/En-us/firefox/addon/httprequester/

PS: I tested it and it worked for me on the IIS server. Not on the has been created temproray IIS server by the Visual studio.

这篇关于删除服务器响应标头 IIS 8.0/8.5的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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