[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details

IPTables External IP

Asked by randy915 in IP Tables/IP Chains, Linux Network Security

Tags: iptables, external ip, outbound

I have a cable modem on a different subnet (10.1.10.x).
I've enabled 1:1 NAT on the modem to map to 2 IPs:
>>> 99.99.99.90 goes to 10.1.10.2 (eth1 - red)
>>> 99.99.99.99 goes to 10.1.10.10 (eth1:0 - red alias)

All devices goes to a switch which then goes to my router/firewall's 192.168.1.1 (eth0 - green)

I have an Exchange server (192.168.1.254) which I want to give an exclusive external address (99.99.99.99) while the rest of my network is seen as (99.99.99.90).  How do I accomplish this via IPtables?  Right now all I have is this rule:

#!/bin/sh
# Used for private firewall rules

# 1:1 NAT
/sbin/iptables -t nat -A POSTROUTING -s 192.168.1.254 -j SNAT to-source 10.1.10.2

# See how we were called.
case "$1" in
  start)
        ## add your 'start' rules here
        ;;
  stop)
        ## add your 'stop' rules here
        ;;
  reload)
        $0 stop
        $0 start
        ## add your 'reload' rules here
        ;;
  *)
        echo "Usage: $0 {start|stop|reload}"
        ;;
esac

Thanks.
 
Loading Advertisement...
 
[+][-]03/30/09 05:28 PM, ID: 24024785Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]03/30/09 11:39 PM, ID: 24026222Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04/07/09 09:09 AM, ID: 24088858Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04/08/09 12:04 AM, ID: 24094529Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04/08/09 11:29 AM, ID: 24100316Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04/08/09 11:37 PM, ID: 24104576Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/15/09 07:23 AM, ID: 25105521Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091111-EE-VQP-89 - Hierarchy / EE_QW_3_20080625