Re: [saag] On PKI vs. Pinning (SAAG 108 preview)

Benjamin Kaduk <kaduk@mit.edu> Tue, 28 July 2020 19:42 UTC

Return-Path: <kaduk@mit.edu>
X-Original-To: saag@ietfa.amsl.com
Delivered-To: saag@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 8EF3C3A0BD0 for <saag@ietfa.amsl.com>; Tue, 28 Jul 2020 12:42:53 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.92
X-Spam-Level:
X-Spam-Status: No, score=-1.92 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-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 DlOaw-4XDJA1 for <saag@ietfa.amsl.com>; Tue, 28 Jul 2020 12:42:52 -0700 (PDT)
Received: from outgoing.mit.edu (outgoing-auth-1.mit.edu [18.9.28.11]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id E1CC53A0BCE for <saag@ietf.org>; Tue, 28 Jul 2020 12:42:51 -0700 (PDT)
Received: from kduck.mit.edu ([24.16.140.251]) (authenticated bits=56) (User authenticated as kaduk@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id 06SJgZLW013993 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 28 Jul 2020 15:42:38 -0400
Date: Tue, 28 Jul 2020 12:42:35 -0700
From: Benjamin Kaduk <kaduk@mit.edu>
To: Stephen Farrell <stephen.farrell@cs.tcd.ie>
Cc: saag@ietf.org
Message-ID: <20200728194235.GY41010@kduck.mit.edu>
References: <20200728191331.GV41010@kduck.mit.edu> <e928e548-f82d-2809-200e-0fc4ac93db14@cs.tcd.ie>
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Disposition: inline
In-Reply-To: <e928e548-f82d-2809-200e-0fc4ac93db14@cs.tcd.ie>
User-Agent: Mutt/1.12.1 (2019-06-15)
Archived-At: <https://mailarchive.ietf.org/arch/msg/saag/RueoQDwHHXiCTdOc9HFeQS70sWA>
Subject: Re: [saag] On PKI vs. Pinning (SAAG 108 preview)
X-BeenThere: saag@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Security Area Advisory Group <saag.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/saag>, <mailto:saag-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/saag/>
List-Post: <mailto:saag@ietf.org>
List-Help: <mailto:saag-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/saag>, <mailto:saag-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 28 Jul 2020 19:42:54 -0000

Hi Stephen,

Thanks for the quick response :)

On Tue, Jul 28, 2020 at 08:36:33PM +0100, Stephen Farrell wrote:
> 
> Hiya,
> 
> Good topic.
> 
> On 28/07/2020 20:13, Benjamin Kaduk wrote:
> > Can we make a classification of what types of protocols are naturally
> > suited for PKI scenarios and what types of protocols are naturally suited
> > for pinning?
> 
> FYI, in our survey of covid-tracing Apps most but not all
> of them do pin. When those apps are uploading keys, it'd
> not be good for that to be logged in an enterprise security
> appliance. That seems to generalise to any applications
> where the relevant entities would not like their data to
> end up logged like that (by accident or design), and where
> the application not working when behind a MITM is ok, or
> where one can expect the application to be whitelisted by
> such MITMs. ISTM that may be a fairly broad class of
> applications, certainly enough to be of interest. I'd
> guess some of the operators of MITMs might prefer to not
> be able to see some of that application data too.

There does seem to be something significant here, yes.
I gave an example of a banking app that would pin, and it's not entirely
clear to me whether "the application not working when behind a MITM is ok"
applies to such an example.  So there's some classification work left to
do.

> > 
> > If you're going to pin, how does it matter if you pin a (raw) public key, a
> > self-signed non-CA cert, an arbitrary cert, an intermediate CA, a root CA,
> > etc?
> 
> Raw public key seems too much a foot-gun. Even with
> pinning, you still need to depend on a CA for TLS, so
> it seems to make sense to pin to your currently
> preferred CA(s) plus one other independent CA. We've
> seen that in at least one of the above apps.
> 
> I'd guess the choice of root vs. intermediate might
> depend, not sure there's an obviously correct choice
> for that, for all cases.
> 
> > 
> > Is there benefit in arranging for a description of the system where the
> > ability to pin is just a degenerate case of a PKI, with a single trust
> > anchor and no real hierarchy?
> 
> I don't get the question sorry.

Sorry for the clumsy description.  Basically, if you squint hard, you could
claim that at least some types of pinning are actually a PKI, just a
degenerate PKI.  E.g., in a PKI I have to pin at least one trust anchor as
the root of the PKI, and if that pinned trust anchor just happens to also
be the certificate directly used in the protocol, it's still a PKI, just a
tree of height one.
What's not clear to me is whether it's useful to force this kind of
thinking on anyone, or to try to insist that all pinning is just a
degenerate PKI.

> > Do we want all protocols that specify one to be usable with the other (and
> > document it that way)?
> > 
> > Is there utility in writing a document to cover any of the above topics?
> 
> I think such a document would be useful. If it doesn't
> already exist then doing that as an informational RFC or
> BCP would be useful. If one exists already that's good
> enough then pointing at that may be fine.

Thanks,

Ben