0

My intention is to create a VPN server.

So i created and configured an instance on AWS as a VPN server (Pfsense), then i added in the security groups the destination 0.0.0.0/0 of the VPN port (1194). It works very well.

When I connect to the VPN, my public IP address is changed to the one on the VPN.

Now my intention is to restrict access to ports 80, 443 and 22 to only the public IP address of the VPN. With other servers it works but with itself it doesn't.

Why can i restrict access to another server but I can't do with the same server?

Also I didn't see any logical explanation for this problem to occur, has anyone faced this same problem?

  • Paying for a static IP on your dynamic IP (assume home internet connection) might be the easiest way. – Tim Aug 13 '22 at 03:26
  • Thanks for your answer, but i expect to access when i connect to my OPENVPN server (PFSENSE on AWS), not using my public ip address from my home connection. – Lucas Polloni Aug 14 '22 at 10:08
  • Suggest you edit your question to make it easier to follow. It's easier to answer a question when the current state and the problem are labeled and clearly described. – Tim Aug 14 '22 at 19:03
  • Hello, thank you for your help, just edited the question, i hope you can now understand better than before, thank you. – Lucas Polloni Aug 16 '22 at 10:37
  • Where you say "Now my intention is to restrict access to ports 80, 443 and 22 to only the public IP address of the VPN. With other servers it works but with itself it doesn't.". Why are you trying to do this - what are you trying to achieve? How have you tried to do it? VPN configuration, iptables configuration, security groups, etc? – Tim Aug 16 '22 at 18:48

0 Answers0