next up previous contents index
Next: Enabling Routing Up: Home Networking Previous: Private Networks   Contents   Index

Network Address Translation

Common switches provide network address translation (NAT), but for a few dollars less you can get one without that service. If you cannot NAT the addresses with a switch you can do it with your computer. Install two network cards and use ipchains to translate the addresses. Here are some lines you could use to translate addresses listed above:

-A forward -s -d -j MASQ
-A forward -s -d -j MASQ
-A forward -s -d -j MASQ

Just put these lines in the /etc/sysconfig/ipchains file. The next time you start ipchains the rules will be in effect. This is how you would restart ipchains:

bash# /etc/rc.d/init.d/ipchains stop
Flushing all chains:                                       [  OK  ]
Removing user defined chains:                              [  OK  ]
Resetting built-in chains to the default ACCEPT policy:    [  OK  ]
bash# /etc/rc.d/init.d/ipchains start
Flushing all current rules and user defined chains:        [  OK  ]
Clearing all current rules and user defined chains:        [  OK  ]
Applying ipchains firewall rules:                          [  OK  ]

Joseph Colton 2002-09-24