Find the answer to your Linux question:
Results 1 to 2 of 2
I am currently runing iptables & masaqurading to share my Internet connection accross my internal network. I have no trouble remotly conecting to ports 80,21,22, etc ..... However when setting ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Mar 2003
    Posts
    1

    Opening port 25 in IPTABLES


    I am currently runing iptables & masaqurading to share my Internet connection accross my internal network. I have no trouble remotly conecting to ports 80,21,22, etc ..... However when setting up SENDMAIL i have found that port 25 is closed (treid to telnet there) I added the 2 lines (eth1 = external)
    iptables -A INPUT -p tcp -i eth1 --dport 25 -j ACCEPT #Open smtp
    iptables -A INPUT -p udp -i eth1 --dport 25 -j ACCEPT
    This is the chain listed
    Chain INPUT (policy ACCEPT)
    target prot opt source destination
    ACCEPT tcp -- anywhere anywhere tcp dpt:smtp
    ACCEPT udp -- anywhere anywhere udp dpt:smtp

    Chain FORWARD (policy DROP)
    target prot opt source destination
    ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
    ACCEPT all -- anywhere anywhere
    LOG all -- anywhere anywhere LOG level warning

    Chain OUTPUT (policy ACCEPT)
    target prot opt source destination

    Now with this i would of expected to get through but i still can't telnet to port 25 ??? Can anyone tell me wherei am going wrong ?

  2. #2
    Linux Engineer
    Join Date
    Jan 2003
    Location
    Lebanon, pa
    Posts
    994
    You can just flush your input table. The default policy is set to ACCEPT.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •