Slowloris HTTP DoS 是一種低頻寬的 HTTP DoS 攻擊,
原理是發送不完整的 HTTP 請求封包, 並且傳送後續的 HEADER 使連線不中斷, 很快就可以把 Session 數佔滿,使得 Web Server 無法服務其他正常用戶, 只需要一台電腦, 跟少量的頻寬, 只要幾百Kbps, 甚至幾十Kbps
測試幾台 Apache Server, 都無招架之力, 一打就掛, 有裝 mod_limitipconn 也沒什麼用,
因為還沒到 mod 處理的階段, Server 也不會有任何 Log
目前想到的只有用 Per Host RatE Limiter 呼叫 iptables 來擋
有網友回應使用 mod_antiloris 可以擋, 測試之後的確可以
在 httpd.conf 加入以下設定後重啟
LoadModule antiloris_module modules/mod_antiloris.so
IPReadLimit 10
2013年10月18日 星期五
在Windows PHP安裝ffmpeg-php
關於在Windows內使用ffmpeg-php, 網路上有很多方法,
e.g. myownserver 在 How to install ffmpeg-php for Windows Apache HTTP Server 介紹安裝在xampp的方法, 從 http://sergey89.ru/files/ffmpeg-php/ 下載ffmpeg-php-5.3-win32-all.zip後, 逐步安裝後再用一支程式測試.
但是我是用AppServ + PHP 5.3.5 所以我用的方法
php.ini
首先解開之後, 先把 php_ffmpeg.dll 複製到 php5/ext內; php.ini 增加 一行
extension=php_ffmpeg.dll
http.conf
我不喜歡複製到 System32 , 所以我在 http.conf 增加下列幾行:
#php 5.3
之前就有的
Loadfile "C:\AppServ\php5\php5ts.dll"
Loadfile "C:\AppServ\php5\libpq.dll"
這次增加的
Loadfile "C:\AppServ\php5\ext\ffmpeg-php-5.3.1\avcodec-52.dll"
Loadfile "C:\AppServ\php5\ext\ffmpeg-php-5.3.1\avcore-0.dll"
Loadfile "C:\AppServ\php5\ext\ffmpeg-php-5.3.1\avdevice-52.dll"
Loadfile "C:\AppServ\php5\ext\ffmpeg-php-5.3.1\avfilter-1.dll"
Loadfile "C:\AppServ\php5\ext\ffmpeg-php-5.3.1\avformat-52.dll"
Loadfile "C:\AppServ\php5\ext\ffmpeg-php-5.3.1\avutil-50.dll"
Loadfile "C:\AppServ\php5\ext\ffmpeg-php-5.3.1\pthreadGC2.dll"
Loadfile "C:\AppServ\php5\ext\ffmpeg-php-5.3.1\swscale-0.dll"
phpinfo測試
測試ffmpeg.php
done.
2013年2月28日 星期四
Apache+PHP5 使用Mysql遇到的問題
Window 7 重灌後, 重拾PHP的專案, 啟動時遇到的問題, 在 Phpinfo 內怎樣都看不到MySql載入, php.ini 也都沒有設定錯, 查看 Apache 的 error.log 出現如下
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\AppServ\\php5\\ext\\php_mysql.dll' - The specified module could not be found.\r\n in Unknown on line 0
原因不是別的, 只是少了 libmysql.dll ;
把libmysql.dll複製一份到C:\Windows\System32就好了.
PS: 請注意你的libMySql.dll 的 版本與 php 相同.
訂閱:
文章 (Atom)

