<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class='hmmessage'>&gt; &gt; It's LAN  or Internet not both.<br><br>Does anyone know a specific reason for this?&nbsp; Just curious.......<br><br>&gt; Assuming he can set up a secondary address on his router, would it be feasible<br>&gt; for him to set up a second subnet on the LAN and then connect to the server<br>&gt; from that subnet ?<br>&gt; <br><br>I haven't tried that, but it's not a bad idea.&nbsp; The workaround I came up with isn't exactly pretty, but it works.&nbsp; I've had to add a few rules to my linux firewall script (using IPTABLES).&nbsp; I
already have rules in place which redirect traffic coming from the public internet to the Call of Duty 4 server.&nbsp; To make this work for internal clients I did the following: <br><br>1. Added rule which redirects traffic coming from the internal NIC, going to my public (external) IP address, on any of the Call of duty 4 ports back to the Call of duty server.&nbsp; (This essentially forwards the packet back off the same NIC - see next rule)<br><br>2. (NOTE: If the default policy in the forward chain is to drop packets, then you will need this next rule as well....)<br>Next I added a rule allowing packets to be forwarded in, and out the same (internal) NIC.&nbsp; <br><br>3. Next I added a rule to 'SNAT' (change the source address for) all packets which came from my internal subnet, leaving on the internal NIC to be translated with my server's external IP.&nbsp; This ensures that when the packets get to the COD4 server from the internal clients they have a source address that's a public internet IP address (my public IP).&nbsp; Also having a rule at the top which accepts RELATED,ESTABLISHED packets is essential to keep everything returning back to the clients properly.<br><br>Confusing??&nbsp; I think so.....&nbsp; Here's basically what I have in my firewall script (if this makes more sense).....<br>This basically assumes that you have a linux IPTABLES router/firewall already configured to forward packets across NICs, and that your (dedicated/internet) Call of Duty 4 server is on the same local subnet as one ore more clients who wish to connect.&nbsp; <br><br>====================================<br>#!/bin/sh<br>#Path to IPTABLES<br>IPTABLES="/sbin/iptables"<br>#Interface for the External NIC<br>OUTSIDE=eth1<br>#Interface for the Internal NIC<br>
INSIDE=eth0<br>#My external IP address<br>OUTSIDE_IP=xx.xx.xx.xx<br>#IP Address of my Call of Duty 4 server<br>COD=192.68.1.100<br><br># This ensures that all return packets go to the correct place.<br>$IPTABLES -t nat -A PREROUTING -m state --state RELATED,ESTABLISHED -j ACCEPT<br><br>#Here we're changing the destination address of packets coming in on the internal NIC,<br># going to the outside IP on any of the COD4 ports<br>$IPTABLES -t nat -A PREROUTING -i $INSIDE -p udp --dport 20800 -d $OUTSIDE_IP -j DNAT --to $COD<br>$IPTABLES -t nat -A PREROUTING -i $INSIDE -p udp --dport 20810 -d $OUTSIDE_IP -j DNAT --to $COD<br>$IPTABLES -t nat -A PREROUTING -i $INSIDE -p udp --dport 28960 -d $OUTSIDE_IP -j DNAT --to $COD<br>$IPTABLES -A FORWARD -i $INSIDE -o $INSIDE -j ACCEPT<br>
<br>#These are my existing rules which allow packets to be forwarded to the server from the outside <br># (public internet) - shown here for clarity....<br>$IPTABLES -t nat -A PREROUTING -i $OUTSIDE -p udp --dport 20800 -j DNAT --to $COD<br>$IPTABLES -t nat -A PREROUTING -i $OUTSIDE -p udp --dport 20810 -j DNAT --to $COD<br>$IPTABLES -t nat -A PREROUTING -i $OUTSIDE -p udp --dport 28960 -j DNAT --to $COD<br>$IPTABLES -A FORWARD -i $OUTSIDE -j ACCEPT<br><br>#Here we're changing the source address of packets going out on the internal NIC, which currently have a <br># source IP from the the internal (private) subnet range.<br>$IPTABLES -t nat -A POSTROUTING -s 192.68.1.0/255.255.255.0 -o $INSIDE -j SNAT --to $OUTSIDE_IP<br>===================<br><br>Hope this helps someone........&nbsp; Cheers!<br><br>-Rick<br><br /><hr />Share life as it happens with the new Windows Live. <a href='http://www.windowslive.com/share.html?ocid=TXT_TAGHM_Wave2_sharelife_012008' target='_new'>Start sharing!</a></body>
</html>