如何禁用危險(xiǎn)的http方法,如TRACE,OPTIONSwindows 2008-2012: 請(qǐng)?jiān)趙wwroot目錄建立web.config,內(nèi)容如下,如果文件已經(jīng)存在,請(qǐng)?zhí)砑蛹t色部分 <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <security> <requestFiltering> <verbs allowUnlisted="true"> <add verb="OPTIONS" allowed="false"/> <add verb="TRACE" allowed="false"/> </verbs> </requestFiltering> </security> </system.webServer> </configuration> windows 2003: 控制面板-ISAPI篩選器-啟用自定義重寫組件,然后編輯/others/discuz/httpd.conf 如果您已有其他規(guī)則,請(qǐng)?zhí)砑拥降谝粭l規(guī)則 RewriteEngine on RewriteCond %{THE_REQUEST} ^(TRACE|OPTIONS) RewriteRule .* - [F] linux: 在wwwroot目錄下創(chuàng)建.htaccess文件,內(nèi)容如下,如果您已有其他規(guī)則,請(qǐng)?zhí)砑拥降谝粭l規(guī)則 RewriteEngine On RewriteCond %{REQUEST_METHOD} ^(TRACE|OPTIONS) RewriteRule .* - [F]
|
|||||
| >> 相關(guān)文章 | |||||
|
|
|||||