Re: [Sidrops] 6486bis: referenced object validation

Job Snijders <job@ntt.net> Fri, 04 December 2020 15:07 UTC

Return-Path: <job@ntt.net>
X-Original-To: sidrops@ietfa.amsl.com
Delivered-To: sidrops@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 82E293A0D86 for <sidrops@ietfa.amsl.com>; Fri, 4 Dec 2020 07:07:17 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.899
X-Spam-Level:
X-Spam-Status: No, score=-1.899 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, UNPARSEABLE_RELAY=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 YhMhvoSglQBc for <sidrops@ietfa.amsl.com>; Fri, 4 Dec 2020 07:07:16 -0800 (PST)
Received: from mail4.sttlwa01.us.to.gin.ntt.net (mail4.sttlwa01.us.to.gin.ntt.net [204.2.238.64]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 109BF3A0D7D for <sidrops@ietf.org>; Fri, 4 Dec 2020 07:07:15 -0800 (PST)
Received: from bench.sobornost.net (mieli.sobornost.net [45.138.228.4]) by mail4.sttlwa01.us.to.gin.ntt.net (Postfix) with ESMTPSA id 7EA0222014A; Fri, 4 Dec 2020 15:07:14 +0000 (UTC)
Received: from localhost (bench.sobornost.net [local]) by bench.sobornost.net (OpenSMTPD) with ESMTPA id cdec34c8; Fri, 4 Dec 2020 15:07:12 +0000 (UTC)
Date: Fri, 04 Dec 2020 15:07:12 +0000
From: Job Snijders <job@ntt.net>
To: Ties de Kock <tdekock@ripe.net>
Cc: sidrops@ietf.org, Martin Hoffmann <martin@opennetlabs.com>, Ben Maddison <benm=40workonline.africa@dmarc.ietf.org>
Message-ID: <X8pQoCQwmrx30cut@bench.sobornost.net>
References: <20201203224213.gnb2nawujxm7a32q@benm-laptop> <20201204111651.4e865d7d@glaurung.nlnetlabs.nl> <X8oSBlR1pDhX83nH@bench.sobornost.net> <EF03D4E0-83EE-4C70-8E81-002DC8C38B95@ripe.net> <X8oUr+zsCbHk0Q3a@bench.sobornost.net> <78C30B6C-820E-49E9-BE88-6137A26F38E2@ripe.net> <X8oarQL4yLjPuRxP@bench.sobornost.net> <F820FD40-DC95-411E-8C69-F6877CDA4196@ripe.net>
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Disposition: inline
In-Reply-To: <F820FD40-DC95-411E-8C69-F6877CDA4196@ripe.net>
X-Clacks-Overhead: GNU Terry Pratchett
Archived-At: <https://mailarchive.ietf.org/arch/msg/sidrops/Z4fmTX6MtNemR4i-ZHcY0HyKCsw>
Subject: Re: [Sidrops] 6486bis: referenced object validation
X-BeenThere: sidrops@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: A list for the SIDR Operations WG <sidrops.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/sidrops>, <mailto:sidrops-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/sidrops/>
List-Post: <mailto:sidrops@ietf.org>
List-Help: <mailto:sidrops-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/sidrops>, <mailto:sidrops-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 04 Dec 2020 15:07:18 -0000

On Fri, Dec 04, 2020 at 02:13:41PM +0100, Ties de Kock wrote:
> > You list two manifests, which means that software should:
> > 
> > round 1: process Manifest 1 containing AS0.roa + sub-CA.cer + crl
> >    check if as0.roa and sub-CA.cer + crl are present and if the hashes
> >    match
> > 
> > round 2: process Manifest 2 containing AS64496.roa + crl
> >    check if AS64496.roa + crl are present and if the hashes match
> > 
> > Now let's image sub-CA.cer is present and the hash match, but turns out
> > to be expired, it just invalidates sub-CA.cer and thus the software
> > would never even open manifest 2, because sub-CA.cer is expired.
> > 
> > If sub-CA.cer is expired the ROA for AS64496 indeed will 'disappear' (as
> > if never existed), leaving just the AS0 ROA. This is as the CA intended.
> 
> Compare that to:
> 
> Valid CA certificate with <AS64496, 192.0.2.0/24>
>  * Manifest, with valid EE certificate, containing
>    * valid CRL
>    * ROA: AS0, 192.0.2.0/24, EE cert with 2020-12-01 expiration
>    * ROA: AS64496, 192.0.2.0/25, EE cert with 2021-01-01 expiration
> 
> This results in a failed fetch when validated today.
>
> Under our interpretation of -00, this manifest would be rejected,
> since all objects on a manifest need to be valid (present, hash match,
> correct, non-expired) for a fetch to succeed.

The objects ON the manifest must be present and matching hashes, and the
manifest's EE certificate being correct, non-expired. I think this is
what is meant with the manifest must be 'valid', and 'current'

> I would argue that to be consistent, this should not result in failed
> fetch, the expired ROA should not apply, because this is what the CA
> intended.
> 
> What do you think the outcome should be?

Current versions of rpki-client and FORT consider the fetch successful,
but the 'AS0 ROA' in your example is expired, so that ROA will not be
emitted as VRP, as the ROA did not pass validation.

Imagine this scenario: I am an IP prefix broker, and I have a /16. For
this /16 I create a AS0 ROA because I don't want anyone to use the /16
unless I've given explicit permission through the creation of a ROA.
In december customer A leases a /24 for 3 months. In January customer B
leases a different /24 for 5 months, starting at February 2020.

Current time: 4 december 2020, 15:03 UTC
Valid CA <10.0.0.0/16>
  * Manifest, with valid EE certificate, containing
    * valid current CRL
    * ROA: AS0 10.0.0.0/16 (start date 1 july 2020, end date 1 july 2030)
    * ROA: AS1, 10.0.0.0/24 (start date 1 december 2020, end march 2021)
    * ROA: AS2, 10.0.1.0/24 (start date 1 february 2021, end juli 2021)

I believe the above to be real-world examples of how people perceive the
functionality of the RPKI, and this is confirmed by APNIC indicating
that the expiration dates on CA .cer files can match the expiration of
APNIC membership status. 

The beauty here is that a CA (an internet number resource holder) can
pre-provision the routing authorisations ahead of time. Each ROA on this
manifest represents a cryptographic 'product' (think something tangible
you can buy and hold), in this case authorizations to originate IP
space. The CA can also pre-provision the decommissioning of the product,
this is done by aligning the ROA expiration dates to the business
contract. This is an important cryptographic feature to be able to
pre-provision contract terminations.

Different expiration dates (and also start dates) for different objects
on the same manifest is an expected state of the RPKI. I believe the
CA's wishes are honored by checking that all files are present & hashes
matched, and that then in a second step each individual object is
validated (both signatures and validity time)

Kind regards,

Job