< Home

Web: Example for Configuring Easy IP for Intranet Users to Access the Internet

This section provides an example for configuring Easy IP for intranet users to access the Internet.

Networking Requirements

An enterprise has deployed a FW as a security gateway on the intranet border. The enterprise applies for a public IP address from an ISP to connect the FW to the ISP router. The router is an access gateway on the ISP network. A source NAT policy working in WAN interface mode must be configured on the FW. This policy allows the FW to translate the IP addresses of intranet users on the network 10.1.1.0/24 into the public IP address so that intranet users can access the Internet. Figure 1 illustrates the networking for a source NAT policy working in WAN interface mode.

Figure 1 Source NAT policy networking

Data Planning

Item

Data

Description

GigabitEthernet 0/0/1

IP address: 10.1.1.1/24

Security zone: trust

Set the default gateway address on each intranet host to 10.1.1.1.

GigabitEthernet 0/0/2

IP address: 1.1.1.1/24

Security zone: untrust

1.1.1.1/24 is a public address provided by the ISP.

Intranet segment that is allowed to access the Internet

10.1.1.0/24

-

FW's default route

Destination address: 0.0.0.0

Next hop address: 1.1.1.254

Configure a default route on the FW to direct intranet traffic to the ISP network.

Configuration Roadmap

The configuration roadmap is as follows:

  1. Assign IP addresses to interfaces, add the interfaces to security zones, and configure network connectivity.
  2. Configure a security policy to allow a specific intranet segment to access the Internet.
  3. Configure a default route on the FW to direct intranet traffic to the ISP router.
  4. Configure a NAT policy working in WAN interface mode so that intranet users can use the FW's public IP address to access the Internet.

    To enable NAT in outbound interface mode, set easy-ip parameter, which enables the FW to automatically map intranet packet addresses to a WAN interface address based on routing information.

  5. On each PC, configure the IP address of the FW interface connected to the intranet as the default gateway address to direct intranet traffic to the FW. The detailed configuration process is omitted.

Procedure

  1. Set IP addresses for interfaces on the FW and assign the interfaces to security zones.
    1. Set the IP address of GigabitEthernet 0/0/1 and assign the interface to a security zone.

      1. Choose Network > Interface.

      2. In Interface List, click of GigabitEthernet 0/0/1 and set the parameters as follows:

        Zone

        trust

        IPv4

        IP Address

        10.1.1.1/24

      3. Click OK.

    2. Set the IP address of GigabitEthernet 0/0/2 and assign the interface to a security zone.

      1. In Interface List, click of GigabitEthernet 0/0/2 and set the parameters as follows:

        Zone

        untrust

        IPv4

        IP Address

        1.1.1.1/24

      2. Click OK.

  2. Configure a security policy to allow users on a specific network to access the Internet.

    1. Choose Policy > Security Policy > Security Policy.

    2. In Security Policy List, click Add, select Add Security Policy, and configure a security policy based on the following parameter values.

      Name

      policy1

      Source Zone

      trust

      Destination Zone

      untrust

      Source Address/Region

      10.1.1.0/24

      Action

      Permit

    3. Click OK.

  3. Configure a default route on the FW, so that traffic from the private network can be forwarded to the ISP router.

    1. Choose Network > Route > Static Route.

    2. In Static Route List, click Add and configure a default route based on the following parameter values.

      Protocol

      IPv4

      Destination Address/Mask

      0.0.0.0/0.0.0.0

      Next Hop

      1.1.1.254

    3. Click OK.

  4. Configure a NAT policy working in outbound interface address mode so that intranet users can use the FW's public IP address to access the Internet.

    1. Choose Policy > NAT Policy > NAT Policy > NAT Policy.

    2. In NAT Policy List, click Add and configure a NAT policy based on the following parameter values.

    3. Click OK.

  5. On each PC, configure the IP address of the FW interface connected to the intranet as the default gateway address to direct intranet traffic to the FW. The detailed configuration process is omitted.

Configuration Scripts

Configuration script for the FW:

#
 sysname FW
#
interface GigabitEthernet0/0/1
 undo shutdown
 ip address 10.1.1.1 255.255.255.0 
#
interface GigabitEthernet0/0/2
 undo shutdown
 ip address 1.1.1.1 255.255.255.0 
#
firewall zone trust
 set priority 85
 add interface GigabitEthernet0/0/1
#
firewall zone untrust
 set priority 5
 add interface GigabitEthernet0/0/2
#
 ip route-static 0.0.0.0 0.0.0.0 1.1.1.254 
#  
security-policy   
  rule name policy1  
    source-zone trust 
    destination-zone untrust 
    source-address 10.1.1.0 24  
    action permit 
#  
nat-policy  
  rule name policy_nat1 
    source-zone trust 
    destination-zone untrust  
    source-address 10.1.1.0 24   
    action source-nat easy-ip 
#                                          
return
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >