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

    Local Network Protection for IPv6

    IPv6
    4
    37
    4.6k
    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

      If you read what I said, I was referring to a VPN service provider, not my ISP.

      I guess I misread "My service provider NATs both the ipv4 and the ipv6 addresses." because you didn't say you got a VPN from a service provider.  I have set up several VPNs in my time and never used a service provider.

      Regardless, where does NAT fit in with your description?  You could use Unique Local Addresses for the VPN, just as you'd use  RFC 1918 addresses on IPv4.  Neither requires NAT.  What address range does the VPN service supply?  They could have a public /48 or other suitable prefix and assign a /64 on a temporary basis to users.  I believe that was also mentioned in that RFC.

      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
      • JKnottJ
        JKnott
        last edited by

        as a single dropped cookie

        Yeah, you don't want to toss your cookies!  ;)

        In fact, just don't deploy IPv6 if a tin-foil hat is part of your wardrobe!

        Or IPv4 for that matter.

        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
        • B
          bimmerdriver
          last edited by

          @JKnott:

          If you read what I said, I was referring to a VPN service provider, not my ISP.

          I guess I misread "My service provider NATs both the ipv4 and the ipv6 addresses." because you didn't say you got a VPN from a service provider.  I have set up several VPNs in my time and never used a service provider.

          Regardless, where does NAT fit in with your description?  You could use Unique Local Addresses for the VPN, just as you'd use  RFC 1918 addresses on IPv4.  Neither requires NAT.  What address range does the VPN service supply?  They could have a public /48 or other suitable prefix and assign a /64 on a temporary basis to users.  I believe that was also mentioned in that RFC.

          If I pay a company to provide a service, it is a service provider, IMO. An ISP is a service provider, but not all service providers are ISPs.

          When I'm connected "through" Telus (i.e., without the VPN connected), my public ipv4 and ipv6 addresses are the assigned ipv4 and a UGA allocated using the assigned ipv6 prefix. They are "traceable" to me, subject to how well Telus maintains logs. When I connect to the VPN service, I can choose from their list of servers which are located around the world. Each server provides different ipv4 and ipv6 addresses, both of which are shared. Depending on the location of the server a different "service provider" is used. I don't choose the addresses. They are assigned when the client connects to the server. The computer sees private ipv4 and ipv6 addresses, but when you use a website like ipv6-test.com, only the public addresses are visible. When I'm connected, I get ads in the local language. It's as if I'm in the location connected using the particular local service provider. The addresses are NATed between private and public by the VPN server. This is how typical VPN services such as PIA or whatever work. If you set up your own VPN server, it's going to be using your ipv4 address and ipv6 prefix. Such a VPN isn't very useful if you are trying to spoof your location or have addresses that aren't traceable to you.

          1 Reply Last reply Reply Quote 0
          • johnpozJ
            johnpoz LAYER 8 Global Moderator
            last edited by

            Hiding behind a vpn providers IP range has ZERO to do with natting the ipv6 address they give your client.. With the almost infinite address space that ipv6 provides there is zero reason for them to NAT this ipv6 address they give the vpn client..

            They would use a tunnel network just like you do in ipv4.  The only reason the tunnel network in ipv4 is normally rfc1918 is the vpn provider doesn't have a shitton of ipv4 public space to use ;)

            There would be ZERO reason for a ipv6 vpn provider to NAT this address space to hide their users real IPv6 address..  To the public the IPv6 address these users come from would still be registered to the VPN provider.. The ipv6 address your traffic presents to the world would be theirs, and not registered to you or your ISP in anyway.

            The only reason you share IPs in the IPv4 world is their is lack of them!!!

            As to the vpn tracking which user tunnel IP is what public IP would be to the vpn provider logging.

            An intelligent man is sometimes forced to be drunk to spend time with his fools
            If you get confused: Listen to the Music Play
            Please don't Chat/PM me for help, unless mod related
            SG-4860 24.11 | Lab VMs 2.7.2, 24.11

            1 Reply Last reply Reply Quote 0
            • awebsterA
              awebster
              last edited by

              As to the vpn tracking which user tunnel IP is what public IP would be to the vpn provider logging.

              And via tossed cookies.  :P

              Not sure who your "tin-foil hat" comment is directed at.

              Not directed at anyone in particular, but generally to people that think that casually using a PIA offers them anonymity.

              I get it, people just want to use torrents and not receive threatening legal letters, but my point is that if you are serious about achieving a true level of anonymity, you first need to ensure that your anonymous environment cannot ever connect to anything without going through a VPN.  You need to select PIA providers that don't keep logs and you need to  change your ISP and PIA providers from time-to-time.  You need to setup machines that will be accessing the Internet anonymous from scratch and from trusted sources, and  you need rebuild them from time-to-time, or use a read-only machine VM instance.  And you better be aggressively blocking Google, Facebook, Twitter and all other social media services.  You must use all new accounts anonymously.  You need to study movies like "Enemy of the state", and "The Conversation", and on and on and on….The required effort is huge, and you must never make a mistake.  :-X

              –A.

              1 Reply Last reply Reply Quote 0
              • B
                bimmerdriver
                last edited by

                @awebster:

                As to the vpn tracking which user tunnel IP is what public IP would be to the vpn provider logging.

                And via tossed cookies.  :P

                Not sure who your "tin-foil hat" comment is directed at.

                Not directed at anyone in particular, but generally to people that think that casually using a PIA offers them anonymity.

                I get it, people just want to use torrents and not receive threatening legal letters, but my point is that if you are serious about achieving a true level of anonymity, you first need to ensure that your anonymous environment cannot ever connect to anything without going through a VPN.  You need to select PIA providers that don't keep logs and you need to  change your ISP and PIA providers from time-to-time.  You need to setup machines that will be accessing the Internet anonymous from scratch and from trusted sources, and  you need rebuild them from time-to-time, or use a read-only machine VM instance.  And you better be aggressively blocking Google, Facebook, Twitter and all other social media services.  You must use all new accounts anonymously.  You need to study movies like "Enemy of the state", and "The Conversation", and on and on and on….The required effort is huge, and you must never make a mistake.  :-X

                I think I was pretty clear that I'm not trying to achieve privacy from NSA or I would be using tor and resorting to the other measures you mentioned. I use a VPN for two purposes. First is geolocation. Second is for torrenting. For these purposes, it works as advertised. My vpn service provider does not log. I'm happy.

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

                  When you get an IPv6 VPN, what address range is it in?  If it starts with 2, then it's a public address that's given to you to use and does not need NAT.  If it starts with fd, then it's a Unique Local Address that requires NAT.

                  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
                  • B
                    bimmerdriver
                    last edited by

                    @johnpoz:

                    Hiding behind a vpn providers IP range has ZERO to do with natting the ipv6 address they give your client.. With the almost infinite address space that ipv6 provides there is zero reason for them to NAT this ipv6 address they give the vpn client..

                    They would use a tunnel network just like you do in ipv4.  The only reason the tunnel network in ipv4 is normally rfc1918 is the vpn provider doesn't have a shitton of ipv4 public space to use ;)

                    There would be ZERO reason for a ipv6 vpn provider to NAT this address space to hide their users real IPv6 address..  To the public the IPv6 address these users come from would still be registered to the VPN provider.. The ipv6 address your traffic presents to the world would be theirs, and not registered to you or your ISP in anyway.

                    The only reason you share IPs in the IPv4 world is their is lack of them!!!

                    As to the vpn tracking which user tunnel IP is what public IP would be to the vpn provider logging.

                    When I go to ipv6-test.com while the vpn is not connected, it shows both addresses are from my isp. When I go to ipv6-test.com while the vpn is connected, it shows both addresses are from the local service provider where the vpn server is located. These addresses are shared. When my pc is connected to the vpn, it has private ipv4 (10…) and ipv6 (fdda::...) addresses according to ipconfig. The vpn connection is NATing the private addresses to the shared public addresses. Maybe they could or should have set it up differently, but as far as I'm concerned, it works, so that's good enough for me.

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

                      When my pc is connected to the vpn, it has private ipv4 (10…) and ipv6 (fdda::...) addresses according to ipconfig. The vpn connection is NATing the private addresses to the shared public addresses. Maybe they could or should have set it up differently, but as far as I'm concerned, it works, so that's good enough for me.

                      Yes they should have done IPv6 differently.  By using a Unique Local Address, they're forcing NAT to be used, with all it's problems.  With all the IPv6 addresses available, they could have used a public address and avoided NAT.  I don't know how many addresses they give you, but a single /64 has 2^64 addresses available.  That's the entire IPv4 address space squared!

                      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
                      • B
                        bimmerdriver
                        last edited by

                        @JKnott:

                        When my pc is connected to the vpn, it has private ipv4 (10…) and ipv6 (fdda::...) addresses according to ipconfig. The vpn connection is NATing the private addresses to the shared public addresses. Maybe they could or should have set it up differently, but as far as I'm concerned, it works, so that's good enough for me.

                        Yes they should have done IPv6 differently.  By using a Unique Local Address, they're forcing NAT to be used, with all it's problems.  With all the IPv6 addresses available, they could have used a public address and avoided NAT.  I don't know how many addresses they give you, but a single /64 has 2^64 addresses available.  That's the entire IPv4 address space squared!

                        No one is questioning that there are 2^64 addresses available in a /64 prefix. However, shared public addresses are considered a feature, because they further obscure individual users. There's no way to share public addresses without translating the individual private addresses to the shared public address. NAT or not, the vpn works. I can max out my available bandwidth and it does exactly what I want.

                        1 Reply Last reply Reply Quote 0
                        • johnpozJ
                          johnpoz LAYER 8 Global Moderator
                          last edited by

                          "There's no way to share public addresses without translating the individual private addresses to the shared public address"

                          Not really true - you could quite easy use a proxy to have multiple users traffic be coming from the same public IP without any actual nat.

                          Also with ipv6 done how its designed, outbound traffic from a client would use multiple IPs all the time.. These Temporary Addresses would expire and new ones created all the time.  So the odds of someone tracking a users actions based upon their IPv6 would be quite difficult because they would use different address all the time for their different connections, and one session might use address X while traffic to some other place would come from address Y.

                          Really the whole point of NAT as a feature to hide someones behavior is gone with the privacy extensions that are built into ipv6.  So while someone would be able to track your IPv6 address to the ISP providing you said address, unless the isp is giving away your info there would normally be no way for someone to know who that IPv6 address is actually registered too.  So you trust the vpn provider more than the isp in giving away said info.  Or your wanting to use the vpn to hide your behavior from your ISP.

                          An intelligent man is sometimes forced to be drunk to spend time with his fools
                          If you get confused: Listen to the Music Play
                          Please don't Chat/PM me for help, unless mod related
                          SG-4860 24.11 | Lab VMs 2.7.2, 24.11

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

                            These Temporary Addresses would expire and new ones created all the time.

                            Quite so.  On my Linux system, I get a new privacy address every 24 hours and they have a lifetime of only 5 or 6 days.  Compare that to the 5000 years it would take to scan a single /64, with a 40 Gb connection, according to the RFC I referenced for this thread.

                            Getting back to the VPN, if a service provider simply provided temporary use of a single address in a /64 for the VPN, then the user would be just as hidden as behind NAT.

                            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
                            • B
                              bimmerdriver
                              last edited by

                              You're both missing the point and getting hung up on semantics. Irrespective of whether "NAT" or a proxy server or some other mechanism is used, a reasonable expectation from a vpn service provider is for to provide public addresses that are not associated with the isp-provided addresses or prefix. The mechanism used to achieve that is immaterial. According to my vpn service provider, "NAT" is being used in their openvpn configuration. They could use magic, as long as they accomplish the same result. It makes no difference.

                              I attached three screen captures.

                              The first is the result of ipv6-test.com when the vpn is not connected. It's possible to determine my isp and my approximate location. The address is the privacy address, not the dhcpv6 address. Both the ipv4 address and the ipv6 prefix are directly associated with me.

                              The second is output from ipconfig /all with the vpn connected. You can see the private addresses used by the vpn, as well as the public addresses used when the vpn is not connected.  (This screen capture was taken at a different time so the privacy address is not the same as above.)

                              The third is the result of ipv6-test.com when the vpn is connected to a server in sweden. It shows the isp the vpn server is connected to and it shows the location in sweden. If I browse to a website, I see local ads in the swedish language. I get local ads for whatever server I connect to. I can view regional content that would otherwise be "not available in my location".

                              This is exactly what I would expect a vpn to do. It completely defeats the purpose of a vpn if the public ipv6 address uses my isp-provided prefix.

                              The issue of whether I trust my vpn service provider more than my isp is somewhat moot, because my isp cannot / will not offer public ip addresses in another geographic location. However, since you bring up trust, my vpn service provider keeps no logs and they have no record of my name or my email address. My isp clearly has that info and more. I completely trust my isp to act in its self-interest. They have my contact info and I don't doubt they would provide it if they were compelled. My vpn service provider has nothing to give, even if it's compelled. For me, this is a big deal, but not nearly as big a deal for me as it is for a person who lives in a country where there is censorship, such as China or Iran.

                              In the (distant) future when isps stop handing out ipv4 addresses, people will still be using vpns for a variety of reasons. A vpn that uses a privacy address allocated using the subscriber's isp-provided prefix is an oxymoron and would serve no purpose. It's neither virtual, nor private.  I don't get why you're beating on this dead horse. A privacy address has a valid purpose, but it's not equivalent to a vpn.

                              Capture.PNG
                              Capture.PNG_thumb
                              ![Capture 2.PNG](/public/imported_attachments/1/Capture 2.PNG)
                              ![Capture 2.PNG_thumb](/public/imported_attachments/1/Capture 2.PNG_thumb)
                              ![Capture 3.PNG](/public/imported_attachments/1/Capture 3.PNG)
                              ![Capture 3.PNG_thumb](/public/imported_attachments/1/Capture 3.PNG_thumb)

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

                                You're both missing the point and getting hung up on semantics. Irrespective of whether "NAT" or a proxy server or some other mechanism is used, a reasonable expectation from a vpn service provider is for to provide public addresses that are not associated with the isp-provided addresses or prefix.

                                And once again, there is no need to use NAT to do that.  Any VPN provider can get a block of global addresses and hand them out as needed, on a temporary basis to their users.  That address will be one of theirs, not yours and can be different every time you connect or even changed periodically.

                                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
                                • awebsterA
                                  awebster
                                  last edited by

                                  … this is a big deal, but not nearly as big a deal for me as it is for a person who lives in a country where there is censorship, such as China or Iran.

                                  Since you brought this up, I've seen that the great firewall of China does a remarkably good job at blocking VPNs. 
                                  I said it before, the IP or IPv6 address the user is using is inconsequential to the identification of the user behavior, and subsequently the user.
                                  In the case of China, it appears that they are using a mechanism by which DNS requests to certain sites resolve to one IP inside China and another outside.  The sites (perhaps gov't run banner ads) could  drop unique cookies on the user's machine, or clever javascript trickery, and if the same cookie ID comes back from an outside facing IP within a certain time window, that means that the user has brought up a VPN.  You now can pick off the IP (could by IPv4 or IPv6) and filter it.  If the ISP is state run, well, you know what can happen next.

                                  So the VPN makes sense for certain use cases that were discussed previously, but if you're in a country where VPN use is controlled, or the government simply wants to keep tabs on what its citizens are doing, privacy addresses, NAT, VPN won't get you anywhere unless you are willing to take all the necessary precautions to evade detection.  Tails might help here, but the great firewall is pretty good at blocking TOR traffic too. YMMV.

                                  –A.

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

                                    I am going to provide an example that shows NAT is not necessary.  Prior to my ISP offering IPv6 last year, I used a 6in4 tunnel for 6 years from a service called gogo6.  They offered a /56 prefix or a single static IPv6 address to a registered account or a single random IPv6 address to an anonymous connection.  I used the prefix on my home network, but the anonymous connection on my notebook computer, when away from home.  That IPv6 address was not in any way assigned to me.  I just used whatever address was available.  How does this differ from what you're trying to accomplish with a VPN?  Also, that service had a few servers around the world.  I used the one in Montreal, but one of the others, which I recall, was in Amsterdam.  So, I could have made an anonymous connection to any of the servers around the world , received a random address, yet required absolutely no use of NAT.  What does your VPN provide, other than possibly encryption, that the anonymous connection didn't?  Also, I bet that gogo6 service had far more IPv6 addresses to hand out, than the IPv4 & port number combinations that your VPN service offers.  Seems to me that's a bit more secure.

                                    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
                                    • johnpozJ
                                      johnpoz LAYER 8 Global Moderator
                                      last edited by

                                      ^ same with Hurricane Electrics IPv6 tunnel.. Which I use because my isp ipv6 deployment is flaky..  While my tunnel runs and runs and runs and I get a /48 to work with.

                                      "It shows the isp the vpn server is connected to and it shows the location in sweden. If I browse to a website, I see local ads in the swedish language."

                                      If your goal is circumvention of some geo restrictions then sure use a VPN, that still has zero to do with them NATing the ipv6 address they give you.  I can create tunnels to any of the HE sites all over the globe, etc.  Some services even block HE ipv6 space as vpn service - since you can tunnel to different regions of the globe to circumvent restrictions.

                                      "In the (distant) future when isps stop handing out ipv4 addresses, people will still be using vpns for a variety of reasons"
                                      Nobody is disagreeing with you on this - its just that the VPN provider has zero need to NAT the ipv6 address they give you. NONE!!!

                                      An intelligent man is sometimes forced to be drunk to spend time with his fools
                                      If you get confused: Listen to the Music Play
                                      Please don't Chat/PM me for help, unless mod related
                                      SG-4860 24.11 | Lab VMs 2.7.2, 24.11

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

                                        No one is questioning that there are 2^64 addresses available in a /64 prefix. However, shared public addresses are considered a feature, because they further obscure individual users.

                                        One question, how many addresses are in the shared pool? 1? 10? 100?  The thing about NAT is the server has to actually be configured for the addresses being used and provide the memory and other resources to process NAT.  So, you'd have as many addresses as they provide multiplied by the number of ports available, which is 65536 minus the 1024 well known ports or 64512.  So, even if they used 100 separated addresses, you'd have nowhere near as many address/port combinations as simply making a single /64 available to users.

                                        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
                                        • B
                                          bimmerdriver
                                          last edited by

                                          @awebster:

                                          … this is a big deal, but not nearly as big a deal for me as it is for a person who lives in a country where there is censorship, such as China or Iran.

                                          Since you brought this up, I've seen that the great firewall of China does a remarkably good job at blocking VPNs. 
                                          I said it before, the IP or IPv6 address the user is using is inconsequential to the identification of the user behavior, and subsequently the user.
                                          In the case of China, it appears that they are using a mechanism by which DNS requests to certain sites resolve to one IP inside China and another outside.  The sites (perhaps gov't run banner ads) could  drop unique cookies on the user's machine, or clever javascript trickery, and if the same cookie ID comes back from an outside facing IP within a certain time window, that means that the user has brought up a VPN.  You now can pick off the IP (could by IPv4 or IPv6) and filter it.  If the ISP is state run, well, you know what can happen next.

                                          So the VPN makes sense for certain use cases that were discussed previously, but if you're in a country where VPN use is controlled, or the government simply wants to keep tabs on what its citizens are doing, privacy addresses, NAT, VPN won't get you anywhere unless you are willing to take all the necessary precautions to evade detection.  Tails might help here, but the great firewall is pretty good at blocking TOR traffic too. YMMV.

                                          I know people in China who use VPNs to get past / around the "great firewall". I guess this is like the attempts to block pirate bay. Shut down one address and two more replace it.

                                          1 Reply Last reply Reply Quote 0
                                          • B
                                            bimmerdriver
                                            last edited by

                                            @johnpoz:

                                            ^ same with Hurricane Electrics IPv6 tunnel.. Which I use because my isp ipv6 deployment is flaky..  While my tunnel runs and runs and runs and I get a /48 to work with.

                                            "It shows the isp the vpn server is connected to and it shows the location in sweden. If I browse to a website, I see local ads in the swedish language."

                                            If your goal is circumvention of some geo restrictions then sure use a VPN, that still has zero to do with them NATing the ipv6 address they give you.  I can create tunnels to any of the HE sites all over the globe, etc.  Some services even block HE ipv6 space as vpn service - since you can tunnel to different regions of the globe to circumvent restrictions.

                                            "In the (distant) future when isps stop handing out ipv4 addresses, people will still be using vpns for a variety of reasons"
                                            Nobody is disagreeing with you on this - its just that the VPN provider has zero need to NAT the ipv6 address they give you. NONE!!!

                                            Honestly, it doesn't matter to me that they have "zero need to NAT" the address. The only thing that matters is that it works. The possibility that they could have implemented the server differently doesn't change that it works.

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