Thursday, August 6, 2020

HTTP Flood & DDoS Filter via Nginx


Try adding something like the following directives to your nginx config to prevent HTTP Flooding & Distributed Denial of Service (DDoS) :

http {
	limit_conn_zone $binary_remote_addr zone=conn_limit_per_ip:10m;
	limit_req_zone $binary_remote_addr zone=req_limit_per_ip:10m rate=5r/s;

	server {
		limit_conn conn_limit_per_ip 10;
		limit_req zone=req_limit_per_ip burst=10 nodelay;
	}
}



NOTE: http://www.botsvsbrowsers.com/details/504401/index.html says the above user agent is not a known bot



Previous Post
Next Post

0 komentar: