AWS Details: https://docs.aws.amazon.com/vpn/latest/s2svpn/VPNTunnels.html
- Install Openswan (details: https://www.openswan.org/)
$ sudo su
$ yum install openswan
- Update /etc/sysctl.conf:
net.ipv4.ip_forward=1net.ipv4.conf.all.accept_redirects=0net.ipv4.conf.all.send_redirects=0
- Restart network service
$ service network restart
- VPC A: Create VGW, Customer Gateway and a VPN Connection. Download `generic` configuration
- Configure Openswan ( IPSec tunnels ) based on the information provided in the downloaded configuration:
- $ vi /etc/ipsec.d/aws-vpn.conf:
conn Tunnel1authby=secret auto=start left=%defaultroute leftid=<Customer Gateway IP> right=<AWS Virtual Private gateway IP> type=tunnel ikelifetime=8h keylife=1h phase2alg=aes128-sha1;modp1024 ike=aes128-sha1;modp1024 keyingtries=%forever keyexchange=ike leftsubnet=<Customer CIDR> rightsubnet=<AWS VPC CIDR> dpddelay=10 dpdtimeout=30 dpdaction=restart_by_peer
- $ vi /etc/ipsec.d/aws-vpn.secrets
<Customer gateway IP> <AWS VGW IP>: PSK "<Pre-Shared Key>"
- $ chkconfig ipsec on
- $ service ipsec start
- $ service ipsec status

No comments:
Post a Comment