/* HINT: Search archives @ http://www.indyramp.com/masq/ before posting! 
/* ALSO: Don't quote this header. It makes you look lame :-) */


Hi,

I am not sure if this is the right forum for this, but I have to give a shot
since I have spent several days trying to figure out what to do...

So here is the setup:

I have ADSL-router (IP-address 10.xxx.yyy.153), which is a small hub. My ISP
gave me IP-addresses 10.xxx.yyy.154 - 10.xxx.yyy.158, thus I have 5 static
IP's.

I have a Linux server (with 2.4.6 and IP-tables and stuff) with two Ethernet
cards and two other machines. Here are all the addresses:

ADSL-Router:       10.xxx.yyy.153
Linux (ADSL-side): 10.xxx.yyy.155 eth1  (Has default GW 10.xxx.yyy.153)
Linux (LAN-side):  192.168.0.1    eth0
Machine#1:         192.168.0.100        (Has default GW 192.168.0.1)
Machine#2:         192.168.0.101        (Has default GW 192.168.0.1)

What I want to do is to make Machine#1 look to the ADSL router as IP-address
10.xxx.yyy.156 and Machine#2 look as 10.xxx.yyy.157.

I have been able make this setup work which means that I am able browse Web and
was able to play Starcraft in BNet from Machine#1 or Machine#2 but I still
cannot host a game. I tried to find out why by logging the packets and using
tcpdump, and I found out that packets that came to the Starcraft-host were
directed to INPUT-chain and not to FORWARD-chain as I was expecting them to.

Here are my scripts:
----------------------------------------------------------------------------
IT=/usr/local/sbin/iptables
# Make the Linux to respond to ARP (this setup didn't work without this!)
ip address add 10.xxx.yyy.156 dev eth1
ip address add 10.xxx.yyy.157 dev eth1

$IT -t nat -A POSTROUTING -o eth1 -j SNAT -s 192.168.0.100 --to 10.xxx.yyy.156
$IT -t nat -A POSTROUTING -o eth1 -j SNAT -s 192.168.0.101 --to 10.xxx.yyy.157

$IT -A FORWARD -j ACCEPT -i eth1 -d 192.168.0.0/24 -p tcp --dport 4000
$IT -A FORWARD -j ACCEPT -i eth1 -d 192.168.0.0/24 -p udp --dport 4000
$IT -A FORWARD -j ACCEPT -i eth1 -d 192.168.0.0/24 -p tcp --dport 6112:6119
$IT -A FORWARD -j ACCEPT -i eth1 -d 192.168.0.0/24 -p udp --dport 6112:6119

$IT -A FORWARD -j ACCEPT  -o eth1 -s 192.168.0.0/24
----------------------------------------------------------------------------

Thanks in advance!




=====
- Riku

--------------------------------------------------------------------------------
Time is fun when you are having flies
                                   - Kermit the Frog
--------------------------------------------------------------------------------

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/

_______________________________________________
Masq maillist  -  [EMAIL PROTECTED]
Admin requests can be handled at http://www.indyramp.com/masq-list/ -- 
THIS INCLUDES UNSUBSCRIBING!
or email to [EMAIL PROTECTED]

PLEASE read the HOWTO and search the archives before posting.
You can start your search at http://www.indyramp.com/masq/
Please keep general linux/unix/pc/internet questions off the list.

Reply via email to