Learn by doing - Cloud, Kubernetes, Python, and more. Get your teams up to speed faster with interactive labs and sandboxes to gain hands-on experience. No environment to set up, no software to install.
Fun Fact: If you prefix ::fff to the start of a IPv4 address, it is a valid IPv6 address. That whole block is "reserved for private Internets". Permitting organizations can do cursed backward compatibility stuff on their NATs/WANs for legacy hardware. Effectively making IPv4 a subset of IPv6. That block is 280 addresses, but only 248 are 'well formed' IPv4 addresses.
There are so much room for activities, there is a duplication of this within 2002::/16. Which is basically that, but externally route-able IPv6 to IPv4 mapping.
Additionally the whole fc00::/7 of 2121 addresses is "reserved for local networks" (basically the new 10.0.0.0/8).
fe80::/64 to fe80::/10 a block of 264 is reserved for link local addresses (the new 169.254.0.0/16 block)
IPv6 has ULA addresses, which are in the [fc::0]/7 range, and also link-local addresses from the range fe80:: (forgot the netmask, but similarly large). You can add these to your localhost interface as you desire and in the case of ULA addresses you can even use them todo cool stuff like giving containers a sable IPv6 address on changing network conditions like a laptop with WiFi moving between networks.
Kubernetes CNIs also use it extensively, albeit they should probably stop defaulting to do NAT since servers usually have dedicated IPv6 ranges like a /56. But alas, some cloud providers only give you a /64, a /112 (digital ocean I think) or even a /128 (oracle cloud, but can't complain since I'm on the free plan). So there are definitely upsides of this since it works on more networks but also kinda sucks because it is an artificial limitation and goes against what IPv6 tries to do.
Before AI crazy ideas were limited by the lack of skills of the engineer concocting such monstrosities. Now such barrier has been lifted and it feels like being at a zoo made of frankestein'd CS projects.
"Your scientists were so preoccupied with whether or not they could that they didn't stop to think if they should."
Barrier to entry is a good thing. Now instead we have daily posts about a new impressive project, until you look inside and everything is actually impressive or new in the project is "TODO". Being forced to acquire skills to implement crazy ideas is a good thing actually.
More of this. God so many devs today don’t even understand basic networking. Every time I worry about the future because AI coding has become the new script kiddy, someone comes along and gives me hope for the future.
you hope and pray 😂 joking you'll just get errors and should override manually with --ip flag. I wanted this thing to be stateless so no collision detection is built in
I'd much rather address this problem the same kinda way that I would in production. Reverse proxy and DNS automated by CICD at its most basic, or, you know, containerized with docker or k8s.
Hooking into syscalls gets you into all kinds of trouble eventually.
Why not just use 10/8 it’s also big? And of course, you can also just NAT any unused IP space you want. Hell, I could find a /8 dedicated to Africa or something and just start using that internally and NAT it outbound to my public IP. I never communicate with those IPs anyway so it won’t matter. Though, consider the extent at which you went, I’m sure you know all of this.
And when you move to IPv6 and only get ::1?
Generate a random ULA prefix and assign it to
lo. It'd be nicer if they had a allocated fixed block for this, but this works too./etc/systemd/network/lo.network:
Also, ipv4 loopback will be with us for a while, it's probably the last v4 feature to die since it'll never suffer from NAT.
this is brilliant. but I can see browsers are gonna complain about this
IPv6-mapped IPv4?
Fun Fact: If you prefix
::fffto the start of a IPv4 address, it is a valid IPv6 address. That whole block is "reserved for private Internets". Permitting organizations can do cursed backward compatibility stuff on their NATs/WANs for legacy hardware. Effectively making IPv4 a subset of IPv6. That block is 280 addresses, but only 248 are 'well formed' IPv4 addresses.There are so much room for activities, there is a duplication of this within
2002::/16. Which is basically that, but externally route-able IPv6 to IPv4 mapping.Additionally the whole
fc00::/7of 2121 addresses is "reserved for local networks" (basically the new10.0.0.0/8).fe80::/64tofe80::/10a block of 264 is reserved for link local addresses (the new 169.254.0.0/16 block)yeah that's the limitation. It downgrades them to ipv4 `127.x.x.x`, so the bind will succeed but you lose ipv6 :\
I feel like there should have been something inbetween IPv4's 16million loopback addresses, and IPv6's 1.
256 maybe?
ipv5 was supposed to have that /j
IPv6 has ULA addresses, which are in the [fc::0]/7 range, and also link-local addresses from the range fe80:: (forgot the netmask, but similarly large). You can add these to your localhost interface as you desire and in the case of ULA addresses you can even use them todo cool stuff like giving containers a sable IPv6 address on changing network conditions like a laptop with WiFi moving between networks.
Kubernetes CNIs also use it extensively, albeit they should probably stop defaulting to do NAT since servers usually have dedicated IPv6 ranges like a /56. But alas, some cloud providers only give you a /64, a /112 (digital ocean I think) or even a /128 (oracle cloud, but can't complain since I'm on the free plan). So there are definitely upsides of this since it works on more networks but also kinda sucks because it is an artificial limitation and goes against what IPv6 tries to do.
Before AI crazy ideas were limited by the lack of skills of the engineer concocting such monstrosities. Now such barrier has been lifted and it feels like being at a zoo made of frankestein'd CS projects.
"Your scientists were so preoccupied with whether or not they could that they didn't stop to think if they should."
Love this, please keep on being crazy!!!
Barrier to entry is a good thing. Now instead we have daily posts about a new impressive project, until you look inside and everything is actually impressive or new in the project is "TODO". Being forced to acquire skills to implement crazy ideas is a good thing actually.
Comment deleted by user
indeed it is. From Jurassic Park, if I am not mistaken!
Just wait until you hear about 0.0.0.0/8
don't give me more cursed ideas
Docker networks would have been less work, but hey still cool
disgustang!
More of this. God so many devs today don’t even understand basic networking. Every time I worry about the future because AI coding has become the new script kiddy, someone comes along and gives me hope for the future.
Good job man.
What do you do in the rare case you have a collision?
U hope and pray
Thanks, I'm tripling my consulting rate starting tomorrow.
you hope and pray 😂 joking you'll just get errors and should override manually with --ip flag. I wanted this thing to be stateless so no collision detection is built in
I'm doing this just editing /etc/hosts using a tiny she'll script
She'll script, but will she engineer?
Clever
I'd much rather address this problem the same kinda way that I would in production. Reverse proxy and DNS automated by CICD at its most basic, or, you know, containerized with docker or k8s.
Hooking into syscalls gets you into all kinds of trouble eventually.
I feel you and there are things that are inherently unsolvable with this approach, but we always have containers to the rescue
Network engineers hate this one trick!
Why not just use 10/8 it’s also big? And of course, you can also just NAT any unused IP space you want. Hell, I could find a /8 dedicated to Africa or something and just start using that internally and NAT it outbound to my public IP. I never communicate with those IPs anyway so it won’t matter. Though, consider the extent at which you went, I’m sure you know all of this.
Fucking crazy man, loved this