Re: Closing on CONNECTION_CLOSE
Eric Rescorla <ekr@rtfm.com> Thu, 27 July 2017 14:13 UTC
Return-Path: <ekr@rtfm.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 16060131C96 for <quic@ietfa.amsl.com>; Thu, 27 Jul 2017 07:13:02 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.598
X-Spam-Level:
X-Spam-Status: No, score=-2.598 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=rtfm-com.20150623.gappssmtp.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 qs-IvUgQdYz6 for <quic@ietfa.amsl.com>; Thu, 27 Jul 2017 07:13:00 -0700 (PDT)
Received: from mail-yw0-x22f.google.com (mail-yw0-x22f.google.com [IPv6:2607:f8b0:4002:c05::22f]) (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 29A40131C84 for <quic@ietf.org>; Thu, 27 Jul 2017 07:13:00 -0700 (PDT)
Received: by mail-yw0-x22f.google.com with SMTP id u207so45519798ywc.3 for <quic@ietf.org>; Thu, 27 Jul 2017 07:13:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rtfm-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=EQSVV3duZQWDuxISIEAIlcejdVdR/Y7H2BNW38J5h/g=; b=Ggb4Yy1mB3eLmp0cGIW8sLDYPl1v3eWy4uMReSQ/CymGxvkVph7AI4E+yYOp4CdRBX 1g31b+Kd2E9TGPKCIKMAG443P3ZQklt9hUY520S1Gt30c+vnzH091FvqfUZHAx6Ym+1x iQ1yL7mgqlealbdTnI5XmRwu8mD0AtCbBk3X9mjyknn7KjUIFE0LbD/DQjkUaX2EV7DG fw1QN4dnoeHghz8PwODznQiEd74t1/ZR51HW06ljsJ5YBHIeVG/TxKtgNMaS0sACWhtf l6SJkLpesQa+iB+HA81tcHEWi5n9RiUh7hAwEGwqBhnukOlODZ/n7skUudxrZGm+lEAQ GuNg==
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=EQSVV3duZQWDuxISIEAIlcejdVdR/Y7H2BNW38J5h/g=; b=XmhFZkk7j6HAx4/sIQ7zXcKyQHyvP7JV+iuCE8AIvlZO8d76Q/1f8AoYImWh6Ffljx g6o/15rv8n+MBmp8YoHskvkmWPjRuUZkB7fjvltrvOaEZXysl097Bc00gOb8MpACqL0U brTSRkCI+8XvBdlbQPIS+LH+6h2qblvNbE5dwiKuEZ+Y+kOL0EYiNNM2pkt6Rx96/oI/ RbQUTfeQIhAzlgU1PxQ1lXKiKioJTtoeb/C1fjUtCd7fKuP058rHqFu4lFJVratbmwDR WMFq1/CeLjDxoef87VcfkIHuhBnxvLOUtU1VqaYTVW1/DyuGe3e7bQ2WrtPKy9IDJ5o9 sl3A==
X-Gm-Message-State: AIVw110R9G6o2a3WZ8QTf7PnA9WAextL3tnQDa+fBnkjHyRaAn4aRXTn C1p1Cg+DPrm/xZJmbgaanS+PnHOJxjK6W+0=
X-Received: by 10.37.160.41 with SMTP id x38mr3650434ybh.339.1501164779285; Thu, 27 Jul 2017 07:12:59 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.129.36.12 with HTTP; Thu, 27 Jul 2017 07:12:18 -0700 (PDT)
In-Reply-To: <MWHPR15MB14558B64A6166EB2C3E66F03B6BE0@MWHPR15MB1455.namprd15.prod.outlook.com>
References: <CABcZeBP_Xh1QC9Qxhy5HYiMiTfknPs7Yp7+X_KnQE1O-juxJ5g@mail.gmail.com> <cb7caadd-73bd-6505-7a57-4b0271fb66d2@huitema.net> <MWHPR15MB14558B64A6166EB2C3E66F03B6BE0@MWHPR15MB1455.namprd15.prod.outlook.com>
From: Eric Rescorla <ekr@rtfm.com>
Date: Thu, 27 Jul 2017 07:12:18 -0700
Message-ID: <CABcZeBPGr2XYRDH9jiYqGk=xstPR0S42wNuU54txa-spSgj06A@mail.gmail.com>
Subject: Re: Closing on CONNECTION_CLOSE
To: Subodh Iyengar <subodh@fb.com>
Cc: Christian Huitema <huitema@huitema.net>, "quic@ietf.org" <quic@ietf.org>
Content-Type: multipart/alternative; boundary="94eb2c1a06506b41c605554d29fb"
Archived-At: <https://mailarchive.ietf.org/arch/msg/quic/wYR5RbohXMmyKgBF2qtiO7yb1q4>
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 14:13:02 -0000
On Thu, Jul 27, 2017 at 7:08 AM, Subodh Iyengar <subodh@fb.com> wrote: > > 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 > > I favor the RST model as well. > You'll end up having to keep a loss timeout even in the FIN model because > of ACKs being lost / the remote side shutting for unrelated reasons / > silently closing > their connection. > > However what is the right response to late packets? The only response I > can think of > is to resend the connection close if you still have the connection state. > Is there anything > else that could be sent that I'm missing? > There seem to be three options, which we can leave to the implementation: - Re-send CONNECTION_CLOSE - Send Stateless Reset - Drop the packet. As an aside on the topic of TIME_WAIT itself: > > The reason I'm aware that TIME_WAIT exists in TCP is to protect us from > the local port > being re-bound to another connection and the data from the old connection > interfering with > the new connection. With QUIC this seems less of an issue though because a > combination of (connection id + packet type + packet encryption) can be > used to determine whether or > not the packet was valid to be received in the context of a new > connection. Going with the > philosophy of dropping packets on the floor that are malformed that martin > proposed during > the last WG meeting, do we even need a TIME_WAIT state in QUIC? > > The advantage of TIME_WAIT that I see is this ability to send the > CONNECTION_CLOSE in a timely > manner to prevent the client from needing to retry till the RTO limit and > realize the connection > needs to be closed. However if we go with the close model of graceful > close always driven by the app, then > this won't be a common case and we might deliver a PUBLIC RESET instead of > a CLOSE. > Yes, that would probably also work. As above, do we need to decide? -Ekr > > Subodh > > ------------------------------ > *From:* QUIC <quic-bounces@ietf.org> on behalf of Christian Huitema < > huitema@huitema.net> > *Sent:* Thursday, July 27, 2017 7:02:33 AM > *To:* quic@ietf.org > *Subject:* Re: Closing on CONNECTION_CLOSE > > > > On 7/27/2017 6:47 AM, Eric Rescorla wrote: > > 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? > > Yes the text is vague. My ID1 code implements the RST behavior -- > immediate close on receipt, no ACK. It seemed natural. > > I have yet to implement a proper zombie state, but that would be needed > whether we want the RST or FIN semantic, since FIN packets can be lost. > > RST behavior is cleaner there: repeat the RST frame if packets are still > received after some timeout. > > -- > Christian Huitema > >
- Closing on CONNECTION_CLOSE Eric Rescorla
- Re: Closing on CONNECTION_CLOSE Ian Swett
- Re: Closing on CONNECTION_CLOSE Christian Huitema
- Re: Closing on CONNECTION_CLOSE Subodh Iyengar
- Re: Closing on CONNECTION_CLOSE Eric Rescorla
- Re: Closing on CONNECTION_CLOSE Willy Tarreau
- RE: Closing on CONNECTION_CLOSE Swindells, Thomas (Nokia - GB/Cambridge, UK)
- Re: Closing on CONNECTION_CLOSE Ian Swett
- Re: Closing on CONNECTION_CLOSE Eric Rescorla
- Re: Closing on CONNECTION_CLOSE Jana Iyengar
- Re: Closing on CONNECTION_CLOSE Eric Rescorla
- Re: Closing on CONNECTION_CLOSE Dmitri Tikhonov
- Re: Closing on CONNECTION_CLOSE Patrick McManus
- Re: Closing on CONNECTION_CLOSE Christian Huitema
- Re: Closing on CONNECTION_CLOSE Mikkel Fahnøe Jørgensen