Re: [Emu] [lamps] EAP/EMU recommendations for client cert validation logic

Ryan Sleevi <ryan-ietf@sleevi.com> Wed, 08 January 2020 14:29 UTC

Return-Path: <ryan.sleevi@gmail.com>
X-Original-To: emu@ietfa.amsl.com
Delivered-To: emu@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 2209F120044; Wed, 8 Jan 2020 06:29:55 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.398
X-Spam-Level:
X-Spam-Status: No, score=-1.398 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, FREEMAIL_FORGED_FROMDOMAIN=0.25, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=no 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 fUgcLNkE5b1n; Wed, 8 Jan 2020 06:29:52 -0800 (PST)
Received: from mail-ed1-f49.google.com (mail-ed1-f49.google.com [209.85.208.49]) (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 0F6D012004C; Wed, 8 Jan 2020 06:29:52 -0800 (PST)
Received: by mail-ed1-f49.google.com with SMTP id e10so2691736edv.9; Wed, 08 Jan 2020 06:29:51 -0800 (PST)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=e5p7wD2zE/IpTTmXOZtEFPcimz9sNounaNNEBdFFrB0=; b=OVnojVb9wkMGRquJzlR9QfIKi8IPjpZvWGsb4hrTZ3i4qULaELN1gH6a25GmG181bt omqc7iQTJ1jIEyMbEzk+d3dtm/VoLvWitt8qNNSJrSmYdrxeOSqUs/CvlmezU8ja0vyn +yHWRhnA0xQV+NjAcc2YuGeY1gLXb2udkjfiVIJ6AuaKud3RFNHiMo+USeJ+89/wVfUN uCV/6HmQsZBb90fk0FOa6rFQDUwN/+er+d4VbQKjZW02w/u8CLZBztwDq72RvAIl2uOi nVLqgEl3vbUdn7BZr6WxP8WUp3HV7JJjr8oGtrSFl3ta+0WsZAeouh1lAhu72lQlq6Oz +6TA==
X-Gm-Message-State: APjAAAXVlKP9hoabcybg1i94s8cGy7CFj5KyuWMSnk6WAbVuWM+vqrHS 2IKxdUdI+A9064gcOtR56G0Xsr8G
X-Google-Smtp-Source: APXvYqxHgW2HpyNwxMyBk6QqRU48WZDIEGzio8tiQUHyRHRXW8RkM/LLmJLXZQjqEQDyicY50MnIBg==
X-Received: by 2002:a17:906:6014:: with SMTP id o20mr5324452ejj.100.1578493790050; Wed, 08 Jan 2020 06:29:50 -0800 (PST)
Received: from mail-wr1-f43.google.com (mail-wr1-f43.google.com. [209.85.221.43]) by smtp.gmail.com with ESMTPSA id dc5sm79833edb.61.2020.01.08.06.29.49 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 08 Jan 2020 06:29:49 -0800 (PST)
Received: by mail-wr1-f43.google.com with SMTP id c14so3589763wrn.7; Wed, 08 Jan 2020 06:29:49 -0800 (PST)
X-Received: by 2002:adf:ebc1:: with SMTP id v1mr4731686wrn.351.1578493789350; Wed, 08 Jan 2020 06:29:49 -0800 (PST)
MIME-Version: 1.0
References: <MN2PR11MB3901F9B86DAC83AF67FBA49DDB560@MN2PR11MB3901.namprd11.prod.outlook.com> <CAErg=HEzR4U9L2Bbj65hSKo4=GEHv=NVGkySFpdCaK2NoJBmFQ@mail.gmail.com> <MN2PR11MB39013D4C54FEACDC8228D136DB3F0@MN2PR11MB3901.namprd11.prod.outlook.com> <CAErg=HG=ZTbzfSr8oQMWgzFNqmdPkUNttLQDprGo5F6LXv9T5Q@mail.gmail.com> <B823CF84-4F78-4B91-BC68-E173FA78C28D@deployingradius.com> <CAErg=HEAtGiJKpLamdUaHicU2Psu7_0RrwsrwiQpb-uHOZ2p2Q@mail.gmail.com> <B2989B0E-8B6B-4B7A-B871-AF520310B3FC@deployingradius.com> <CAErg=HG06ZpiRUYogiVwoJPsZDsjzAVvO0B4=K=PE7aAHe44rA@mail.gmail.com> <6CEB4C89-B749-4A65-A25A-A12830ED8A62@deployingradius.com> <CAErg=HFPCYKgUEXHaOC0sQECYaVmt0TZXe-uDrKzFiNSAcdckg@mail.gmail.com> <00453E78-D991-4B4D-A138-5788FACC47C2@deployingradius.com> <CAErg=HFYQpfqTE9==TzGo795ZiuNBGVMqWuXS6GJ2DV0nGxPzA@mail.gmail.com> <316CC74D-667B-4A1E-AD48-A702DF705423@deployingradius.com>
In-Reply-To: <316CC74D-667B-4A1E-AD48-A702DF705423@deployingradius.com>
From: Ryan Sleevi <ryan-ietf@sleevi.com>
Date: Wed, 08 Jan 2020 09:29:37 -0500
X-Gmail-Original-Message-ID: <CAErg=HF-so7nvNmYd04wJ-DCHYGarkHpt3XjTGOhFNT1h=69UA@mail.gmail.com>
Message-ID: <CAErg=HF-so7nvNmYd04wJ-DCHYGarkHpt3XjTGOhFNT1h=69UA@mail.gmail.com>
To: Alan DeKok <aland@deployingradius.com>
Cc: Ryan Sleevi <ryan-ietf@sleevi.com>, EMU WG <emu@ietf.org>, "Owen Friel (ofriel)" <ofriel@cisco.com>, "spasm@ietf.org" <spasm@ietf.org>
Content-Type: multipart/alternative; boundary="00000000000098330c059ba1b951"
Archived-At: <https://mailarchive.ietf.org/arch/msg/emu/VX8ij063N09bfc5Z5mTpYQIeoqw>
Subject: Re: [Emu] [lamps] EAP/EMU recommendations for client cert validation logic
X-BeenThere: emu@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "EAP Methods Update \(EMU\)" <emu.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/emu>, <mailto:emu-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/emu/>
List-Post: <mailto:emu@ietf.org>
List-Help: <mailto:emu-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/emu>, <mailto:emu-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 08 Jan 2020 14:29:55 -0000

On Wed, Jan 8, 2020 at 8:14 AM Alan DeKok <aland@deployingradius.com> wrote:

>   Except, of course, CAs don't really have a process to issue certs with
> distinct EKUs.  So they're impossible to get in practice.
>

I'm not sure what your data to support this is, but this does not match the
commercial space. While I think we're in agreement you "shouldn't" be using
publicly trusted CAs, it's not at all true that they don't really have a
process. Perhaps this was more true a decade ago, but the work on Delegated
Credentials and Signed HTTP Exchanges - both which require custom
certificate profiles for issuance, and both which are relatively recent and
yet available from CAs.


>   If mis-use isn't defined, then it's reasonable to argue that following
> IETF standards isn't mis-use.
>

I'm not sure how you reached this conclusion. I gave you an example of
where misuse is defined to preclude such certificates, and that's but one
of many examples if you read commercial CA's CP/CPSes. The argument you
might be making is that "Well, they can change" - and sure, but that's just
continuing to move the goalposts, when the high level message is the same:
that overlaying with extant CAs, the original proposal, is a bad idea and
full of sharp edges.


> >   So... if we upgrade EAP implementations to use id-kp-eapOverLAN, then
> only the EAP applications have to be updated.  The common PKI libraries
> don't change.
> >
> > I agree that this goes away if you use an explicit EKU; the problem I
> was describing exists only if the profile tries to require id-kp-serverAuth.
>
>   I don't see how.  Validation of id-kp-serverAuth is the responsibility
> of the application, not the TLS library.  i.e. the TLS library exports APIs
> which (a) do TLS, and (b) allow the application to selectively validate
> certificates.
>
>   It is inappropriate for a TLS library to enforce one EKU on all users of
> TLS.  And how would the library do that?  It is entirely unaware of the
> transport protocol (TCP / HTTPS vs EAP).
>

I'm guessing you may be more familiar with the embedded libraries that roll
their own TLS stacks or build on OpenSSL?  This isn't how many of the
popular root stores and PKI libraries are implemented, which again goes
back to Owen's original question, for "public" certificates and extant root
stores - for example, the root stores and PKI/TLS libraries in a number of
popular operating systems, such as Windows, macOS/iOS, Android, and
ChromeOS.

These libraries have the client say "I want it for TLS", and the validation
library not only does validation for items like EKU, but that the
certificate complies with the root store policies for such certificates.
The root store policies may (as I mentioned previously) *also* have
dependencies on the particular TLS library being used; that is, they're not
designed to be used/operated outside of a given library.


>   The situation we have here is that we have a normal TLS "web server"
> certificate which is being used for TLS.  The transport protocol here is
> EAP, not TCP.  You seem to be claiming that there are security issues with
> this use-case.  I don't see how.
>

I'm afraid we're quickly diverging again, because I'm worried this claim
isn't being taken in the context it was made, so perhaps we should circle
back to this once we're on the same page on the fundamentals?


> > I’m sure everyone’s got a favorite citation, but the TLS WG spent so
> long on formal security proofs in part because of the number of issues that
> resulted from the negotiation and key reuse across TLS versions, which are
> functionally “different” protocols.
>
>   But using the *same* TLS version across different transport protocols is
> insecure?


I didn't say it was.


>   I agree CAs can shut down individual use-cases if they desire.  My
> push-back is against the idea of turning off enterprise WiFi whole-sale,
> world-wide.  That's just not going to happen, no matter what the policies
> of the CA.
>

Great. I don't think anyone has suggested turning off enterprise WiFi,
whole-scale, world-wide, or even anything remotely close to that, so I
think we're good?


>   It's simple English.  Stating that this *is* the status quo doesn't mean
> I think it's a good idea.  I've spent many messages agreeing it's bad, and
> working on a better solution.  It's not just possible to describe my
> position as a "full-throated support for the broken and dangerous status
> quo."
>

I think I've spent as many messages saying the same thing: let's work on a
better solution. I've tried to articulate one several times, which doesn't
involve "break WiFi world wide", so perhaps we can focus on that?


> > I agree that we have a disconnect, but the context here is from Owen’s
> original message, and I get the feeling you have a different design or
> conclusion that you’ve not expressed but are operating on, or that I’ve
> fundamentally misunderstood.
>
>   The disconnect is largely that I don't think we can simply shut-down
> Wi-Fi world-wide.  Plus, you think that me describing the current system
> means I'm supporting it.  That's just not true.
>

I certainly haven't suggested we shut-down Wi-Fi world-wide. I have argued
against specifying the extant behaviour, in as much as standards imply
support, even informational. Even as tombstones of ideas that didn't work,
they serve as attractive nuisances for implementors.


> > That original discussion was in the context of public CAs. In the world
> of locally-configured or private CAs, I don’t have as strong opinions.
> However, if the objective is to get to an end state where EAP is “secure by
> default” and any EAP operator can “just” get a certificate, then any
> discussion about id-kp-serverAuth isn’t the extant status quo.
>
>   I have no idea what that means.  It reads like you're saying the use of
> id-kp-serverAuth isn't the existing practice.  Which it is.  So... why the
> disconnect?
>

Put simply: There's no "obtain a certificate from a public CA and it just
works", where that certificate contains id-kp-serverAuth. I don't and
haven't disagreed that people can and do use id-kp-serverAuth for private
CAs, and I also don't doubt people obtain server certs from public CAs and
then manually configure them, but there's no "it just works". If the goal
is to specify "it just works", there's no reason or need to be constrained
by id-kp-serverAuth.


>   My recommendation for ~15 years for EAP has been that people should use
> private CAs.  It avoids all of the issues we're discussing here.
>

We're in quite violent agreement :)


> >   Apple, Microsoft, and 3GPP all require the use of id-kp-serverAuth.
> wpa_supplicant checks for it, too.  See src/tls/tlsv1_client_read.c.  The
> requirements of RFC 5216 Section 5.3 are followed.
> >
> > Thanks for the pointer! Applying it post-validation is definitely an
> interesting strategy, given the operational considerations and issues like
> > https://trailofbits.files.wordpress.com/2012/06/flame-md5.pdf that can
> allow for EKUs to bleed across hierarchies. I had mistakenly looked on the
> validation side, since that’s where the identity validation occurs.
>
>   I think that's another disconnect.  TLS libraries don't perform HTTPS
> validation checks for all certificates.  They can't, because they have no
> idea what the underlying transport is.  All the TLS library knows is that
> it gets handed a TLS blob.  The library does its TLS magic, and hands
> decoded data to the application.
>

I think we have very different perspectives of the industry, and I suspect
this is unfamiliarity with our divergent areas. I get the impression you're
speaking more about embedded libraries and stuff like OpenSSL, and you're
true. That's not an accurate reflection of the stacks in a number of
operating systems - e.g. Windows, macOS/iOS, Linux Standard Base (via NSS),
Android, or ChromeOS. These libraries and APIs, used to underpin much of
the client TLS traffic (including browsers) are often abstracted APIs in
which the library handles the transport as well as the verification, and
they explicitly don't support disconnects.


> >   So id-kp-serverAuth is *entrenched*.  It's not used sometimes by some
> vendors.  It's baked into existing standards and implementations.  Everyone
> uses it all of the time.  Everywhere.  Always.
> >
> > And going back to the original message: is everyone always using public
> CAs? I got the impression that our experiences are similar: which is that
> it requires manual and explicit configuration, and there’s no “out of the
> box” trust store here, and that the use of public CAs is not a concept that
> can MSP, because inherently, these are all manually configured.-
>
>   Many people use private CAs.  Many use public CAs.  *All* of them use
> id-kp-serverAuth.  Common EAP supplicants (MS / Apple / etc.) ship with
> known root CAs.  These root CAs are trusted by default for web browsing.
> None are trusted by default for EAP.
>

Right: we're in agreement, I believe? Getting "trusted by default for EAP"
means disconnecting from id-kp-serverAuth, as part of, well, introducing
the concept of "trusted by default for EAP".