By Manny Fernandez

March 25, 2020

Adding Elastic IPs to AWS FortiGate to be used as VIPs

Lately I have been doing some AWS.  I am looking to get certified in the short-term.  I was struggling with a customer after I deployed a FortiGate in AWS and could not figure out how to allocate Elastic IPs to be used by the FortiGate to perform NATs for different internal instances.  Here is an article showing what I did.

On AWS

Log into you AWS Console and choose you VPC

2020-03-25_12-28-13

Then choose the Instances and choose your Fortigate instance.

2020-03-25_12-29-49

Then you will need to (1) Choose the Instance, (2) Click Actions (3) Choose

Networking then choose (4) Manage IP Addresses

2020-03-25_12-31-14

Once in Manage IP Addresses you will see your interfaces that you have assigned to your Fortigate instance.  Choose the interface that represents the outside of the Fortigate and click Assign new IP.

2020-03-25_12-32-49

You can see that my subnet is 172.31.254.0/24 and I have .5 assigned to my Public Facing IP address. Enter another IP in that same range (I believe AWS reserves the first 4 IP addresses) and then click Yes, Update

You will need to get the interface ID by going to EC2 then the instance and go to the bottom portion of the screen.  You can hover over the eth0 (or whatever interface you are using for the outside) and write down the ID.  In my example below, you can see my Interface ID ends in bd

2020-03-25_12-40-21

Now you will need to go to your (2) Elastic IPs under your (1) VPC and choose (3) Allocate new addresses .

2020-03-25_12-37-30

Next you will need to choose Amazon pool and click Allocate

2020-03-25_12-38-48

You should now see the newly allocated Elastic IP allocated to the VPC.

2020-03-25_12-39-23

Once this is done, you will see the newly allocated Elastic IP on the list of Elastic IPs.  Choose (1) Actions then choose (2) Associate Elastic IP address

2020-03-25_12-41-48

Next you will need to choose (1) Network Interface instead of the default of Instance , then choose (2) the Network Interface from the drop-down list.  Finally choose the additional (3) IP we created in the Managed IP Addresses section of this article and choose (4) Associate

2020-03-25_12-43-09

On FortiGate

2020-03-25_12-47-50

Log into your ForitGate instance via the FortiGate GUI.  Then choose (1) Policy & Objects then (2) Virtual IPs or DNAT & Virtual IPs (if you are using Central NAT), and (3) Create New

2020-03-25_12-50-40

Now it is just like creating a VIP on any FortiGate device.  (1) Give it a descriptive name, (2) (Optional) choose the interface from the dropdown then (3) enter the external IP address, this is the one we added as an additional  IP to your FortiGate instance, then (4) enter the internal IP of the device you are NAT’ng.

2020-03-25_12-55-43

Finally, create your policy.  If you are using Central NAT you will have the internal IP address of the NAT’d device in the destination, if you are using policy nat then you will have the VIP as the destination.

UPDATES:

You will need to disable Source/Dest. Check before the VIP works.

2020-04-02_13-33-00

 

2020-04-02_13-33-28

Make sure you do this for all the interfaces on the FortiGate in your VPCs

Hope this helps.

Recent posts

  • If you've spent any time configuring user authentication on... Full Story

  • DNS is one of those technologies that quietly underpins... Full Story

  • BGP issues on FortiGate firewalls usually trace back to... Full Story

  • Every time your laptop talks to your router, a... Full Story

  • If you've spent any time configuring NAT on a... Full Story

  • If you have spent any time configuring firewall policies... Full Story

  • High availability on FortiGate is one of those features... Full Story

  • If you've configured SD-WAN on a FortiGate, you've almost... Full Story

  • FortiLink is the management protocol that turns a FortiSwitch... Full Story

  • FortiSwitches are pretty rock solid from Mean Time Between... Full Story

  • This is a quicky tip.  Have you ever gone... Full Story

  • DNS is one of those quiet pieces of internet... Full Story

  • This article is an updated version of the previous... Full Story

  • You will add ns2 as a secondary (slave) BIND9... Full Story

  • In the process of deploying my lab, I needed... Full Story

  • RFC 8805, used to be known as Self-Correcting IP... Full Story

  • Years back, I wrote an article about certificate pinning. ... Full Story

  • FortiGates have the ability to send alerts to Microsoft... Full Story

  • In this post, I am going to walk through... Full Story

  • Troubleshooting VoIP on a FortiGate can feel like trying... Full Story

  • Prior to FortiOS 7.0, there were three commands to... Full Story

  • In this post, I am going to go over... Full Story

  • What we are going to do:  We are going... Full Story

  • Choosing between FGCP (FortiGate Clustering Protocol) and FGSP (FortiGate... Full Story

  • Creating a VLAN on macOS (The "Pro" Move) A... Full Story

  • This blog post explores the logic behind how macOS... Full Story

  • Pretty Fly for a Wi-Fi Tell My Wi-Fi Love... Full Story

  • Part of my daily gig is creating BoMs (Bill-of-Materials)... Full Story

  • ICMP introduces several security risks, but careful filtering, rate... Full Story

  • The command diag debug application dhcps -1 enables full... Full Story

  • In the world of FortiOS, execute tac report is... Full Story

  • LLDP; What is it The Link Layer Discovery Protocol... Full Story

  • What it actually does When you run diagnose fdsm... Full Story

  • Monkey Bites are bite-sized, high-impact security insights designed for... Full Story

  • I have run macOS in macOS with Parallels but... Full Story

  • Don't be confused with my other FortiNAC posts where... Full Story

  • This is the third session in a multi-part article... Full Story

  • Today I was configuring key-based authentication on a FortiGate... Full Story

  • Netcat, often called the "Swiss Army knife" of networking,... Full Story

  • At its core, IEEE 802.1X is a network layer... Full Story

  • In case you did not see the previous FortiNAC... Full Story

  • This is our 5th session where we are going... Full Story

  • Now that we have Wireshark installed and somewhat configured,... Full Story

  • The Philosophy of Packet Analysis Troubleshooting isn't about looking... Full Story

  • Overview FortiOS 8.0 introduces custom tags as a first-class... Full Story

  • These are two distinct mechanisms on FortiOS, and conflating... Full Story

  • Replacement messages are the pages and text blocks that... Full Story