Skip to Content

Site-to-Site VPN and Client VPN

AWS Site-to-Site VPN with a virtual private gateway and customer gateway, route propagation, tunnels and bandwidth, VPN CloudHub for many sites, and AWS Client VPN for users.

AWS Site-to-Site VPN

AWS Site-to-Site VPN: a virtual private gateway attached to the VPC, with route propagation enabled in the subnet route table, connects through two IPsec tunnels over the public internet to the customer gateway in the corporate data center, which uses a public IP address or the public IP of a NAT device with NAT traversal AWS Site-to-Site VPN: a virtual private gateway attached to the VPC, with route propagation enabled in the subnet route table, connects through two IPsec tunnels over the public internet to the customer gateway in the corporate data center, which uses a public IP address or the public IP of a NAT device with NAT traversal

An encrypted link over the internet.

AWS Site-to-Site VPN connects an on-premises data center to a VPC with an encrypted IPsec connection over the public internet.

  • Virtual private gateway (VGW):
    • the VPN concentrator on the AWS side of the VPN connection;
    • the VGW is created and attached to the VPC to connect;
    • the ASN (Autonomous System Number) is customizable.
  • Customer gateway (CGW): a software application or physical device on the customer side of the VPN connection.
  • Each VPN connection has two tunnels for high availability, each up to 1.25 Gbps.
  • A transit gateway can also be the AWS side of the VPN (see ECMP).

Site-to-Site VPN connections

  • Customer gateway device (on premises): what IP address to use?
    • a public internet-routable IP address for the customer gateway device;
    • if it's behind a NAT device enabled for NAT traversal (NAT-T), use the public IP address of the NAT device.
  • Important step: enable route propagation for the virtual private gateway in the route table associated with the subnets.
  • To ping the EC2 instances from on premises, add the ICMP protocol to the inbound rules of their security groups.

Updated since the slides

Site-to-Site VPN now offers Large Bandwidth Tunnels of up to 5 Gbps each (instead of 1.25 Gbps), for VPN connections attached to a transit gateway or Cloud WAN. The exam uses 1.25 Gbps per tunnel.

AWS VPN CloudHub

AWS VPN CloudHub: several sites, each with its own customer gateway and VPN connection, connect to the same virtual private gateway, which acts as a hub so the sites can talk to each other and to the VPC over the internet AWS VPN CloudHub: several sites, each with its own customer gateway and VPN connection, connect to the same virtual private gateway, which acts as a hub so the sites can talk to each other and to the VPC over the internet

One VGW as the hub for all the sites.

VPN CloudHub:

  • provides secure communication between multiple sites, if there are multiple VPN connections;
  • a low-cost hub-and-spoke model for primary or secondary network connectivity between different locations (VPN only);
  • it's a VPN connection, so it goes over the public internet;
  • to set it up, connect multiple VPN connections on the same VGW, set up dynamic routing (BGP, a unique ASN per customer gateway) and configure route tables.

AWS Client VPN

Not in the course slides

AWS Client VPN is on the exam guide's in-scope list but not in the course slides. This section is written from the AWS documentation.

AWS Client VPN is a managed, client-based VPN for people rather than sites.

  • Users install an OpenVPN-based client on their laptop and connect from anywhere.
  • They reach resources in the VPC, and through it peered VPCs and on-premises networks (over Site-to-Site VPN or Direct Connect), or even the internet.
  • Authentication with Active Directory, SAML federation (single sign-on) or mutual certificates.
  • Scales automatically; billing is per endpoint association hour and per connected client hour.

Site-to-Site VPN connects networks; Client VPN connects individual users.

Exam tips

  • "Connect the data center to AWS quickly, encrypted, over the internet" → Site-to-Site VPN (VGW + CGW).
  • "VPN up but no traffic" → enable route propagation; check security groups (ICMP for ping).
  • "Customer gateway behind NAT" → use the NAT device's public IP with NAT-T.
  • "Connect many branch offices to each other cheaply" → VPN CloudHub.
  • "Remote employees need secure access to the VPC" → AWS Client VPN.

Common traps

  • "Site-to-Site VPN goes over a private line." It's over the public internet (encrypted); the private line is Direct Connect.
  • "Client VPN connects two offices." That's Site-to-Site VPN.

Check yourself

A VPN connection costs about $0.05 an hour and needs an on-premises device, so instead:

AWS documentation

On this page

Open notes

Spotted a mistake?

These notes are open source. Suggest a fix, or star the repo if they helped you.

Suggest an edit

For AI agents: llms.txt · llms-full.txt