Gateway-to-gateway configurations

Solution for route-based VPN

You need to:

  • Configure IPsec Phase 1 and Phase 2 as you usually would for a route-based VPN. In this example, the resulting IPsec interface is named FGT1_to_FGT2.
  • Configure virtual IP (VIP) mapping:
  • the 10.21.101.0/24 network mapped to the 10.11.101.0/24 network on FortiGate_1
  • the 10.31.101.0/24 network mapped to the 10.11.101.0/24 network on FortiGate_2
  • Configure an outgoing security policy with ordinary source NAT on both FortiGates.
  • Configure an incoming security policy with the VIP as the destination on both FortiGates.
  • Configure a route to the remote private network over the IPsec interface on both FortiGates.

 

To configure VIP mapping on both FortiGates

1. Go to Policy & Objects > Virtual IPs and select Create New.

2. Enter the following information, and select OK:

Name                                           Enter a name, for example, my_vip.

External Interface                      Select FGT1_to_FGT2. The IPsec interface.

Type                                            Static NAT

External IP Address/Range     For the External IP Address field enter:

10.21.101.1 when configuring FortiGate_1, or 10.31.101.1 when configuring FortiGate_2.

Mapped IP Address/Range      For the Mapped IP Address enter 10.11.101.1.

For the Range enter 10.11.101.254.

Port Forwarding                        Disable

3. Repeat this procedure on both FortiGate_1 and FortiGate_2.

 

To configure the outbound security policy on both FortiGates

1. Go to Policy & Objects > IPv4 Policy and select Create New.

2. Leave the Policy Type as Firewall and leave the Policy Subtype as Address.

3. Enter the following information, and select OK:

Incoming Interface                   Select Port 1.

Source Address                        Select all.

Outgoing Interface                   Select FGT1_to_FGT2.

The IPsec interface.

Destination Address                 Select all.

Action                                         Select ACCEPT

Enable NAT                                Enable

4. Repeat this procedure on both FortiGate_1 and FortiGate_2.

 

To configure the inbound security policy on both FortiGates

1. Go to Policy & Objects > IPv4 Policy and select Create New.

2. Leave the Policy Type as Firewall and leave the Policy Subtype as Address.

3. Enter the following information, and then select OK:

Incoming Interface                   Select FGT1_to_FGT2.

Source Address                        Select all.

Outgoing Interface                   Select Port 1.

The IPsec interface.

Destination Address                 Select myvip.

Action                                         Select ACCEPT

Enable NAT                                Disable

4. Repeat this procedure on both FortiGate_1 and FortiGate_2.

 

To configure the static route for both FortiGates

1. Go to Network > Static Routes and select Create New.

2. Enter the following information, and then select OK:

 

Destination IP / Mask               Enter 10.31.101.0/24 when configuring FortiGate_1.

Enter 10.21.101.0/24 when configuring FortiGate_2.

Device                                         Select FGT1_to_FGT2.

Gateway                                     Leave as default: 0.0.0.0.

Distance (Advanced)                Leave at default.

If you have advanced routing on your network, you may have to change this value

This entry was posted in FortiOS 5.4 Handbook and tagged , on by .

About Mike

Michael Pruett, CISSP has a wide range of cyber-security and network engineering expertise. The plethora of vendors that resell hardware but have zero engineering knowledge resulting in the wrong hardware or configuration being deployed is a major pet peeve of Michael's. This site was started in an effort to spread information while providing the option of quality consulting services at a much lower price than Fortinet Professional Services. Owns PacketLlama.Com (Fortinet Hardware Sales) and Office Of The CISO, LLC (Cybersecurity consulting firm).

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.