Re: [quicwg/base-drafts] Define requirements for handling packets (#724)
janaiyengar <notifications@github.com> Fri, 08 September 2017 21:40 UTC
Return-Path: <bounces+848413-a050-quic-issues=ietf.org@sgmail.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 1FA0F126B71 for <quic-issues@ietfa.amsl.com>; Fri, 8 Sep 2017 14:40:21 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.02
X-Spam-Level:
X-Spam-Status: No, score=-2.02 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-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 6_q-Wmm0HGpw for <quic-issues@ietfa.amsl.com>; Fri, 8 Sep 2017 14:40:18 -0700 (PDT)
Received: from o7.sgmail.github.com (o7.sgmail.github.com [167.89.101.198]) (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 AFAFD124E15 for <quic-issues@ietf.org>; Fri, 8 Sep 2017 14:40:18 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=github.com; h=from:reply-to:to:cc:in-reply-to:references:subject:mime-version:content-type:content-transfer-encoding:list-id:list-archive:list-post:list-unsubscribe; s=s20150108; bh=++nlRt0+zpWY8raRI37GlMFqAOM=; b=IA6jy440b5UNgPGR aI7bu/nz9wvO+jG7bD5PaDBnjd6ZRMOGrVVMK2+LFZelWtG9pLpvy8VgTIUpQ2n9 2I4DJNZWAsLV6urAtq6XnX5KukJXdJvQAXrF1gKpDkSHlxAQnTdXgbpZIgxes5nl UMiTgC9ObcjRICjihLIG6f+h3tE=
Received: by filter1117p1mdw1.sendgrid.net with SMTP id filter1117p1mdw1-8399-59B30E42-3 2017-09-08 21:40:18.009906443 +0000 UTC
Received: from github-smtp2b-ext-cp1-prd.iad.github.net (github-smtp2b-ext-cp1-prd.iad.github.net [192.30.253.17]) by ismtpd0035p1mdw1.sendgrid.net (SG) with ESMTP id xHJYp7vTQlKUSwFZ063K1A for <quic-issues@ietf.org>; Fri, 08 Sep 2017 21:40:17.917 +0000 (UTC)
Date: Fri, 08 Sep 2017 21:40:18 +0000
From: janaiyengar <notifications@github.com>
Reply-To: quicwg/base-drafts <reply+0166e4abb16712204ef7937bea8db2d18601809c6febeb0a92cf0000000115cad04192a169ce0edfdc09@reply.github.com>
To: quicwg/base-drafts <base-drafts@noreply.github.com>
Cc: Subscribed <subscribed@noreply.github.com>
Message-ID: <quicwg/base-drafts/pull/724/review/61626833@github.com>
In-Reply-To: <quicwg/base-drafts/pull/724@github.com>
References: <quicwg/base-drafts/pull/724@github.com>
Subject: Re: [quicwg/base-drafts] Define requirements for handling packets (#724)
Mime-Version: 1.0
Content-Type: multipart/alternative; boundary="--==_mimepart_59b30e415a5cc_4d2f3f9eafc59c381237af"; charset="UTF-8"
Content-Transfer-Encoding: 7bit
Precedence: list
X-GitHub-Sender: janaiyengar
X-GitHub-Recipient: quic-issues
X-GitHub-Reason: subscribed
X-Auto-Response-Suppress: All
X-GitHub-Recipient-Address: quic-issues@ietf.org
X-SG-EID: l64QuQ2uJCcEyUykJbxN122A6QRmEpucztpreh3Pak3O52u1zTRx3vvVmBIhhzsuJ/VgiclSiQT0Ib qWRBWvSUFwYLut6pp5H9m6fc9wEJUG8Od2t+4kAalrlVo1yj17SsJnE//kG8EIE1KCKGDnncrg+9XQ KW8CtYGT7Rxsmz1K07B+2x/889RySj7xzk81tIUzm3xCZ2Tc9Etn2+VwWmCR+7CDwoz0J1M88zr6tT g=
Archived-At: <https://mailarchive.ietf.org/arch/msg/quic-issues/DsLsEkGnQjErldvlJQ7V4eIRxGc>
X-BeenThere: quic-issues@ietf.org
X-Mailman-Version: 2.1.22
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: Fri, 08 Sep 2017 21:40:21 -0000
janaiyengar commented on this pull request.
Comments inline
> +packets for connections that have incomplete cryptographic handshakes are
+associated using the tuple of source and destination IP addresses and ports.
+
+A packet that uses the short header form could be associated with an existing
+connection with an incomplete cryptographic handshake. Such a packet could be a
+valid packet that has been reordered with respect to the long-form packets that
+will complete the cryptographic handshake. These packets SHOULD be buffered in
+anticipation of the handshake completing.
+
+Buffering ensures that data is not lost, which improves performance; conversely,
+discarding these packets could create false loss signals for the congestion
+controllers. However, limiting the number and size of buffered packets might be
+needed to prevent exposure to denial of service.
+
+For clients, all packets that cannot be associated with an existing connection
+MUST be discarded. Discarded packets MAY be logged for diagnostic or security
MUST -> SHOULD, since there's no reason to require this.
Separately, if the handshake is not complete, there's no existing connection, and this statement contradicts the advice on buffering short header packets for such connections. I would suggest starting this para with "In all other cases, packets SHOULD be discarded."
> +
+## Matching Packets to Connections
+
+Incoming packets are classified on receipt. Packets can either be associated
+with an existing connection, be discarded, or - for servers - potentially create
+a new connection.
+
+A packet that can be identified as belonging to an existing connection is
+handled according to the current state of that connection. Packets are
+associated with existing connections using connection ID if it is present; this
+might include connection IDs that were advertised using NEW_CONNECTION_ID
+({{frame-new-connection-id}}). Packets without connection IDs and long-form
+packets for connections that have incomplete cryptographic handshakes are
+associated using the tuple of source and destination IP addresses and ports.
+
+A packet that uses the short header form could be associated with an existing
This isn't accurate. A server could use the long header for 1-RTT encypted packets, and 0-RTT encrypted packets are long header.
> ## Version Negotiation {#version-negotiation}
QUIC's connection establishment begins with version negotiation, since all
communication between the endpoints, including packet and frame formats, relies
on the two endpoints agreeing on a version.
-A QUIC connection begins with a client sending a handshake packet. The details
-of the handshake mechanisms are described in {{handshake}}, but all of the
-initial packets sent from the client to the server MUST use the long header
-format and MUST specify the version of the protocol being used.
-
-When the server receives a packet from a client with the long header format, it
-compares the client's version to the versions it supports.
-
-If the version selected by the client is not acceptable to the server, the
-server discards the incoming packet and responds with a Version Negotiation
-packet ({{packet-version}}). This includes a list of versions that the server
-will accept.
+A QUIC connection begins with a client sending a client initial packet
capitalize Client Initial
>
If the packet contains a version that is acceptable to the server, the server
proceeds with the handshake ({{handshake}}). This commits the server to the
version that the client selected.
-When the client receives a Version Negotiation packet from the server, it should
-select an acceptable protocol version. If the server lists an acceptable
-version, the client selects that version and reattempts to create a connection
-using that version. Though the contents of a packet might not change in
+
+### Sending and Handling Version Negotiation Packets {#send-vn}
+
+If the version selected by the client is not acceptable to the server, the
With the section break now, it's not obvious that this flows from the previous, especially if you start reading at this section. I would remove the section break.
>
If the packet contains a version that is acceptable to the server, the server
proceeds with the handshake ({{handshake}}). This commits the server to the
version that the client selected.
-When the client receives a Version Negotiation packet from the server, it should
-select an acceptable protocol version. If the server lists an acceptable
-version, the client selects that version and reattempts to create a connection
-using that version. Though the contents of a packet might not change in
+
+### Sending and Handling Version Negotiation Packets {#send-vn}
+
+If the version selected by the client is not acceptable to the server, the
+server responds with a Version Negotiation packet ({{packet-version}}). This
+includes a list of versions that the server will accept.
+
+A server sends a Version Negotiation packet for any packet with an unaccepable
+version if that packet could create a new connection. This allows a server to
I think Ian's point is that it's not clear what "might_create_a_connection" means. I am not clear about this either, TBH. How does a server know that a received packet might create a connection if the version is unspoken? I think all you need is if (!acceptable(version)) { send_vn() }
> +
+A server sends a Version Negotiation packet for any packet with an unaccepable
+version if that packet could create a new connection. This allows a server to
+process packets with unsupported versions without retaining state. Though
+either the client initial packet or the version negotiation packet that is sent
+in response could be lost, the client will send new packets until it
+successfully receives a response or it abandons the connection attempt.
+
+When the client receives a Version Negotiation packet, it first checks that the
+packet number and connection ID match the values it sent in a client initial
+packet. If this check fails, the packet MUST be discarded.
+
+Once the Version Negotiation packet is determined to be valid, the client then
+selects an acceptable protocol version from the list provided by the server.
+The client then attempts to create a connection using that version. Though the
+contents of the client initial packet the client sends might not change in
capitalize Client Initial
--
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/724#pullrequestreview-61626833
- [quicwg/base-drafts] Define requirements for hand… Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Patrick McManus
- Re: [quicwg/base-drafts] Define requirements for … ianswett
- Re: [quicwg/base-drafts] Define requirements for … ekr
- Re: [quicwg/base-drafts] Define requirements for … Mike Bishop
- Re: [quicwg/base-drafts] Define requirements for … ianswett
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … janaiyengar
- Re: [quicwg/base-drafts] Define requirements for … Mike Bishop
- Re: [quicwg/base-drafts] Define requirements for … janaiyengar
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Mike Bishop
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … ianswett
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … ianswett
- Re: [quicwg/base-drafts] Define requirements for … ianswett
- Re: [quicwg/base-drafts] Define requirements for … ianswett
- Re: [quicwg/base-drafts] Define requirements for … janaiyengar
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … janaiyengar
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … janaiyengar
- Re: [quicwg/base-drafts] Define requirements for … Martin Thomson
- Re: [quicwg/base-drafts] Define requirements for … janaiyengar
- Re: [quicwg/base-drafts] Define requirements for … janaiyengar