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

    Does OpenVPN favour IPv4?

    Scheduled Pinned Locked Moved OpenVPN
    6 Posts 2 Posters 552 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.
    • JKnottJ
      JKnott
      last edited by

      I just noticed something curious. I have many devices on my LAN with both IPv4 and IPv6 addresses. When my notebook computer connected directly to my LAN and I ping one of those devices, the IPv6 address is used. However, if I connect to my LAN via OpenVPN and do the same, the IPv4 address is used. However, if I ping something out on the Internet, such as google.com or yahoo.com, IPv6 is used.

      Any idea what might be causing this curiosity? Redirect IPv4 & IPv6 gateways are selected.

      PfSense running on Qotom mini PC
      i5 CPU, 4 GB memory, 32 GB SSD & 4 Intel Gb Ethernet ports.
      UniFi AC-Lite access point

      I haven't lost my mind. It's around here...somewhere...

      1 Reply Last reply Reply Quote 0
      • jimpJ
        jimp Rebel Alliance Developer Netgate
        last edited by

        When you ping over OpenVPN, how is it resolving the target? It may only be getting an A response back or using some other method like NBNS perhaps which doesn't do IPv6?

        Remember: Upvote with the ๐Ÿ‘ button for any user/post you find to be helpful, informative, or deserving of recognition!

        Need help fast? Netgate Global Support!

        Do not Chat/PM for help!

        JKnottJ 1 Reply Last reply Reply Quote 0
        • JKnottJ
          JKnott @jimp
          last edited by

          @jimp

          I am using the pfSense resolver for both LAN and via OpenVPN. I can force IPv6, with ping -6, but normally, I'd have to force IPv4. Also, Block Outside DNS is selected.

          PfSense running on Qotom mini PC
          i5 CPU, 4 GB memory, 32 GB SSD & 4 Intel Gb Ethernet ports.
          UniFi AC-Lite access point

          I haven't lost my mind. It's around here...somewhere...

          1 Reply Last reply Reply Quote 0
          • jimpJ
            jimp Rebel Alliance Developer Netgate
            last edited by

            Right but OpenVPN is just a transport there. Sniff the DNS requests and see what the client is doing.

            Remember: Upvote with the ๐Ÿ‘ button for any user/post you find to be helpful, informative, or deserving of recognition!

            Need help fast? Netgate Global Support!

            Do not Chat/PM for help!

            JKnottJ 1 Reply Last reply Reply Quote 0
            • JKnottJ
              JKnott @jimp
              last edited by

              @jimp said in Does OpenVPN favour IPv4?:

              Right but OpenVPN is just a transport there.

              That's what I thought. My suspicion was the OpenVPN client might have something to do with it. Regardless, I pinged an address on my LAN via both OpenVPN and direct Ethernet connections. With both, Wireshark showed the sequence:
              A query
              AAAA query
              A response
              AAAA response

              So, the only difference is one connection is via OpenVPN and the other, Ethernet.

              My notebook is running OpenSUSE Linux 15.0. I got the same result on Ethernet with my desktop system running 15.1.

              PfSense running on Qotom mini PC
              i5 CPU, 4 GB memory, 32 GB SSD & 4 Intel Gb Ethernet ports.
              UniFi AC-Lite access point

              I haven't lost my mind. It's around here...somewhere...

              1 Reply Last reply Reply Quote 0
              • jimpJ
                jimp Rebel Alliance Developer Netgate
                last edited by

                Might be something in the client that prioritizes RFC1918 addresses to prevent VPN leakage in cases like that. It's unfortunately common for people to accidentally mix DNS like that and unintentionally send private traffic across public networks via IPv6 when it was meant to stay private on IPv4.

                Remember: Upvote with the ๐Ÿ‘ button for any user/post you find to be helpful, informative, or deserving of recognition!

                Need help fast? Netgate Global Support!

                Do not Chat/PM for help!

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