Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Mapping VPN addresses to internal LAN addresses

    Scheduled Pinned Locked Moved NAT
    7 Posts 3 Posters 1.4k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D
      DavidK
      last edited by

      I am running a network with a Cisco ASA that is providing DHCP and acting as the gateway for all of the machines on the network. For a variety of reasons, we want to replace the Cisco with a pfSense firewall. So far, we have successfully built and installed the firewall and it is connected to a separate outside IP.

      We next installed OpenVPN on the pfSense and that works fine as well, except that from machines that are VPN'd in, we can only ping internal machines that use the pfSense as a gateway, not machines that use the Cisco as a gateway. This is expected since the internal LAN is 192.168.180.0/24 and the VPN addresses are 10.1.1.0/24 so they appear to be 'outside' addresses to machines on the LAN.

      I would like to configure the pfSense to map the 10.1.1.x VPN addresses to internal 192.168.180.x addresses so that I can connect to the internal machines.

      What is the best way to do that.

      Thanks!

      1 Reply Last reply Reply Quote 0
      • DerelictD
        Derelict LAYER 8 Netgate
        last edited by

        A better way would be to install a route that routes traffic for the LAN served by the ASA to the ASA.  And a route in the ASA sending traffic served by pfSense to pfSense.

        Vastly better than trying to do an OpenVPN bridge, which is not a recommended config.

        Chattanooga, Tennessee, USA
        A comprehensive network diagram is worth 10,000 words and 15 conference calls.
        DO NOT set a source address/port in a port forward or firewall rule unless you KNOW you need it!
        Do Not Chat For Help! NO_WAN_EGRESS(TM)

        1 Reply Last reply Reply Quote 0
        • D
          DavidK
          last edited by

          Thanks Derelict,

          We were hoping that we could run both firewalls together for a period of time as we gradually obsolete the Cisco. The problem is that the Cisco 5505 doesn't have much horsepower and easily becomes overwhelmed in the face of attacks from China. We're working with our ISP, but that seems to be a lengthy process.

          In the meantime, we need a reliable VPN to remotely access our internal machines. We have the Cisco at outside address x.x.x.74 and the pfSense at outside address x.x.x.78. So far the pfSense handles all the noise very easily.

          I was hoping to "spoof" the internal machines to think that they were talking to another internal machine, even though they are actually talking to the VPN 10.1.1.1. As I mentioned in my previous post, they are all treating the 10.1.1.1 as an external address and sending outbound traffic through the Cisco.

          I guess we will have to bite the bullet and just change the firewalls one late night.

          Thanks for your thoughts!

          1 Reply Last reply Reply Quote 0
          • DerelictD
            Derelict LAYER 8 Netgate
            last edited by

            If you have an extra interface or VLAN on each firewall you just need a /30 between the two and a couple quick static routes.  Maybe a couple firewall rules. No big deal.

            Chattanooga, Tennessee, USA
            A comprehensive network diagram is worth 10,000 words and 15 conference calls.
            DO NOT set a source address/port in a port forward or firewall rule unless you KNOW you need it!
            Do Not Chat For Help! NO_WAN_EGRESS(TM)

            1 Reply Last reply Reply Quote 0
            • D
              DavidK
              last edited by

              Thanks! I'll check that out.

              1 Reply Last reply Reply Quote 0
              • V
                viragomann
                last edited by

                Another easy solution is to add an Outbound NAT rule to pfSense to translate the OVPN net to LAN address:

                
                LAN     10.1.1.0/24      *      *      *      LAN address      *      NO      OVPN NAT
                
                

                So the VPN source IP is translated to LAN address when the packet go out LAN interface and responses will find the right way back. pfSense does the rest.

                1 Reply Last reply Reply Quote 0
                • D
                  DavidK
                  last edited by

                  Thanks viragomann!

                  That solution worked perfectly.

                  1 Reply Last reply Reply Quote 0
                  • First post
                    Last post
                  Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.