NAT & PAT Network Address Translation Port Address Translation
Why use NAT? Ability to use private addresses internally and still access the Internet RFC1918 addresses are not globally unique Ability to connect overlapping IP address space Not a security cure
NAT Characteristics Converts internal private address to configured public address that is routable Performed statically or dynamically Creates state table on connection Delete state table entry on disconnect With use of ACLs to prevent routing, can add to security profile, control traffic
NAT Applications Hardware and software firewalls Routers Proxy servers RAS server that is a simple router/firewall
NAT Configuration NAT(config)#access-list 1 permit NAT(config)#ip nat pool public netmask NAT(config)#ip nat inside source list 1 pool public-1 NAT(config)#interface fa 0/0 NAT(config-if)#ip nat inside NAT(config-if)#interface s 0/0 NAT(config-if)#ip nat outside
NAT Show IP nat translations Pro Inside global Inside local Outside local Outside global Show IP nat statistics
PAT Ip nat pool net Access-list 1 permit ip ip nat inside source list 1 pool net-1 overload Int f0/0 Ip nat inside Int s0/0 Ip nat outside NAT#show ip nat translations Pro Inside global Inside local Outside local Outside global Tcp : : : :4806 tcp : : : :4809 tcp : : : :4814 tcp : :
Your NAT configuration X = the second digit of your loopback IP address (config)#access-list 1 permit 1x (config)#ip nat pool public-1 21x x netmask (config)#ip nat inside source list 1 pool public-1 (config)#interface fa 0/0 (config-if)#ip nat inside (config-if)#interface s 0/0 (config-if)#ip nat outside
Testing NAT Extended ping from your loopback to a serial interface of your neighbor When ping works – Show ip nat translations