Netgate SG-1000 microFirewall

Author Topic: OpenVPN NAT  (Read 165 times)

0 Members and 1 Guest are viewing this topic.

Offline Soarin

  • Jr. Member
  • **
  • Posts: 67
  • Karma: +7/-0
    • View Profile
OpenVPN NAT
« on: October 10, 2017, 02:43:17 am »
Hello!

I've been trying to make my OpenVPN be a transportation system for my friend's servers, they host some small servers that aren't latency sensitive but they don't want to expose their own IP for security reasons. So I decided to try to configure OpenVPN to route their traffic to my network and let me NAT it for them.

They don't have pfSense so I can't do site to site, they'll just be a client. I had made an interface and NAT'd in multiple ways but I eventually deleted all of it and decided to start fresh after making a mess. Is there any guides to help me with this goal?

I had gotten it to work before but it was messy and I forgot how to do it, I'd rather let experienced members help me with the proper way.
I hardly understand pfSense but it was love at first sight.

Offline JKnott

  • Hero Member
  • *****
  • Posts: 780
  • Karma: +29/-4
    • View Profile
Re: OpenVPN NAT
« Reply #1 on: October 10, 2017, 06:11:53 am »
When I set up OpenVPN, to use with my notebook, I didn't have to do anything special.  I just created another subnet for VPN use that was different from the LAN subnet.  I let the Wizard do it's thing and exported the configuration.  I did this for both IPv4 and IPv6.

Offline Soarin

  • Jr. Member
  • **
  • Posts: 67
  • Karma: +7/-0
    • View Profile
Re: OpenVPN NAT
« Reply #2 on: October 10, 2017, 07:03:11 am »
Thanks for the reply, how would I run a server through it though? I'm using it like a GRE tunnel, hide the source server IP but route it through the VPN for a new public IP.
I hardly understand pfSense but it was love at first sight.

Offline JKnott

  • Hero Member
  • *****
  • Posts: 780
  • Karma: +29/-4
    • View Profile
Re: OpenVPN NAT
« Reply #3 on: October 10, 2017, 07:56:37 am »
????

When you create an OpenVPN tunnel, it sets up everything for you.  It sets up the routing, opens a port in the firewall and creates the configuration to use on the computer.  Once you're connected via the VPN, psSense takes care of the routing.

Offline Soarin

  • Jr. Member
  • **
  • Posts: 67
  • Karma: +7/-0
    • View Profile
Re: OpenVPN NAT
« Reply #4 on: October 10, 2017, 08:46:47 am »
I'll try to explain it a bit better.

Take a GRE tunnel for example, I have one connecting my home pfSense to my pfSense VPS in Maimi, FL. With that GRE, I can route my traffic from my server (Let's say video game server, like Half-Life 2) through it, changing the IP of the server that the players join.

My question is how to NAT a game server to go through the VPN from the client to be displayed as the VPN Server's IP. I don't redirect gateway, since it's pretty much a dedicated VPN to route only server traffic through.
I hardly understand pfSense but it was love at first sight.