Advertise a receive limit for each direction
01QUIC peers negotiate support for receiving DATAGRAM frames with a transport parameter called max_datagram_frame_size. Each endpoint’s value describes what that endpoint can receive, not what it can send.
If B receives a 1201-byte DATAGRAM after advertising 1200, B must terminate with PROTOCOL_VIOLATION. The sender was also forbidden to send that frame.
Source for this drawing: RFC 9221 · Read RFC section 3 ↗
New to this? Start hereA quick picture + helpful background
A message needs an address.
Think of a packet as a small addressed envelope. Devices pass it onward; transport protocols decide what delivery promises an application gets.
Helpful first, if these ideas are unfamiliar
These pictures are analogies to help you learn. The linked RFC explains the actual rules.
Terms in this drawing
- Transport parameter
- A QUIC handshake value describing an endpoint capability or limit.
- Receive limit
- The maximum full DATAGRAM frame size this endpoint is willing to receive.
Related RFCs and changes
“Updates” changes part of an earlier RFC. “Obsoletes” replaces it. This list shows selected related documents.
An endpoint MUST NOT send DATAGRAM frames before learning a nonzero peer receive limit in the handshake, or a stored previous-handshake value for 0-RTT. It MUST NOT exceed the received limit.
- An endpoint MUST NOT send DATAGRAM frames before learning a nonzero peer receive limit in the handshake, or a stored previous-handshake value for 0-RTT. It MUST NOT exceed the received limit.
- The transport parameter has identifier 0x20. Its integer value counts the entire DATAGRAM frame: type, optional length and payload. An absent parameter defaults to zero, meaning no DATAGRAM receive support.
- The limit is unidirectional. If B advertises 1200 and A advertises zero, A can send within B’s bound, while B cannot send DATAGRAM frames to A. An application MAY use only one direction.
- If a peer receives a DATAGRAM without having advertised support, or larger than its own advertised limit, it MUST terminate the connection with PROTOCOL_VIOLATION. This is not just a quiet datagram drop.
- A value of 65535 is RECOMMENDED for most uses to accept any frame fitting in a QUIC packet. It is not a guarantee of a 65535-byte usable datagram or a mandatory receive size.
- Applications using datagrams MUST define their reaction when the parameter is absent. An application that requires datagrams can fail its handshake rather than silently assuming support.
The numbers 1200, 1201 and zero are chosen teaching fixtures, not defaults other than the specified default zero. A failed sender permission check stops before transmission. The oversized-receive case separately depicts arrival followed by a connection error, not a successful application delivery. 0-RTT is covered later.
Read the RFC section ↗