Re: [Masque] Comments on draft-Pauly-masque-quic-proxy

Martin Duke <martin.h.duke@gmail.com> Tue, 09 March 2021 17:32 UTC

Return-Path: <martin.h.duke@gmail.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 AB66F3A147B for <masque@ietfa.amsl.com>; Tue, 9 Mar 2021 09:32:51 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.098
X-Spam-Level:
X-Spam-Status: No, score=-2.098 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id UN68shoTezED for <masque@ietfa.amsl.com>; Tue, 9 Mar 2021 09:32:49 -0800 (PST)
Received: from mail-il1-x12e.google.com (mail-il1-x12e.google.com [IPv6:2607:f8b0:4864:20::12e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id B1F093A147D for <masque@ietf.org>; Tue, 9 Mar 2021 09:32:49 -0800 (PST)
Received: by mail-il1-x12e.google.com with SMTP id f10so12900121ilq.5 for <masque@ietf.org>; Tue, 09 Mar 2021 09:32:49 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=NlbIwDLLI46ih4bichPv/7zKRAecfahGILzfYY+LBTI=; b=oey/SmZetza55ImhL8Mty3fsTjN84LTJXvDw44Hc4R+DNnTweSQQlLHT86CgUDMOLM V/iO3oZSOMAJJbN9KRwGklpqS3gRRz5oaQk0nSDLyfKhwWSMa6P9T9lzzRALDDX60wk/ w5bGXISGyCXv3MhCxNinOMfyQbG0DDnEHgve6L6KaPQzDU1NGwBD2PCD3/2EpHXhkhsb bH3tiitYl82aZuFP2H/fC8CuRYVvB1dCsYOB81YPYol0eF9OIGkllH02/Apw1H/W9WK4 n5q/ukaaku8eHnXRBkerGSZXCtm9fn9obGV77En28bQ9Dl47nmsJbVU2SFGXHkCK05Fu uF+Q==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=NlbIwDLLI46ih4bichPv/7zKRAecfahGILzfYY+LBTI=; b=arJAzitZYUD5QxBCrYis5o4F1fRSFHmhBvwi2+WbwSLBaUWlJq72VrDuwwOHzV1bqg 9d/HgxeE2bBUTAIGFlUh3DEzseJmlMmrrjvY+jCV4UAfk/n310nREFnjtGzmoNDAxRBw vAHiX5h7FxbWOc4wJf2Ms49KYxH9m6+VyHCW4MHOsyuHG+Ej+2Wbd5oydlwp2OSfxZWn 1HXiD7fMjrcKnqoxLXIhYs/ix4NAGQ2D2OFkidlkMjhe5jNitnUx9ysWroFS3Ns2JdVX 5JkjzBGPtuI4DvDnBc1WyldXC/YcwHEpyfa+WtHIPyvwbL6yYt2OgoXadVwJXeGBZyr7 pmNg==
X-Gm-Message-State: AOAM530PCtlzFFrVEuaxDnb9pXfPpSnrcm9SSjBTFXm/n/CYG7Mc4GCJ tnV8zm7Z04UyYUb0z9TmoKrEP8fW9823TH8v+r/FHg0m0q8=
X-Google-Smtp-Source: ABdhPJwnuJDa2/BeL9kDpHZ50O1Xa7v8wJYFyhNURs0g08uc81KdxCFrl8LW+xAIDjwh0Xt71BW8bgqxoOqvylErL2g=
X-Received: by 2002:a05:6e02:2142:: with SMTP id d2mr25090733ilv.249.1615311168196; Tue, 09 Mar 2021 09:32:48 -0800 (PST)
MIME-Version: 1.0
References: <CAM4esxR1RVMBsbb-OsX0RUMHH4XbSBdrgBFP4oUAs=ws3at_wQ@mail.gmail.com> <438EC9D4-76D0-4639-ADB6-BD9C77ABC9F8@apple.com> <CAM4esxSoWVXtF-CXL-uptmA+iYnBr8AoG1W7ZnxBTzC0aP_PWw@mail.gmail.com> <547B8CA4-2E2C-49D6-9E75-4EE3DA5B6948@apple.com>
In-Reply-To: <547B8CA4-2E2C-49D6-9E75-4EE3DA5B6948@apple.com>
From: Martin Duke <martin.h.duke@gmail.com>
Date: Tue, 09 Mar 2021 09:32:41 -0800
Message-ID: <CAM4esxTkxyAbXETE6Q_DCpwmQyauR=2qmV0TJAzTVgMREa1z0A@mail.gmail.com>
To: Tommy Pauly <tpauly@apple.com>
Cc: David Schinazi <dschinazi.ietf@gmail.com>, MASQUE <masque@ietf.org>
Content-Type: multipart/alternative; boundary="00000000000061d82c05bd1df083"
Archived-At: <https://mailarchive.ietf.org/arch/msg/masque/CCH7JX_VjnoHBIGfsnrYhi8TuLI>
Subject: Re: [Masque] Comments on draft-Pauly-masque-quic-proxy
X-BeenThere: masque@ietf.org
X-Mailman-Version: 2.1.29
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: Tue, 09 Mar 2021 17:32:52 -0000

I'm asking about these packets in the context of the MASQUE (outer)
connection.

On Tue, Mar 9, 2021 at 9:26 AM Tommy Pauly <tpauly@apple.com> wrote:

>
>
> On Mar 9, 2021, at 6:35 AM, Martin Duke <martin.h.duke@gmail.com> wrote:
>
> I don't think this applies to base CONNECT-UDP. If the client changes its
> address, the MASQUE connection will do all the verification necessary to
> mitigate any attacks.
>
>
> Yes, the proxy will do the validation, but it may want to reset the port
> to give a hint to the target to look at least like a NAT rebinding event.
>
>
> The difference in your draft is the UDP packets are not entirely part of
> the MASQUE connection anymore.
>
>
> They’re no longer tunneled, they are just forwarded, right. The proxy
> becomes a switch/NAT.
>
> In fact, it would be good to clarify to what extent they do count as part
> of the connection. Do they:
> 1) have (implied?) packet numbers?
>
> 2) if so, can they be acknowledged?
> 3) If not, how can they count against congestion control?
>
>
> The packet numbers, ACKs, and congestion control are all end-to-end, and
> do not involve the “control” connection between the client and proxy after
> tunneling starts.
>
> The forwarder still gets to rate control if it wants on a per-flow basis.
>
> 4) Can they trigger address change events, or will the proxy get a new
> socket to make the server handle it?
>
>
> The proxy always is able to choose what socket to forward on, and what
> rate it allows for forwarding.
>
> Tommy
>
>
> I'm sure there are several other similar questions.
>
> On Tue, Mar 9, 2021 at 5:10 AM Tommy Pauly <tpauly@apple.com> wrote:
>
>> Hi Martin,
>>
>> On Mar 8, 2021, at 3:51 PM, Martin Duke <martin.h.duke@gmail.com> wrote:
>>
>> Thanks for writing this draft! I have some comments mostly focused on
>> migration.
>>
>> I conceptualize this design as the proxy falling back to NAT behavior
>> after the handshake is done. If that’s correct, I suggest you take a look
>> at the (rapidly evolving!) NAT section of the quic-managability draft.
>>
>>
>> You’re quite correct that this ends up being quite similar to some NAT
>> considerations, or almost a client-side load balancer.
>>
>> Specifically:
>>
>> 1) you should discuss the implications of the client receiving
>> NEW_CONN_ID. I gather the client would have to request it from the proxy
>> and revert to tunneling for that CID if rejected?
>>
>>
>> That is correct! It’s described a bit in section 4, but we could expand
>> upon it:
>>
>>    A client sends new CONNECT-UDP requests when it wants to start a new
>>    QUIC connection to a target, when it has received a new Server
>>    Connection ID for the target, and before it advertises a new Client
>>    Connection ID to the target.
>>
>>
>>
>>
>> 2) It’s important that any address or port change by the client translate
>> to a new UDP socket in the server direction. To do otherwise would break
>> the path validation mechanisms that protect against a variety of attacks.
>> To the maximum extent possible, port changes should beget port changes and
>> address changes lead to address changes, as QUIC implementations may use
>> this as a heuristic.
>>
>>
>> Yes, I agree, and will be adding that to the next version:
>>
>> https://github.com/tfpauly/quic-proxy/issues/41
>>
>> I do think this plays into the base CONNECT-UDP as well:
>>
>> https://github.com/ietf-wg-masque/draft-ietf-masque-connect-udp/issues/42
>>
>> Best,
>> Tommy
>>
>>
>> Martin
>>
>>
>>
>