Sponsored Content
Special Forums IP Networking howto start with gateway / router / masquerading Post 302342948 by Zykl0n-B on Tuesday 11th of August 2009 06:16:01 AM
Old 08-11-2009
Code:
Second, I understand that this means no limitation, no control and no secutity at all in the network traffic

Oh yeah, netfilter/iptables means packets limitation, traffic control and high security for the network.

The only device that is able to interconnect two logical networks is a router, so you want to interconnect three networks, then what you need is a router.

With iptables you can easily set up a router/firewall device for your network. It's included with Linux, so you don't have to pay or download anything at all.

What i understand of your needs is to set cassiopeia host to do something like this:

Image
So, if i'm right you'll need three network interfaces and the problem is solved, here is how you must set iptables to make this work:


Code:
echo 1 >/proc/sys/net/ipv4/ip_forward
echo 0 >/proc/sys/net/ipv4/conf/all/send_redirecs
iptables -t nat -F
iptables -F
iptables -X
iptables -Z
iptables -A INPUT ACCEPT
iptables -A OUTPUT ACCEPT
iptables -A FORWARD ACCEPT
 
iptables -t nat -A POSTROUTING -s 172.16.199.0/24 -o eth0 -j MASQUERADE
iptables -t nat -A POSTROUTING -s 172.16.70.0/24 -o eth1 -j MASQUERADE
iptables -t nat -A POSTROUTING -s 192.168.1.0/25 -o eth2 -j MASQUERADE

I think this should work,
best regards
Zykl0n-B
 

4 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Remote Unix printing to my WinXP works with no router. How can I make it work through my router?

I set up remote printing on a clients Unix server to my Windows XP USB printer. My USB printer is connected directly to my PC (no print server and no network input on printer). With my Win XP PC connected to my cable modem (without the router), i can do lp -dhp842c /etc/hosts and it prints. I... (7 Replies)
Discussion started by: jmhohne
7 Replies

2. Linux

GNUGK-How to setup static gateway to gateway routing

Dear Sir I am a newbie in the world of IP telephony. I have been working with Asterisk PBX (SIP) and Cisco Call Manager (MGCP) but now I am learning on how to work GNUGK for H.323 Gatekeeper. I am having a problem, configuring static call routing on GNUGK in the section ... (0 Replies)
Discussion started by: mfondoum
0 Replies

3. UNIX for Beginners Questions & Answers

Inconsistency between RedHat 6.5 global gateway and single gateway leads to loss of default gateway

Dear friends I use RedHat 6.5, which sets the gateway in the configuration file / etc / sysconfig / network as GATEWAY = 192.168.1.26, and the gateway in the configuration file / etc / sysconfig / network-scripts / ifcfg-eth11 as GATEWAY = 192.168.1.256. The two gateways are different.... (6 Replies)
Discussion started by: tanpeng
6 Replies

4. UNIX for Beginners Questions & Answers

Howto auto boot SPARC | How to auto supply "start /SYS" and "start /SP/console" commands

When I power ON my T4-1, I got a prompt -> where I have to start /SYS and start /SP/console. How can I auto supply these two commands ? (3 Replies)
Discussion started by: z_haseeb
3 Replies
IPTABLES-SAVE(8)                                                  iptables 1.6.1                                                  IPTABLES-SAVE(8)

NAME
iptables-save -- dump iptables rules to stdout ip6tables-save -- dump iptables rules to stdout SYNOPSIS
iptables-save [-M modprobe] [-c] [-t table] ip6tables-save [-M modprobe] [-c] [-t table] DESCRIPTION
iptables-save and ip6tables-save are used to dump the contents of IP or IPv6 Table in easily parseable format to STDOUT. Use I/O-redirect- ion provided by your shell to write to a file. -M, --modprobe modprobe_program Specify the path to the modprobe program. By default, iptables-save will inspect /proc/sys/kernel/modprobe to determine the exe- cutable's path. -c, --counters include the current values of all packet and byte counters in the output -t, --table tablename restrict output to only one table. If not specified, output includes all available tables. BUGS
None known as of iptables-1.2.1 release AUTHORS
Harald Welte <laforge@gnumonks.org> Rusty Russell <rusty@rustcorp.com.au> Andras Kis-Szabo <kisza@sch.bme.hu> contributed ip6tables-save. SEE ALSO
iptables-apply(8),iptables-restore(8), iptables(8) The iptables-HOWTO, which details more iptables usage, the NAT-HOWTO, which details NAT, and the netfilter-hacking-HOWTO which details the internals. iptables 1.6.1 IPTABLES-SAVE(8)
All times are GMT -4. The time now is 09:04 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy