RFC 9621 | Transport Services Architecture | January 2025 |
Pauly, et al. | Standards Track | [Page] |
This document describes an architecture that exposes transport protocol features to applications for network communication. The Transport Services Application Programming Interface (API) is based on an asynchronous, event-driven interaction pattern. This API uses Messages for representing data transfer to applications and describes how a Transport Services Implementation can use multiple IP addresses, multiple protocols, and multiple paths and can provide multiple application streams. This document provides the architecture and requirements. It defines common terminology and concepts to be used in definitions of a Transport Services API and a Transport Services Implementation.¶
This is an Internet Standards Track document.¶
This document is a product of the Internet Engineering Task Force (IETF). It represents the consensus of the IETF community. It has received public review and has been approved for publication by the Internet Engineering Steering Group (IESG). Further information on Internet Standards is available in Section 2 of RFC 7841.¶
Information about the current status of this document, any errata, and how to provide feedback on it may be obtained athttps://www.rfc-editor.org/info/rfc9621.¶
Copyright (c) 2025 IETF Trust and the persons identified as the document authors. All rights reserved.¶
This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License.¶
Many Application Programming Interfaces (APIs) to provide transport interfaces to networks have been deployed, perhaps the most widely known and imitated being the Socket interface (Socket API)[POSIX].The naming of objects and functions across these APIs is not consistent and varies, depending on the protocol being used.For example, the concept of sending and receiving streams of data is the same for both an unencrypted Transmission Control Protocol (TCP) stream and operating on an encrypted Transport Layer Security (TLS) stream[RFC8446] over TCP, but applications cannot use the same socketsend()
andrecv()
calls on top of both kinds of connections.Similarly, terminology for the implementation of transport protocols varies based on the context of the protocols themselves: terms such as "flow", "stream", "message", and "connection" can take on many different meanings.This variety can lead to confusion when trying to understand the similarities and differences between protocols and how applications can use them effectively.¶
The goal of the Transport Services System architecture is to provide a flexibleand reusable system with a common interface for transport protocols.An application uses the Transport Services System through an abstract Connection (we use capitalization to distinguish these from the underlying connections of, for example, TCP).This providesflexible Connection establishment allowing an application to request or require a set of Properties.¶
As applications adopt this interface, they will benefit from a wide set of transport features that can evolve over timeand will ensure that the system providing the interface can optimize its behavior based on the application requirementsand network conditions, without requiring changes to the applications. This flexibility enables faster deployment of new features and protocols.¶
This architecture can also support applications by offering racing mechanisms (attempting multiple IP addresses, protocols, or network paths in parallel), which otherwise need to be implemented in each application separately (seeSection 4.2.2). Racing selects one or more candidates, each with equivalent Protocol Stacks that are used to identifyan optimal combination of a transport protocol instance such as TCP, UDP, or another transport, together with configuration of parameters andinterfaces.A Connection represents an object that, once established, can be used to send and receive Messages.A Connection can also be created from another Connection, by cloning, and then forms a part of a Connection Group whose Connections share Properties.¶
This document was developed in parallel with the specification of the Transport Services API[RFC9622] and implementation guidelines[RFC9623]. Although following the Transport Services Architecture does not require all APIs and implementations to be identical, a common minimal set of features represented in a consistent fashion will enable applications to be easily ported from one implementation of the Transport Services System to another.¶
The architecture of the Transport Services System is based on the survey of services provided by IETF transport protocols and congestion control mechanisms[RFC8095] and the distilled minimal set of the features offered by transport protocols[RFC8923]. These documents identified common features and patterns across all transport protocols developed thus far in the IETF.¶
Since transport security is an increasingly relevant aspect of using transport protocols on the Internet, this document also considers the impact of transport security protocols on the feature set exposed by Transport Services[RFC8922].¶
One of the key insights to come from identifying the minimal set of features provided by transport protocols[RFC8923] was that features either (1) require application interaction and guidance (referred to in that document as Functional or Optimizing Features) or (2) can be handled automatically by an implementation of the Transport Services System (referred to as Automatable Features). Among the identified Functional and Optimizing Features, some are common across all or nearly all transport protocols, while others present features that, if specified, would only be useful with a subset of protocols, but would not harm the functionality of other protocols. For example, some protocols can deliver messages more quickly for applications that do not require messages to arrive in the order in which they were sent. This functionality needs to be explicitly allowed by the application, since reordering messages would be undesirable in many cases.¶
The following sections describe the Transport Services System:¶
Section 2 describes how the Transport Services API model differs from that of socket-based APIs. Specifically, it offers asynchronous event-driven interaction, the use of Messages for data transfer, and the flexibility to use different transport protocols and paths without requiring major changes to the application.¶
Section 3 explains the fundamental requirements for a Transport Services System. These principles are intended to make sure that transport protocols can continue to be enhanced and evolve without requiring significant changes by application developers.¶
Section 4 presents the Transport Services Implementation and defines the concepts that are used by the API[RFC9622] and described in the implementation guidelines[RFC9623]. This introduces the Preconnection, which allows applications to configure Connection Properties.¶
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14[RFC2119][RFC8174] when, and only when, they appear in all capitals, as shown here.¶
This subsection provides a glossary of key terms related to the Transport Services Architecture. It provides a short description of key terms that are defined later in this document.¶
The model of using sockets can be represented as follows (seeFigure 1):¶
Applications create connections and transfer data using the Socket API.¶
The Socket API provides the interface to the implementations of TCP and UDP(typically implemented in the system's kernel).¶
TCP and UDP in the kernel send and receive data over the available network-layer interfaces.¶
Sockets are bound directly to transport-layer and network-layer addresses,obtained via a separate resolution step, usually performed by asystem-provided DNS stub resolver.¶
+-----------------------------------------------------+| Application |+-----------------------------------------------------+ | | | +------------+ +------------+ +--------------+ | DNS Stub | | Stream API | | Datagram API | | Resolver | +------------+ +--------------+ +------------+ | | +---------------------------------+ | TCP UDP | | Kernel Networking Stack | +---------------------------------+ |+-----------------------------------------------------+| Network-Layer Interface |+-----------------------------------------------------+
The architecture of the Transport Services System is an evolution of this general model of interaction. It both modernizes the API presented to applications by the transport layer and enriches the capabilities of the Transport Services Implementation below this API.¶
The Transport Services API[RFC9622] defines the interface for an application to create Connections and transfer data. It combines interfaces for multiple interaction patterns into a unified whole (seeFigure 2).This offers generic functions and also the protocol-specific mappings for TCP, UDP, UDP-Lite, and other protocol layers. These mappings are extensible. Future documents could define similar mappings for new layers and for other transport protocols, such as QUIC[RFC9000].¶
+-----------------------------------------------------+| Application |+-----------------------------------------------------+ |+-----------------------------------------------------+| Transport Services API |+-----------------------------------------------------+ |+-----------------------------------------------------+| Transport Services Implementation || (Using DNS, UDP, TCP, SCTP, DCCP, TLS, QUIC, etc.) |+-----------------------------------------------------+ |+-----------------------------------------------------+| Network-Layer Interface |+-----------------------------------------------------+
By combining name resolution with Connection establishment and data transfer in a single API, it allows for more flexible implementations to provide path and transport protocol agility on the application's behalf.¶
The Transport Services Implementation[RFC9623] is the component of the Transport Services System that implements the transport-layer protocols and other functions needed to send and receive data. It is responsible for mapping the API to a specific available transport Protocol Stack and managing the available network interfaces and paths.¶
There are key differences between the architecture of the Transport Services System and the architecture of the Socket API. The API of the Transport Services System:¶
Originally, the Socket API presented a blocking interface for establishing connections and transferring data. However, most modern applications interact with the network asynchronously. Emulation of an asynchronous interface using the Socket API can use a try-and-fail model: if the application wants to read but data has not yet been received from the peer, the call to read will fail. The application then waits and can try again later.¶
In contrast to the Socket API, all interactions using the Transport Services API are expected to be asynchronous. The API is defined around an event-driven model (seeSection 4.1.6), which models this asynchronous interaction. Other forms of asynchronous communication could also be available to applications, depending on the platform implementing the interface.¶
For example, when an application that uses the Transport Services API wants to receive data, it issues an asynchronous call to receive new data from the Connection. When delivered data becomes available, this data is delivered to the application using asynchronous events that contain the data. Error handling is also asynchronous, resulting in asynchronous error events.¶
This API also delivers events regarding the lifetime of a connection and changes in the available network links, which were not previously made explicit in the Socket API.¶
Using asynchronous events allows for a more natural interaction model when establishing connections and transferring data. Events in time more closely reflect the nature of interactions over networks, as opposed to how the Socket API represents network resources as file system objects that may be temporarily unavailable.¶
Separate from events, callbacks are also provided for asynchronous interactions with the Transport Services API that are not directly related to events on the network or network interfaces.¶
The Socket API provides a message interface for datagram protocols like UDP but provides an unstructured stream abstraction for TCP. While TCP has the ability to send and receive data as a byte-stream, most applications need to interpret structure within this byte-stream. For example, HTTP/1.1 uses character delimiters to segment messages over a byte-stream[RFC9112]; TLS record headers carry a version, content type, and length[RFC8446]; and HTTP/2 uses frames to segment its headers and bodies[RFC9113].¶
The Transport Services API represents data as Messages, so that it more closely matches the way applications use the network. A Message-based abstraction provides many benefits, such as:¶
providing additional information to the Protocol Stack;¶
the ability to associate deadlines with Messages, for applications that care about timing;¶
the ability to control reliability, which Messages to retransmit when there is packet loss, and how best to make use of the data that arrived;¶
the ability to automatically assign Messages and connections to underlying transport connections to utilize multistreaming and create Pooled Connections.¶
Allowing applications to interact with Messages is backward-compatible with existing protocols and APIs because it does not change the wire format of any protocol. Instead, it provides the Protocol Stack with additional information to allow it to make better use of modern transport protocols, while simplifying the application's role in parsing data. For protocols that inherently use a streaming abstraction, Framers (Section 4.1.5) bridge the gap between the two abstractions.¶
The Socket API for protocols like TCP is generally limited to connecting to a single address over a single interface (IP source address).It also presents a single stream to the application. Software layers built upon this API often propagate this limitation of a single-address single-stream model. The Transport Services Architecture is designed to:¶
handle multiple candidate endpoints, protocols, and paths;¶
support candidate protocol racing to select the most optimal stack in each situation;¶
support multipath and multistreaming protocols;¶
provide state caching and application control over it.¶
A Transport Services Implementation is intended to be flexible at Connection establishment time, considering many different options and trying to select the most optimal combinations by racing them and measuring the results (see Sections 4.2.1 and4.2.2). This requires applications to specify identifiers for the Local and Remote Endpoint that are at a higher level than IP addresses, such as a hostname or URL. These identifiers are used by a Transport Services Implementation for resolution, path selection, and racing. An implementation can further implement fallback mechanisms if connection establishment for one protocol fails or performance is determined to be unsatisfactory.¶
Information used in Connection establishment (e.g., cryptographic resumption tokens, information about usability of certain protocols on the path, results of racing in previous connections) is cached in the Transport Services Implementation. Applications have control over whether this information is used for a specific establishment, in order to allow trade-offs between efficiency and linkability.¶
Flexibility after Connection establishment is also important. Transport protocols that can migrate between multiple network-layer interfaces need to be able to process and react to interface changes. Protocols that support multiple application-layer streams need to support initiating and receiving new streams using existing connections.¶
While the architecture of the Transport Services System is designed as an enhanced replacement for the Socket API, it need not replace it entirely on a system or platform; indeed, coexistence has been recommended for incremental deployability[RFC8170]. The architecture is therefore designed such that it can run alongside (or, indeed, on top of) an existing Socket API implementation; only applications built on the Transport Services API are managed by the system's Transport Services Implementation.¶
One goal of the architecture is to redefine the interface between applications and transports in a way that allows the transport layer to evolve and improve without fundamentally changing the contract with the application. This requires careful consideration of how to expose the capabilities of protocols. The architecture also encompasses system policies that can influence and inform how transport protocols use a network path or interface.¶
There are several ways the Transport Services System can offer flexibility to an application. It can:¶
Beyond these, if the Transport Services API remains the same over time, new protocols and features can be added to the Transport Services Implementation without requiring changes in applications for adoption. Similarly, this can provide a common basis for utilizing information about a network path or interface, enabling evolution below the transport layer.¶
The normative requirements described in this section allow Transport Services APIs and Transport Services Implementations to provide this functionality without causing incompatibility or introducing security vulnerabilities.¶
Any functionality that is common across multiple transport protocolsSHOULD be made accessible through a unified set of calls using the Transport Services API. As a baseline, any Transport Services APISHOULD allow access to the minimal set of features offered by transport protocols[RFC8923]. If that minimal set is updated or expanded in the future, the Transport Services API ought to be extended to match.¶
An application can specify constraints and preferences for the protocols, features, and network interfaces it will use via Properties. Properties are used by an application to declare its preferences for how the transport service should operate at each stage in the lifetime of a connection. Transport Properties are subdivided into the following:¶
It isRECOMMENDED that the Transport Services API offer Properties that are common to multiple transport protocols. This enables a Transport Services System to appropriately select between protocols that offer equivalent features. Similarly, it isRECOMMENDED that the Properties offered by the Transport Services API be applicable to a variety of network-layer interfaces and paths, to permit racing of different network paths without affecting the applications using the API. Each is expected to have a default value.¶
It isRECOMMENDED that the default values for Properties be selected to ensure correctness for the widest set of applications, while providing the widest set of options for selection. For example, since both applications that require reliability and those that do not require reliability can function correctly when a protocol provides reliability, reliability ought to be enabled by default. As another example, the default value for a Property regarding the selection of network interfaces ought to permit as many interfaces as possible.¶
Applications using the Transport Services API need to be designed to be robust to the automated selection provided by the Transport Services System. This automated selection is constrained by the preferences expressed by the application and requires applications to explicitly set Properties that define any necessary constraints on protocol, path, and interface selection.¶
There are applications that will need to control fine-grained details of transport protocols to optimize their behavior and ensure compatibility with remote systems. It is thereforeRECOMMENDED that the Transport Services API and the Transport Services Implementation permit more specialized protocol features to be used.¶
Some specialized features could be needed by an application only when using a specific protocol and not when using others. For example, if an application is using TCP, it could require control over the User Timeout Option for TCP[RFC5482]. Such features would not take effect for other transport protocols. In such cases, the API ought to expose the features in such a way that they take effect when a particular protocol is selected but do not imply that only that protocol could be used. For example, if the API allows an application to specify a preference for using the User Timeout Option, communication would not fail when a protocol such as UDP is selected.¶
Other specialized features, however, can also be strictly required by an application and thus further constrain the set of protocols that can be used. For example, if an application requires support for automatic handover or failover for a connection, only Protocol Stacks that provide this feature are eligible to be used, e.g., Protocol Stacks that include a multipath protocol or a protocol that supports connection migration. A Transport Services API needs to allow applications to define such requirements and constrain the options available to a Transport Services Implementation. Since such options are not part of the core/common features, it will generally be simple for an application to modify its set of constraints and change the set of allowable protocol features without changing the core implementation.¶
To control these specialized features, the application can declare its preference: whether the presence of a specific feature is prohibited, should be avoided, can be ignored, is preferred, or is required in the preestablishment phase. An implementation of a Transport Services API would honor this preference and allow the application to query the availability of each specialized feature after successful establishment.¶
A Transport Services Implementation can attempt to use, and select between, multiple Protocol Stacks based on the Selection and Connection Properties communicated by the application, along with any Security Parameters. The implementation can only attempt to use multiple Protocol Stacks when they are "equivalent", which means that the stacks can provide the same Transport Properties and interface expectations as requested by the application. Equivalent Protocol Stacks can be safely swapped or raced in parallel (seeSection 4.2.2) during Connection establishment.¶
The following two examples show non-equivalent Protocol Stacks:¶
If the application requires preservation of Message boundaries, a Protocol Stack that runs UDP as the top-level interface to the application is not equivalent to a Protocol Stack that runs TCP as the top-level interface. A UDP stack would allow an application to read out Message boundaries based on datagrams sent from the remote system, whereas TCP does not preserve Message boundaries on its own but needs a framing protocol on top to determine Message boundaries.¶
If the application specifies that it requires reliable transmission of data, then a Protocol Stack using UDP without any reliability layer on top would not be allowed to replace a Protocol Stack using TCP.¶
The following example shows equivalent Protocol Stacks:¶
If the application does not require reliable transmission of data, then a Protocol Stack that adds reliability could be regarded as an equivalent Protocol Stack as long as providing this would not conflict with any other application-requested Properties.¶
A Transport Services Implementation can race different securityprotocols, e.g., if the System Policy is explicitly configured to consider them equivalent.A Transport Services ImplementationSHOULD only race Protocol Stacks where the transport security protocols within the stacks are identical.To ensure that security protocols are not incorrectly swapped, a Transport Services ImplementationMUST only select Protocol Stacks that meet application requirements[RFC8922].A Transport Services ImplementationMUST NOT automatically fall back from secure protocols to insecure protocols or fall back to weaker versions of secure protocols.A Transport Services ImplementationMAY allow applications to explicitly specify which versions of a protocol ought to be permitted, e.g., to allow a minimum version of TLS 1.2 if TLS 1.3 is not available.¶
A Transport Services ImplementationMAY specify security Properties relating to how the system operates (e.g., requirements, prohibitions, and preferences for the use of DNS Security Extensions (DNSSEC) or DNS over HTTPS (DoH)).¶
It is important to note that neither the Transport Services API[RFC9622] nor the guidelines for implementation of the Transport Services System[RFC9623] define new protocols or protocol capabilities that affect what is communicated across the network. A Transport Services SystemMUST NOT require that a peer on the other side of a connection use the same API or implementation. A Transport Services Implementation acting as a connection initiator is able to communicate with any existing Endpoint that implements the transport protocol(s) and all the required Properties selected. Similarly, a Transport Services Implementation acting as a Listener can receive connections for any protocol that is supported from an existing initiator that implements the protocol, independently of whether or not the initiator uses the Transport Services System.¶
A Transport Services Implementation makes decisions that select protocols and interfaces. In normal use, a given version of a Transport Services SystemSHOULD result in consistent protocol and interface selection decisions for the same network conditions, given the same set of Properties. This is intended to provide predictable outcomes to the application using the API.¶
The Transport Services API increases the layer of abstraction for applications, and it enables greater automation below the API. Such increasedabstraction comes at the cost of increased complexity when application programmers, users, or system administratorstry to understand why any issues and failures may be happening.A Transport Services System should therefore offer monitoring functions thatprovide relevant debug and diagnostics information. For example, such monitoring functions could indicate the protocol(s) in use, thenumber of open connections per protocol, and any statistics that these protocols may offer.¶
This section describes the architecture non-normatively and explains the operation of a Transport Services Implementation. The concepts defined in this document are intended primarily for use in the documents and specifications that describe the Transport Services System. This includes the architecture, the Transport Services API, and the associated Transport Services Implementation. While the specific terminology can be used in some implementations, it is expected that there will remain a variety of terms used by running code.¶
The architecture divides the concepts for the Transport Services System into two categories:¶
API concepts, which are intended to be exposed to applications; and¶
System-implementation concepts, which are intended to be internally used by a Transport Services Implementation.¶
The following diagram summarizes the top-level concepts in a Transport Services System and how they relate to one another.¶
+-----------------------------------------------------+ | Application | +-+----------------+------^-------+--------^----------+ | | | | | pre- | data | events establishment | transfer | | | establishment | termination | | | | | | | +--v------v-------v+ | +-v-------------+ Connection(s) +-------+----------+ | Transport +--------+---------+ | | Services | | | API | +-------------+ | +------------------------+--+ Framer(s) |-----------+ | +-------------+ +------------------------|----------------------------+ | Transport | | | System | +-----------------+ | | Implementation | | Cached | | | | | State | | | (Candidate Gathering) | +-----------------+ | | | | | (Candidate Racing) | +-----------------+ | | | | System | | | | | Policy | | | +----------v-----+ +-----------------+ | | | Protocol | | +-------------+ Stack(s) +----------------------+ +-------+--------+ V+-----------------------------------------------------+| Network-Layer Interface |+-----------------------------------------------------+
The Transport Services Implementation includes the Cached State and System Policy.¶
The System Policy provides input from an operating system or other global preferences that can constrain or influence how an implementation will gather Candidate Paths and Protocol Stacks and race the candidates when establishing a Connection. As the details of System Policy configuration and enforcement are largely dependent on the platform and implementation and do not affect application-level interoperability, the Transport Services API[RFC9622] does not specify an interface for reading or writing System Policy.¶
The Cached State is the state and history that the Transport Services Implementation keeps for each set of associated Endpoints that have previously been used. An application ought to explicitly request any required or preferred Properties via the Transport Services API.¶
Fundamentally, a Transport Services API needs to provide Connection objects (Section 4.1.2) that allow applications to establish communication and then send and receive data. These could be exposed as handles or referenced objects, depending on the chosen programming language.¶
Beyond the Connection objects, there are several high-level groups of actions that any Transport Services API needs to provide:¶
Preestablishment (Section 4.1.3) encompasses the Properties that an application can pass to describe its intent, requirements, prohibitions, and preferences for its networking operations. These Properties apply to multiple transport protocols, unless otherwise specified. Properties specified during preestablishment can have a large impact on the rest of the interface: they modify how establishment occurs, influence the expectations around data transfer, and determine the set of events that will be supported.¶
Establishment (Section 4.1.4) focuses on the actions that an application takes on the Connection objects to prepare for data transfer.¶
Data transfer (Section 4.1.5) consists of how an application represents the data to be sent and received, the functions required to send and receive that data, and how the application is notified of the status of its data transfer.¶
Event handling (Section 4.1.6) defines categories of notifications that an application can receive during the lifetime of a Connection. Events also provide opportunities for the application to interact with the underlying transport by querying state or updating maintenance options.¶
Termination (Section 4.1.7) focuses on the methods by which data transmission is stopped and connection state is torn down.¶
The diagram below provides a high-level view of the actions and events during the lifetime of a Connection object. Note that some actions are alternatives (e.g., whether to initiate a connection or listen for incoming connections), while others are optional (e.g., setting Connection and Message Properties in preestablishment) or have been omitted for brevity and simplicity.¶
Preestablishment : Established : Termination ----------------- : ----------- : ----------- : :+-- Local Endpoint : Message :+-- Remote Endpoint : Receive() | :+-- Transport Properties : Send() | :+-- Security Parameters : | :| : | :| InitiateWithSend() | Close() :| +---------------+ Initiate() +-----+------+ Abort() :+---+ Preconnection |------------->| Connection |-----------> Closed +---------------+ Rendezvous() +------------+ : Listen() | : | | : | : | v : v : | Connection : +----------+ : | Ready : | Listener |----------------------+ : +----------+ Connection Received : : :
In this diagram, the lifetime of a Connection object is divided into three phases:preestablishment, the Established state, and termination of a Connection.¶
Preestablishment is based around a Preconnection object containing varioussub-objects that describe the Properties and parameters of desired Connections(Local and Remote Endpoints, Transport Properties, and Security Parameters).A Preconnection can be used to start listening for inbound connections --in which case a Listener object is created -- or can be used to establish a newconnection directly usingInitiate
(for outbound connections) orRendezvous
(for peer-to-peer connections).¶
Once a Connection is in the Established state, an application can send and receiveMessage objects and can receive state updates.¶
Closing or aborting a Connection, either locally or from the peer, can terminatea Connection.¶
An Endpoint Identifier specifies one side of a transport connection. Endpoints can be Local Endpoints or Remote Endpoints, and the Endpoint Identifiers can respectively represent an identity that the application uses for the source or destination of a connection. An Endpoint Identifier can be specified at various levels of abstraction. An Endpoint Identifier at a higher level of abstraction (such as a hostname) can be resolved to more concrete identities (such as IP addresses). A Remote Endpoint Identifier can also represent a multicast group or anycast address. In the case of multicast, a multicast transport will be selected for communication.¶
Listen
for incoming Connections but is optional if it is used toInitiate
a Connection. The Remote Endpoint Identifier is required in a Preconnection that is used toInitiate
a Connection but is optional if it is used toListen
for incoming Connections. The Local Endpoint Identifier and the Remote Endpoint Identifier are both required if a peer-to-peerRendezvous
is to occur based on the Preconnection.¶Transport Properties allow the application to express requirements, prohibitions, and preferences and configure a Transport Services Implementation. There are three kinds of Transport Properties:¶
Initiate
.¶Rendezvous
.As with Listeners, the set of local paths and endpoints is constrainedby Selection Properties. If successful, callingRendezvous
generates and asynchronously returns aConnection object to represent the established peer-to-peer connection.The processes by which connections are initiated during aRendezvous
action will depend on the set of Local and Remote Endpoints configured onthe Preconnection. For example, if the Local and Remote Endpoints are TCPhost candidates, then a TCP simultaneous open[RFC9293] might be performed.However, if the set of Local Endpoints includes server-reflexivecandidates, such as those provided by STUN (Session Traversal Utilitiesfor NAT)[RFC8489], aRendezvous
action will racecandidates in the style of the ICE (Interactive Connectivity Establishment)algorithm[RFC8445] to perform NATbinding discovery and initiate a peer-to-peer connection.¶Send
action transmits a Message over a Connection to the Remote Endpoint. The interface toSend
can accept Message Properties specific to how the Message content is to be sent. The status of theSend
action is delivered back to the sending application in an event (Section 4.1.6).¶Receive
action indicates that the application is ready to asynchronously accept a Message over a Connection from a Remote Endpoint, while the Message content itself will be delivered in an event (Section 4.1.6). The interface toReceive
can include Message Properties specific to the Message that is to be delivered to the application.¶The following categories of events can be delivered to an application:¶
Receive
action. To allow an application to limit the occurrence of such events, each call toReceive
will be paired with a singleReceive
event. This can include an error if theReceive
action cannot be satisfied, e.g., due to the Connection being closed.¶Send
action. This might indicate a failure if the Message cannot be sent or might indicate that the Message has been processed by the Transport Services System.¶A Connection Group is a set of Connections that shares Connection Properties and Cached State generated by protocols.A Connection Group represents state for managing Connections within a single application and does not require end-to-end protocol signaling. For transport protocols that support multiplexing, only Connections within the same Connection Group are allowed to be multiplexed together.¶
The API allows a Connection to be created from another Connection. This adds the new Connection to the Connection Group. A change to one of the Connection Properties on any Connection in the Connection Group automatically changes the Connection Property for all others. All Connections in a Connection Group share the same set of Connection Properties except for the Connection Priority. These Connection Properties are said to be entangled.¶
Passive Connections can also be added to a Connection Group, e.g., when a Listener receives a new Connection that is just a new stream of an already-active multistreaming protocolinstance.¶
While Connection Groups are managed by the Transport Services Implementation, an application can define different Connection Contexts for different Connection Groups to explicitly control caching boundaries, as discussed inSection 4.2.3.¶
This section defines the key architectural concepts for the Transport Services Implementation within the Transport Services System.¶
The Transport Services System consists of the Transport Services Implementation and the Transport Services API.The Transport Services Implementation consists of all objects and protocol instances used internally to a system or library to implement the functionality needed to provide a transport service across a network, as required by the abstract interface.¶
Connection establishment attempts for a set of candidates may be performed simultaneously, synchronously, serially, or using some combination of all of these. We refer to this process as racing, borrowing terminology from Happy Eyeballs[RFC8305].¶
A Transport Services Implementation can by default share stored Properties across Connections within an application, such as cached protocol state, cached path state, and heuristics. This provides efficiency and convenience for the application, since the Transport Services System can automatically optimize behavior.¶
The Transport Services API can allow applications to explicitly define Connection Contexts that force separation of Cached State and Protocol Stacks.For example, a web browser application could use Connection Contexts with separate caches when implementing different tabs. Possible reasons to isolate Connections using separate Connection Contexts include privacy concerns regarding:¶
reusing cached protocol state, as this can lead to linkability. Sensitive state could include TLS session state[RFC8446] and HTTP cookies[RFC6265]. These concerns could be addressed using Connection Contexts with separate caches, such as for different browser tabs.¶
allowing Connections to multiplex together, which can tell a Remote Endpoint that all of the Connections are coming from the same application. Using Connection Contexts avoids the Connections being multiplexed in an HTTP/2 or QUIC stream.¶
This document has no IANA actions.¶
The Transport Services System does not recommend the use of specific securityprotocols or algorithms. Its goal is to offer ease of use for existing protocolsby providing a generic security-related interface. Each provided interfacetranslates to an existing protocol-specific interface provided by supportedsecurity protocols. For example, trust verification callbacks are common partsof TLS APIs; a Transport Services API exposes similar functionality[RFC8922].¶
As described above inSection 3.3, if a Transport Services Implementation racesbetween two different Protocol Stacks, both need to use the same security protocolsand options. However, a Transport Services Implementation can race different securityprotocols, e.g., if the application explicitly specifies that it considers themequivalent.¶
The application controls whetherinformation from previous racing attempts or other informationabout past communications that was cached bythe Transport Services System is used during establishment.This allows applications to maketrade-offs between efficiency (through racing) and privacy (via information thatmight leak from the cache toward an on-path observer). Some applications havefeatures (e.g., "incognito mode") that align with this functionality.¶
Applications need to ensure that they use security APIs appropriately. In caseswhere applications use an interface to provide sensitive keying material, e.g.,access to private keys or copies of pre-shared keys (PSKs), key use needs to bevalidated and scoped to the intended protocols and roles. For example, if anapplication provides a certificate to only be used as client authentication foroutbound TLS and QUIC connections, the Transport Services SystemMUST NOT use thisautomatically in other contexts (such as server authentication for inboundconnections or in other security protocol handshakes that are not equivalent to TLS).¶
A Transport Services SystemMUST NOT automatically fall back fromsecure protocols to insecure protocols or fall back to weaker versions of secureprotocols (seeSection 3.3). For example, if an application requests a specific version of TLSbut the desired version of TLS is not available, its connection will fail.As described inSection 3.3, the Transport Services API can allow applicationsto specify minimum versions that are allowed to be used by the Transport Services System.¶
This work has received funding from the European Union's Horizon 2020 researchand innovation programme under grant agreements No. 644334 (NEAT), No. 688421(MAMI), and No. 815178 (5GENESIS).¶
This work has been supported by:¶
Thanks toReese Enghardt,Max Franke,Mirja Kühlewind,Jonathan Lennox, andMichael Welzl for the discussions and feedback that helped shape the architectureof the system described here.Particular thanks are also due toPhilipp S. Tiesel andChristopher A. Wood,who were both coauthors of this specification as it progressedthrough the Transport Services (TAPS) Working Group.Thanks as well toStuart Cheshire,Josh Graessley,David Schinazi,andEric Kinnear for their implementation and design efforts, including HappyEyeballs, that heavily influenced this work.¶