Network Address Translation
(NAT)
Ahmed O. Alazzawi
Private Network
• Private IP network is an IP network that is not
directly connected to the Internet
• IP addresses in a private network can be assigned
arbitrarily.
– Not registered and not guaranteed to be globally
unique
• Generally, private networks use addresses from
the following experimental address ranges (non-
routable addresses):
– 10.0.0.0 – 10.255.255.255
– 172.16.0.0 – 172.31.255.255
– 192.168.0.0 – 192.168.255.255
Private Addresses
H1
R1
H2
10.0.1.3
10.0.1.1
10.0.1.2
H3
R2
H4
10.0.1.310.0.1.2
Private network 1
Internet
H5
10.0.1.1
Private network 1
213.168.112.3
128.195.4.119 128.143.71.21
3
Network Address Translation (NAT)
• A short term solution to the problem of the depletion of IP addresses
– Long term solution is IP v6
– CIDR (Classless InterDomain Routing ) is a possible short term
solution
– NAT is another
• NAT is a way to conserve IP addresses
– Can be used to hide a number of hosts behind a single IP address
– Uses private addresses:
• 10.0.0.0-10.255.255.255,
• 172.16.0.0-172.32.255.255 or
• 192.168.0.0-192.168.255.255
4
Network Address Translation (NAT)
• NAT is a router function where IP addresses (and possibly
port numbers) of IP datagrams are replaced at the boundary
of a private network
• NAT is a method that enables hosts on private networks
to communicate with hosts on the Internet
• NAT is run on routers that connect private networks to the
public Internet, to replace the IP address-port pair of an IP
packet with another IP address-port pair.
5
Basic Operation of NAT
• NAT device has address translation table
• One to one address translation
6
IP Masquerading
• Also called: Network address and port
translation (NAPT), port address translation (PAT).
• Scenario: Single public IP address is mapped to
multiple hosts in a private network.
• NAT solution:
– Assign private addresses to the hosts of the corporate
network
– NAT device modifies the port numbers for outgoing
traffic
7
IP Masquerading
8
Load Balancing of Servers
• Scenario: Balance the load on a set of identical
servers, which are accessible from a single IP
address
• NAT solution:
– Here, the servers are assigned private addresses
– NAT device acts as a proxy for requests to the
server from the public network
– The NAT device changes the destination IP
address of arriving packets to one of the private
addresses for a server
– A sensible strategy for balancing the load of the
servers is to assign the addresses of the servers in
a round-robin fashion.
9
Load Balancing of Servers
10
Configuring NAT with iptables
• First example:
iptables –t nat –A POSTROUTING –s 10.0.1.2
–j SNAT --to-source 128.143.71.21
• Pooling of IP addresses:
iptables –t nat –A POSTROUTING –s 10.0.1.0/24
–j SNAT --to-source 128.128.71.0–
• 128.143.71.30
• ISP migration:
iptables –t nat –R POSTROUTING –s 10.0.1.0/24
–j SNAT --to-source 128.195.4.0–
128.195.4.254
• IP masquerading:
iptables –t nat –A POSTROUTING –s 10.0.1.0/24
–o eth1 –j MASQUERADE
• Load balancing:
iptables -t nat -A PREROUTING -i eth1 –
j DNAT --to-destination 10.0.1.2-10.0.1.4
11
NAT Summary
• NAT provides transparent and bi-directional connectivity
between networks having arbitrary addressing schemes
• NAT eliminates costs associated with host renumbering
• NAT conserves IP addresses
• NAT eases IP address management
• NAT enhances network privacy
NAT Limitations
• Applications with IP-address content
– Need AGL (Application Level Gateway)
• Applications with inter-dependent control
and and data sessions
• Translation of fragmented FTP control
packets

More Related Content

PPTX
System interconnect architecture
PPT
Microprocessor 80386
PPTX
Subnetting Presentation
PPTX
Mobility Management
PDF
Displacement addressing
PPTX
Addressing modes
PPT
system interconnect architectures in ACA
PDF
MPLS Presentation
System interconnect architecture
Microprocessor 80386
Subnetting Presentation
Mobility Management
Displacement addressing
Addressing modes
system interconnect architectures in ACA
MPLS Presentation

What's hot (20)

PPTX
Sonet (synchronous optical networking )
PDF
Lecture 1 introduction to parallel and distributed computing
PPTX
Timing and control
DOCX
8086 pin diagram description
PPT
Integrated services digital network (isdn)
PDF
Pipelining and ILP (Instruction Level Parallelism)
PDF
Introduction to IPv6
PPTX
Accessing I/O Devices
PDF
QoS Cheatsheet by packetlife.net
PPTX
Branching instructions in 8086 microprocessor
PPT
Fisheye State Routing (FSR) - Protocol Overview
PPTX
Cloud File System with GFS and HDFS
PPTX
Flag Registers (Assembly Language)
PPT
Case study windows
PDF
Mobile computing (Wireless) Medium Access Control (MAC)
PPT
PPTX
Computer organization and architecture
PPT
Divide and conquer
Sonet (synchronous optical networking )
Lecture 1 introduction to parallel and distributed computing
Timing and control
8086 pin diagram description
Integrated services digital network (isdn)
Pipelining and ILP (Instruction Level Parallelism)
Introduction to IPv6
Accessing I/O Devices
QoS Cheatsheet by packetlife.net
Branching instructions in 8086 microprocessor
Fisheye State Routing (FSR) - Protocol Overview
Cloud File System with GFS and HDFS
Flag Registers (Assembly Language)
Case study windows
Mobile computing (Wireless) Medium Access Control (MAC)
Computer organization and architecture
Divide and conquer
Ad

Similar to network address translate (20)

PDF
Module17 nat v2
PPT
network address translation and ip masquerading
PPTX
Network address translation
PPTX
networkaddresstranslation-160909142440.pptx
PPTX
03 coms 525 tcpip - ip address
PPTX
8-Lect_8 Addressing the Network.tcp.pptx
PPTX
Topic 2.3 network addressing for tcpip
PPT
PPTX
Computer Networking: A Top-Down Approach
PPTX
Learning series fundamentals of Networking and Medical Imaging
PPTX
CCN CEP.pptx
PPTX
Week1-Chapter1.pptx Next Generation Networks
PPTX
70-410_r2_lecture_slides_lehjhjkhjkhjhkjhjkhkjsson_10.pptx
PPTX
Configuring IPv4 and IPv6 Addressing to STEM
PPT
Classless Interdomain Data Routing CIDR.ppt
PDF
MULTIMEDIA COMMUNICATION & NETWORKS
PPT
Mcts chapter 8
PDF
Successes and Challenges of IPv6 Transition at APNIC
PPT
PPT
IP Address
Module17 nat v2
network address translation and ip masquerading
Network address translation
networkaddresstranslation-160909142440.pptx
03 coms 525 tcpip - ip address
8-Lect_8 Addressing the Network.tcp.pptx
Topic 2.3 network addressing for tcpip
Computer Networking: A Top-Down Approach
Learning series fundamentals of Networking and Medical Imaging
CCN CEP.pptx
Week1-Chapter1.pptx Next Generation Networks
70-410_r2_lecture_slides_lehjhjkhjkhjhkjhjkhkjsson_10.pptx
Configuring IPv4 and IPv6 Addressing to STEM
Classless Interdomain Data Routing CIDR.ppt
MULTIMEDIA COMMUNICATION & NETWORKS
Mcts chapter 8
Successes and Challenges of IPv6 Transition at APNIC
IP Address
Ad

Recently uploaded (20)

PDF
5.Physics 8-WBS_Light.pdfFHDGJDJHFGHJHFTY
PPTX
TORCH INFECTIONS in pregnancy with toxoplasma
PPTX
Introcution to Microbes Burton's Biology for the Health
PPT
Cell Structure Description and Functions
PDF
Social preventive and pharmacy. Pdf
PDF
BET Eukaryotic signal Transduction BET Eukaryotic signal Transduction.pdf
PPTX
Cells and Organs of the Immune System (Unit-2) - Majesh Sir.pptx
PDF
Worlds Next Door: A Candidate Giant Planet Imaged in the Habitable Zone of ↵ ...
PPTX
SCIENCE 4 Q2W5 PPT.pptx Lesson About Plnts and animals and their habitat
PPTX
Platelet disorders - thrombocytopenia.pptx
PDF
Packaging materials of fruits and vegetables
PPTX
Presentation1 INTRODUCTION TO ENZYMES.pptx
PDF
Cosmology using numerical relativity - what hapenned before big bang?
PPTX
2currentelectricity1-201006102815 (1).pptx
PPTX
limit test definition and all limit tests
PPT
1. INTRODUCTION TO EPIDEMIOLOGY.pptx for community medicine
PDF
Unit 5 Preparations, Reactions, Properties and Isomersim of Organic Compounds...
PDF
Is Earendel a Star Cluster?: Metal-poor Globular Cluster Progenitors at z ∼ 6
PDF
The Future of Telehealth: Engineering New Platforms for Care (www.kiu.ac.ug)
PDF
Science Form five needed shit SCIENEce so
5.Physics 8-WBS_Light.pdfFHDGJDJHFGHJHFTY
TORCH INFECTIONS in pregnancy with toxoplasma
Introcution to Microbes Burton's Biology for the Health
Cell Structure Description and Functions
Social preventive and pharmacy. Pdf
BET Eukaryotic signal Transduction BET Eukaryotic signal Transduction.pdf
Cells and Organs of the Immune System (Unit-2) - Majesh Sir.pptx
Worlds Next Door: A Candidate Giant Planet Imaged in the Habitable Zone of ↵ ...
SCIENCE 4 Q2W5 PPT.pptx Lesson About Plnts and animals and their habitat
Platelet disorders - thrombocytopenia.pptx
Packaging materials of fruits and vegetables
Presentation1 INTRODUCTION TO ENZYMES.pptx
Cosmology using numerical relativity - what hapenned before big bang?
2currentelectricity1-201006102815 (1).pptx
limit test definition and all limit tests
1. INTRODUCTION TO EPIDEMIOLOGY.pptx for community medicine
Unit 5 Preparations, Reactions, Properties and Isomersim of Organic Compounds...
Is Earendel a Star Cluster?: Metal-poor Globular Cluster Progenitors at z ∼ 6
The Future of Telehealth: Engineering New Platforms for Care (www.kiu.ac.ug)
Science Form five needed shit SCIENEce so

network address translate

  • 2. Private Network • Private IP network is an IP network that is not directly connected to the Internet • IP addresses in a private network can be assigned arbitrarily. – Not registered and not guaranteed to be globally unique • Generally, private networks use addresses from the following experimental address ranges (non- routable addresses): – 10.0.0.0 – 10.255.255.255 – 172.16.0.0 – 172.31.255.255 – 192.168.0.0 – 192.168.255.255
  • 3. Private Addresses H1 R1 H2 10.0.1.3 10.0.1.1 10.0.1.2 H3 R2 H4 10.0.1.310.0.1.2 Private network 1 Internet H5 10.0.1.1 Private network 1 213.168.112.3 128.195.4.119 128.143.71.21 3
  • 4. Network Address Translation (NAT) • A short term solution to the problem of the depletion of IP addresses – Long term solution is IP v6 – CIDR (Classless InterDomain Routing ) is a possible short term solution – NAT is another • NAT is a way to conserve IP addresses – Can be used to hide a number of hosts behind a single IP address – Uses private addresses: • 10.0.0.0-10.255.255.255, • 172.16.0.0-172.32.255.255 or • 192.168.0.0-192.168.255.255 4
  • 5. Network Address Translation (NAT) • NAT is a router function where IP addresses (and possibly port numbers) of IP datagrams are replaced at the boundary of a private network • NAT is a method that enables hosts on private networks to communicate with hosts on the Internet • NAT is run on routers that connect private networks to the public Internet, to replace the IP address-port pair of an IP packet with another IP address-port pair. 5
  • 6. Basic Operation of NAT • NAT device has address translation table • One to one address translation 6
  • 7. IP Masquerading • Also called: Network address and port translation (NAPT), port address translation (PAT). • Scenario: Single public IP address is mapped to multiple hosts in a private network. • NAT solution: – Assign private addresses to the hosts of the corporate network – NAT device modifies the port numbers for outgoing traffic 7
  • 9. Load Balancing of Servers • Scenario: Balance the load on a set of identical servers, which are accessible from a single IP address • NAT solution: – Here, the servers are assigned private addresses – NAT device acts as a proxy for requests to the server from the public network – The NAT device changes the destination IP address of arriving packets to one of the private addresses for a server – A sensible strategy for balancing the load of the servers is to assign the addresses of the servers in a round-robin fashion. 9
  • 10. Load Balancing of Servers 10
  • 11. Configuring NAT with iptables • First example: iptables –t nat –A POSTROUTING –s 10.0.1.2 –j SNAT --to-source 128.143.71.21 • Pooling of IP addresses: iptables –t nat –A POSTROUTING –s 10.0.1.0/24 –j SNAT --to-source 128.128.71.0– • 128.143.71.30 • ISP migration: iptables –t nat –R POSTROUTING –s 10.0.1.0/24 –j SNAT --to-source 128.195.4.0– 128.195.4.254 • IP masquerading: iptables –t nat –A POSTROUTING –s 10.0.1.0/24 –o eth1 –j MASQUERADE • Load balancing: iptables -t nat -A PREROUTING -i eth1 – j DNAT --to-destination 10.0.1.2-10.0.1.4 11
  • 12. NAT Summary • NAT provides transparent and bi-directional connectivity between networks having arbitrary addressing schemes • NAT eliminates costs associated with host renumbering • NAT conserves IP addresses • NAT eases IP address management • NAT enhances network privacy
  • 13. NAT Limitations • Applications with IP-address content – Need AGL (Application Level Gateway) • Applications with inter-dependent control and and data sessions • Translation of fragmented FTP control packets