Re: Need your help: different connection IDs in the same datagram

Martin Thomson <mt@lowentropy.net> Thu, 16 July 2020 00:29 UTC

Return-Path: <mt@lowentropy.net>
X-Original-To: quic@ietfa.amsl.com
Delivered-To: quic@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 0CAAD3A0F0E for <quic@ietfa.amsl.com>; Wed, 15 Jul 2020 17:29:29 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.12
X-Spam-Level:
X-Spam-Status: No, score=-2.12 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, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=lowentropy.net header.b=h7/Qh/H4; dkim=pass (2048-bit key) header.d=messagingengine.com header.b=CyFR1uxp
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 XQT-spdKzewD for <quic@ietfa.amsl.com>; Wed, 15 Jul 2020 17:29:28 -0700 (PDT)
Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 130243A07D1 for <quic@ietf.org>; Wed, 15 Jul 2020 17:29:28 -0700 (PDT)
Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailout.nyi.internal (Postfix) with ESMTP id 6DA785C00DA for <quic@ietf.org>; Wed, 15 Jul 2020 20:29:27 -0400 (EDT)
Received: from imap2 ([10.202.2.52]) by compute2.internal (MEProxy); Wed, 15 Jul 2020 20:29:27 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lowentropy.net; h=mime-version:message-id:in-reply-to:references:date:from:to :subject:content-type; s=fm2; bh=bAbaTYR/BikaSYPs0kWG0JzSpdKSuUC FeN1apvj3enw=; b=h7/Qh/H41qhsVhufdFIrnlIOGwU378jickLn1v+rPWAbe+K qBiuK4zog2mk3VRXihWC6kist2fT97eiGS9ihbuQY8mugAhhCArirvszuwtFYW6f apChge5xAElhkC9Q4bRFqA6t6MdqJuYTlihcuWSS1eApjqaG67WdggX6hf5wL5hE jplK5AxMoNMGlee8Fo1XpaZltAJhH2yFkTQqn3pqvZy6WSNbnHTLUbTO8NqTHsor eZcbyi29fvFdnoZ4FADYn29tPgYLoL39PF/y9iumV2sx8J8for3pmcqkkGzULVbg gONIrMNi0NIWmPb4uo+3Jn9Qa8nBxht5cW1C5QQ==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=bAbaTY R/BikaSYPs0kWG0JzSpdKSuUCFeN1apvj3enw=; b=CyFR1uxpf8oWy0XjBcwMrO 9HfKTMa8Qps5dytlDOVYq18ygC7cBfQgVXsFjW1HmsObFR5yXDCXI+bznQt6nS4d qEQLMZswRKxnmSlXEEHkK6JWw8hym62umAZVeoDzEtzw6UwEOPnZIixw8DtOQebf iT6fZOiK+YjMYCV68jOUeoxeXHutxS0xLOw1HrmV905ev8NY0czsMu+5jqW6Vfkd xtVkDmEvNzU2F+CZE6GjoBgQZRRdTNLnG9ernRRzeVIt9ysiQVGNsN6I+evlqqO8 PquP56UGFRgQyVRfawCFxeDxZZrdakN7g/GDTBAbdSXWAzVrlyGFU6ulPuamxGhQ ==
X-ME-Sender: <xms:Z58PX50WQA8Czwep7UjtF0wY7el6jM9jbkx2jRiZbH_XJ-sL58nPjQ>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduiedrfeefgdefgecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecunecujfgurhepofgfggfkjghffffhvffutgesthdtre dtreertdenucfhrhhomhepfdforghrthhinhcuvfhhohhmshhonhdfuceomhhtsehlohif vghnthhrohhphidrnhgvtheqnecuggftrfgrthhtvghrnhepkeetueeikedtkeelfeekve fhkeffvedvvefgkefgleeugfdvjeejgeffieegtdejnecuvehluhhsthgvrhfuihiivgep tdenucfrrghrrghmpehmrghilhhfrhhomhepmhhtsehlohifvghnthhrohhphidrnhgvth
X-ME-Proxy: <xmx:Z58PXwHLTFkBpdS_jkZ-Tva-tylW84I-czhQ3-NCHUYpcg_H_3X08A> <xmx:Z58PX56tYf4-KG20KhsvXD8oYPD8PIkzl69fOLYIIhgJCGZODLVE8A> <xmx:Z58PX21MHmi8QHeZyI13lqUKK3BX4lBlxsxZQRxqUjMa6mWDwVVEag> <xmx:Z58PXwExSAHx98ZaSmFEQ6HnbV2iD8QIiZCSLCNdI0_MPy0f6XCK-w>
Received: by mailuser.nyi.internal (Postfix, from userid 501) id 016D9E00DF; Wed, 15 Jul 2020 20:29:26 -0400 (EDT)
X-Mailer: MessagingEngine.com Webmail Interface
User-Agent: Cyrus-JMAP/3.3.0-52-g083df19-fm-idx2020-20200715.003-g083df194
Mime-Version: 1.0
Message-Id: <4f59efcf-0fc6-4e64-ad20-8eb4e1978095@www.fastmail.com>
In-Reply-To: <20200715235957.GE9808@lubuntu>
References: <ae21cc02-3357-40c8-a1e9-3966fdf575a5@www.fastmail.com> <20200715180231.GB9808@lubuntu> <7ee5a352-fef6-44ed-9e82-09194aae366e@www.fastmail.com> <20200715235957.GE9808@lubuntu>
Date: Thu, 16 Jul 2020 10:29:07 +1000
From: Martin Thomson <mt@lowentropy.net>
To: quic@ietf.org
Subject: Re: Need your help: different connection IDs in the same datagram
Content-Type: text/plain
Archived-At: <https://mailarchive.ietf.org/arch/msg/quic/PSEdQ8RFaSfhtAKSg1WX1rknnZI>
X-BeenThere: quic@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Main mailing list of the IETF QUIC working group <quic.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/quic>, <mailto:quic-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/quic/>
List-Post: <mailto:quic@ietf.org>
List-Help: <mailto:quic-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/quic>, <mailto:quic-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 16 Jul 2020 00:29:29 -0000

On Thu, Jul 16, 2020, at 09:59, Dmitri Tikhonov wrote:
> You've lost me a bit, Martin.  Is this the code you aimed for?
...
>         if (conn)
>         {
>   #if VARIANT_A
>             if (!conn_owns_scid(conn, dcid))
>   #elif VARIANT_B
>             if (conn != lookup_by_dcid(dcid))
>   #else
> 	    if (false)
>   #endif
>                 continue;
>         }
>         conn = process_packet(quic_packet);
>     }

Yeah, the point being that the check here is added at your discretion.  It is possible to rely on the crypto to ensure that the connection rejects anything that isn't intended for it.