概要 †
HTTPレスポンスヘッダに含まれるApacheなどのバージョン情報内容を、簡易なものに置き換えます。
手順 †
- <Apacheルート>/conf/httpd.confを開きます。
以下の設定を追加します。
1
2
| -
!
| ServerTokens Prod
|
- Apacheを再起動します。
1
|
| /etc/init.d/httpd restart
|
- HTTPレスポンスヘッダを確認します。
今回はlynxで確認しました。
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
| lynx -head -dump <URL>
HTTP/1.1 200 OK
Date: Wed, 08 Dec 2010 15:14:47 GMT
Server: Apache
Accept-Ranges: bytes
Cache-control: no-cache
Pragma: no-cache
Content-Type: text/html; charset=UTF-8
X-Pad: avoid browser bug
Vary: Accept-Encoding
Connection: close
[Server:]欄が「Apache」となっていれば成功です。
|
検証時の環境 †
参考 †