51 points · by pavel_odintsov · 3y ago · 39 comments
I just got a patch into the ip(7) man page that describes this
https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git/...
although there hasn't been a man-pages release since then, so you probably can't see this on your own system yet.
The original change (included in Linux 5.3) is
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/lin...
(I'm working on a project that aims to make these addresses potentially useful for numbering Internet hosts in the future, as part of which Dave Taht's patch linked above was written, so I follow this very closely!)
Separately, you need to be able to process a 0.0.0.0/32 source address on external interfaces (though not to forward it) in order to be able to implement a DHCP server, as that's the source address used by DHCP clients. (edit: another commenter pointed out that this commonly uses raw sockets so it doesn't necessarily require any explicit kernel support)
So the DHCP case does not necessarily need any special kernel support (other than not prefiltering before the raw socket).
Thanks for the correction.
https://www.ietf.org/archive/id/draft-schoen-intarea-unicast...
The big prize is 240/4.
https://www.ietf.org/archive/id/draft-schoen-intarea-unicast...
Our proposals have not been warmly received in the intarea WG so far.
> The best way to fix this issue is to change Netflow / IPFIX / sFlow agent configuration on device to use another legitimate IP address instead of 0.0.0.0.
Um, yes. 0.0.0.0 looks like a really bad choice of source address.
Which the code can easily do of course, but a foolish name like this could confuse someone debugging code during development, or worse while debugging a communication problem in process far away.
(BTW this is an earnest, not humorous comment).
Darn, it's still a short-sighted choice. Even "interstellar" would be good for another 75 years or so ( https://i4is.org/what-we-do/technical/project-dragonfly/ ), though "intergalactic" would be better, even if ipv6 were used.
"Martian" meaning the planet would come up in application code, not in the kernel. Why would the kernel even have that concept?
> sudo sysctl net.ipv4.conf.all.log_martians=1
If you copy it from the console and then use a `<pre>` tag rather than a `<blockquote>` tag it'll work well.
See here: https://i.imgur.com/gAsb9TR.png
It relies on the page Reserved_IP_addresses, implying that a martian is a packet with a source address within certain ranges. In fact a martian is a packet with a source address for which the receiving interface isn't configured; any address could be a martian, depending on how the interface is set up.
Hey, if I'm wrong, please set me straight.
What you're talking about is referred to as source address validation [2] also known as strict reverse path forwarding (RPF) [3].
[1] https://datatracker.ietf.org/doc/html/rfc1812#section-5.3.7
[2] https://datatracker.ietf.org/doc/html/rfc1812#section-5.3.8
[3] https://datatracker.ietf.org/doc/html/rfc3704#section-2.2
A quick usenet search shows references to the term back into the 90's.
A contemporary definition that is not self-contradictory is in Eric S. Raymond's New Hacker's Dictionary, published four years earlier; but which isn't what RFC 1812 says either, however.
So whilst the people who weren't alive in the 1990s are wrong to be hung up on the "I thought it meant 'from Mars'." confusion, since the saddening reality of 2023 is that we're no nearer to that being a realistic source of confusion than we were in 1991; the obverse of the coin is that, like much of the Jargon File, it's woolly slang set over-hard into stone by Eric S. Raymond and a document from Cisco that it is unwise to rely upon for strict technical meaning.
Why can't RFCs be readable by default? Why do they still have explicit line- and page-breaks and fixed-width fonts?