Hi Rohit On Tue, Mar 31, 2009 at 1:16 PM, Rohit khaladkar <rohit.khaladkar@xxxxxxxxx> wrote: > Hi All,As a security measure, I need to block port 1521on the database > server , which is used by Oracle for all machines, except one.I tried using > the following commands to block the port, but for some reason it is not > working.Can someone please help me. > > > iptables -A INPUT -s $1 -p tcp --dport 1521 -j ACCEPT > iptables -A INPUT -p tcp --dport 1521 -j DROP > > where $1 is the machine name or ip address of the machine which needs access > to the port. try with this rule iptables -A INPUT -s ! $1 -p tcp --dport 1521 -j REJECT/DROP this is an except rule ! except this machine all would be denied to access 1521 port !!! Just reply me back if this works for you Thanks Vijay > -- > redhat-list mailing list > unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe > https://www.redhat.com/mailman/listinfo/redhat-list > -- ~~~ 0Pen ~~~ S0uRce ~~~ -- redhat-list mailing list unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe https://www.redhat.com/mailman/listinfo/redhat-list