Re: [quicwg/base-drafts] Handshake deadlock (#1824)
martinduke <notifications@github.com> Wed, 03 October 2018 19:44 UTC
Return-Path: <noreply@github.com>
X-Original-To: quic-issues@ietfa.amsl.com
Delivered-To: quic-issues@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 2C70F129619 for <quic-issues@ietfa.amsl.com>; Wed, 3 Oct 2018 12:44:44 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -8.455
X-Spam-Level:
X-Spam-Status: No, score=-8.455 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.456, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_HI=-5, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=github.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 tp49XOltYRxX for <quic-issues@ietfa.amsl.com>; Wed, 3 Oct 2018 12:44:41 -0700 (PDT)
Received: from out-7.smtp.github.com (out-7.smtp.github.com [192.30.252.198]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 0205E129385 for <quic-issues@ietf.org>; Wed, 3 Oct 2018 12:44:41 -0700 (PDT)
Date: Wed, 03 Oct 2018 12:44:40 -0700
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=github.com; s=pf2014; t=1538595880; bh=LFbz8e8Q+J+rpVe14H9lxXOowoLWMqNywisUQIwyfmY=; h=Date:From:Reply-To:To:Cc:In-Reply-To:References:Subject:List-ID: List-Archive:List-Post:List-Unsubscribe:From; b=gOWGWatWEJY2SURTrBjt0bhov9/WHN2lNiZ2EYvERVSfv83j93aC5tPopsX2yhzDh 4t8H+AGauasomoA9P3se8wDmN4peuRK5Oe7SEXRyokkWbysYnuSujzxPQO12mrJdMX cldHszGyg8cf+jb5iW1UH5AUB1d1PACLmNk+taNM=
From: martinduke <notifications@github.com>
Reply-To: quicwg/base-drafts <reply+0166e4ab5630f7c1fc14428c413f55fbb55233ceb77d12f092cf0000000117ccde2892a169ce15d10b5e@reply.github.com>
To: quicwg/base-drafts <base-drafts@noreply.github.com>
Cc: Subscribed <subscribed@noreply.github.com>
Message-ID: <quicwg/base-drafts/pull/1824/review/161327536@github.com>
In-Reply-To: <quicwg/base-drafts/pull/1824@github.com>
References: <quicwg/base-drafts/pull/1824@github.com>
Subject: Re: [quicwg/base-drafts] Handshake deadlock (#1824)
Mime-Version: 1.0
Content-Type: multipart/alternative; boundary="--==_mimepart_5bb51c2844666_4583fe3eead45b46641f"; charset="UTF-8"
Content-Transfer-Encoding: 7bit
Precedence: list
X-GitHub-Sender: martinduke
X-GitHub-Recipient: quic-issues
X-GitHub-Reason: subscribed
X-Auto-Response-Suppress: All
X-GitHub-Recipient-Address: quic-issues@ietf.org
Archived-At: <https://mailarchive.ietf.org/arch/msg/quic-issues/39JtCF8dDedGKqWi49nb2tcxpFs>
X-BeenThere: quic-issues@ietf.org
X-Mailman-Version: 2.1.29
List-Id: Notification list for GitHub issues related to the QUIC WG <quic-issues.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/quic-issues>, <mailto:quic-issues-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/quic-issues/>
List-Post: <mailto:quic-issues@ietf.org>
List-Help: <mailto:quic-issues-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/quic-issues>, <mailto:quic-issues-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 03 Oct 2018 19:44:44 -0000
martinduke commented on this pull request. If it's too late and you're cool with the changes, I can drop a PR. > @@ -875,11 +875,18 @@ The first Handshake packet sent by a server contains a packet number of 0. Handshake packets are their own packet number space. Packet numbers are incremented normally for other Handshake packets. -Servers MUST NOT send more than three datagrams including Initial and Handshake -packets without receiving a packet from a verified source address. Source -addresses can be verified through an address validation token -(delivered via a Retry packet or a NEW_TOKEN frame) or by receiving -any message from the client encrypted using the Handshake keys. +Servers MUST NOT send more than three times as many bytes as the number of bytes +received prior to verifying the client's address. Source addresses can be +verified through an address validation token (delivered via a Retry packet or +a NEW_TOKEN frame) or by receiving any message from the client encrypted using +the Handshake keys. This limit exists to mitigate amplification attacks. + +In order to prevent this limit causing a handshake deadlock, the client SHOULD +send a packet as large as the Initial containing only PADDING if it has no +other data to send and does not yet have the Handshake keys. If the client +has no data to send and the Hanshake keys are available, it SHOULD send a ... send a Handshake packet ... > -packets without receiving a packet from a verified source address. Source -addresses can be verified through an address validation token -(delivered via a Retry packet or a NEW_TOKEN frame) or by receiving -any message from the client encrypted using the Handshake keys. +Servers MUST NOT send more than three times as many bytes as the number of bytes +received prior to verifying the client's address. Source addresses can be +verified through an address validation token (delivered via a Retry packet or +a NEW_TOKEN frame) or by receiving any message from the client encrypted using +the Handshake keys. This limit exists to mitigate amplification attacks. + +In order to prevent this limit causing a handshake deadlock, the client SHOULD +send a packet as large as the Initial containing only PADDING if it has no +other data to send and does not yet have the Handshake keys. If the client +has no data to send and the Hanshake keys are available, it SHOULD send a +packet with a single byte of padding. Details on when to send these PADDING +packets are in {{QUIC-RECOVERY}}. I couldn't find these details after a quick skim. > @@ -875,11 +875,18 @@ The first Handshake packet sent by a server contains a packet number of 0. Handshake packets are their own packet number space. Packet numbers are incremented normally for other Handshake packets. -Servers MUST NOT send more than three datagrams including Initial and Handshake -packets without receiving a packet from a verified source address. Source -addresses can be verified through an address validation token -(delivered via a Retry packet or a NEW_TOKEN frame) or by receiving -any message from the client encrypted using the Handshake keys. +Servers MUST NOT send more than three times as many bytes as the number of bytes +received prior to verifying the client's address. Source addresses can be +verified through an address validation token (delivered via a Retry packet or +a NEW_TOKEN frame) or by receiving any message from the client encrypted using I think valid resumption keys should also be sufficient. > @@ -875,11 +875,18 @@ The first Handshake packet sent by a server contains a packet number of 0. Handshake packets are their own packet number space. Packet numbers are incremented normally for other Handshake packets. -Servers MUST NOT send more than three datagrams including Initial and Handshake -packets without receiving a packet from a verified source address. Source -addresses can be verified through an address validation token -(delivered via a Retry packet or a NEW_TOKEN frame) or by receiving -any message from the client encrypted using the Handshake keys. +Servers MUST NOT send more than three times as many bytes as the number of bytes +received prior to verifying the client's address. Source addresses can be +verified through an address validation token (delivered via a Retry packet or +a NEW_TOKEN frame) or by receiving any message from the client encrypted using +the Handshake keys. This limit exists to mitigate amplification attacks. + +In order to prevent this limit causing a handshake deadlock, the client SHOULD Is SHOULD sufficient? I feel like this a MUST, or compliant implementations will never complete under certain otherwise recoverable loss scenarios. Perhaps the recovery draft is more strict? > @@ -875,11 +875,18 @@ The first Handshake packet sent by a server contains a packet number of 0. Handshake packets are their own packet number space. Packet numbers are incremented normally for other Handshake packets. -Servers MUST NOT send more than three datagrams including Initial and Handshake -packets without receiving a packet from a verified source address. Source -addresses can be verified through an address validation token -(delivered via a Retry packet or a NEW_TOKEN frame) or by receiving -any message from the client encrypted using the Handshake keys. +Servers MUST NOT send more than three times as many bytes as the number of bytes I suggest a rephrase: Prior to verifying the client's address, servers MUST NOT send more than three times as many bytes as the number of bytes received. > @@ -875,11 +875,18 @@ The first Handshake packet sent by a server contains a packet number of 0. Handshake packets are their own packet number space. Packet numbers are incremented normally for other Handshake packets. -Servers MUST NOT send more than three datagrams including Initial and Handshake -packets without receiving a packet from a verified source address. Source -addresses can be verified through an address validation token -(delivered via a Retry packet or a NEW_TOKEN frame) or by receiving -any message from the client encrypted using the Handshake keys. +Servers MUST NOT send more than three times as many bytes as the number of bytes +received prior to verifying the client's address. Source addresses can be +verified through an address validation token (delivered via a Retry packet or +a NEW_TOKEN frame) or by processing any message from the client encrypted using Why not valid resumption keys? -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/quicwg/base-drafts/pull/1824#pullrequestreview-161327536
- [quicwg/base-drafts] Handshake deadlock (#1824) ianswett
- Re: [quicwg/base-drafts] Handshake deadlock (#182… ianswett
- Re: [quicwg/base-drafts] Handshake deadlock (#182… Mike Bishop
- Re: [quicwg/base-drafts] Handshake deadlock (#182… ianswett
- Re: [quicwg/base-drafts] Handshake deadlock (#182… ianswett
- Re: [quicwg/base-drafts] Handshake deadlock (#182… ianswett
- Re: [quicwg/base-drafts] Handshake deadlock (#182… ianswett
- Re: [quicwg/base-drafts] Handshake deadlock (#182… ianswett
- Re: [quicwg/base-drafts] Handshake deadlock (#182… ianswett
- Re: [quicwg/base-drafts] Handshake deadlock (#182… Mike Bishop
- Re: [quicwg/base-drafts] Handshake deadlock (#182… janaiyengar
- Re: [quicwg/base-drafts] Handshake deadlock (#182… martinduke
- Re: [quicwg/base-drafts] Handshake deadlock (#182… ianswett
- Re: [quicwg/base-drafts] Handshake deadlock (#182… ianswett