<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
<!-- generated by https://github.com/cabo/kramdown-rfc version 1.7.29 (Ruby 3.2.2) -->
<?rfc-ext html-pretty-print="prettyprint https://cdn.rawgit.com/google/code-prettify/master/loader/run_prettify.js"?>
<rfc xmlns:x="http://purl.org/net/xml2rfc/ext"
     category="std"
     consensus="true"
     docName="draft-ietf-httpbis-h3-websockets-latest"
     ipr="trust200902"
     number="9220"
     sortRefs="true"
     submissionType="IETF"
     symRefs="true"
     tocInclude="true">
   <x:feedback template="mailto:ietf-http-wg@w3.org?subject={docname},%20%22{section}%22\&amp;amp;body=%3c{ref}%3e:"/>
   <front>
      <title>Bootstrapping WebSockets with HTTP/3</title>
      <author fullname="Ryan Hamilton" initials="R." surname="Hamilton">
         <organization>Google</organization>
         <address>
            <email>rch@google.com</email>
         </address>
      </author>
      <date day="06" month="November" year="2025"/>
      <area>ART</area>
      <workgroup>HTTP</workgroup>
      <keyword>extended connect</keyword>
      <keyword>42</keyword>
      <abstract><?line 93?>
         <t>The mechanism for running the WebSocket Protocol over a single stream of an HTTP/2 connection is equally applicable to HTTP/3, but the HTTP-version-specific details need to be specified. This document describes how the mechanism is adapted for HTTP/3.</t>
      </abstract>
      <note removeInRFC="true" title="About This Document">
         <t>Status information for this document may be found at <eref target="https://datatracker.ietf.org/doc/draft-ietf-httpbis-h3-websockets/"/>.</t>
         <t>Discussion of this document takes place on the HTTP Working Group mailing list (<eref target="mailto:ietf-http-wg@w3.org"/>), which is archived at <eref target="https://lists.w3.org/Archives/Public/ietf-http-wg/"/>. Working Group information can be found at <eref target="https://httpwg.org/"/>.</t>
         <t>Source for this draft and an issue tracker can be found at <eref target="https://github.com/httpwg/http-extensions/labels/h3-websockets"/>.</t>
      </note>
   </front>
   <middle><?line 100?>
      <section anchor="introduction">
         <name>Introduction</name>
         <t>"Bootstrapping WebSockets with HTTP/2" <xref target="RFC8441"/> defines an extension to HTTP/2 <xref target="HTTP2"/> that is also useful in HTTP/3 <xref target="HTTP3"/>. This extension makes use of an HTTP/2 setting. <xref section="A.3" sectionFormat="of" target="HTTP3"/> gives some guidance on what changes (if any) are appropriate when porting settings from HTTP/2 to HTTP/3.</t>
      </section>
      <section anchor="conventions-and-definitions">
         <name>Conventions and Definitions</name>
         <t>The key words "<bcp14>MUST</bcp14>", "<bcp14>MUST NOT</bcp14>", "<bcp14>REQUIRED</bcp14>", "<bcp14>SHALL</bcp14>", "<bcp14>SHALL NOT</bcp14>", "<bcp14>SHOULD</bcp14>", "<bcp14>SHOULD NOT</bcp14>", "<bcp14>RECOMMENDED</bcp14>", "<bcp14>NOT RECOMMENDED</bcp14>", "<bcp14>MAY</bcp14>", and "<bcp14>OPTIONAL</bcp14>" in this document are to be interpreted as described in BCP 14 <xref target="RFC2119"/>
            <xref target="RFC8174"/> when, and only when, they appear in all capitals, as shown here.</t>
         <?line -18?>
      </section>
      <section anchor="websockets-upgrade-over-http3">
         <name>WebSockets Upgrade over HTTP/3</name>
         <t>
            <xref target="RFC8441"/> defines a mechanism for running the WebSocket Protocol <xref target="RFC6455"/> over a single stream of an HTTP/2 connection. It defines an Extended CONNECT method that specifies a new ":protocol" pseudo-header field and new semantics for the ":path" and ":authority" pseudo-header fields. It also defines a new HTTP/2 setting sent by a server to allow the client to use Extended CONNECT.</t>
         <t>The semantics of the pseudo-header fields and setting are identical to those in HTTP/2 as defined in <xref target="RFC8441"/>. <xref section="A.3" sectionFormat="of" target="HTTP3"/> requires that HTTP/3 settings be registered separately for HTTP/3. The SETTINGS_ENABLE_CONNECT_PROTOCOL value is 0x08 (decimal 8), as in HTTP/2.</t>
         <t>If a server advertises support for Extended CONNECT but receives an Extended CONNECT request with a ":protocol" value that is unknown or is not supported, the server <bcp14>SHOULD</bcp14> respond to the request with a 501 (Not Implemented) status code (<xref section="15.6.2" sectionFormat="of" target="HTTP"/>). A server <bcp14>MAY</bcp14> provide more information via a "problem details" response <xref target="RFC7807"/>.</t>
         <t>The HTTP/3 stream closure is also analogous to the TCP connection closure of <xref target="RFC6455"/>. Orderly TCP-level closures are represented as a FIN bit on the stream (<xref section="4.2" sectionFormat="of" target="HTTP3"/>). RST exceptions are represented with a stream error (<xref section="8" sectionFormat="of" target="HTTP3"/>) of type H3_REQUEST_CANCELLED (<xref section="8.1" sectionFormat="of" target="HTTP3"/>).</t>
      </section>
      <section anchor="security-considerations">
         <name>Security Considerations</name>
         <t>This document introduces no new security considerations beyond those discussed in <xref target="RFC8441"/>.</t>
      </section>
      <section anchor="iana-considerations">
         <name>IANA Considerations</name>
         <t>This document registers a new setting in the "HTTP/3 Settings" registry (<xref section="11.2.2" sectionFormat="of" target="HTTP3"/>).</t>
         <dl>
            <dt>Value:</dt>
            <dd>
               <t>0x08</t>
            </dd>
            <dt>Setting Name:</dt>
            <dd>
               <t>SETTINGS_ENABLE_CONNECT_PROTOCOL</t>
            </dd>
            <dt>Default:</dt>
            <dd>
               <t>0</t>
            </dd>
            <dt>Status:</dt>
            <dd>
               <t>permanent</t>
            </dd>
            <dt>Specification:</dt>
            <dd>
               <t>This document</t>
            </dd>
            <dt>Change Controller:</dt>
            <dd>
               <t>IETF</t>
            </dd>
            <dt>Contact:</dt>
            <dd>
               <t>HTTP Working Group (ietf-http-wg@w3.org)</t>
            </dd>
         </dl>
      </section>
   </middle>
   <back>
      <displayreference target="HTTP2" to="HTTP/2"/>
      <displayreference target="HTTP3" to="HTTP/3"/>
      <references anchor="sec-normative-references" title="Normative References">
         <reference anchor="HTTP">
            <front>
               <title>HTTP Semantics</title>
               <author fullname="Roy T. Fielding"
                       initials="R."
                       role="editor"
                       surname="Fielding">
                  <organization>Adobe</organization>
               </author>
               <author fullname="Mark Nottingham"
                       initials="M."
                       role="editor"
                       surname="Nottingham">
                  <organization>Fastly</organization>
               </author>
               <author fullname="Julian Reschke"
                       initials="J."
                       role="editor"
                       surname="Reschke">
                  <organization>greenbytes</organization>
               </author>
               <date month="April" year="2022"/>
            </front>
            <seriesInfo name="RFC" value="9110"/>
            <seriesInfo name="DOI" value="10.17487/RFC9110"/>
         </reference>
         <reference anchor="HTTP2">
            <front>
               <title>HTTP/2</title>
               <author fullname="Martin Thomson" role="editor">
                  <organization>Mozilla</organization>
               </author>
               <author fullname="Cory Benfield" role="editor">
                  <organization>Apple Inc.</organization>
               </author>
               <date month="April" year="2022"/>
            </front>
            <seriesInfo name="RFC" value="9113"/>
            <seriesInfo name="DOI" value="10.17487/RFC9113"/>
         </reference>
         <reference anchor="HTTP3">
            <front>
               <title>Hypertext Transfer Protocol Version 3 (HTTP/3)</title>
               <author fullname="Mike Bishop"
                       initials="M."
                       role="editor"
                       surname="Bishop">
                  <organization>Akamai</organization>
               </author>
               <date month="April" year="2022"/>
            </front>
            <seriesInfo name="RFC" value="9114"/>
            <seriesInfo name="DOI" value="10.17487/RFC9114"/>
         </reference>
         <reference anchor="RFC8441">
            <front>
               <title>Bootstrapping WebSockets with HTTP/2</title>
               <author fullname="P. McManus" initials="P." surname="McManus"/>
               <date month="September" year="2018"/>
            </front>
            <seriesInfo name="RFC" value="8441"/>
            <seriesInfo name="DOI" value="10.17487/RFC8441"/>
         </reference>
         <reference anchor="RFC2119">
            <front>
               <title>Key words for use in RFCs to Indicate Requirement Levels</title>
               <author fullname="S. Bradner" initials="S." surname="Bradner"/>
               <date month="March" year="1997"/>
            </front>
            <seriesInfo name="BCP" value="14"/>
            <seriesInfo name="RFC" value="2119"/>
            <seriesInfo name="DOI" value="10.17487/RFC2119"/>
         </reference>
         <reference anchor="RFC8174">
            <front>
               <title>Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words</title>
               <author fullname="B. Leiba" initials="B." surname="Leiba"/>
               <date month="May" year="2017"/>
            </front>
            <seriesInfo name="BCP" value="14"/>
            <seriesInfo name="RFC" value="8174"/>
            <seriesInfo name="DOI" value="10.17487/RFC8174"/>
         </reference>
         <reference anchor="RFC6455">
            <front>
               <title>The WebSocket Protocol</title>
               <author fullname="I. Fette" initials="I." surname="Fette"/>
               <author fullname="A. Melnikov" initials="A." surname="Melnikov"/>
               <date month="December" year="2011"/>
            </front>
            <seriesInfo name="RFC" value="6455"/>
            <seriesInfo name="DOI" value="10.17487/RFC6455"/>
         </reference>
         <reference anchor="RFC7807">
            <front>
               <title>Problem Details for HTTP APIs</title>
               <author fullname="M. Nottingham" initials="M." surname="Nottingham"/>
               <author fullname="E. Wilde" initials="E." surname="Wilde"/>
               <date month="March" year="2016"/>
            </front>
            <seriesInfo name="RFC" value="7807"/>
            <seriesInfo name="DOI" value="10.17487/RFC7807"/>
         </reference>
      </references>
      <?line 190?>
      <section anchor="acknowledgments" numbered="false">
         <name>Acknowledgments</name>
         <t>This document had reviews and input from many contributors in the IETF HTTP and QUIC Working Groups, with substantive input from David Schinazi, Martin Thomson, Lucas Pardue, Mike Bishop, Dragana Damjanovic, Mark Nottingham, and Julian Reschke.</t>
      </section>
   </back>
</rfc>
