Blocking All Traffic from a
Particular IP
Trying to block all traffic from a particular IP on my network to my unix box. I've tried the following commands: iptables -A INPUT -s 192.168.0.6 -j DROP
When I view the iptables it says that it's blocked, but I am still able to ping and ssh into the unix box from 192.168.0.6. What am I doing wrong? Remember it matters where in the list of rules your 'drop' rules are positioned. If there is a rule earlier which is permitting the traffic, then those packets match there and are never tested against your 'drop' rule. move your 'drop' rule (the -s foo w/o -p tcp is sufficient) to the top: iptables -I INPUT 1 ... that's a cap 'i'. The -A arg appends on the end of the list. -c
Applying Firewalls to Block Sites Having internet in linux server which acts as gateway
for other windows and linux clients. I want to apply firewall in linux
server for blocking certain sites. What commands should I use to
block. I used this command for blocking some site say www.rediffmail.com
-
Above command does not work. even after applying we were able to open rediffmail from every client m/c. You may also want to do:
or possibly:
Have a Linux Problem
Linux Books
Linux Home: Linux System Administration Hints and Tips (c) www.gotothings.com All material on this site is Copyright.
|