Copyright © 2013 Weidmüller Interface GmbH & Co. KG
71 / 103
All rights reserved. Reproduction without permission is prohibited.
This document describes an application scenario using 3 Routers. But for a simple test of the feature “1:1 NAT”
you only need 1 Router (configured as Router 1 of machine network 1)
. In this case use 2 devices (PC’s or what-
ever) to simulate one member of “machine network” and one member of the “production network”.
Short description how to solve the task by using 1:1 NAT:
Both Routers of machine network 1 and 2 have to be connected by WAN port to the production network 172.16.1.0. The
IP addresses of the WAN ports will be set to
172.16.1.252 / 255.255.0.0 for Router 1 and
172.16.1.253 / 255.255.0.0 for Router 2
The LAN port of each Router is to be connected to their corresponding machine network. Due to the fact that each ma-
chine network uses the same IP address range each LAN port of the Routers is to be configured with 2 IP addresses,
one as a
public
and one as
private
address.
In this example
– using the feature 1:1 NAT at
LAN port
–
the
public
IP addresses will be set to
192.168.
20
.254 / 255.255.255.0
for Router 1 and
192.168.
21
.254 / 255.255.255.0
for Router 2
and the
private
IP addresses (both the same) will be set to
192.168.
1
.254 / 255.255.255.0
for Router 1 and
192.168.
1
.254 / 255.255.255.0
for Router 2
By assigning the
private
IP address (192.168.1.254) at the Router’s LAN port automatically the complete IP address
range 192.168.1.0 / 255.255.255.0 is defined as local network IP range for devices connected to the LAN port.
“1:1 NAT” means that for each communication between devices of LAN and WAN network the
public
IP addresses of
LAN devices have to be used.
How to configure Router 1 (Machine network 1), Router 2 (Machine network 2) and Router 3 (Production net-
work)
General note:
The configuration of all Routers is very similar and will be described below together for the Routers of both machine
networks and the production network. Different configuration parameters between the Routers are marked individually.
IP address and subnet of a
device connected to LAN port
(used as private IP address)
Configured
Private
IP address
and subnet of Router's LAN port
Configured
Public
IP address and
subnet of Router's LAN port
Resulting
Public
IP address and
subnet of device connected to
LAN port (1:1 NAT)
This IP address is known by devices
of WAN network
192.168.1.
100
/ 255.255.255.0
192.168.21.
100
/ 255.255.255.0
192.168.1.
101
/ 255.255.255.0
192.168.21.
101
/ 255.255.255.0
172.16.1.
101
/ 255.255.255.0
172.16.1.1 / 255.255.255.0
192.168.100.1 / 255.255.255.0
192.168.100.
101
/ 255.255.255.0
10.8.
1.10
/ 255.255.0.0
172.16.
1.10
/ 255.255.0.0
10.8.
2.10
/ 255.255.0.0
172.16.
2.10
/ 255.255.0.0
Note: In a class C network with subnet mask 255.255.255.0 only the last segment of an IP address is translated
Note: In a class B network with subnet mask 255.255.0.0 the last 2 segments of an IP address are translated
Examples of IP address mapping (private / public) using 1:1 NAT at LAN port
192.168.1.254 / 255.255.255.0
192.168.21.254 / 255.255.255.0
10.8.1.1 /
255.255
.0.0
172.16.1.254 /
255.255
.0.0
Subnets of private and public network must be the same