Re: Closing on CONNECTION_CLOSE

Ian Swett <ianswett@google.com> Thu, 27 July 2017 13:58 UTC

Return-Path: <ianswett@google.com>
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 E6245131C8F for <quic@ietfa.amsl.com>; Thu, 27 Jul 2017 06:58:38 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.7
X-Spam-Level:
X-Spam-Status: No, score=-2.7 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_DNSWL_LOW=-0.7, RP_MATCHES_RCVD=-0.001, 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=google.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 lbqJbTKHrmJf for <quic@ietfa.amsl.com>; Thu, 27 Jul 2017 06:58:36 -0700 (PDT)
Received: from mail-yw0-x231.google.com (mail-yw0-x231.google.com [IPv6:2607:f8b0:4002:c05::231]) (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 2BFE7131FF1 for <quic@ietf.org>; Thu, 27 Jul 2017 06:58:36 -0700 (PDT)
Received: by mail-yw0-x231.google.com with SMTP id x125so106728299ywa.0 for <quic@ietf.org>; Thu, 27 Jul 2017 06:58:36 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=caVkbHUZ3ZC+M4VesukI3muXjeOCD+iZbB+UEcb3kdY=; b=HL4VzqkIXhxISc9nibqCwBnkO8hp0HaeT+W//tvhVWAY2xC5tAinvRxaZeBMSWnhDA NoBK9oaCCMFl57JBlim1Q4YK6b8Pcu1BsUeU1HO2p/m/oZYTAeJJfU8YJdjICYpQuUqH yjFlu7R6BzRLnXKNaplaOLe8IPtBBvl7wosdD12qGEVZRpAMVhojw3yE4ash3Vu9aUxd d5DQwSPda9C2A4bfymIIuZMaaBmivvojMzGzlJ37FWyzhmnxCmoIF/J06Db51pn+GqkI 0CZ+cOgj9Ems8KTRq9Utxli2ke1D/aUa2F2RkDlGPha7U/GXwTqgJloA0bzQUasLxJlR 62YA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=caVkbHUZ3ZC+M4VesukI3muXjeOCD+iZbB+UEcb3kdY=; b=DEVFtyxIAuyElyrCzlnPZPzw6lhncw+IAJtqMRBXw0zw16T/NGc+dBXVvxXH4wYLH8 FZX69YlSpcKZjbwWczvjIsy8v4WwK9MMrjZrjIXBtVSUx+75oTL73OJp5tGoeFqdxngh XO5jxRnAt+8XKhlTgZ+PxF5qJYEKaKDgds2Ci4KIqPuMx6NyDsbxAn/19h1pnaI39qsx xPg2qVTCBc5ly5+RMApA/odxQyf9/tuKTEpDYtLkGACh9OPJnxX0+fv25NhF+8HWeKRp SlkFhtj8DoGR1F0rLlENXuE8hQ8kOQPUNgWIAuGGo0ya+mR8CXdihOpeGdylTvCK907t gDmA==
X-Gm-Message-State: AIVw110peXt9VFFMQ9XRc5o1QZqe1E6xmsZ+Pc6geBeeM9lTzI9uDhAg fwsQ5DQDNr9zsZqebtjYOAi0fsIampgC
X-Received: by 10.129.92.3 with SMTP id q3mr3615053ywb.298.1501163915246; Thu, 27 Jul 2017 06:58:35 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.37.217.137 with HTTP; Thu, 27 Jul 2017 06:58:14 -0700 (PDT)
In-Reply-To: <CABcZeBP_Xh1QC9Qxhy5HYiMiTfknPs7Yp7+X_KnQE1O-juxJ5g@mail.gmail.com>
References: <CABcZeBP_Xh1QC9Qxhy5HYiMiTfknPs7Yp7+X_KnQE1O-juxJ5g@mail.gmail.com>
From: Ian Swett <ianswett@google.com>
Date: Thu, 27 Jul 2017 09:58:14 -0400
Message-ID: <CAKcm_gNuYsn2dY8MQXK+FZxe0kj4vRtRfr-Ukhn=MgJ9stt4NQ@mail.gmail.com>
Subject: Re: Closing on CONNECTION_CLOSE
To: Eric Rescorla <ekr@rtfm.com>
Cc: IETF QUIC WG <quic@ietf.org>
Content-Type: multipart/alternative; boundary="001a114d6f02eb9d1105554cf58a"
Archived-At: <https://mailarchive.ietf.org/arch/msg/quic/0-15Dgw4-bpIz1ic1oCJWR3fAvA>
X-BeenThere: quic@ietf.org
X-Mailman-Version: 2.1.22
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, 27 Jul 2017 13:58:39 -0000

Nice summary.  As you implied, I favor the RST-like model.

And as you stated, it'd be very helpful to specify something soon, since
it's about to become an implementation blocker.

On Thu, Jul 27, 2017 at 9:47 AM, Eric Rescorla <ekr@rtfm.com> wrote:

> There have been a number of issues raised about the exact semantics of
> CONNECTION_CLOSE [0], but we have never really closed on them. As Ryan
> says, one might have think that CONNECTION_CLOSE is like TCP FIN or
> like TCP RST.
>
>
> In the FIN-like model:
> - The closing side sends a CONNECTION_CLOSE
> - The non-closing side ACKs it
> - The closing side keeps retransmitting until it gets an ACK or it
>   times out.
>
>
> In the RST-like model:
> - The closing side sends a CONNECTION_CLOSE
> - The non-closing side just terminates the connection
> - The closing side responds to new packets from the non-closing side
>   with a retransmitted CONNECTION_CLOSE (perhaps just a stored packet)
>   for some time.
>
> The specification seems kind of vague on this point (there is a big
> TODO for TIME_WAIT) and in places suggests retransmission [1] I had
> previously assumed the FIN-like model but after talking to Ian this
> morning I think the RST-like model is better. It's easier to implement
> because you don't need to manage a post-close state machine on either
> side. The only downside I'm really aware of is that the closing side
> has to keep state for something like 2MSL (so that it can properly
> respond to late packets), rather than being able to clean up on
> receiving an ACK. However, this isn't that big a deal, because as
> noted above, you can throw away the connection and just send a stored
> packet, or alternately, just send public reset (or just go silent).
>
> Given that ID1 does include CONNECTION_CLOSE, albeit with limited
> semantics, it would be good to resolve this soon. Are there people who
> want to argue in favor of the FIN-like model?
>
> -Ekr
>
>
> [0] https://github.com/quicwg/base-drafts/issues/330
> https://github.com/quicwg/base-drafts/issues/328
>
> [1] See also the spec for ID1 which says:
> "The packet containing a connection close does not need to be
> retransmitted."
>
>