Web example: Configuring IPsec smart link selection

Network configuration

As shown in Figure 1, Device A is the IPsec gateway of the branch. Device B is the IPsec gateway of the headquarters. Configure IPsec smart link selection so the branch can establish an IPsec tunnel to the headquarters over link 1 or link 2, whichever has a better link quality.

Figure 1 Network diagram

 

Software versions used

This configuration example was created and verified on E8371 of the F5000-AI160 device.

Restrictions and guidelines

 

If a wider ACL rule is used by the SA initiator, the negotiation request might be rejected because the matching traffic is beyond the scope of the responder.

For the modifications to take effect on existing IPsec SAs, you must reset the IPsec SAs.

Procedure

Configuring Device A

  1. Assign IP addresses to interfaces and add the interfaces to security zones:

# On the top navigation bar, click Network.

# From the navigation pane, select Interface Configuration > Interfaces.

# Click the Edit icon for GE 1/0/4.

# In the dialog box that opens, configure the interface:

  1. Select the Untrust security zone.

  1. Click the IPv4 Address tab. Enter the IP address and mask length of the interface. In this example, use 1.1.1.2/24. Specify the gateway address for the interface as 1.1.1.3.

  1. Use the default settings for other parameters.

  1. Click OK.

# Add GE 1/0/5 to the Trust security zone and set its IP address to 2.2.2.2/24 and its gateway address to 2.2.2.3 in the same way you configure GE 1/0/4.

# Add GE 1/0/3 to the Trust security zone and set its IP address to 10.1.1.10/24 in the same way you configure GE 1/0/4.

  1. Configure security policies:

# On the top navigation bar, click Policies.

# From the navigation pane, select Security Policies > Security Policies.

# Click Create, and then click Create a policy.

# Configure a security policy named trust-untrust to permit specific traffic from the Trust to Untrust security zones:

  1. Set the security policy name to trust-untrust.

  1. Select source zone Trust.

  1. Select destination zone Untrust.

  1. Select IPv4 as the type.

  1. Select action Permit.

  1. Enter source IPv4 address 10.1.1.0/24.

  1. Enter destination IPv4 address 10.1.2.0/24.

  1. Use the default settings for other parameters.

  1. Click OK.

# On the Security Policies page, click Create.

# Configure a security policy named untrust-trust to permit specific traffic from the Untrust to Trust security zones:

  1. Set the security policy name to untrust-trust.

  1. Select source zone Untrust.

  1. Select destination zone Trust.

  1. Select IPv4 as the type.

  1. Select action Permit.

  1. Enter source IPv4 address 10.1.2.0/24.

  1. Enter destination IPv4 address 10.1.1.0/24.

  1. Use the default settings for other parameters.

  1. Click OK.

# On the Security Policies page, click Create.

# Configure a security policy named local-untrust to permit specific traffic from the Local to Untrust security zones:

  1. Set the security policy name to local-untrust.

  1. Select source zone Local.

  1. Select destination zone Untrust.

  1. Select IPv4 as the type.

  1. Select action Permit.

  1. Enter source IPv4 address 1.1.1.2,2.2.2.2.

  1. Enter destination IPv4 address 3.3.3.3.

  1. Use the default settings for other parameters.

  1. Click OK.

# On the Security Policies page, click Create.

# Configure a security policy named untrust-local to permit specific traffic from the Untrust to Local security zones:

  1. Set the security policy name to untrust-local.

  1. Select source zone Untrust.

  1. Select destination zone Local.

  1. Select IPv4 as the type.

  1. Select action Permit.

  1. Enter source IPv4 address 3.3.3.3.

  1. Enter destination IPv4 address 1.1.1.2,2.2.2.2.

  1. Use the default settings for other parameters.

  1. Click OK.

  1. Create an IKE proposal:

# On the top navigation bar, click Network.

# From the navigation pane, select VPN > IPsec > IKE Proposals.

# Click Create.

# Click OK.

Figure 2 Creating an IKE proposal

 

  1. Configure the IPsec policy:

# On the top navigation bar, click Network.

# From the navigation pane, select VPN > IPsec > IPsec Policies.

# Click Create.

# Configure the basic settings as follows:

Figure 3 Basic settings

 

# Configure the IKE profile settings as follows:

Figure 4 IKE profile settings

 

# Configure the data flow filter rules as follows:

# Click OK.

Figure 5 Creating a data flow filter rule

 

# Configure the IPsec advanced settings as follows:

# Click OK.

Figure 6 Advanced settings

 

Configuring Device B

  1. Assign IP addresses to interfaces and add the interfaces to security zones:

# On the top navigation bar, click Network.

# From the navigation pane, select Interface Configuration > Interfaces.

# Click the Edit icon for GE 1/0/1.

# In the dialog box that opens, configure the interface:

  1. Select the Untrust security zone.

  1. Click the IPv4 Address tab. Enter the IP address and mask length of the interface. In this example, use 3.3.3.3/24. Specify the gateway address for the interface as 3.3.3.4.

  1. Use the default settings for other parameters.

  1. Click OK.

# Add GE 1/0/3 to the Trust security zone and set its IP address to 10.1.2.10/24 in the same way you configure GE 1/0/1.

  1. Configure security policies:

# On the top navigation bar, click Policies.

# From the navigation pane, select Security Policies > Security Policies.

# Click Create, and then click Create a policy.

# Configure a security policy named trust-untrust to permit specific traffic from the Trust to Untrust security zones:

  1. Set the security policy name to trust-untrust.

  1. Select source zone Trust.

  1. Select destination zone Untrust.

  1. Select IPv4 as the type.

  1. Select action Permit.

  1. Enter source IPv4 address 10.1.2.0/24.

  1. Enter destination IPv4 address 10.1.1.0/24.

  1. Use the default settings for other parameters.

  1. Click OK.

# On the Security Policies page, click Create.

# Configure a security policy named untrust-trust to permit specific traffic from the Untrust to Trust security zones:

  1. Set the security policy name to untrust-trust.

  1. Select source zone Untrust.

  1. Select destination zone Trust.

  1. Select IPv4 as the type.

  1. Select action Permit.

  1. Enter source IPv4 address 10.1.1.0/24.

  1. Enter destination IPv4 address 10.1.2.0/24.

  1. Use the default settings for other parameters.

  1. Click OK.

# On the Security Policies page, click Create.

# Configure a security policy named local-untrust to permit specific traffic from the Local to Untrust security zones:

  1. Set the security policy name to local-untrust.

  1. Select source zone Local.

  1. Select destination zone Untrust.

  1. Select IPv4 as the type.

  1. Select action Permit.

  1. Enter source IPv4 address 3.3.3.3.

  1. Enter destination IPv4 addresses 1.1.1.2,2.2.2.2.

  1. Use the default settings for other parameters.

  1. Click OK.

# On the Security Policies page, click Create.

# Configure a security policy named untrust-local to permit specific traffic from the Untrust to Local security zones:

  1. Set the security policy name to untrust-local.

  1. Select source zone Untrust.

  1. Select destination zone Local.

  1. Select IPv4 as the type.

  1. Select action Permit.

  1. Enter source IPv4 addresses 1.1.1.2,2.2.2.2.

  1. Enter destination IPv4 address 3.3.3.3.

  1. Use the default settings for other parameters.

  1. Click OK.

  1. Create an IKE proposal:

# On the top navigation bar, click Network.

# From the navigation pane, select VPN > IPsec > IKE Proposals.

# Click Create.

# Click OK.

Figure 7 Creating an IKE proposal

 

  1. Configure the IPsec policy:

# On the top navigation bar, click Network.

# From the navigation pane, select VPN > IPsec > IPsec Policies.

# Click Create.

# Configure the basic settings as follows:

Figure 8 Basic settings

 

# Configure the IKE profile settings as follows:

Figure 9 IKE profile settings

 

# Configure the IPsec advanced settings as follows:

# Click OK.

Figure 10 Advanced settings

 

Verifying the configuration

  1. Verify that Device A and Device B can communicate with each other.

  1. On Device A, display IPsec tunnel information:

# On the top navigation bar, click Network.

# From the navigation pane, select VPN > IPsec > IPsec Tunnels. The established IPsec tunnel is displayed.

# Click the Details icon for the IPsec tunnel. The Tunnel Details page displays tunnel information, SA information, and tunnel statistics.

Figure 11 Details of the IPsec tunnel on Device A

 

  1. On Device A, automatically or manually switch links:

# On the top navigation bar, click Network.

# From the navigation pane, select VPN > IPsec > IPsec Policies. In this example, the created IPsec policy policy1_1 is displayed, and IPsec smart link selection is enabled in the policy.

IPsec smart link selection enables the branch gateway to monitor the real-time packet loss ratio and delay of the active link over which the IPsec tunnel is established. The branch gateway can dynamically select a link with desired transmission quality to establish the IPsec tunnel to the headquarters.

Figure 12 IPsec policies

 

# Click Adjust in the Smart link selection column to open the Adjust Link Priorities page.

# Select the check box in the Activate column of a link to manually activate the link.

Figure 13 Adjust link priorities

 

  1. On Device B, display IPsec tunnel information:

# On the top navigation bar, click Network.

# From the navigation pane, select VPN > IPsec > IPsec Tunnels. The established IPsec tunnel is displayed.

# Click the Details icon for the IPsec tunnel. The Tunnel Details page displays tunnel information, SA information, and tunnel statistics.

Figure 14 Details of the IPsec tunnel on Device B