Nat Configuration PAT - devinziegler/Devin-Tech-Journal GitHub Wiki
PAT or Port Address Translation is a type of NAT that is often referred to as many to one. In out class lab, we were tasked with configuring PAT for six clients using private addresses that need to access a server on another network. Many of the same steps to configuring NAT are taken plus more to configure PAT.
- Assigning inside interface:
ip nat inside
- Assigning outside interface:
ip nat outside
Creating an address pool is a crucial step when configuring PAT. This is the address that all private IPs in the network will be translated too (Many to One).
Create the pool
ip nat pool <pool_name> <first_ip> <last_ip> netmask <netmask>
Example:
nat pool test 30.0.0.120 30.0.0.120 netmask 255.0.0.0
The access list defines what internal IPs can be translated. Use the following command:
access-list <access_list_number> permit <internal_network_to_translate>.<wildcard_subnet>
Example:
access-list 1 permit 192.168.0.0 0.0.0.255
This bridges the first two command into one rule that allows the internal interface to be translated via the pool and access list. In this case, the overload flag states that the IP can be used by many clients.
nat inside source list <list_number> pool <pool_name> overload
Example:
nat inside source list 1 pool test overload
To verify that PAT is functioning as intended the following command can be run to show the NAT table. This table keeps track of connections that have been translated.
ip nat translations