Re: [pkix] [saag] Fwd: New Version Notification for draft-belyavskiy-certificate-limitation-policy-04.txt

Dmitry Belyavsky <beldmit@gmail.com> Sat, 07 October 2017 18:37 UTC

Return-Path: <beldmit@gmail.com>
X-Original-To: pkix@ietfa.amsl.com
Delivered-To: pkix@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 49498134B12; Sat, 7 Oct 2017 11:37:14 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.699
X-Spam-Level:
X-Spam-Status: No, score=-2.699 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.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 uycmojqQWQUt; Sat, 7 Oct 2017 11:37:12 -0700 (PDT)
Received: from mail-wm0-x22d.google.com (mail-wm0-x22d.google.com [IPv6:2a00:1450:400c:c09::22d]) (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 A79E01342F1; Sat, 7 Oct 2017 11:37:11 -0700 (PDT)
Received: by mail-wm0-x22d.google.com with SMTP id t69so13641053wmt.2; Sat, 07 Oct 2017 11:37:11 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=x94bjUdkXDMVmhfXlLTCu4egzpqJb5s7zTtFk52b1YQ=; b=EOZvUU42P0+tY8esykPQSAY9y2rj0TTpR9AOBLFXrBQZCvvFmEmNC9ZDIMCLDxYu/6 30YWiQfRZ+CH9JcVUQaFw1U6EIS4DOKjQCBXG8G9dsIlczbTysJLkHYMBIS7Aw3hjbau hb8+iPVySvPBL9WsFuCUauFPFlqR6lxCUvS5BBcoFXTyz1+fE0p4HddFk789SfaiyNyI +G6jz/oCg1LZslVSsLfxz05SAc2XpVJOocJAArGw7h6fkvDuUOhx0VKsy2CJNygcqAKA iqDC2NfyZfyamRu70UR4hn+DKK2KKPad6ONrv7KUAbfXeKQDjgLozhkgVCMuwN9l0RSB hlHQ==
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=x94bjUdkXDMVmhfXlLTCu4egzpqJb5s7zTtFk52b1YQ=; b=f/bGsEUDPhV/N5HdDC0FbN4jcYxpvFi5RORPD4iMmy1n3sYfyOrqSuHIRj9nmXxY+m Fx6WMp6Xhw0kA7+HuwCY6IZyYy5k2mbcwJpD0AshI3p/EO3RR0l5fzuo8PcmUGY4WlE2 UxasxuCcnLb3UdUc0V3GS72t38cQCRxbz15s1VIKT5/N7jonmRP9q6ZfuYS6xtSw0tCl MZ1oCrTUVXBVhocNJkNlO2tnrYeSi/PCDOLtuccDBl9AHfz4jYlGr4p49LyJzI582M6b NNXt6tpGxSVf8kWYhxW0cpGhxE/NAf0JQM/YwrqyUAL4AkGkBJ4E/mNgeQybDXtHWPL3 lZsQ==
X-Gm-Message-State: AMCzsaXW9gbKkMO97fqfnys77BHwOBM7hCp6iTvvx9Xi6/KuLEEzVI9x FHZ6+JmAIsznx5Hk+0hJ69tzoZ+Nxjnijg3bryo=
X-Google-Smtp-Source: AOwi7QBZLFVdLrLWMfNXYEf4+jrxj4diUUwLrBWsBOZWjHBcNTV7tFqxYWA5m6DkLp6JVlFxkRyWdaDFE3a8I25lnSk=
X-Received: by 10.80.174.241 with SMTP id f46mr7882561edd.135.1507401430163; Sat, 07 Oct 2017 11:37:10 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.80.220.202 with HTTP; Sat, 7 Oct 2017 11:37:09 -0700 (PDT)
In-Reply-To: <CAJU7za+TVnhmyATbwdzC4B0Ci3CtdxrqPTzVQnP9BfN_RX+8kw@mail.gmail.com>
References: <150522092693.4724.2532571098567577114.idtracker@ietfa.amsl.com> <CADqLbz+OB86s4E-Ntr6eaEow+sBtxscJ703nGN+PAS7zQmJ==Q@mail.gmail.com> <CAJU7zaLsza65gvERm__njLYM82jGWx9ht_QwHi+e6WQAtFKsZA@mail.gmail.com> <CADqLbz+-86OoH6wJQj4cu4daCUmh6mDPCkmVhbBYnLgv9AmOHw@mail.gmail.com> <CAJU7za+TVnhmyATbwdzC4B0Ci3CtdxrqPTzVQnP9BfN_RX+8kw@mail.gmail.com>
From: Dmitry Belyavsky <beldmit@gmail.com>
Date: Sat, 07 Oct 2017 21:37:09 +0300
Message-ID: <CADqLbzLatQzsRTiCos4oD5p_8TLZ_Pt2zGkksEjt7hAV-CfSbA@mail.gmail.com>
To: Nikos Mavrogiannopoulos <nmav@gnutls.org>
Cc: "saag@ietf.org" <saag@ietf.org>, LAMPS <spasm@ietf.org>, dev-security-policy@lists.mozilla.org, pkix@ietf.org
Content-Type: multipart/alternative; boundary="f403045c18e0c76566055af93e42"
Archived-At: <https://mailarchive.ietf.org/arch/msg/pkix/csKLgyCoP4yl8Tl80DWAa67zXPc>
Subject: Re: [pkix] [saag] Fwd: New Version Notification for draft-belyavskiy-certificate-limitation-policy-04.txt
X-BeenThere: pkix@ietf.org
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: PKIX Working Group <pkix.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/pkix>, <mailto:pkix-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/pkix/>
List-Post: <mailto:pkix@ietf.org>
List-Help: <mailto:pkix-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/pkix>, <mailto:pkix-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 07 Oct 2017 18:37:14 -0000

Dear Nicos,

Sorry for the delay with my response.

On Fri, Sep 22, 2017 at 11:06 AM, Nikos Mavrogiannopoulos <nmav@gnutls.org>
wrote:

> On Wed, Sep 20, 2017 at 3:21 PM, Dmitry Belyavsky <beldmit@gmail.com>
> wrote:
> > Dear Nikos
> >
> > On Wed, Sep 13, 2017 at 9:39 AM, Nikos Mavrogiannopoulos <
> nmav@gnutls.org>
> > wrote:
> >>
> >>
> >> 4. How do you handle extensions to this format?
> >>
> >> Overall, why not use X.509 extensions to store such additional
> >> constraints? We already (in the p11-kit trust store in Fedora/RHEL
> >> systems) use the notion of stapled extensions to limit certificates
> >> [0, 1] and seems quite a flexible approach. Have you considered that
> >> path?
> >>
> >> regards,
> >> Nikos
> >>
> >> [0].
> >> https://p11-glue.freedesktop.org/doc/storing-trust-policy/
> storing-trust-model.html
> >> [1].
> >> http://nmav.gnutls.org/2016/06/restricting-scope-of-ca-
> certificates.html
> > I've looked through the specification. It's OK for me, but I do not get
> > whether the attached extensions are crypto-protected.
>
> No, as these values are inserted by the administrator of the system,
> or us (the distributor of the software), we didn't feel we needed the
> introduction of additional PKI.
>

Well, the specification I suggest should allow applying CLPs issued by
major vendors (Mozilla etc).
For this purposes the CLPs should be validable => signed.



> How do you see the infrastructure on the
> draft-belyavskiy-certificate-limitation-policy? Who do you envision
> signing these structures? (I assume that distribution of data will be
> done by software distributors?)
>

I anticipate some ways to distribute CLPs.

1. Major vendor-issued CLPs are distributed either by vendors or by OS
vendors
(similar to, e.g., ca-certificates package in Debian). In this case we
should have
certificates to sign these CLPs distributed together with these bundles.

2. App-specific CLPs may include the key as a part of the application
bundle.
So CLP is distributed via normal app-distributing channel.

3. Locally created CLPs. This is the case more or less similar to the
p11-glue solution,
if I understand it correctly.

Various protocols, such as TAMP (RFC 5934) can be used for transport the
CLPs too.


>
> >> 4. How do you handle extensions to this format?
> >>
> > Simillary to CRL. Do you have ideas of the extensions?
>
> One problem with that is the fact that the existing CRL extensions are
> about extending attributes of the CRL, rather than adding/removing
> attributes to the certificate in question.
>

For this purposes I implied that the limitations are provided not by
extensions,
but as SEQUENCE of limitations related to the certificates.

Was I wrong in the ASN1 scheme in the current version of my draft?



> To bring the stapled extensions to your proposal, you'd need the
> Extensions and Extension fields from RFC5280, and
> add into limitedCertificates structure (I'll split it on the example
> below for clarity) the following field.
>
> LimitedCertificates  ::=   SEQUENCE OF LimitedCertificate
>
> LimitedCertificate ::= SEQUENCE {
>                 userCertificate         CertificateSerialNumber,
>                 certificateIssuer       Name,
>                 limitationDate          Time,
>                 limitationPropagation   Enum,
>                 fingerprint SEQUENCE {
>                     fingerprintAlgorithm AlgorithmIdentifier,
>                     fingerprintValue     OCTET STRING
>                                      } OPTIONAL,
>                 limitations          SEQUENCE,
>                                    } OPTIONAL,
>                                  };
>
>
>                 stapledExtensions Extensions; <----- NEW
> }
>

Sorry, I do not get the difference between the purposes of the field
'limitations'
and 'stapledExtensions'.


> Another difference between this profile and the p11-kit one, is that
> the extensions/revocation here is done on the certificate, while in
> p11-kit is done on the public key. Both approaches have pros and cons.
>

Sure.


>
> Another question. I also noticed the fingerprint field above. Is that
> to distinguish between same CAs with different keys? In that case
> using the SubjectPublicKeyIdentifier may be sufficient, and more
> natural as this is how certificates with matching DNs/serials are
> distinguished.
>

Do you mean Subject Key Identifier (RFC 5280, 4.2.1.2)?
Yes, I agree and I'll update the draft.

I introduced the fingerprint field to distinguish bogus certs from the
valid ones,
but I think the SKI will be OK for this purpose.

Thank you!

-- 
SY, Dmitry Belyavsky