Skip to contentSkip to conversation

Vijay - port 25 to be blocked

DISCUSSION Eric Ellis 1 participant 1 message Dec 28, 2004 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): 20041228170317.34EE82BBF8@tharbad

Eric Ellis

author
#1 lore raw
Quoted 10 lines · Vijay Kumar

Hi,

I want to allow my internal network to only connect to some specific email servers.
Apart from these mail server I want to block port 25 and 110 from my internal network to anywhwere. I am doing the following :

iptables -I INPUT -I eth0 --dport 25 -d !<ip addr of mail server> -j REJECT

Quoted 9 lines

This does not seem to block the port 25 traffic. Where am I going wrong?

Kindly help.

Regards,
Vijay Kumar

Lemme try this again,

I believe that this needs to be in the "forward" table, not the "input" table.

IIRC, Input is just for traffic destined to the firewall box itself, the mail servers that you're talking to are on the far side of the firewall, if I read you correctly.