OpenVZ Forum


Home » General » HowTo » iptables Blocking for ALL VEs
Re: iptables Blocking for ALL VEs [message #1344 is a reply to message #1123] Tue, 07 February 2006 04:42 Go to previous message
phpfreak is currently offline  phpfreak
Messages: 47
Registered: January 2006
Member
to make life easier, I put this into /usr/local/sbin/vzdrop:

#!/bin/bash
iptables -A FORWARD -i eth0 -s $1 -j DROP
iptables -A FORWARD -i eth1 -s $1 -j DROP
iptables -A INPUT -i eth0 -s $1 -j DROP
iptables -A INPUT -i eth1 -s $i -j DROP


chmod +x /usr/local/sbin/vzdrop

Then to drop an IP:

vzdrop 65.252.39.146

And you've blocked the attacker.


[Updated on: Tue, 07 February 2006 04:42]

Report message to a moderator

 
Read Message
Read Message
Previous Topic: Debian template cache creation in 5 minutes
Next Topic: Bandwidth Accounting for VPS
Goto Forum:
  


Current Time: Wed Jul 17 12:36:28 GMT 2024

Total time taken to generate the page: 0.02841 seconds