| rfc9221.original | rfc9221.txt | |||
|---|---|---|---|---|
| QUIC T. Pauly | Internet Engineering Task Force (IETF) T. Pauly | |||
| Internet-Draft E. Kinnear | Request for Comments: 9221 E. Kinnear | |||
| Intended status: Standards Track Apple Inc. | Category: Standards Track Apple Inc. | |||
| Expires: 8 August 2022 D. Schinazi | ISSN: 2070-1721 D. Schinazi | |||
| Google LLC | Google LLC | |||
| 4 February 2022 | March 2022 | |||
| An Unreliable Datagram Extension to QUIC | An Unreliable Datagram Extension to QUIC | |||
| draft-ietf-quic-datagram-10 | ||||
| Abstract | Abstract | |||
| This document defines an extension to the QUIC transport protocol to | This document defines an extension to the QUIC transport protocol to | |||
| add support for sending and receiving unreliable datagrams over a | add support for sending and receiving unreliable datagrams over a | |||
| QUIC connection. | QUIC connection. | |||
| Discussion Venues | ||||
| This note is to be removed before publishing as an RFC. | ||||
| Discussion of this document takes place on the QUIC Working Group | ||||
| mailing list (mailto:quic@ietf.org), which is archived at | ||||
| https://mailarchive.ietf.org/arch/browse/quic/. | ||||
| Source for this draft and an issue tracker can be found at | ||||
| https://github.com/quicwg/datagram. | ||||
| Status of This Memo | Status of This Memo | |||
| This Internet-Draft is submitted in full conformance with the | This is an Internet Standards Track document. | |||
| provisions of BCP 78 and BCP 79. | ||||
| Internet-Drafts are working documents of the Internet Engineering | ||||
| Task Force (IETF). Note that other groups may also distribute | ||||
| working documents as Internet-Drafts. The list of current Internet- | ||||
| Drafts is at https://datatracker.ietf.org/drafts/current/. | ||||
| Internet-Drafts are draft documents valid for a maximum of six months | This document is a product of the Internet Engineering Task Force | |||
| and may be updated, replaced, or obsoleted by other documents at any | (IETF). It represents the consensus of the IETF community. It has | |||
| time. It is inappropriate to use Internet-Drafts as reference | received public review and has been approved for publication by the | |||
| material or to cite them other than as "work in progress." | Internet Engineering Steering Group (IESG). Further information on | |||
| Internet Standards is available in Section 2 of RFC 7841. | ||||
| This Internet-Draft will expire on 8 August 2022. | Information about the current status of this document, any errata, | |||
| and how to provide feedback on it may be obtained at | ||||
| https://www.rfc-editor.org/info/rfc9221. | ||||
| Copyright Notice | Copyright Notice | |||
| Copyright (c) 2022 IETF Trust and the persons identified as the | Copyright (c) 2022 IETF Trust and the persons identified as the | |||
| document authors. All rights reserved. | document authors. All rights reserved. | |||
| This document is subject to BCP 78 and the IETF Trust's Legal | This document is subject to BCP 78 and the IETF Trust's Legal | |||
| Provisions Relating to IETF Documents (https://trustee.ietf.org/ | Provisions Relating to IETF Documents | |||
| license-info) in effect on the date of publication of this document. | (https://trustee.ietf.org/license-info) in effect on the date of | |||
| Please review these documents carefully, as they describe your rights | publication of this document. Please review these documents | |||
| and restrictions with respect to this document. Code Components | carefully, as they describe your rights and restrictions with respect | |||
| extracted from this document must include Revised BSD License text as | to this document. Code Components extracted from this document must | |||
| described in Section 4.e of the Trust Legal Provisions and are | include Revised BSD License text as described in Section 4.e of the | |||
| provided without warranty as described in the Revised BSD License. | Trust Legal Provisions and are provided without warranty as described | |||
| in the Revised BSD License. | ||||
| Table of Contents | Table of Contents | |||
| 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 | 1. Introduction | |||
| 1.1. Specification of Requirements . . . . . . . . . . . . . . 3 | 1.1. Specification of Requirements | |||
| 2. Motivation . . . . . . . . . . . . . . . . . . . . . . . . . 3 | 2. Motivation | |||
| 3. Transport Parameter . . . . . . . . . . . . . . . . . . . . . 4 | 3. Transport Parameter | |||
| 4. Datagram Frame Types . . . . . . . . . . . . . . . . . . . . 5 | 4. Datagram Frame Types | |||
| 5. Behavior and Usage . . . . . . . . . . . . . . . . . . . . . 6 | 5. Behavior and Usage | |||
| 5.1. Multiplexing Datagrams . . . . . . . . . . . . . . . . . 6 | 5.1. Multiplexing Datagrams | |||
| 5.2. Acknowledgement Handling . . . . . . . . . . . . . . . . 7 | 5.2. Acknowledgement Handling | |||
| 5.3. Flow Control . . . . . . . . . . . . . . . . . . . . . . 7 | 5.3. Flow Control | |||
| 5.4. Congestion Control . . . . . . . . . . . . . . . . . . . 8 | 5.4. Congestion Control | |||
| 6. Security Considerations . . . . . . . . . . . . . . . . . . . 8 | 6. Security Considerations | |||
| 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8 | 7. IANA Considerations | |||
| 7.1. QUIC Transport Parameter . . . . . . . . . . . . . . . . 8 | 7.1. QUIC Transport Parameter | |||
| 7.2. QUIC Frame Types . . . . . . . . . . . . . . . . . . . . 9 | 7.2. QUIC Frame Types | |||
| 8. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 9 | 8. References | |||
| 9. References . . . . . . . . . . . . . . . . . . . . . . . . . 9 | 8.1. Normative References | |||
| 9.1. Normative References . . . . . . . . . . . . . . . . . . 9 | 8.2. Informative References | |||
| 9.2. Informative References . . . . . . . . . . . . . . . . . 10 | Acknowledgments | |||
| Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 10 | Authors' Addresses | |||
| 1. Introduction | 1. Introduction | |||
| The QUIC Transport Protocol [RFC9000] provides a secure, multiplexed | The QUIC transport protocol [RFC9000] provides a secure, multiplexed | |||
| connection for transmitting reliable streams of application data. | connection for transmitting reliable streams of application data. | |||
| QUIC uses various frame types to transmit data within packets, and | QUIC uses various frame types to transmit data within packets, and | |||
| each frame type defines whether the data it contains will be | each frame type defines whether the data it contains will be | |||
| retransmitted. Streams of reliable application data are sent using | retransmitted. Streams of reliable application data are sent using | |||
| STREAM frames. | STREAM frames. | |||
| Some applications, particularly those that need to transmit real-time | Some applications, particularly those that need to transmit real-time | |||
| data, prefer to transmit data unreliably. In the past, these | data, prefer to transmit data unreliably. In the past, these | |||
| applications have built directly upon UDP [RFC0768] as a transport | applications have built directly upon UDP [RFC0768] as a transport | |||
| and have often added security with DTLS [RFC6347]. Extending QUIC to | and have often added security with DTLS [RFC6347]. Extending QUIC to | |||
| support transmitting unreliable application data provides another | support transmitting unreliable application data provides another | |||
| option for secure datagrams with the added benefit of sharing the | option for secure datagrams with the added benefit of sharing the | |||
| cryptographic and authentication context used for reliable streams. | cryptographic and authentication context used for reliable streams. | |||
| This document defines two new DATAGRAM QUIC frame types which carry | This document defines two new DATAGRAM QUIC frame types that carry | |||
| application data without requiring retransmissions. | application data without requiring retransmissions. | |||
| 1.1. Specification of Requirements | 1.1. Specification of Requirements | |||
| The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", | The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", | |||
| "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and | "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and | |||
| "OPTIONAL" in this document are to be interpreted as described in BCP | "OPTIONAL" in this document are to be interpreted as described in | |||
| 14 [RFC2119] [RFC8174] when, and only when, they appear in all | BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all | |||
| capitals, as shown here. | capitals, as shown here. | |||
| 2. Motivation | 2. Motivation | |||
| Transmitting unreliable data over QUIC provides benefits over | Transmitting unreliable data over QUIC provides benefits over | |||
| existing solutions: | existing solutions: | |||
| * Applications that want to use both a reliable stream and an | * Applications that want to use both a reliable stream and an | |||
| unreliable flow to the same peer can benefit by sharing a single | unreliable flow to the same peer can benefit by sharing a single | |||
| handshake and authentication context between a reliable QUIC | handshake and authentication context between a reliable QUIC | |||
| skipping to change at page 4, line 8 ¶ | skipping to change at line 132 ¶ | |||
| Internet-layer tunneling protocols generally require a reliable and | Internet-layer tunneling protocols generally require a reliable and | |||
| authenticated handshake followed by unreliable secure transmission of | authenticated handshake followed by unreliable secure transmission of | |||
| IP packets. This can, for example, require a TLS connection for the | IP packets. This can, for example, require a TLS connection for the | |||
| control data and DTLS for tunneling IP packets. A single QUIC | control data and DTLS for tunneling IP packets. A single QUIC | |||
| connection could support both parts with the use of unreliable | connection could support both parts with the use of unreliable | |||
| datagrams in addition to reliable streams. | datagrams in addition to reliable streams. | |||
| 3. Transport Parameter | 3. Transport Parameter | |||
| Support for receiving the DATAGRAM frame types is advertised by means | Support for receiving the DATAGRAM frame types is advertised by means | |||
| of a QUIC Transport Parameter (name=max_datagram_frame_size, | of a QUIC transport parameter (name=max_datagram_frame_size, | |||
| value=0x20). The max_datagram_frame_size transport parameter is an | value=0x20). The max_datagram_frame_size transport parameter is an | |||
| integer value (represented as a variable-length integer) that | integer value (represented as a variable-length integer) that | |||
| represents the maximum size of a DATAGRAM frame (including the frame | represents the maximum size of a DATAGRAM frame (including the frame | |||
| type, length, and payload) the endpoint is willing to receive, in | type, length, and payload) the endpoint is willing to receive, in | |||
| bytes. | bytes. | |||
| The default for this parameter is 0, which indicates that the | The default for this parameter is 0, which indicates that the | |||
| endpoint does not support DATAGRAM frames. A value greater than 0 | endpoint does not support DATAGRAM frames. A value greater than 0 | |||
| indicates that the endpoint supports the DATAGRAM frame types and is | indicates that the endpoint supports the DATAGRAM frame types and is | |||
| willing to receive such frames on this connection. | willing to receive such frames on this connection. | |||
| skipping to change at page 6, line 32 ¶ | skipping to change at line 241 ¶ | |||
| Note that while the max_datagram_frame_size transport parameter | Note that while the max_datagram_frame_size transport parameter | |||
| places a limit on the maximum size of DATAGRAM frames, that limit can | places a limit on the maximum size of DATAGRAM frames, that limit can | |||
| be further reduced by the max_udp_payload_size transport parameter | be further reduced by the max_udp_payload_size transport parameter | |||
| and the Maximum Transmission Unit (MTU) of the path between | and the Maximum Transmission Unit (MTU) of the path between | |||
| endpoints. DATAGRAM frames cannot be fragmented; therefore, | endpoints. DATAGRAM frames cannot be fragmented; therefore, | |||
| application protocols need to handle cases where the maximum datagram | application protocols need to handle cases where the maximum datagram | |||
| size is limited by other factors. | size is limited by other factors. | |||
| 5.1. Multiplexing Datagrams | 5.1. Multiplexing Datagrams | |||
| DATAGRAM frames belong to a QUIC connection as a whole, and are not | DATAGRAM frames belong to a QUIC connection as a whole and are not | |||
| associated with any stream ID at the QUIC layer. However, it is | associated with any stream ID at the QUIC layer. However, it is | |||
| expected that applications will want to differentiate between | expected that applications will want to differentiate between | |||
| specific DATAGRAM frames by using identifiers, such as for logical | specific DATAGRAM frames by using identifiers, such as for logical | |||
| flows of datagrams or to distinguish between different kinds of | flows of datagrams or to distinguish between different kinds of | |||
| datagrams. | datagrams. | |||
| Identifiers used to multiplex different kinds of datagrams, or flows | Defining the identifiers used to multiplex different kinds of | |||
| of datagrams, are the responsibility of the application protocol | datagrams or flows of datagrams is the responsibility of the | |||
| running over QUIC to define. The application defines the semantics | application protocol running over QUIC. The application defines the | |||
| of the Datagram Data field and how it is parsed. | semantics of the Datagram Data field and how it is parsed. | |||
| If the application needs to support the coexistence of multiple flows | If the application needs to support the coexistence of multiple flows | |||
| of datagrams, one recommended pattern is to use a variable-length | of datagrams, one recommended pattern is to use a variable-length | |||
| integer at the beginning of the Datagram Data field. This is a | integer at the beginning of the Datagram Data field. This is a | |||
| simple approach that allows a large number of flows to be encoded | simple approach that allows a large number of flows to be encoded | |||
| using minimal space. | using minimal space. | |||
| QUIC implementations SHOULD present an API to applications to assign | QUIC implementations SHOULD present an API to applications to assign | |||
| relative priorities to DATAGRAM frames with respect to each other and | relative priorities to DATAGRAM frames with respect to each other and | |||
| to QUIC streams. | to QUIC streams. | |||
| skipping to change at page 7, line 30 ¶ | skipping to change at line 288 ¶ | |||
| [RFC9002]. | [RFC9002]. | |||
| If a sender detects that a packet containing a specific DATAGRAM | If a sender detects that a packet containing a specific DATAGRAM | |||
| frame might have been lost, the implementation MAY notify the | frame might have been lost, the implementation MAY notify the | |||
| application that it believes the datagram was lost. | application that it believes the datagram was lost. | |||
| Similarly, if a packet containing a DATAGRAM frame is acknowledged, | Similarly, if a packet containing a DATAGRAM frame is acknowledged, | |||
| the implementation MAY notify the sender application that the | the implementation MAY notify the sender application that the | |||
| datagram was successfully transmitted and received. Due to | datagram was successfully transmitted and received. Due to | |||
| reordering, this can include a DATAGRAM frame that was thought to be | reordering, this can include a DATAGRAM frame that was thought to be | |||
| lost, but which at a later point was received and acknowledged. It | lost but, at a later point, was received and acknowledged. It is | |||
| is important to note that acknowledgement of a DATAGRAM frame only | important to note that acknowledgement of a DATAGRAM frame only | |||
| indicates that the transport-layer handling on the receiver processed | indicates that the transport-layer handling on the receiver processed | |||
| the frame, and does not guarantee that the application on the | the frame and does not guarantee that the application on the receiver | |||
| receiver successfully processed the data. Thus, this signal cannot | successfully processed the data. Thus, this signal cannot replace | |||
| replace application-layer signals that indicate successful | application-layer signals that indicate successful processing. | |||
| processing. | ||||
| 5.3. Flow Control | 5.3. Flow Control | |||
| DATAGRAM frames do not provide any explicit flow control signaling, | DATAGRAM frames do not provide any explicit flow control signaling | |||
| and do not contribute to any per-flow or connection-wide data limit. | and do not contribute to any per-flow or connection-wide data limit. | |||
| The risk associated with not providing flow control for DATAGRAM | The risk associated with not providing flow control for DATAGRAM | |||
| frames is that a receiver might not be able to commit the necessary | frames is that a receiver might not be able to commit the necessary | |||
| resources to process the frames. For example, it might not be able | resources to process the frames. For example, it might not be able | |||
| to store the frame contents in memory. However, since DATAGRAM | to store the frame contents in memory. However, since DATAGRAM | |||
| frames are inherently unreliable, they MAY be dropped by the receiver | frames are inherently unreliable, they MAY be dropped by the receiver | |||
| if the receiver cannot process them. | if the receiver cannot process them. | |||
| 5.4. Congestion Control | 5.4. Congestion Control | |||
| skipping to change at page 8, line 42 ¶ | skipping to change at line 344 ¶ | |||
| The use of DATAGRAM frames might be detectable by an adversary on | The use of DATAGRAM frames might be detectable by an adversary on | |||
| path that is capable of dropping packets. Since DATAGRAM frames do | path that is capable of dropping packets. Since DATAGRAM frames do | |||
| not use transport-level retransmission, connections that use DATAGRAM | not use transport-level retransmission, connections that use DATAGRAM | |||
| frames might be distinguished from other connections due to their | frames might be distinguished from other connections due to their | |||
| different response to packet loss. | different response to packet loss. | |||
| 7. IANA Considerations | 7. IANA Considerations | |||
| 7.1. QUIC Transport Parameter | 7.1. QUIC Transport Parameter | |||
| This document registers a new value in the QUIC Transport Parameter | This document registers a new value in the "QUIC Transport | |||
| Registry maintained at https://www.iana.org/assignments/quic/ | Parameters" registry maintained at <https://www.iana.org/assignments/ | |||
| quic.xhtml#quic-transport. | quic>. | |||
| Value: 0x20 | Value: 0x20 | |||
| Parameter Name: max_datagram_frame_size | Parameter Name: max_datagram_frame_size | |||
| Status: permanent | Status: permanent | |||
| Specification: RFC 9221 | ||||
| Specification: This document | ||||
| 7.2. QUIC Frame Types | 7.2. QUIC Frame Types | |||
| This document registers two new values in the QUIC Frame Type | This document registers two new values in the "QUIC Frame Types" | |||
| registry maintained at https://www.iana.org/assignments/quic/ | registry maintained at <https://www.iana.org/assignments/quic>. | |||
| quic.xhtml#quic-frame-types. | ||||
| Value: 0x30 and 0x31 (if this document is approved) | ||||
| Value: 0x30-0x31 | ||||
| Frame Name: DATAGRAM | Frame Name: DATAGRAM | |||
| Status: permanent | Status: permanent | |||
| Specification: RFC 9221 | ||||
| Specification: This document | 8. References | |||
| 8. Acknowledgments | ||||
| The original proposal for this work came from Ian Swett. | ||||
| This document had reviews and input from many contributors in the | ||||
| IETF QUIC Working Group, with substantive input from Nick Banks, | ||||
| Lucas Pardue, Rui Paulo, Martin Thomson, Victor Vasiliev, and Chris | ||||
| Wood. | ||||
| 9. References | ||||
| 9.1. Normative References | 8.1. Normative References | |||
| [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate | [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate | |||
| Requirement Levels", BCP 14, RFC 2119, | Requirement Levels", BCP 14, RFC 2119, | |||
| DOI 10.17487/RFC2119, March 1997, | DOI 10.17487/RFC2119, March 1997, | |||
| <https://www.rfc-editor.org/rfc/rfc2119>. | <https://www.rfc-editor.org/info/rfc2119>. | |||
| [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC | [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC | |||
| 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, | 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, | |||
| May 2017, <https://www.rfc-editor.org/rfc/rfc8174>. | May 2017, <https://www.rfc-editor.org/info/rfc8174>. | |||
| [RFC9000] Iyengar, J., Ed. and M. Thomson, Ed., "QUIC: A UDP-Based | [RFC9000] Iyengar, J., Ed. and M. Thomson, Ed., "QUIC: A UDP-Based | |||
| Multiplexed and Secure Transport", RFC 9000, | Multiplexed and Secure Transport", RFC 9000, | |||
| DOI 10.17487/RFC9000, May 2021, | DOI 10.17487/RFC9000, May 2021, | |||
| <https://www.rfc-editor.org/rfc/rfc9000>. | <https://www.rfc-editor.org/info/rfc9000>. | |||
| [RFC9001] Thomson, M., Ed. and S. Turner, Ed., "Using TLS to Secure | [RFC9001] Thomson, M., Ed. and S. Turner, Ed., "Using TLS to Secure | |||
| QUIC", RFC 9001, DOI 10.17487/RFC9001, May 2021, | QUIC", RFC 9001, DOI 10.17487/RFC9001, May 2021, | |||
| <https://www.rfc-editor.org/rfc/rfc9001>. | <https://www.rfc-editor.org/info/rfc9001>. | |||
| [RFC9002] Iyengar, J., Ed. and I. Swett, Ed., "QUIC Loss Detection | [RFC9002] Iyengar, J., Ed. and I. Swett, Ed., "QUIC Loss Detection | |||
| and Congestion Control", RFC 9002, DOI 10.17487/RFC9002, | and Congestion Control", RFC 9002, DOI 10.17487/RFC9002, | |||
| May 2021, <https://www.rfc-editor.org/rfc/rfc9002>. | May 2021, <https://www.rfc-editor.org/info/rfc9002>. | |||
| 9.2. Informative References | 8.2. Informative References | |||
| [RFC0768] Postel, J., "User Datagram Protocol", STD 6, RFC 768, | [RFC0768] Postel, J., "User Datagram Protocol", STD 6, RFC 768, | |||
| DOI 10.17487/RFC0768, August 1980, | DOI 10.17487/RFC0768, August 1980, | |||
| <https://www.rfc-editor.org/rfc/rfc768>. | <https://www.rfc-editor.org/info/rfc768>. | |||
| [RFC6347] Rescorla, E. and N. Modadugu, "Datagram Transport Layer | [RFC6347] Rescorla, E. and N. Modadugu, "Datagram Transport Layer | |||
| Security Version 1.2", RFC 6347, DOI 10.17487/RFC6347, | Security Version 1.2", RFC 6347, DOI 10.17487/RFC6347, | |||
| January 2012, <https://www.rfc-editor.org/rfc/rfc6347>. | January 2012, <https://www.rfc-editor.org/info/rfc6347>. | |||
| Acknowledgments | ||||
| The original proposal for this work came from Ian Swett. | ||||
| This document had reviews and input from many contributors in the | ||||
| IETF QUIC Working Group, with substantive input from Nick Banks, | ||||
| Lucas Pardue, Rui Paulo, Martin Thomson, Victor Vasiliev, and Chris | ||||
| Wood. | ||||
| Authors' Addresses | Authors' Addresses | |||
| Tommy Pauly | Tommy Pauly | |||
| Apple Inc. | Apple Inc. | |||
| One Apple Park Way | One Apple Park Way | |||
| Cupertino, California 95014, | Cupertino, CA 95014 | |||
| United States of America | United States of America | |||
| Email: tpauly@apple.com | Email: tpauly@apple.com | |||
| Eric Kinnear | Eric Kinnear | |||
| Apple Inc. | Apple Inc. | |||
| One Apple Park Way | One Apple Park Way | |||
| Cupertino, California 95014, | Cupertino, CA 95014 | |||
| United States of America | United States of America | |||
| Email: ekinnear@apple.com | Email: ekinnear@apple.com | |||
| David Schinazi | David Schinazi | |||
| Google LLC | Google LLC | |||
| 1600 Amphitheatre Parkway | 1600 Amphitheatre Parkway | |||
| Mountain View, California 94043, | Mountain View, CA 94043 | |||
| United States of America | United States of America | |||
| Email: dschinazi.ietf@gmail.com | Email: dschinazi.ietf@gmail.com | |||
| End of changes. 42 change blocks. | ||||
| 112 lines changed or deleted | 87 lines changed or added | |||
This html diff was produced by rfcdiff 1.48. The latest version is available from http://tools.ietf.org/tools/rfcdiff/ | ||||