Skip to main content
sarahjohn
New Member
December 27, 2017
Question

AWS VPN NAT'ing

  • December 27, 2017
  • 2 replies
  • 4542 views

Hello Friends, I have been facing with an issue help me with that.

 

This seems like a basic questions, but I'm having difficulty finding an appropriate solution.

 

I have a VPN connection to AWS and need to access my EC2 instance at, say, 10.1.0.40, but I already have a subnet locally for 10.1.0.x/24. How can I NAT the address in AWS so that when it receives data through this VPN, it maps, say 10.1.50.40 to 10.1.0.40?

 

This seems like it would be a pretty basic request, but I can't seem to find the solution on AWS Certified. NAT instances and NAT gateways all talk about accessing the Internet from a private server and seem to have little to do with this simple address translation from a VPN connection.

 

What am I missing?

 

Thank you!

Sarahjohn

2 replies

mahesh_secure
New Member
December 29, 2017

Hi

 

create a new ip pool under firewall --> ip pool ( 172.16.1.1-172.16.1.1). set this ip as customer end ip in AWS vpn configuration. now add this ip pool in vpn policy from LAN to AWS vpn enabled NAT and use custom ip pool.

all your traffic from lan to aws will nat with NAT ip pool.

 

 

Regards

Mahesh

 

Johnson267
New Member
February 2, 2022
You cannot use AWS NAT Gateway or an EC2 instance to solve the problem of CIDR overlap when setting up a VPN connection. For this to work either
  • NATing should happen from On-Premise.
  • Create a new private subnet to represent in your VPC side.
  • To user Third-party VPN solution hosting on an EC2 instance which supports your use case, instead of using VPC native VPN.

https://www.kbstraining.com/aws-training.html