Brief Analysis on the Implementation of NAT technology

Source: Internet
Author: User

Implementation of NAT technology-static address translation

Assume that the lP address segment used by the internal LAN is 192.168.12.1 ~ 192.168.12.254, the IP address of the router LAN port (that is, the default gateway) is 192.168.0.1/24. The valid public IP address allocated by the network ranges from 11.11.11.128 ~ 11.11.11.135, the IP address of the router in the Wan is 11.11.11.129, And the subnet mask is 255.255.255.255.248. The IP address range that can be used for conversion is 11.11.11.130 ~ 11.11.11.134. You must stop the Intranet from 192.168.12.2 ~ 192.168.12.4 are converted to valid IP addresses 11.11.11.130 ~ 11.11.11.132.

Step 1: Set the external port.

Before configuring network address translation, you must first understand the internal and external interfaces, and on which external interfaces enable NAT. Generally, the interface connecting to the user's internal network is a NAT Internal interface, and the interface connecting to the external network (such as the Internet) is a NAT external interface.

 
 
  1. interface serial 0  
  2.  
  3. ip address 11.11.11.129 255.255.255.248  
  4.  
  5. ip nat outside 

Step 2: Set the internal port.

 
 
  1. interface ethernet 0  
  2.  
  3. ip address 192.168.0.1 255.255.255.0  
  4.  
  5. ip nat inside 

Step 3: create static address translation between the local and valid internal addresses.

Ip nat inside source static internal local address internal legal address

Example:

 
 
  1. Ip nat inside source static 192.168.12.2 11.11.11.130 // convert the internal network address 192.168.12.2 to a valid ip address 11.11.130
  2.  
  3. Ip nat inside source static 192.168.12.3 11.11.11.131 // convert the internal network address 192.168.12.3 to a valid ip address 11.11.11.131
  4.  
  5. Ip nat inside source static 192.168.12.4 11.11.11.132 // convert the internal network address 192.168.12.4 to a valid ip address 11.11.11.132

In this way, the static address translation configuration is complete.

For more information about NAT technology, see:

Implementation of NAT technology-Dynamic Address Translation

Implementation of NAT technology-port multiplexing Dynamic Address Translation (PAT)

  1. Principles of NAT technology
  2. Analysis on the concept of vronat NAT
  3. Analysis of multicast knowledge in IGMP V2 package
  4. Horizontal split-by-the-command-by-product
  5. Instance resolution: the floating summary routing configuration of the VPN gateway.
  6. Analysis of multicast knowledge-Layer 2 device forwarding Multicast

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.