Re: [Masque] Endpoint requirements for unknown Capsules

Tommy Pauly <tpauly@apple.com> Wed, 22 November 2023 05:48 UTC

Return-Path: <tpauly@apple.com>
X-Original-To: masque@ietfa.amsl.com
Delivered-To: masque@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 902D3C15109D for <masque@ietfa.amsl.com>; Tue, 21 Nov 2023 21:48:38 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.102
X-Spam-Level:
X-Spam-Status: No, score=-2.102 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, MIME_QP_LONG_LINE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01, URIBL_BLOCKED=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=apple.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0ea18eH_40if for <masque@ietfa.amsl.com>; Tue, 21 Nov 2023 21:48:34 -0800 (PST)
Received: from rn-mailsvcp-mx-lapp01.apple.com (rn-mailsvcp-mx-lapp01.apple.com [17.179.253.22]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 6F74CC14CE3F for <masque@ietf.org>; Tue, 21 Nov 2023 21:48:34 -0800 (PST)
Received: from rn-mailsvcp-mta-lapp02.rno.apple.com (rn-mailsvcp-mta-lapp02.rno.apple.com [10.225.203.150]) by rn-mailsvcp-mx-lapp01.rno.apple.com (Oracle Communications Messaging Server 8.1.0.23.20230328 64bit (built Mar 28 2023)) with ESMTPS id <0S4I00PK2G4XJR10@rn-mailsvcp-mx-lapp01.rno.apple.com> for masque@ietf.org; Tue, 21 Nov 2023 21:48:34 -0800 (PST)
X-Proofpoint-ORIG-GUID: ZVh49KnGmHGR_TqSV5RkfWCloniNnchx
X-Proofpoint-GUID: ZVh49KnGmHGR_TqSV5RkfWCloniNnchx
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.619, 18.0.987 definitions=2023-11-22_03:2023-11-21, 2023-11-22 signatures=0
X-Proofpoint-Spam-Details: rule=interactive_user_notspam policy=interactive_user score=0 adultscore=0 phishscore=0 suspectscore=0 mlxscore=0 spamscore=0 mlxlogscore=999 malwarescore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2311060000 definitions=main-2311220040
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=apple.com; h=content-type : content-transfer-encoding : from : mime-version : subject : date : message-id : references : cc : in-reply-to : to; s=20180706; bh=f+y7RuRvO5qqWm3OB0cBq2MSlRwHGKm+jLhQpZjPtCU=; b=D0oytDeOFJ0iIHvFeV4sb/rwrANxMwKEkw8GeXfBbuDgcFfiaetv7CVQVPAsTJCkz2GB yteF18o2LR+hyXiEP1UVl7EZnPdhWbDThacMf4+lfFpkTl0aHcZs3uHggVBAmQdypsgT RqeClCND8nq5GcbIJrMydV58o3frdUDpX8EsgNXJULfGsp9HYhhEDB2DVdAaY2xBb5dp O88HJfCnv7u64gxc6ByWukii+f5BrI/Mnc5S7F7UWY8VDRh5gQ1Fkcs/+JbtcMlleX+2 82/bS/vbQV2GgHRZhHiUiSCe0tQ06Fev49W5CNjGCCTXalpWe/WcvuXMfBP4+YTP8ApR QA==
Received: from rn-mailsvcp-mmp-lapp03.rno.apple.com (rn-mailsvcp-mmp-lapp03.rno.apple.com [17.179.253.16]) by rn-mailsvcp-mta-lapp02.rno.apple.com (Oracle Communications Messaging Server 8.1.0.23.20230328 64bit (built Mar 28 2023)) with ESMTPS id <0S4I00KYZG4XWU10@rn-mailsvcp-mta-lapp02.rno.apple.com>; Tue, 21 Nov 2023 21:48:33 -0800 (PST)
Received: from process_milters-daemon.rn-mailsvcp-mmp-lapp03.rno.apple.com by rn-mailsvcp-mmp-lapp03.rno.apple.com (Oracle Communications Messaging Server 8.1.0.23.20230328 64bit (built Mar 28 2023)) id <0S4I00K00FZU3B00@rn-mailsvcp-mmp-lapp03.rno.apple.com>; Tue, 21 Nov 2023 21:48:32 -0800 (PST)
X-Va-A:
X-Va-T-CD: 7c41845d202abaa5133654699ccc487a
X-Va-E-CD: 290d74a9517533f2629f59b04d62b2c4
X-Va-R-CD: 5f4a0cfc0437a465a05e021cbf08c4e7
X-Va-ID: 9e25757c-4428-422d-9c9d-fdb67e4585dd
X-Va-CD: 0
X-V-A:
X-V-T-CD: 7c41845d202abaa5133654699ccc487a
X-V-E-CD: 290d74a9517533f2629f59b04d62b2c4
X-V-R-CD: 5f4a0cfc0437a465a05e021cbf08c4e7
X-V-ID: 92ab8461-c938-422e-bd64-1b2f7036bf51
X-V-CD: 0
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.619, 18.0.987 definitions=2023-11-22_02:2023-11-21, 2023-11-22 signatures=0
Received: from smtpclient.apple (unknown [17.11.151.175]) by rn-mailsvcp-mmp-lapp03.rno.apple.com (Oracle Communications Messaging Server 8.1.0.23.20230328 64bit (built Mar 28 2023)) with ESMTPSA id <0S4I010BYG4T4X00@rn-mailsvcp-mmp-lapp03.rno.apple.com>; Tue, 21 Nov 2023 21:48:29 -0800 (PST)
Content-type: multipart/alternative; boundary="Apple-Mail-8F329A16-7F9F-4F1B-B9DF-ABEB0E2BAC0B"
Content-transfer-encoding: 7bit
From: Tommy Pauly <tpauly@apple.com>
MIME-version: 1.0 (1.0)
Date: Tue, 21 Nov 2023 21:48:19 -0800
Message-id: <EFFA5FC9-0A09-4494-9F03-64D0C93CD79E@apple.com>
References: <CALGR9oaGSX+p6K=yjjMye14oD+cpYqika05gkw6N8KbPOiRcTQ@mail.gmail.com>
Cc: MASQUE <masque@ietf.org>, HTTP Working Group <ietf-http-wg@w3.org>, WebTransport <webtransport@ietf.org>
In-reply-to: <CALGR9oaGSX+p6K=yjjMye14oD+cpYqika05gkw6N8KbPOiRcTQ@mail.gmail.com>
To: Lucas Pardue <lucaspardue.24.7@gmail.com>
X-Mailer: iPhone Mail (21C52)
Archived-At: <https://mailarchive.ietf.org/arch/msg/masque/_fNBo1ysTelIAdukk38969bYMzM>
Subject: Re: [Masque] Endpoint requirements for unknown Capsules
X-BeenThere: masque@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: Multiplexed Application Substrate over QUIC Encryption <masque.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/masque>, <mailto:masque-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/masque/>
List-Post: <mailto:masque@ietf.org>
List-Help: <mailto:masque-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/masque>, <mailto:masque-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 22 Nov 2023 05:48:38 -0000

Good question!

While the connect-ip capsules don’t have defined behavior for connect-udp, that shouldn’t prevent them from being used in the future. An assign IP could make sense there. There’s a benefit from being able to use capsules across protocols like that. 

However, in order for it to work, I think we’d need to have a negotiation between client and server to say “I support the connect-udp extension that allows address assigning.”

That doesn’t answer your question. I could see this going either way. The problem with option d is that it requires the connect-udp implementation to be aware of these capsules in order to send an error. So I’d probably go with interpretation b?

Tommy 

> On Nov 21, 2023, at 12:05 PM, Lucas Pardue <lucaspardue.24.7@gmail.com> wrote:
> 
> 
> Hi folks,
> 
> I have a question about how endpoints (not intermediaries) should approach handling HTTP Capsules and I'm looking for some WG input.
> 
> RFC 9297 defined HTTP Datagrams and the Capsule Protocol[1]. During standardization, the primary use case was for proxying UDP over HTTP (RFC 9298).
> 
> 9297 defines Datagram capsules and 9298 defines how an Upgrade or extended request accompanied with a connect-udp token, when successful, enables *both* UDP proxying and the Capsule protocol. Once the request is set up it is the expectation that Datagram capsules are exchanged, modulo HTTP/3 which also has a native QUIC Datagram mapping (so endpoints can exchange either form).
> 
> RFC 9297 section 3.2 states:
> 
> > Endpoints that receive a Capsule with an unknown Capsule Type MUST silently drop that Capsule and skip over it to parse the next Capsule.
> 
> This is inspired by HTTP/2&3 frame design with the goal of extensibility and maintenance*. We have GREASE capsule codepoints and unknown real extensions can be used with causing things to fall over. So far so good.
> 
> Recently, RFC 9484 was published, defining IP over HTTP. This defined a connect-ip token and 3 new capsule types, ADDRESS_ASSIGN, ADDRESS_REQUEST, and ROUTE_ADVERTISEMENT.
> 
> So here's the question:
> 
> Assume there's an endpoint that supports both IP and UDP tunneling. It knows about the tokens and the capsules I mentioned above. If it receives a request for connect-udp and accepts it, then receives an ADDRESS_ASSIGN capsule what should it do?
> 
> The text in RFC 9297 seems a little ambiguous and I tried to map out the options
> 
> a) The ADDRESS_ASSIGN capsule is unknown in the context of RFC 9298, so it MUST be ignored
> b) The ADDRESS_ASSIGN capsule is unknown in the connect-udp context of the target resource of the request over which the capsule protocol is using, so it MUST be ignored
> c) The ADDRESS_ASSIGN capsule is known to the endpoint. However, it is undefined and so is silently dropped
> d) The ADDRESS_ASSIGN capsule is known to the endpoint. Since this capsule is unexpected for connect-udp, the server treats this as some form of protocol violation (stream or connection close).
> 
> Option (d) seems drastic but is more in the theme of dealing with the "Harmful consequences of Tolerating the Unexpected" [4], so might actually be The Right Thing TM.
> 
> We have other specs like WebTransport queuing up 13 new capsule registrations. If there's anything we could do to clarify the situation (such as a short update doc to RFC 9297) then now seems like the right time to be doing it. So please let me know your opinions.
> 
> Cheers,
> Lucas
> 
> * There are other considerations for intermediaries but I'm overlooking that complication right now.
> 
> 
> [1] - https://www.rfc-editor.org/rfc/rfc9297.html
> [2] - https://www.rfc-editor.org/rfc/rfc9298.html
> [3] - https://www.rfc-editor.org/rfc/rfc9484.html
> [4] - https://www.rfc-editor.org/rfc/rfc9413.html#section-4
> --
> Webtransport mailing list
> Webtransport@ietf.org
> https://www.ietf.org/mailman/listinfo/webtransport