Connect On-premises to OCI using an IPSec VPN with Hub and Spoke VCN Routing Architecture

From Iwan
Jump to: navigation, search

Oracle Cloud Infrastructure (OCI) makes it easy to configure VPN connectivity between your on-premises environment and your OCI environment, however, they can create some complexities in routing when using a hub and spoke topology in OCI. In this tutorial, we will set up an Internet Protocol Security (IPSec) VPN connection to OCI, and configure routing to ensure that traffic from the on-premises environment is evaluated by firewall policies before connecting to resources in OCI.

7ea2af92e45fd6d36f7964cf0d2d1b78.png

The following images illustrate the traffic flows.

- On-premises to Spoke A Connectivity

Fa28c13e85bb2f94a9b35024a0865dc4.png

- Spoke B to On-premises Connectivity

80972136fc1d8b6c906550e912abba83.png

Objectives

- Connect an on-premises location to the OCI environment using an IPSec VPN tunnel. Given that our OCI environment utilizes a hub and spoke routing architecture, we will also configure the necessary routing to ensure that traffic flows correctly and verify the connectivity through basic ping tests.

Prerequisites

Complete the following tutorials:

- [Deploy a Windows Instance in Oracle Cloud Infrastructure.]
- [Install a pfSense Firewall in Oracle Cloud Infrastructure.]
- [Route Hub and Spoke VCN Routing with a pfSense Firewall in the Hub VCN.]

Task 1 - Prepare the On-premises Environment

- OCI Topology
In this tutorial, the OCI topology is the hub and spoke VCN routing topology.
For more information, see [Route Hub and Spoke VCN with pfSense Firewall in the Hub VCN.]

The following image illustrates the visual representation of the starting point.

2aac4a949cc12faaad38a33b24b37a06.png

- On-premises Topology
To simulate an on-premises environment, I built a sample set up, created two VPS instances and installed pfSense on each.
One pfSense instance will serve as the IPSec Customer-premises equipment (CPE) termination point, while the other pfSense instance will function as the internal client.
Set up of this environment is not in the scope of this tutorial.

5ad1cf1eb6a875b943138918b64d0527.png

- OCI and On-premises Final Topology

When we connect on-premises environment with the OCI environment the topology will look like this:

B1de23405cf0c057913ea1b039cba96b.png

Task 2 - Create a CPE in OCI

Before creating an IPSec VPN connection, we need to first create a CPE object in OCI.

- Go to the OCI Console.

1. Click the hamburger menu (≡) from the upper left corner.
2. Click Networking.
3. Click Site-to-Site VPN.

444781205e1cee25f5655cd9950e1592.png

1. Click Customer-premises equipment.
2. Click Create CPE.

4bd25790435c2640066637dd914f1a4d.png

- In Create CPE, enter the following information.

1. Enter the Name for the CPE.
2. Enter IP address, this IP address is the public IP address of the device that is going to be used to set up the VPN on-premises.
3. Click Create CPE.

C057f972aa3ec361c06c9b419a0f602e.png

1. Notice that the new CPE object in OCI is created.
2. Click Customer Connectivity to return to the customer connectivity page.

9e50e4000c6487f65d5736e1533d3810.png

Task 3 - Create a Site-to-Site VPN in OCI

To configure the OCI Site-to-Site VPN, we need to perform the configuration on two ends, the OCI side and the on-premises side.
- Let us configure the OCI side.
1. Click Site-to-Site VPN.
2. Click Create IPSec connection.

68f8d628f7d9ddd91795ac65e82490d8.png

1. Enter the Name for the IPSec connection.
2. Select the CPE created in Task 2.
3. Select the DRG that will be used to terminate this IPSec connection.
4. Select Routes to your on-premises network (LAN) on your on-premises location that you want to route traffic to from your OCI networks.
5. Scroll down.

B830c4602ee824bcbdf6b1d552bb9ec5.png

1. In IKE version, select `IKEv1`.
2. In Routing Type, select Static routing.
3. Scroll down.

Cd55dc240094db66b13f38c1412204b7.png

1. Click Show advanced options.
2. Scroll down.

A456943b041a6bc05a1005d7554eb45a.png

- In OCI, we need to create and configure two tunnels by default. Let us configure the first Tunnel.
1. Click right-angle bracket (>) for Phase one (ISAKMP).configuration.
2. Scroll down.

Fddf0e81c38de859771510573a656964.png

- In the Phase one (ISAKMP) configuration section, enter the following information. 1. Select Set custom configurations.
2. In Custom encryption algorithm, select `AES_256_CBC`.
3. In Custom authentication algorithm, select `SHA_256`.
4. In Custom Diffie-Hellman Group, select `GROUP 2`.
5. Leave IKE session key lifetime in seconds default to `288500` seconds.
6. Click right-angle bracket (>) for Phase two (IPSec) configuration.
7. Scroll down.

907c1bbd0c5760367844162fee4a88db.png

- In the Phase two (IPSec) configuration section, enter the following information.
1. Select Set custom configurations.
2. In Custom encryption algorithm, select `AES_256_CBC`.
3. In Custom authentication algorithm, select `HMAC_SHA2_256_128`.
4. Leave IPSec session key lifetime in seconds default to `3600` seconds.
5. Select Enable perfect forward secrecy.
6. In Perfect forward secrecy Diffie-Hellman Group, select `GROUP 5`.

6158637f2596d43ba64c555d6bed6c22.png

- Configure the second tunnel.
1. Use the same configuration details used by the first tunnel.
2. Scroll down.

5dc79e7cfdac2f869fc53a935766ef31.png

- Click Create IPSec connection.

1c99cfefdfd5b1beb2c0313d737f195d.png

- Note that both IPSec tunnels Lifecycle state is PROVISIONING .

F9bb2fda049f393ae85d9b747f4bae24.png

1. Note that the state is changed to AVAILABLE.
2. Note the Oracle VPN IP address that we need to save. These IP addresses will be required to configure the on-premises tunnel.

35b3ee6b54584cd1c292e121f9030a86.png

Note

We will only make use of one of the two IPSec tunnels and therefore, we will only focus on the first tunnel configuration, so only collect and save the first IP address of the first IPSec tunnel.

- Click CPE & Tunnels information.

91737f1e9222e573f94984e5cf84d36e.png

- Click Show.

Bf0c206544c0a55514146384b59a0f91.png

1. Note that the Shared Secret key is autogenerated. Save this secret key, this is required to configure the other side of the tunnel (on-premises).
2. Click Close.

D1a215563139d35b081576d70aa6d5c9.png

Task 4 - Configure Hub and Spoke VCN Routing for the On-premises Subnet

To route network traffic coming from the on-premises network within our Hub and Spoke network architecture, we need to make some changes to Dynamic Routing Gateways (DRG) and VCN route tables.
The following image illustrates the routing tables so this is our starting point.

28e302f4a64109d7e536c3b469bf11f9.png

Task 4-1 - Update the Route Import

- Update the route distribution group (`DRG_RDG_IMPORT`) in the DRG. Add the IPSec tunnel attachment type (priority 4).

Priority Match Type Match Criteria Action
1 Attachment SPOKE_VCN-A_ATTACHMENT ACCEPT
2 Attachment SPOKE_VCN-B_ATTACHMENT ACCEPT
3 Attachment SPOKE_VCN-C_ATTACHMENT ACCEPT
4 Attachment Type IPSec Tunnel ACCEPT

- Go to the OCI Console.

1. Click the the hamburger menu (≡) from the upper left corner.
2. Click Networking.
3. Click Dynamic Routing Gateway.

6a677fd76a8d3178a5a399da27576d65.png

1. Click Dynamic Routing Gateway.
2. Click the DRG that we are using for our VCN routing environment.

9b09985fc42fc48d89dd486b9808a31b.png

1. Click Import route distribution.
2. Click import route distribution (`DRG_RDG_IMPORT`).

538ff23f76161cbb1daa89f624ee92bb.png

- Make sure to add the new route distribution statement.
1. Notice the route distribution statement is added successfully.
2. Click Dynamic routing gateways details to return to the DRG details page.

Ecce6dcb8fc98cb853a68866247042b0.png

- The following image illustrates the visual representation of what we have created so far.

Ece425d3f7b0de1475b66ea6cce8f3b3.png

- We already imported the route in the DRG route table `DRG_RT_HUB_VCN_3`.

Note

This DRG route table (`DRG_RT_HUB_VCN_3`) and route table attachment will make sure that all networks from the spokes and on-premises (IPSec) are known and learned on the DRG so that the DRG knows what networks are available on the spokes and where to route the spoke networks to.

1. Click DRG route tables to verify.
2. Click `DRG_RT_HUB_VCN_3` route table.

4918c455e285d6567595a4d8eb04972e.png

- Click Get all route rules.

2c6c725a189593a34e642249b8d72acc.png

1. Notice that the route from on-premises (`10.222.10.0/24`) is visible in the table. This means that the DRG knows how to reach the on-premises network (`10.222.10.0/24`) that is through the IPSec tunnel.
2. Click Close.

3c8aa40fe780071480d05fc06419961f.png

- Click DRG to return to the DRG details page.

Ebedc9cbd317d852f1667742844dafb6.png

Task 4-2 - Create a new Hub VCN Route Table and Associate with the IPSec DRG Attachment

- Create a new route table (`DRG_RT_IPSEC_VC_1`) in the DRG.

Destination CIDR Next Hop Attachment Type Next Hop Attachment Name
172.16.0.0/24 Virtual Cloud Network HUB_VCN_ATTACHMENT
172.16.1.0/24 Virtual Cloud Network HUB_VCN_ATTACHMENT
172.16.2.0/24 Virtual Cloud Network HUB_VCN_ATTACHMENT
172.16.3.0/24 Virtual Cloud Network HUB_VCN_ATTACHMENT

- Go to the OCI Console.
1. Click DRG route tables.
2. Click Create DRG route table.

C1148012f0e24cab3bea22cef270af6c.png

1. Enter the Name for the DRG route table.
2. In Static route rule, enter the following information to add a new static rule.
- Destination CIDR Block: Enter `172.16.0.0/24`.
- Next hop attachment type: Select Virtual Cloud Network.
- Next hop attachment: Select hub VCN.
3. Click + Another Rule.

Eb77a22863751d4ad0ad28fa92c39251.png

1. Add a new static rule.
- Destination CIDR Block: Enter `172.16.1.0/24`.
- Next hop attachment type: Select Virtual Cloud Network.
- Next hop attachment: Select hub VCN.
2. Click + Another Rule.

1995bb45ec416bbb4f9e30c3bcabb544.png

1. Add a new static rule.
- Destination CIDR Block: Enter `172.16.2.0/24`.
- Next hop attachment type: Select Virtual Cloud Network.
- Next hop attachment: Select hub VCN.
2. Click + Another Rule.

F6ace687a8ab48a9f08129bedd0c8f52.png

1. Add a new static rule.
- Destination CIDR Block: Enter `172.16.3.0/24`.
- Next hop attachment type: Select Virtual Cloud Network.
- Next hop attachment: Select hub VCN.
2. Click Create DRG route table.

6d361ccaf05bac34464d10de42b751c6.png

- After a few minutes, route table will be created.

1695f5ab3039fedf3dd41e91083f851f.png

1. Notice that the new DRG route table (`DRG_RT_IPSEC_VC_1`) is created.

031c25679cddf7e9aee1bcbb93511f46.png

- The following image illustrates the visual representation of what we have created so far.

Ca205a2eb229a0a1cf25189b0a4e5a5c.png

- We need to associate/attach/bind the route table to the DRG IPSec tunnel attachments.

Note

This DRG route table (`DRG_RT_IPSEC_VC_1`) and route table attachment will make sure that all networks from the spokes are reachable from on-premises. This is also a way to control the routing and only allow routing to the spokes you want to be able to route to.

1. Click IPSec tunnel attachments.
2. Click the first attachment.

Aecbf3a45772fce86e258f927424658d.png

1. Notice that the IPSec attachment is using the autogenerated default DRG route table.
2. Click Edit.

C208d42ba054ca7bcbf11916aac12d3f.png

1. Select the DRG route table created above (`DRG_RT_IPSEC_VC_1`).
2. Click Save changes.

7bc65677e7cbf1f99a681e65202ab5c2.png

1. Notice that a new DRG route table is active on the IPSec attachment of the first IPSec tunnel.
2. Click DRG to return to the DRG details page.

A3c5698cd9ab4a7c4a5814e8ae000196.png

- The following image illustrates the visual representation of what we have created so far.

1f5ea6482db0725e5f734c2f57d531db.png

Note

We will not update the DRG route table on the second IPSec tunnel attachment as we do not use the second tunnel in this tutorial.

Task 4-3 - Update the Hub VCN Private Subnet Route Table

The last route table to update is the VCN route table that is associated with the private subnet in the hub VCN.
- Update the route table (`VCN_RT_HUB_PRIVATE_SUBNET`) in the hub VCN.
Add the on-premises network to the (`VCN_RT_HUB_PRIVATE_SUBNET`) table.

Destination Target Type Target Route Type
0.0.0.0/0 NAT Gateway hub-nat-gw Static
172.16.1.0/24 Dynamic Route Gateway DRG Static
172.16.2.0/24 Dynamic Route Gateway DRG Static
172.16.3.0/24 Dynamic Route Gateway DRG Static
10.222.10.0/24 Dynamic Route Gateway DRG Static
Note

This VCN route table (`VCN_RT_HUB_PRIVATE_SUBNET`) will route traffic that is destined for the spokes and on-premises IPSec network to the firewall. Traffic that is destined to the internet (all traffic other than spoke networks) to the NAT gateway will also be routed by this route table.

- Go to the OCI Console.
1. Click the the hamburger menu (≡) from the upper left corner.
2. Click Networking.
3. Click Virtual cloud networks.

33aaedb981d3c2da31b6fbef9c7c42c1.png

- Click the hub VCN.

Ef988bfbf3ee95ecbf68c138ea7b90f5.png

1. Click Route Tables.
2. Click the `VCN_RT_HUB_PRIVATE_SUBNET` route table.

0ea3c89b8bfc85cea7a435def8dc255d.png

- I have already added the new route rule, so make sure you add it. When you successfully add in the route rule it should look like this.

118755907fdda43fe83e814f168fc08f.png

- The following image illustrates the visual representation of what we have created so far.

Dd447a68ee5a65336e15d0e999c7f15d.png

Task 5 - Create a Site-to-Site VPN on On-premises using pfSense

We have configured the OCI side of the IPSec tunnel. Let's configure the on-premises side. We are using a pfSense firewall as the IPSec termination endpoint.

Task 5-1 - Create the IPSec Tunnel (Phase 1 ISAKMP)

- Go to the pfSense portal.
1. Click the VPN drop-down menu.
2. Click IPSec.

F078d92115659143cce8dae1ab6a03cb.png

1. Click Tunnels.
2. Click + Add P1.

61dc3686bb53d357de4126fb7bff029d.png

1. Enter a Description.
2. In Key exchange version, select IKEv1.
3. In Internet Protocol, select IPv4.
4. In Interface, select WAN.
5. In Remote Gateway, enter the public IP address, which can be retrieved from the OCI Console. Go to Networking, Customer Connectivity, Site-to-Site VPN and click VPN.
6. Scroll down.

784098b9256c66d5ecdfdf35066c2509.png

- In Phase 1 Proposal section, enter the following information.
1. In Authentication Method, select Mutual PSK.
2. In Negotiation mode, select Main.
3. In My Identifier, select IP address and enter your local public IP address of the on-premises side retrieved in Task 3.
4. In Peer Identifier, select IP address and enter your remote public IP address of the OCI side.
5. Enter the (Pre) Shared secret key retrieved in Task 3.
6. Configure the Encryption Algorithm:
- Algorithm: Select AES.
- Key Length: Select256 bits.
- Hash: Select SHA256.
- DH Group: Select 2 (1024 bit).
7. Scroll down.

Ee1a0de620b070e1751202fd252f63f6.png

1. In Life Time, enter `28800` seconds.
2. In Child SA Close Action, select Restart/Reconnect.
3. Scroll Down.

C73a67422753f083491d02b7d53f27fa.png

- Click Save.

7b2297641ad15fd936707aadb66cf035.png

1. Notice that the phase 1 IPSec configuration has been configured.
2. Click Apply Changes to commit the changes.

58df2e527233b0bfd07b06cdd22225dc.png

1. Notice that the changes have been applied successfully.
2. Click Show Phase 2 Entries.

7fec160b228837c0cd4d8ef2f0d116a1.png

Task 5-2 - Create the IPSec Tunnel (Phase 2 IPSec)

- Click + Add P2.

1bae943b468caac68b2f4352fb45e1e9.png

1. Enter a Description.
2. In Mode, select Routed (VTI).
3. Select the local (on-premises) network.
4. Select the remote (OCI) network.
5. Scroll down.

3608238050c8417bcdd1abd0f09dcfc0.png

1. In Protocol, select ESP.
2. In Encryption Algorithm, select AES 256 bits.
3. In Hash Algorithm, select SHA256.
4. In PFS key group, select 5 (1536 bit).
5. In Life Time, enter 3600 seconds.
6. Scroll down.

9765ecd718aee7c0565b087997c5a82a.png

- Click Save.

D47972df4dc3e59d6e09ae384555105a.png

1. Notice that the phase 1 IPSec configuration has been configured.
2. Click the statistics.

E12dbd1f445e2b3ccf86d1f498268fa1.png

- Notice that the status is Established.

C14750cb41fdfcb6a8dec19d33f47f50.png

- Let's verify the tunnel state on OCI side. Go to the OCI Console, navigate to Networking, Customer Connectivity, Site-to-Site VPN and click the VPN. Notice that the IPSec status of the first tunnel is Up.

169979c376c79ac635e867c8df757a2e.png

Task 5-3 - Enable the Tunnel Interface

- We need to enable the tunnel interfaces on on-premises side. Go to the pfSense Portal.
1. Click the Interfaces drop-down menu.
2. Click Assignments.
3. Note that a new VTI interface is available.
4. Click + Add to add the interface.

Eaaf57b036b705b04d8e2adc2d217a31.png

1. Note that the interface has been added.
2. Click added tunnel interface (`OPT1`).

C67b36a2fa97a204437f2ac869880028.png

1. Select Enable interface to enable the interface.
2. Click Save.

02031872af041ac8476e6edaf43c4042.png

Task 5-4 - Open the Firewall Rules for IPSec

- To allow IPSec traffic to flow through the tunnel we need to add some firewall rules.
1. Click the Firewall drop-down menu.
2. Click Rules.

72b9a14957bfc53cf0b2b4fa44c5eeb2.png

1. Click IPSec.
2. Note that there are no firewall rules related to IPSec.
3. Click Add.

F9fec5be756bf217478e198e6d9e8d91.png

- Enter the following information.
1. Action: Select Pass.
2. Interface: Select IPSec.
3. Address Family: Select IPv4.
4. Protocol: Select Any.
5. Source: Select Any.
6. Destination: Select Any.
7. Scroll down.

30a3dc2fb2a2ce2e34f4192bfcabd0fa.png

- Click Save.

F72cbb13ea5a27d28ddc6bcab5a5c137.png

1. Note that the new rule is in place.
2. Click Apply Changes to commit the changes.

5fec37a2e9ec8ba9680849fcde06a5aa.png

- Note that the changes have been applied successfully.

52a9ca0d5bea210fcda6f00023ca2d91.png

Task 5-5 - Configure IPSec Routing

In this task, we will configure routing so that the pfSense firewall knows how to reach the OCI network through the IPSec tunnel and the `OPT1` interface.

- Go to the pfSense Portal.
1. Click the System drop-down menu.
2. Click Routing.
3. In Default gateway IPv4, select the `WAN_DHCP` or your default gateway that you want to use as the first priority.
4. Click + Add to add a new gateway.

871f965cab330724eb17113cedc24975.png

1. In Interface, select `OPT1` (the tunnel interface).
2. In Address Family, select `IPv4`.
3. Enter a Name.
4. In Gateway, do not specify any IP address, leave blank.
5. Scroll down.

Dc75978ba1a6f54c5d3028f58323464b.png

- Click Save.

De8a4a784d6fce7e74729ef0f07e7c74.png

1. Note that a new gateway has been added for our IPSec tunnel.
2. Click Static Routes.

33341d53d15529a8a0a3d360b8421f1e.png

- Click + Add to add a new static route.

Abe6a6b0264a36b8eab92742c009d8fe.png

1. Enter Destination network of the OCI networks.
2. Select Destination subnet of the OCI networks.
3. Select the Gateway created above.
4. Click Save.

6449b0d34df1f05b56a9e4a75d7761e4.png

- Note that a new static route is added that will route traffic destined for the OCI networks using the tunnel interface.

264d8a187733e4b507e6aef9edbce742.png

Task 6 - Configure On-premises Routing

We have routing working on pfSense, that is the IPSec VPN endpoint. We need to make sure that the rest of the on-premises network knows how to reach the OCI networks. So we need to route all traffic destined to OCI to the pfSense VPN endpoint.

Configure routing on the test On-premises Compute Client

We are using a pfSense instance to simulate the on-premises network.

Note

This is a different instance than the one we just used to configure the IPSec tunnel on!

- Go to the PfSense Portal.
1. Click the System drop-down menu.
2. Click the Routing.

281bfe014d1c5dec2c1b5f0887ef0be5.png

1. Select `WAN_DHCP` or your default gateway that will be used as the first priority.
2. Click + Add to add a new gateway.

6f684f99ef20784d05869bf6649b0269.png

1. In Interface, select `LAN`.
2. In Address Family, select `IPv4`.
3. Enter a Name.
4. Enter the LAN IP address of the other pfSense instance, the one that terminates the IPSec tunnel.
5. Scroll down.

D7282c120d758f7d1d6cd8e93675d9c8.png

- Click Save.

6beae3581e156aa77dc543a21e7a615e.png

1. Note that a new gateway is added for our other pfSense instance.
2. Click Static Routes.

34c1076025b93d7d4dd61ebc34c3cf0f.png

- Click + Add to add a new static route.

7755031236ebd668b9f6d90fa33629a8.png

1. Select Destination network of the OCI networks.
2. Select Destination subnet of the OCI networks.
3. Select the Gateway created above.
4. Click Save.

24c12c15f14d1d91ab3d376b961b9bce.png

- Note that a new static route is added that will route traffic destined for the OCI networks using the other pfSense instance.

D979753e881242f0061b5558ff32255b.png

Task 7 - Verify the Connectivity

We have configured the VPN, added the correct firewall rules, and configured routing, now test the connectivity.

Task 7-1 - Ping from On-premises to Spoke VCN A

- Due to routing configuration:
- The traffic will be sent to the (on-premises) pfSense VPN instance.
- The traffic is sent through the IPSec VPN tunnel to the DRG.
- The DRG will then route the traffic to the OCI pfSense firewall.
- The OCI pfSense firewall will allow or deny the traffic based on the configured firewall rules.
- When the ICMP traffic is accepted it will route the traffic to the Spoke instance.

E1ec9c4bde6d228a73aece5beaf73c00.png

- Perform a ping test from the VPN pfSense on-premises instance.
1. Click the Diagnostics drop-down menu.
2. Click Ping.
3. Enter the Hostname which is an IP address of the Spoke VCN A instance.
4. In IP Protocol, select `IPv4`.
5. In Source address, select the `LAN` interface.
6. In Maximum number of pings, select `3`.
7. Click Ping.
8. Notice that we have 0% Packet loss.

3767379109ca8335811dd351527a4234.png

- We can also do a test from the other pfSense instance (the Client). Perform a ping test from the Client pfSense on-premises instance.
1. Click the Diagnostics drop-down menu.
2. Click Ping.
3. Enter the Hostname which is an IP address of the Spoke VCN A instance.
4. In IP Protocol, select `IPv4`.
5. In Source address, select the `LAN` interface.
6. In Maximum number of pings, select `3`.
7. Click Ping.
8. Note that we have 0% Packet loss.

3d37bf87e7d175b544089b49bb06435c.png

Task 7-2 - Ping from Spoke VCN B to On-premises

- Due to routing configuration:
- The traffic will be sent to the DRG.
- The DRG will then route the traffic to the OCI pfSense firewall.
- The OCI pfSense firewall will allow or deny the traffic based on the configured firewall rules.
- When the ICMP traffic is accepted it will route the traffic back to the DRG.
- The traffic is sent through the IPSec VPN tunnel to the on-premises pfSense instance.

72667a38ff7c077bff4032dee4cc1f21.png

1. Connect to the spoke B VCN instance.
2. Do a ping to the LAN IP address of the on-premises pfSense VPN instance (`10.222.10.1`).
3. Notice that we have 0% packet loss so the ping is successful.
4. Do a ping to the LAN IP address of the on-premises pfSense client instance (`10.222.10.100`).
5. Notice that we have 0% packet loss so the ping is successful.

89ede99bea3e3841ad26ec4046c00292.png

Task 7.3: Check IPSec VPN Network Statistics on OCI

- Go to the OCI Console.
1. Click the the hamburger menu (≡) from the upper left corner.
2. Click Networking.
3. Click Site-to-Site VPN.

Fc9a9a7435316933912acc2b16ea081d.png

- Click the VPN.

C6bc7c8853862a2c232117f60167d7f1.png

- Click the first tunnel.

516cbe65d7c53a883a45a2a1727203ff.png

1. Note that the tunnel state shows a constant `1` in the binary state, indicating that the tunnel is up constantly.
2. Scroll down.

6cd1d351247b43b49509bee52af261f9.png

1. Note that the graph is peaking for the Packets Received and Packets Sent, this is due to the ping we did in Task 7.1.
2. Note that the graph is peaking for the Packets Received and Packets Sent, this is due to the ping we did in Task 7.2.

2187b2f74f373f9b59a336b38457cd60.png

Task 7-4 - Check IPSec VPN Network Statistics on the pfSense VPN Instance -On-premises-

- Go to the PfSense Portal.
1. Click the Status drop-down menu.
2. Click IPSec.

F2b149ce4f3830b4c5315c13cd890977.png

- Click Show Child SA Entries (1 connection).

83635dfa9d7a579a7203a480a0a89402.png

- Notice the Packets and Bytes came in and went out.

40288a14d5eb4261cb3f4eefe32a0d5c.png

Network Visualizer

As we have added the VPN, we can use the Network Visualizer on the OCI Console to get a network overview.

- Go to the OCI Console.
1. Click the the hamburger menu (≡) from the upper left corner.
2. Click Network.
3. Click Network Visualizer.

39e7e43caa4d42bef926ecc033d928b0.png

- You can see four VCNs (one Hub and three Spokes) and the on-premises connected with VPN.

9d87e5bbd81544055a0e332012287ec5.png

Conclusion

In this tutorial, we have connected our on-premises location to our OCI cloud environment with an IPSec VPN Tunnel. Because our OCI environment is using a Hub and Spoke Routing Architecture we also needed to configure routing to make sure the traffic flows are still following the required path. We ended this tutorial by proving connectivity is possible with some basic ping tests.