關於 PHP, Linux, Open Source 及個人生活記載的網誌。
RSS icon
  • 隱藏 Apache 及 PHP 版本

    Posted on July 19th, 2006 Sam Tang 1 comment

    要將 Apache 及 PHP 的版本隱藏,可以用以下方法:

    Apache:
    開啟 httpd.conf,加入以下兩行:

    ServerTokens ProductOnly
    ServerSignature Off

    PHP:
    隱藏 PHP 版本就是隱藏 "X-Powered-By: PHP/5.1.2-1+b1" 這個,開啟 php.ini,加入:

    expose_php = Off

    完成以上兩個設定後,重新啟動 Apache 即可。


     

    One response to “隱藏 Apache 及 PHP 版本”

    1. [...] From:http://www.real-blog.com/linux-bsd-notes/197 [...]

    Leave a reply

    *
    To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
    Click to hear an audio file of the anti-spam word