This will reject connections above 15 from one source IP.
iptables -A INPUT -p tcp --syn --dport 80 -m connlimit --connlimit-above 15 --connlimit-mask 32 -j REJECT --reject-with tcp-reset
In this 160 new connections (packets really) are allowed before the limit of 150 NEW connections (packets) per second is applied.
iptables -A INPUT -m state --state RELATED,ESTABLISHED -m limit --limit 150/second --limit-burst 160 -j ACCEPT
?? 이거는 뭔지 해석을..
# iptables -A INPUT -i eth0 -m string —algo bm —string "facebook.com" -j DROP
# iptables -A OUTPUT -m string —algo bm —string "facebook.com" -j DROP
# iptables -A FORWARD -i eth0 -m string —algo bm —string "facebook.com" -j DROP
iptables -A INPUT -p tcp --syn --dport 80 -m connlimit --connlimit-above 15 --connlimit-mask 32 -j REJECT --reject-with tcp-reset
In this 160 new connections (packets really) are allowed before the limit of 150 NEW connections (packets) per second is applied.
iptables -A INPUT -m state --state RELATED,ESTABLISHED -m limit --limit 150/second --limit-burst 160 -j ACCEPT
?? 이거는 뭔지 해석을..
# iptables -A INPUT -i eth0 -m string —algo bm —string "facebook.com" -j DROP
# iptables -A OUTPUT -m string —algo bm —string "facebook.com" -j DROP
# iptables -A FORWARD -i eth0 -m string —algo bm —string "facebook.com" -j DROP
iptables -I FORWARD -m string --string "facebook.com" --algo bm --from 1 --to 600 -j REJECT
참고로, l7-filter는 세션 첫 10개 패캣 또는 2kB(최대64kB)만 검색합니다. 그 이후는 매칭이 안되죠.
댓글
댓글 쓰기