HELP: Forwarding Traffic to VPN Client
Posted: Thu Jun 01, 2023 10:56 pm
I am running Access Server in AWS, and I have a web server running at port 5000 in my VPN client.
I would like to forward all port 5000 traffic to my client.
Tried using IpTables but unfortunately does not reflect my commands from the command line. Currently trying the configuration with NFtables but still not forwarding traffic to my client's web service.
nft 'add chain nat POSTROUTING { type nat hook postrouting priority 100 ; }'
nft 'add chain nat PREROUTING { type nat hook prerouting priority -100; }'
nft 'add rule nat PREROUTING ip daddr 172.31.29.25 tcp dport {5000} dnat 192.168.10.66:5000'
nft add rule nat POSTROUTING masquerade
----------------------------------------------
EC2 private IP: 172.31.29.25
VPN client IP: 192.168.10.66
I am setting this up since my home network is under CGNAT. I hope someone can help me out.
I would like to forward all port 5000 traffic to my client.
Tried using IpTables but unfortunately does not reflect my commands from the command line. Currently trying the configuration with NFtables but still not forwarding traffic to my client's web service.
nft 'add chain nat POSTROUTING { type nat hook postrouting priority 100 ; }'
nft 'add chain nat PREROUTING { type nat hook prerouting priority -100; }'
nft 'add rule nat PREROUTING ip daddr 172.31.29.25 tcp dport {5000} dnat 192.168.10.66:5000'
nft add rule nat POSTROUTING masquerade
----------------------------------------------
EC2 private IP: 172.31.29.25
VPN client IP: 192.168.10.66
I am setting this up since my home network is under CGNAT. I hope someone can help me out.