- Newest
- Most votes
- Most comments
That looks like the issue. The "Local IPv4 network CIDR" needs to contain all subnets allowed from the client-side of the VPN
Hello, It sounds like what you need is to enable "hairpin nat" on the Ubiquiti Dream Machine Pro (DMP). Here's an article on how to do that for the Ubiquiti EdgeRouter.
Here's how I'd think about it: you don't want to allow the Public IP address of the VPN client access, you want to hide/NAT the client behind a private (RFC1918 address) that's within your network.
I'd also ensure the Security Group is allowing traffic from the Clients' IP address as assigned by Ubiquiti Teleport. What's important here is to allow the Private addresses assigned to the VPN clients to be allowed to connect to the resources in the AWS VPC.
You do Not need to create another customer (2nd) gateway as long as the traffic is coming from the existing DMP.
Since you wrote: inside ip of AWS vgw (looping) This makes me think it's a problem with route table config in your AWS VPC. I suggest you ensure you're routing traffic destined for the VPN clients back to the VGW (and not out towards a NAT or Internet Gateway)
Can you share more info about the Ubiquiti architecture? a rough diagram would be super helpful!
Here are 3 components needed to make this work without hairpin nat:
- Security Association - both sides of the VPN need to allow the subnets that are allowed to send traffic over the VPN - sounds like this must be correct or the tunnel(s) wouldn't come up
- Routing a) Route traffic destined for the VPC to the inside IP of the VPG b) Return route - in AWS you need to ensure you're routing traffic destined for the VPN clients back to the VGW (and not out towards a NAT or Internet Gateway)
- Security Groups
Can you enable VPC Flow Logging?
Hi,
I finally figured out how to make it work after seeing this post https://repost.aws/questions/QUVxhGEH-iSiy1UvGpzs5Ijw/aws-site-to-site-vpn-configure-multiple-cidr-ranges. Basically, need to set Local IPv4 network CIDR to 0.0.0.0/0 in the vpn connection configuration. And then tighten the security control in the VPC security group.
that link points back to this question
Hi Randy, attached the routes in the route table that the site to site VPN connects to. For 2.b), where do I set the route to direct the traffic destined 192.168.2.0/24 to the vgw? Is it the one in the screenshot attached?
I can enable the VPC flow log. Shall I log all the traffic or just 'REJECT' traffic? Thanks.
Also, can I add two 'Local IPv4 network CIDR' to the s2s vpn connection?
Relevant content
- asked a year ago
- asked 2 years ago
- asked 2 years ago
Thanks Randy. Before I try the "hairpin nat", can I confirm that If the Teleport CIDR is different from Local IPv4 network CIDR in the s2s vpn connection, will the vpn allow the Teleport traffic to go through even though I already added the IP prefixes to Static routes? The s2s vpn was set up using the customer gateway of our office network CIDR. Do I need to create another customer gateway with Teleport's CIDR as the Local IPv4 network CIDR?