3 ms·
At that point it pretty much amounts to "send a message in a raw IP header to the destination rather than a message in an IP+ICMP header to the source". The ext
by zamadatix 6y ago
At that point it pretty much amounts to "send a message in a raw IP header to the destination rather than a message in an IP+ICMP header to the source". The extra step of truncation of the original payload doesn't gain you anything except still doing more work on the router than v6 would have it do to gain a lot of pain for the upper layers/endpoint stacks all so the inner session doesn't have to resend the first part of the first packets of a conversation.
The vast majority IPv4 traffic does not have the DNF bit set. Your logic of why they would doesn't even make sense as setting DNF only means it'll drop on routers that would fragment have fragmented not improve the situation with the ones that wouldn't have.
MSS is definitely a negotiation but a negotiation just between the TCP aware nodes not along the whole IP path which is why I say endpoint stacks can use it to detect if the IP path is fragmenting by comparing incoming IP fragment sizes to the MSS.
- toast0 6y ago> The vast majority IPv4 traffic does not have the DNF bit set. I don't think that's correct. Windows, Linux (including Android), FreeBSD, macOs and (Apple) iOS all default to sending Don't Frag. Together, they form the overwhelming majority of IPv4 traffic. Nobody actually wants fragments, and very few fragments are seen in regular activity. When I ran high traffic servers, I would normally see a few fragments a minute per server, except for when we were under a chargen reflection DDoS attack; Microsoft Services for Unix sends back a hunormous UDP reply which is of course fragmented, and that caused some trouble with fragment reassembly buffers (dropping the buffer size to the minimum solved that, although during a DDoS the couple of people sending fragments would have a bad time; can't win them all). I think sometimes there's fragments in large UDP DNS replies; but it's generally best to avoid large UDP DNS replies because they often get dropped by poor decisions in network design and software, and there's probably a better way to do what you need to do. Stacks could use MSS and fragment size to do something cool, but they don't; in part, because nobody sends fragments anymore, and in part, because there's a lot of other cool stuff to do so path MTU gets left behind in a lot of places, like Android. :( Edit to add: > At that point it pretty much amounts to "send a message in a raw IP header to the destination rather than a message in an IP+ICMP header to the source". The thing is, we know that the router that's in a position to truncate the packet can probably get a packet to the destination (otherwise, it wouldn't have this packet). We don't have anything to indicate that it can get a packet to the source; and it turns out that often it can't. An in-band indication would be so much more useful than an out of band (which doesn't work), or fragmentation (which people don't want). Yes, the indication goes to the wrong party, the destination will get the information, but the source needs it; but most interactions on IPv4 are two way, so presumably the destination can tell the source that it needs to send smaller packets, again in-band with the communication it already has, that presumably works.
- zamadatix 6y agoSorry you're right the default stacks do set DF on v4, my bad. Otherwise they wouldn't be able to get the PMTUD message so they know to change MSS as when fragmentation is enabled v4 won't send PMTUD ICMP back (and PMTUD working out of the box most of the time is preferred to fragmentation all the time). Had that backwards in my head. Yeah no stacks do it that I know of, just a theoretical way one could without having to rely on in-path devices sending messages or dropping traffic. I think the v6 path of drop it and send it back was better though. If it's blocked that's their fault :p. Regarding sending the "message too long" note via in band channel instead of its own ICMP message I actually think that's a great angle as it'll get through more FWs I'm just hung up on trying to do something the truncated payload once it arrives... but I guess that doesn't really matter from a protocol perspective - the important bit is the note on the MTU issue arrive in band and the OS can decide what to do with any remaining payload for inner protocols after that as it's not IP's problem. v6 already got rid of the IP checksum so the only other things that might need to be updated are NICs/FWs/NAT boxes that check TCP/UDP/protocol checksums to ignore them if the header had that note.
- sleepydog 6y ago> The thing is, we know that the router that's in a position to truncate the packet can probably get a packet to the destination (otherwise, it wouldn't have this packet). We don't have anything to indicate that it can get a packet to the source; and it turns out that often it can't. Another point to add to this is that many routers will rate limit control plane traffic (ICMP, BGP etc), or prioritize data plane traffic ahead of it, so the ICMP too large message is more likely to be lost than a hypothetical in-band indication. It's the same reason you sometimes see packet loss in the middle of a traceroute, but not the end.