Professional Documents
Culture Documents
NAT
Private Addressing
4
Network Address Translation
E0 S1
10.1.1.1 165.193.3.1
SA SA
10.1.1.11 165.193.1.35
Internet
Inside Host
10.1.1.11
NAT Table
•NAT table records inside to outside mappings.
List of situations when NAT is used
• When you need to connect the Internet and your host don’t have
globally unique IP addresses
• When you’ve changed to a new ISP that requires you to renumber
your network
• When you need to merge two intranets with duplicate addresses
List of situations when NAT is used
When you need to connect the Internet and your host don’t have
globally unique IP addresses
8
List of situations when NAT is used
Private Public
Address Address
128.143.71.21
10.0.1.2
128.195.4.120
9
Inside & Outside Addresses
NAT
Local Address
• IP address of an internal or e0 e1
external host as it appears in the 10.1.1.1 165.193.3.1
internal IP header.
Global Address Internal External
Network Network
• IP address of an internal or
external host as it appears on
the external IP header.
SA DA
Destination
Internal Header 10.1.1.11 165.193.3.2 Local Host
Host
External Header 165.193.3.3 165.193.3.2 10.1.1.11
165.193.3.2
IP Header Translation
Inside Host
10.1.1.11
Configure Static Nat
• As an inbound packet
Inside Local Inside Global
enters the NAT router IP Address IP Address
10.0.0.110 204.168.1.33
address.
Configure Dynamic Nat
• Define a pool of global addresses to be allocated as
needed.
router(config)# ip nat pool pool-name start-
ip end-ip netmask netmask
• Define a standard access list to identify which hosts will be
translated.
router(config)# access-list number permit
network mask
• Establish dynamic source translation, identifying the
access list defined in the previous step.
router(config)# ip nat inside source list
access-list-num pool pool-name
• Identify interfaces as inside or outside with regard to NAT.
router(config-if)# ip nat {inside|outside}
Sample Dynamic NAT Configuration
1
3
4
2
Confirming NAT Operation
Static
Dynamic
Port Address Translation
Port Address Translation (PAT)
192.168.1.33:1743
multiple inside addresses 192.168.1.33:4376
to a single globally
routable address. 192.168.1.33:1103
• Sometimes called
10.0.0.111:1103
overloading.
NAT Overload
• The PAT router keeps track of the different conversations by mapping TCP
and UDP port numbers in the NAT table.
Overloading NAT
• Assign this access list to the NAT pool and set it for overload
4
3