Configuring nat, Overview – H3C Technologies H3C WX3000E Series Wireless Switches User Manual

Page 283

Advertising
background image

262

Configuring NAT

Support for NAT depends on the device model. For more information, see "

About the H3C Access

Controllers Web-Based Configuration Guide

."

Overview

Network Address Translation (NAT) provides a way to translate an IP address in the IP packet header to

another IP address. NAT enables a large number of private users to access the Internet by using a small

number of public IP addresses. NAT effectively alleviates the depletion of IP addresses.
A private IP address is used only in an internal network, and a public or external IP address is used on
the Internet and is globally unique.
According to RFC 1918, three blocks of IP addresses are reserved for private networks:

Class A—10.0.0.0 through 10.255.255.255.

Class B—172.16.0.0 through 172.31.255.255.

Class C—192.168.0.0 through 192.168.255.255.

No host with an IP address in the above three ranges exists on the Internet. You can use those IP

addresses in an enterprise network freely without requesting them from an ISP or registration center.
In addition to translating private addresses to public addresses, NAT also performs address translation

between any two networks. In this document, the two networks refer to an internal network and an
external network. Generally a private network is an internal network, and a public network is an external

network.

Figure 236

shows the NAT operation.

Figure 236 NAT operation

1.

The internal host at 192.168.1.3 sends an IP packet to the external server at 1.1.1.2 through the
NAT device.

2.

After receiving the packet, the NAT device checks the IP header. Finding that the packet is destined
to the external network, the NAT device translates the private source IP address 192.168.1.3 to

the globally unique IP address 20.1.1.1, and then forwards the packet to the external server.
Meanwhile, the NAT device records the mapping between the two addresses in its NAT table.

192.168.1.3

Src : 192.168.1.3
Dst : 1.1.1.2

Src : 20.1.1.1
Dst : 1.1.1.2

192.168.1.1

20.1.1.1

Src : 1.1.1.2
Dst : 20.1.1.1

Src : 1.1.1.2
Dst : 192.168.1.3

1.1.1.2

Server

Host

NAT

Intranet

Internet

Before NAT

192.168.1.3

After NAT

20.1.1.1

Direction

Outbound

Advertising