Aller au contenu principal

14. Datagram Size

14. Datagram Size

A UDP datagram can include one or more QUIC packets. The datagram size refers to the total UDP payload size of a single UDP datagram carrying QUIC packets. The datagram size includes one or more QUIC packet headers and protected payloads, but not the UDP or IP headers.

The maximum datagram size is defined as the largest size of UDP payload that can be sent across a network path using a single UDP datagram. QUIC MUST NOT send datagrams larger than the maximum datagram size.

14.1 Initial Datagram Size

A client MUST expand the payload of all UDP datagrams carrying Initial packets to at least 1200 bytes. Sending UDP datagrams of this size ensures that the network path supports a reasonable Path Maximum Transmission Unit (PMTU), in both directions. This also helps reduce the amplitude of amplification attacks caused by server responses toward an unverified client address; see Section 8.

14.2 Path Maximum Transmission Unit

The PMTU is the maximum size of the entire IP packet, including the IP header, UDP header, and UDP payload. The UDP payload includes one or more QUIC packet headers and protected payloads.

All QUIC packets sent in a datagram MUST fit within the maximum datagram size. If a QUIC packet cannot fit in the maximum datagram size, it MUST be sent in a separate datagram.

14.2.1 Handling of ICMP Messages by PMTUD

Implementations SHOULD handle ICMP messages that indicate the packet was too large (PTB) [RFC1191][RFC8201].

14.3 Datagram Packetization Layer PMTU Discovery

Datagram Packetization Layer PMTU Discovery (DPLPMTUD) [RFC8899] relies on tracking loss or acknowledgment of QUIC packets that are carried in PMTU probes.

14.3.1 DPLPMTUD and Initial Connectivity

From the perspective of DPLPMTUD, QUIC is an acknowledged packetization layer (PL). A QUIC sender can therefore enter the DPLPMTUD BASE state (Section 5.2 of [RFC8899]) once the QUIC connection is established.

14.3.2 Validating the Network Path with DPLPMTUD

QUIC is an acknowledged PL, so QUIC acknowledgments can be used as confirmation that a packet of a certain size was successfully received.

14.3.3 Handling of ICMP Messages by DPLPMTUD

An endpoint using DPLPMTUD requires knowledge of the maximum size of UDP payload that can be sent over a path.

14.4 Sending QUIC PMTU Probes

PMTU probes are ack-eliciting packets. Endpoints validate that a path is capable of supporting a particular PMTU by using PMTU probes that are at least that large.

14.4.1 PMTU Probes Containing Source Connection ID

Endpoints that rely on the server's preferred address (Section 9.6) or connection migration (Section 9) to a new path SHOULD ensure that packets of at least the PMTU are sendable on these paths.