Netgate SG-1000 microFirewall

Author Topic: NAT Translation issues with OpenVPN on a private network  (Read 140 times)

0 Members and 1 Guest are viewing this topic.

Offline pkris

  • Newbie
  • *
  • Posts: 4
  • Karma: +0/-0
    • View Profile
NAT Translation issues with OpenVPN on a private network
« on: January 05, 2018, 04:52:44 pm »
Hey all,

Iíve got a pfSense box thatís acting as a firewall and an OpenVPN server in my rack at a datacenter.

Iíve set Redirect all traffic through gateway, I can access the World Wide Web when connected to VPN.

Essentially, when connected to VPN my virtual IP is on the LAN subnet (10.8.200.XX), but because it's doing the translation to the Internet for the public IPs of each VM, I can only access internal web servers via their LAN (and not public) IP when connected to VPN. Is double NAT the best option, is there a way to re-write these IPs for VPN connected clients?

Example: Public IP of 10.10.10.10 redirects to LAN IP 10.8.200.1 on my pfSense, I do this so I can say, forward only port 80 to 10.8.200.1.

When connected to VPN I get a virtual IP of 10.8.255.3, which can talk to 10.8.200.1, but NOT 10.10.10.10 (the public IP of the webserver locate at 10.8.200.1) this means I can't visit my ticketing system when over VPN, etc... therefore I can't lock it down via public IP address.

If I edit the /etc/hosts file on my computer, sure I can add

Code: [Select]
10.8.200.1 myticketingsystem.com
But, that's not really a solution, and can't be deployed to all my employees quickly...

Offline Derelict

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 9591
  • Karma: +1089/-309
    • View Profile
Re: NAT Translation issues with OpenVPN on a private network
« Reply #1 on: January 05, 2018, 10:23:02 pm »
https://doc.pfsense.org/index.php/Why_can%27t_I_access_forwarded_ports_on_my_WAN_IP_from_my_LAN/OPTx_networks

I do not know if NAT reflection will work from an OpenVPN client.

If it does not initially work, assign an interface and maybe move the pass rules to the assigned interface and remove them from the OpenVPN tab.
Las Vegas, Nevada, USA
Use this diagram to describe your issue.
The pfSense Book is now available for just $24.70!
Do Not PM For Help! NO_WAN_EGRESSTM

Offline pkris

  • Newbie
  • *
  • Posts: 4
  • Karma: +0/-0
    • View Profile
Re: NAT Translation issues with OpenVPN on a private network
« Reply #2 on: January 12, 2018, 11:03:22 am »
That did it, holy crap.

Thank you so much.