NAT 10 Lab Tasks
NAT 10 Lab Tasks
Lab 10
NAT Configuration
Objective
In this lab, static Network Address Translation (NAT) and dynamic NAT are conf igured.
Scenario
The International Travel Agency needs approximately 100 private IP addresses translated in a one-
to-one f ashion with a pool of public IP addresses. To do this, ITA will use NAT translation with a
portion of its class C address space allocated by ISP1.
Step 1
Build and conf igure the network according to the diagram.
Use ping to test connectivity between the NAT and ISP1 routers, between the workstations and the
def ault gateway, and between WebServer and ISP1.
Step 2
Since no routing protocol will be enabled, conf igure a def ault route to the Internet on the NAT router:
Step 3
Create a standard Access Control List that def ines all Internal Users:
Step 4
In this step, conf igure private and public address spaces to be used f or NAT and conf igure the
translation:
The public address space 200.200.100.128/25 will be used as a pool to provide NAT translation f or
the private IP addresses. To statically map the Internal User with IP address 192.168.1.2 pictured in
the diagram, enter the f ollowing command
This static mapping has the advantage of allowing “external” users to always access the host
192.168.1.2 by way of the f ixed IP address 200.200.100.252 (in addition to letting the 192.168.1.2
Internal User access the Internet). On the down side, this external accessibility is also viewed as a
security vulnerability. To allow the other hosts on the internal (private) network to reach the Internet,
translations will need to be made f or those hosts as well. A list of static translations could be made
one by one, but a simpler alternative is to conf igure a pool of addresses and let the router make one-
to-one dynamic NAT translations f or these hosts. For example, to map the non-statically mapped
hosts in the 192.168.1.0/24 network to public IP addresses in the range 200.200.100.129
to200.200.100.250, proceed as f ollows:
This provides a dynamic one-to-one NAT translation between public IP addresses in the “public” pool
and private IP addresses specif ied by access list 1. The Internal Users IP addresses are conf igured
independently of the NAT translation. Dynamic NAT translations are made f or any internal hosts f or
which no static translation has been def ined. The conf iguration above reserves IP addresses
200.200.100.251 to 200.200.100.254 f or use in f urther static NAT mappings. Static translations are
of ten used with an internal server to enable external access to it by way of a f ixed external IP.
Now, designate the inside NAT interf ace and the outside NAT interf ace. In more complex topologies,
it is possible to have more than one inside NAT interf ace.
Step 5
NAT(config)#interface fastethernet 0/0
NAT(config-if)#ip nat inside
NAT(config-if)#interface serial 0/0
NAT(config-if)#ip nat outside
There are several show commands that can be used to see if NAT is working: show ip nat
translations, show ip nat statistics, and show ip nat translations verbose.
From the two Internal User workstations, ping WebServer (200.200.50.2). Then check that
WebServer is accessible by connecting f rom an Internal User workstation using a browser with the
WebServer IP address, 200.200.50.2. Issue the three NAT show commands listed above on the NAT
router. Sample outputs are shown below.
Notice that the Internal User with IP address 192.168.1.5 had its address dynamically translated to
200.200.100.129, the f irst available address in the “public” pool. The command clear ip nat
translation * can be used to clear all dynamic NAT translatio ns :
0.0.0.0 0.0.0.0 : This represents the destination IP address and subnet mask. In this context,
0.0.0.0 with a subnet mask of 0.0.0.0 signifies the default route. It means that any traffic that
doesn't match a more specific route in the routing table will be directed to the next-hop specified.
200.200.100.2 : This is the next-hop IP address. It indicates that any traffic not matching a more
specific route should be sent to the device with the IP address 200.200.100.2 .