NAT

What is NAT

 With the rapid growth of the Internet, the problem of IP address exhaustion has emerged and several solutions have been developed to deal with it. One solution is NAT (Network Address Translation).

 NAT allows you to convert private IP addresses that can only be used on your premises to global IP addresses that can be used on the Internet. By doing so, devices assigned private IP addresses can transparently access the Internet.

Without NAT, devices with private IP addresses cannot access the Internet.

 It is no longer difficult to obtain global IP addresses for the number of terminals. By using NAT, private IP addresses can be assigned to terminals in individual companies and homes, and connections to the Internet can be provided by converting them to acquired global IP addresses.

There are three methods of NAT:

  • Static NAT
  • Dynamic NAT
  • IP Masquerade (NAPT)

 ”Static NAT” where the correspondence between private IP addresses and global IP addresses is always 1:1, and “Dynamic NAT” where private IP addresses and global IP addresses are corresponded 1:1 in the pool of prepared global IP addresses. , there is “IP masquerading” that allows multiple terminals with local IP addresses to communicate simultaneously with one global IP address by managing TCP/UDP ports.

Even inexpensive broadband routers support this NAT function.

 Before configuring NAT settings, you should be familiar with the NAT terminology in the table below. I think it’s confusing and hard to remember, but let’s understand this name and the difference!

typemeaning
internal local addressPrivate IP address used in LAN
internal global addressIP address used outside. A global IP address, usually obtained from your ISP.
external local addressThe IP address to the outside that is the destination within the LAN
external global addressGlobal IP address obtained by the communication partner. Normally, the outside global address and the outside local address are the same.

NAT translation is based on the translation of internal local addresses and external local addresses.

Local ・・・ LAN
Global ・・・ Internet

Internal ・・・
Source External・・・ Destination

It may be easier to understand if you think about it.

NAT type

There are three methods of NAT:

  • Static NAT
  • Dynamic NAT
  • IP Masquerade (NAPT)

Static NAT

 ”Static NAT” is a method in which private IP addresses and global IP addresses are always mapped one-to-one. It is used when you always want to fix the correspondence between the IP address and the global IP address.

 With static NAT, local terminals can only connect to the outside (Internet) for the number of global IPs provided.

Dynamic NAT

 ”Dynamic NAT” is a one-to-one correspondence between a private IP address and one global IP address from a pool of prepared global IP addresses.

In the example above, the pool’s range of 200.1.1.1 to 200.1.1.20 will be converted to internal global addresses.

IP Masquerade (NAPT)

 ”IP Masquerade (NAPT)” manages TCP/UDP ports so that multiple terminals with local IP addresses can communicate simultaneously with a single global IP address.

“IP Masquerading (NAPT)” is called “PAT (Overloading)” by Cisco.

* Here, the source port number and the converted port number are the same for ease of understanding, but they may differ.