Re: [IPsec] Comments on draft-ietf-ipsecme-tcp-encaps

Eric Rescorla <ekr@rtfm.com> Sun, 19 March 2017 13:48 UTC

Return-Path: <ekr@rtfm.com>
X-Original-To: ipsec@ietfa.amsl.com
Delivered-To: ipsec@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 755611294B3 for <ipsec@ietfa.amsl.com>; Sun, 19 Mar 2017 06:48:26 -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 QSeVZsYjgTRn for <ipsec@ietfa.amsl.com>; Sun, 19 Mar 2017 06:48:24 -0700 (PDT)
Received: from mail-yw0-x22e.google.com (mail-yw0-x22e.google.com [IPv6:2607:f8b0:4002:c05::22e]) (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 1BEBC1294AF for <ipsec@ietf.org>; Sun, 19 Mar 2017 06:48:24 -0700 (PDT)
Received: by mail-yw0-x22e.google.com with SMTP id v76so76599978ywg.0 for <ipsec@ietf.org>; Sun, 19 Mar 2017 06:48:24 -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=Fm0SmIEzV4/sTF8mDGob1ihemVNwvSrrx7eQC8Shw3U=; b=dca13TGcy+EyIwDEw8el6MhE8mLD0dNnG4+2BHcFfCWZVjQHRAwZZC1KRHhiEJN8Cw M+t09MUXr4skVnaoaX21p+yLu2pWHwui6PRMvAKFUd7CCyeToQkSzrOHDVlz3N7jyUgU 9EAdN0YBafhA3KdsQwosW4xmo3iIpGc07chGYxu5RHfiRnCUTPfpCh6HUwiHIF1KCZge xaYadxYJqS9Za2+6H3s+9wKW8dpM9umbNzxbuX7OUK/82e6PEnquj0RGVoMVB2vQ42ei ztNKv8ousKlDiE8xTTpAASql1G7w92ai7aGYOljqSUyCEORENnklNng26h0OHr8OL4In 7b6g==
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=Fm0SmIEzV4/sTF8mDGob1ihemVNwvSrrx7eQC8Shw3U=; b=jDUO76aHgFLf1ajYoLW8RYcSN5NHeKj60+v4cTl0euLYoawkJRyqKsgHurCHV172ts qXhAZRZ5ml6ilEGh3rV/FgfKM+AbgD5MWRv6FIgggHqMbGAAm2d2oEhUAcTuEkMO1gqS 8Hq7Wh/pe+Trf+NqpS53KZUel7G0CMxRDV+MEFLqTAtm2Yl7n63P4uAjZzPmM6So3l7y GPTg4vpX3f0tinVfF5JoRUpOM9LlP+T3fxg78dCPI5C5BAv24HKbVc1ABuDWHEU4xohd oGIm0ivw3mLbFbKZeB1mxtVFdk+OJHbkLWHxkNHoUDl6BpHQ3q6iqqqfMpcCfDAJXnyg Nuhw==
X-Gm-Message-State: AFeK/H27UfgpZhlV09pr8KwzHTPr7JK9Xex6tnLb65SkyuahRmqf8EfVHvtUDnyLodlHXuiIxrODB3Odh20eyw==
X-Received: by 10.37.113.135 with SMTP id m129mr14711805ybc.65.1489931303374; Sun, 19 Mar 2017 06:48:23 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.129.154.210 with HTTP; Sun, 19 Mar 2017 06:47:42 -0700 (PDT)
In-Reply-To: <A5D592C8-AEE0-4675-88AE-0064FD52B49B@gmail.com>
References: <CABcZeBPMR9m8zPdhG4Bc3DHWj9UmVq22Z7G4ApYjBGJeC7MU=A@mail.gmail.com> <A5D592C8-AEE0-4675-88AE-0064FD52B49B@gmail.com>
From: Eric Rescorla <ekr@rtfm.com>
Date: Sun, 19 Mar 2017 06:47:42 -0700
Message-ID: <CABcZeBPiZmWBJEW5PYFDafS_v3dumEkS285MAifme85-ziu=ig@mail.gmail.com>
To: Yoav Nir <ynir.ietf@gmail.com>
Cc: draft-ietf-ipsecme-tcp-encaps@ietf.org, ipsec@ietf.org
Content-Type: multipart/alternative; boundary="001a1148a84813e560054b15aad7"
Archived-At: <https://mailarchive.ietf.org/arch/msg/ipsec/1xKy7RjKVugjif4v7z_ocjuskKk>
Subject: Re: [IPsec] Comments on draft-ietf-ipsecme-tcp-encaps
X-BeenThere: ipsec@ietf.org
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: Discussion of IPsec protocols <ipsec.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ipsec>, <mailto:ipsec-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ipsec/>
List-Post: <mailto:ipsec@ietf.org>
List-Help: <mailto:ipsec-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ipsec>, <mailto:ipsec-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sun, 19 Mar 2017 13:48:26 -0000

On Sat, Mar 18, 2017 at 11:29 PM, Yoav Nir <ynir.ietf@gmail.com> wrote:

> Hi, Eric.
>
> On 19 Mar 2017, at 4:04, Eric Rescorla <ekr@rtfm.com> wrote:
>
> [Now with the right address]
>
> I just finished reading this document. Some comments below.
>
>
> - You have a uniform 16 bit length field followed by a 4 byte all-zeros
>    sentinel value to indicate that a packet is IKE rather than ESP.
>    Given that in S 3 graf 2 you have a SHOULD-level requirement
>    to use typical UDP payload lengths, why not instead explicitly
>    limit lengths to 15 bits and use the top bit to indicate IKE versus
>    ESP. This would be slightly more efficient and seems simpler.
>    I suppose that the counterargument is that IKE over UDP behaves
>    differently, but in terms of implementation, that doesn't seem like
>   much of an argument.
>
>
> Another counter-argument is that we sometimes need the entire theoretical
> length of a UDP packet. The IKE_AUTH messages typically carry a certificate
> chain and sometimes even a CRL. And there is no way to split a certificate
> chain over several messages. With remote access VPN you also get a CFG
> payload with configuration information that can also encode an unbounded
> amount of data. So I would not want to constrain the certificate chains
> that we are able to send any more than the IP packet length already does.
>

OK.



Early on there was a proposal to increase the length field to 4 bytes to do
> away with these IKE limitations, but that was rejected.
>
> - If you're going to have a framing disambiguator, why not choose
>   one that has higher entropy. If there is a protocol with a random
>   start, then you are going to get some collisions with 2^48 bits.
>
>
> I don’t think anyone plans to implement this on any port other than 443.
> And on that port we’re worrying about exactly one protocol and it doesn’t
> start with “IKETCP"
>

Fair enough.


> - It seems like IKE associations can span TCP connections (S 6)
>   so why not instead of doing UDP first then TCP, do happy eyeballs.
>
>
> I don’t think it’s necessary to prescribe for or against this, but that is
> what we do, and I think that is what Apple intends to do.
>

Right, but the text here actively discourages this.
https://tools.ietf.org/html/draft-ietf-ipsecme-tcp-encaps-09#section-5.1

"   to reduce connection setup delays. It is recommended that theinitial
message over UDP is retransmitted at least once before falling back to TCP,
unless the Initiator knows beforehand that the   network is likely to block
UDP."


" when TLS is used on the TCP connection, both the TCP Originator and TCP
> Responder SHOULD allow the NULL cipher to be selected for performance
> reasons."
>
> This seems like you are going to have some problems with TLS 1.3
>
> - If you are going to use TLS, shouldn't you be using ALPN?
>
>
> The idea of using TLS (rather than just IKE on port 443) is to get past
> firewalls and IDP that examine the TCP traffic to determine that it “really
> looks like HTTPS”. There was some discussion about whether this was a good
> idea or whether we should in such a case either give up or standardize some
> kind of SSL-VPN. There was no consensus to go with SSL-VPN in either this
> group or any other (there was a bar bof a few IETFs ago)
>

OK. You're still going to have a problem with 1.3...

-Ekr