For Linux, there's a kernel setting for that. Just run sysctl -w net.ipv6.bindv6only=1 so IPv6 will not include IPv4-mapped addresses. https://www.kernel.org/doc/Documentation/networking/ip-sysct...
This affects -to my best knowledge- only bind()ing, not outgoing connect()ing. As the name implies, really. (I should try this, not entirely sure tbh.) It won't help you though if the resolver library gives you a ::ffff:ma.p.p.ed address (yes they can do that), then you just fail to connect…
eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
21–30 of 35 posts
Re: eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
#22>I thought I must have this wrong, surely you can’t just smash an ipv4 address in ipv6 field and magic happens?! Nope, didn’t have it wrong, that’s what happens. Linux supports this, and will go on to route the request as IPv4. I mean... it's literally one of the officially defined unicast IPv6 address types. If you ever read the Wikipedia page to learn about what link-local, global unicast, etc. addresses are you su…
Re: eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
#23>I thought I must have this wrong, surely you can’t just smash an ipv4 address in ipv6 field and magic happens?! Nope, didn’t have it wrong, that’s what happens. Linux supports this, and will go on to route the request as IPv4. I mean... it's literally one of the officially defined unicast IPv6 address types. If you ever read the Wikipedia page to learn about what link-local, global unicast, etc. addresses are you su…
Not everyone spends their days digging through networking specifications. I for one earned CCENT and CCNA certifications was entirely unaware of this mechanism.
If you are searching for information about IPv6 (as the author of the post was doing for their endeavor) the Wikipedia page will be among the first things you will look at. And if the Wikipedia page clearly states this information then not only is it reasonable to expect someone to find it, but it's very far from "digging through specification"
Re: eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
#24Earlier quoted context omitted.
Not everyone spends their days digging through networking specifications. I for one earned CCENT and CCNA certifications was entirely unaware of this mechanism.
What a bad faith response. If you are searching for information about IPv6 (as the author of the post was doing for their endeavor) the Wikipedia page will be among the first things you will look at. And if the Wikipedia page clearly states this information then not only is it reasonable to expect someone to find it, but it's very far from "digging through specification"
Re: eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
#25>I thought I must have this wrong, surely you can’t just smash an ipv4 address in ipv6 field and magic happens?! Nope, didn’t have it wrong, that’s what happens. Linux supports this, and will go on to route the request as IPv4. I mean... it's literally one of the officially defined unicast IPv6 address types. If you ever read the Wikipedia page to learn about what link-local, global unicast, etc. addresses are you su…
Not everyone spends their days digging through networking specifications. I for one earned CCENT and CCNA certifications was entirely unaware of this mechanism.
I mean I have a small book of notes I built up based on various network RFCs and I am don't even have a CCENT and CCNA certifications.
This sort of thing isn't unreasonable.
Of course this isn't a dunk on the author of the article (except the part about doing weird DNS games, which sounds like a nightmare for whoever needs to figure out what he did months or years from now). Everybody has run into situations were they think they know how something works and it turns out they are wrong and get a nasty surprise from it.
Re: eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
#26>I thought I must have this wrong, surely you can’t just smash an ipv4 address in ipv6 field and magic happens?! Nope, didn’t have it wrong, that’s what happens. Linux supports this, and will go on to route the request as IPv4. I mean... it's literally one of the officially defined unicast IPv6 address types. If you ever read the Wikipedia page to learn about what link-local, global unicast, etc. addresses are you su…
Not everyone spends their days digging through networking specifications. I for one earned CCENT and CCNA certifications was entirely unaware of this mechanism.
Re: eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
#27The former (compatible) are not in use anymore, they were specified in an old tunnelling RFC. The latter (mapped) are used for sockets that bind to both IPv4 and IPv6.
There are even more ways to include IPv4 addresses in IPv6 ones (NAT64, 6to4, ...)
Re: eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
#28Earlier quoted context omitted.
Not everyone spends their days digging through networking specifications. I for one earned CCENT and CCNA certifications was entirely unaware of this mechanism.
maybe it just means those a pretty worthless certs focused on training you to shill for cisco instead of teaching you actually important network concepts...
Re: eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
#29Earlier quoted context omitted.
This affects -to my best knowledge- only bind()ing, not outgoing connect()ing. As the name implies, really. (I should try this, not entirely sure tbh.) It won't help you though if the resolver library gives you a ::ffff:ma.p.p.ed address (yes they can do that), then you just fail to connect…
I did try this. connect(2) with an IPv4-mapped IPv6 address on an AF_INET6 socket with IPV6_V6ONLY set on it fails.
Re: eBPF Mystery: When is IPv4 not IPv4? When it's pretending to be IPv6
#30For Linux, there's a kernel setting for that. Just run sysctl -w net.ipv6.bindv6only=1 so IPv6 will not include IPv4-mapped addresses. https://www.kernel.org/doc/Documentation/networking/ip-sysct...