Re: [IPsec] ESP next payload number [Re: Some thoughts regarging draft-hopps-ipsecme-iptfs-01]

Christian Hopps <chopps@chopps.org> Sun, 01 December 2019 08:52 UTC

Return-Path: <chopps@chopps.org>
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 083E712001A for <ipsec@ietfa.amsl.com>; Sun, 1 Dec 2019 00:52:34 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.898
X-Spam-Level:
X-Spam-Status: No, score=-1.898 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001] autolearn=ham autolearn_force=no
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 imuNYU7iytq8 for <ipsec@ietfa.amsl.com>; Sun, 1 Dec 2019 00:52:32 -0800 (PST)
Received: from smtp.chopps.org (smtp.chopps.org [54.88.81.56]) by ietfa.amsl.com (Postfix) with ESMTP id 2FD861200F4 for <ipsec@ietf.org>; Sun, 1 Dec 2019 00:52:32 -0800 (PST)
Received: from stubbs.int.chopps.org (66-227-211-29.dhcp.trcy.mi.charter.com [66.227.211.29]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by smtp.chopps.org (Postfix) with ESMTPSA id 354126090E; Sun, 1 Dec 2019 08:52:31 +0000 (UTC)
Content-Type: text/plain; charset="us-ascii"
Mime-Version: 1.0 (Mac OS X Mail 13.0 \(3601.0.10\))
From: Christian Hopps <chopps@chopps.org>
In-Reply-To: <alpine.LRH.2.21.1912010233510.2378@bofh.nohats.ca>
Date: Sun, 01 Dec 2019 03:52:30 -0500
Cc: Christian Hopps <chopps@chopps.org>, Valery Smyslov <smyslov.ietf@gmail.com>, IPsecME WG <ipsec@ietf.org>
Content-Transfer-Encoding: quoted-printable
Message-Id: <3F136824-B2BB-429A-BC24-226FC2F9D199@chopps.org>
References: <039e01d5a5f2$ac51d350$04f579f0$@gmail.com> <A8BDEB5B-332E-4767-9EC6-9AF4CFA2E34B@chopps.org> <042301d5a6b6$bc8e9fe0$35abdfa0$@gmail.com> <C6E9B9B8-EE15-4E86-8C39-77BCFF50ADC2@chopps.org> <044701d5a6d0$032d5a90$09880fb0$@gmail.com> <5CAB559D-595E-4503-AC72-31E88B6F53AA@chopps.org> <alpine.LRH.2.21.1912010233510.2378@bofh.nohats.ca>
To: Paul Wouters <paul@nohats.ca>
X-Mailer: Apple Mail (2.3601.0.10)
Archived-At: <https://mailarchive.ietf.org/arch/msg/ipsec/2dx7fRXwRskwkV6qwKrnHRPZzL8>
Subject: Re: [IPsec] ESP next payload number [Re: Some thoughts regarging draft-hopps-ipsecme-iptfs-01]
X-BeenThere: ipsec@ietf.org
X-Mailman-Version: 2.1.29
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, 01 Dec 2019 08:52:34 -0000

I think it's important for this discussion to recognize that we have 2 orthogonal issues.

1) How does IP-TFS work on the wire with IPsec/ESP - this is where we need to make sure we don't unnecessarily restrict uni-directional use.

2) What are the changes to IKEv2 to support IP-TFS - this is where we need to decided if we need the ability to negotiate uni-direction cases, we don't believe we need to do this. I think this is inline with what people are expecting here (i.e., a pair of SAs with IP-TFS enabled or not).

More inline..

> On Dec 1, 2019, at 2:41 AM, Paul Wouters <paul@nohats.ca> wrote:
> 
> On Fri, 29 Nov 2019, Christian Hopps wrote:
> 
>>> ESP SAs are always created in pairs. And whether IP-TFS is enabled or not is common for both SAs.
>>> Even if you use only one SA for IP-TFS traffic, the other will have IP-TFS enabled too.
>>> How are you going with your spec to create a pair of SAs where IP-TFS is enabled in one direction and
>>> disabled in the other? Am I missing something? Even if you are able to create such a pair of SAs, is it justified?
>> 
>> Understood that SAs are created in pairs. The intent here (and throughout the draft) is not to unnecessarily restrict possible uses. Having IP-TFS enabled on only one of a pair of SAs can make sense when you're only trying to protect traffic sent in one direction from traffic analysis (again e.g., telemetry). The use of IP-TFS does involve the allocation of a fixed amount of bandwidth so the justification for not enabling it in one direction is to save that bandwidth.
> 
> It seems unwise to protect traffic one way but not the other way. Are
> endusers really able to make the right decision based on their generated
> traffic? If you are that hungry for resources, perhaps this isn't an
> option for you to use?

There is no traffic to protect in the reverse direction. Consider telemetry where one is simply sending un-acked UDP data using to monitors.

> 
> Also, if an inbound or outbound SA is not using IP-TFS, couldn't the
> memory be deallocated, or the memory allocation could be postponed
> until the first IP-TFS type packet arrives?
> 
> The architecture is really symmetrical for in/out bound SA's, so I
> would prefer we do not change that.

We are not looking to change the architecture, only to use the existing one (see orthogonal issues). The telemetry example is one case of uni-directional traffic; however, multicast is another area where you can get non-"TCP flow-like" unidirectional configurations.

> 
>> The spec is (trying to be) very careful in not restricting the unidirectional TFS use case b/c there's no reason to do so, and so there should not be anything in the document that restricts having only one of the SA pairs used by IPsec/ESP running with IP-TFS.
> 
> The question is, does it need to be negotiated or not or can a well
> implemented implementation postpone all memory requirements if this
> feature is unused in one direction?

The standard case of using IKEv2 (i.e., what most users will use) assumes bi-directional use which seems appropriate. The draft also allows for not starting the IP-TFS constant send immediately. Finally, the draft does not restrict other less-traditional use cases which fall outside the scope of IKEv2 use.

For IKEv2 we believe bi-directional only is fine and that's what the draft has defined.

> 
>> Setting up such an SA pair is orthogonal to being able to run with that configuration. While the vast majority of IPsec utilizes IKEv2 for SA creation/management, this is not a requirement of IPsec/ESP. The unidirectional case can be covered with local configuration (along with IKEv2), or by using another method entirely for the SA management.
> 
> Non-IKE can negotiate whatever it want and hack in custom IPsec SA's
> that we would find completely illegal. That's out of scope of this WG,
> but we should also not bring it into scope as "others might want that".
> 
>> The intent in the end is to specify what we need to for IP-TFS operation, but not too over-specify and unnecessarily restrict possible future (or outside) uses. IOW, less is more.
> 
> But I am still not convinced endusers can make these decisions of
> bidirectional vs unidirectional and whther or not their traffic
> becomes more susceptible to traffic analyses attacks.

Which users are we talking about here? We agree, for the vast majority of end-users the standard use case will be bi-directional, and the IKEv2 changes reflect this (see 2).

We're not making it *easy* to run uni-directional we're simply not outright prohibiting this use case for users who may have more complex requirements and/or know what they are doing. 

We've got the restriction in IKEv2, but what is the value in further restricting things at the IPsec/ESP level (1)? There is real value lost in making this restriction, so I think we need to justify it if we choose to do so.

Thanks,
Chris.

>> FWIW, I did explore adding machinery to IKEv2 to allow setting up/negotiating unidirectional use cases, but it adds a lot of complexity, and so we decided that while unidirectional TFS protection is useful it will still be a relatively uncommon configuration and was best left for local configuration for now. If in the future we see a large call for on-demand/negotiated (vs local config) uni-directional TFS we can always come back and add it to IKEv2. What's important in the context of the IKEv2 changes for now is that we don't do anything to block doing this in the future.
> 
> I have not yet been convinced of this.
> Paul
>