LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 03-10-2004, 02:58 AM   #1
madunix
LQ Newbie
 
Registered: Oct 2003
Posts: 25

Rep: Reputation: 0
ADSL port mapping 25 110


my local network is connected to internet with dial-up DSL.
linux Gateway: eth0: 192.168.0.1, ppp0
Windows mail server(exchange): 192.168.0.200 port: 25 + 110

I want to enable my LAN users to send/receive emails
to/from "outside" by using iptables.
I use following rules but it doesn't work.
What do I need to add to my rules...
such as mapping for the real IP (6.5.4.3) on ports 25, 110 pointing the exchange server


Can any body help me in this issue?

Thanks



#!/bin/sh

modprobe ip_tables
echo "modprobe iptables"
modprobe ip_conntrack
echo "modprobe ip_conntrack"
modprobe ip_conntrack_ftp
modprobe ip_nat_ftp
echo "modprobe ip_conntrack_ftp"
modprobe iptable_nat
echo "modprobe iptable_nat"
#modprobe ipt_MASQUERADE
#echo "modprobe ipt_MASQUERADE"

iptables -X;
iptables -F;
echo "iptables -f"
iptables -t nat -F;
echo "iptables nat F"
iptables -t mangle -F;
echo "iptables mangle F"
#iptables -A FORWARD -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu
#iptables -A FORWARD -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --set-mss 1440
#iptables -A FORWARD -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --set-mss 1440
echo "SET MTU 1440"

iptables -t nat -A POSTROUTING -s 192.168.0.11 -o ppp0 -j SNAT --to 6.5.4.3
echo 1 > /proc/sys/net/ipv4/ip_forward
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
SSH on port 25 or 110 idahoakl Linux - Networking 7 11-13-2005 08:58 AM
Cannot telnet to port 110 Lostboys Linux - Newbie 11 04-19-2005 02:12 AM
telnet to site on port 110 mwmethe Linux - Networking 5 10-30-2004 09:43 AM
Turning off Firewall for Port 110? coffee9876 Linux - Security 1 10-14-2003 04:37 PM
changing port 110 jonfa Linux - Networking 3 03-03-2002 03:09 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:01 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration