Re: [OAUTH-WG] WGLC on draft-ietf-oauth-mtls-07

Mike Jones <> Mon, 30 April 2018 15:51 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 07AD61241F5 for <>; Mon, 30 Apr 2018 08:51:03 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -2.01
X-Spam-Status: No, score=-2.01 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, T_DKIMWL_WL_HIGH=-0.01] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (1024-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id F7IbFLaLDJr4 for <>; Mon, 30 Apr 2018 08:50:59 -0700 (PDT)
Received: from ( []) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 81017124C27 for <>; Mon, 30 Apr 2018 08:50:58 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=AvOwdhIUJsw+53wyr+QF8XA5SzIwvcHQgOZ+nApQ2uQ=; b=Fq5FgzYP6urjKmiTW+EvOfxhKB8iCPRaixUcHY36jmPb8dzGsiZai2Xp/pUUxZQ2D/EaU1nvcbwzv3r2jtsab8I+4EqHbIAxKDlBWCW5OWr3fuC9Qye/hy9wOHUnj92x+zy41CfVXbvZpB0f1Ux4qZGW/Q+HyJFCTsJsPrhqVHY=
Received: from (2603:10b6:302:8::29) by (2603:10b6:302:9::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.764.0; Mon, 30 Apr 2018 15:50:55 +0000
Received: from ([fe80::95a5:3531:866a:36e6]) by ([fe80::95a5:3531:866a:36e6%8]) with mapi id 15.20.0766.000; Mon, 30 Apr 2018 15:50:55 +0000
From: Mike Jones <>
To: John Bradley <>, Brian Campbell <>
CC: oauth <>
Thread-Topic: [OAUTH-WG] WGLC on draft-ietf-oauth-mtls-07
Date: Mon, 30 Apr 2018 15:50:55 +0000
Message-ID: <>
References: <> <> <> <5758ae34-1d2d-4946-9190-7a2e2bc184d2@Canary> <> <> <> <> <> <>
In-Reply-To: <>
Accept-Language: en-US
Content-Language: en-US
x-originating-ip: []
x-ms-publictraffictype: Email
x-microsoft-exchange-diagnostics: 1; MW2PR00MB0379; 7:B6ikfP+meivBewKD6JPLv/BUHq6yDer8ydo3yNUBOzVr3DsKdvy83YyNsBgxmFbR06YEws83zvnenm07zgh8+RWOF0L+cF77YUGniOMPFPg5L8lAQiTkJFOe7TgeYhUuPrizwx9gSqYkuOKlpOtVU708UeY9zkHX9ggL/D9JBxsCSkUcX7qjguuUG/3zMQ08kdIQMeEmFBJ8dk85NPlxAAJKDxrbfLclvCgExvXSa0Z1fQ68Um3+FTMfx+/7WqXe; 20:S5Ex1V63bsoEHtKRRJUoAMmj93h5L1MQhMrU3STcXQRD4EAP7849PHwlnR+Rs8N3LVb239jWYEOzOm7yg1FoJMh4Z5QHjD3pP7Fm5woUjZwv2uv79M7ZKHlK2ROeNh+Ap80ACn9eQs+TB6dk3zllF14jPaCi0IGGJ6fG11RUiyw=
x-ms-exchange-antispam-srfa-diagnostics: SOS;
x-ms-office365-filtering-ht: Tenant
x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(48565401081)(5600026)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7193020); SRVR:MW2PR00MB0379;
x-ms-traffictypediagnostic: MW2PR00MB0379:
authentication-results: spf=none (sender IP is );
x-microsoft-antispam-prvs: <>
x-exchange-antispam-report-test: UriScan:(28532068793085)(158342451672863)(244540007438412)(192374486261705)(100405760836317)(21748063052155);
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(2017102700009)(2017102701064)(6040522)(2401047)(8121501046)(5005006)(2017102702064)(20171027021009)(20171027022009)(20171027023009)(20171027024009)(20171027025009)(20171027026009)(2017102703076)(3231254)(2018427008)(944501410)(52105095)(10201501046)(93006095)(93001095)(3002001)(6055026)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123564045)(20161123562045)(20161123558120)(6072148)(201708071742011); SRVR:MW2PR00MB0379; BCL:0; PCL:0; RULEID:; SRVR:MW2PR00MB0379;
x-forefront-prvs: 0658BAF71F
x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(39380400002)(39860400002)(366004)(396003)(376002)(346002)(189003)(199004)(40224003)(74316002)(55016002)(6506007)(93886005)(53546011)(4326008)(68736007)(186003)(81156014)(8676002)(6306002)(54896002)(19609705001)(59450400001)(236005)(53386004)(6246003)(9686003)(53936002)(5250100002)(316002)(14454004)(7736002)(26005)(22452003)(86362001)(86612001)(110136005)(5890100001)(102836004)(3280700002)(2906002)(3660700001)(606006)(6116002)(486006)(81166006)(790700001)(97736004)(25786009)(52396003)(105586002)(10290500003)(229853002)(11346002)(5660300001)(476003)(106356001)(2900100001)(3846002)(8936002)(99286004)(966005)(446003)(6436002)(76176011)(7696005)(478600001)(10090500001)(66066001)(8990500004)(33656002)(72206003); DIR:OUT; SFP:1102; SCL:1; SRVR:MW2PR00MB0379;; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1;
received-spf: None ( does not designate permitted sender hosts)
x-microsoft-antispam-message-info: iDXFiBYFrJVUy04n2hsPEVv1O4gvU7k0v9ee9rMZwZsjsJFNM+X0fwX6yvWlMMmD8F9+R0fneSEVJUnYZ1cMeOJoTX8M9oeYVYwHxngef8S8D3tGFr28i8a32CfFbhkBPdqPgZc4KN47N04zndw4T56JHBkTe/iRxhJWUNhSKp+9n/HAwQi5PxVMIvmg4zMf
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
Content-Type: multipart/alternative; boundary="_000_MW2PR00MB0298114EFC7165151F5514A9F5820MW2PR00MB0298namp_"
MIME-Version: 1.0
X-MS-Office365-Filtering-Correlation-Id: 41cccbe9-4b55-4a6d-a689-08d5aeb228fe
X-MS-Exchange-CrossTenant-Network-Message-Id: 41cccbe9-4b55-4a6d-a689-08d5aeb228fe
X-MS-Exchange-CrossTenant-originalarrivaltime: 30 Apr 2018 15:50:55.6411 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47
X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW2PR00MB0379
Archived-At: <>
Subject: Re: [OAUTH-WG] WGLC on draft-ietf-oauth-mtls-07
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: OAUTH WG <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Mon, 30 Apr 2018 15:51:03 -0000

I agree that this specification should not define new certificate thumbprint methods.  They can always be registered by other specifications if needed in the future.

                                                       -- Mike

From: OAuth <> On Behalf Of John Bradley
Sent: Monday, April 30, 2018 7:07 AM
To: Brian Campbell <>
Cc: oauth <>
Subject: Re: [OAUTH-WG] WGLC on draft-ietf-oauth-mtls-07

I lean towards letting new certificate thumbprints be defined someplace else.

With SHA256, it is really second preimage resistance that we care about for a certificate thumbprint, rather than simple collision resistance.

MD5 failed quite badly with chosen prefix collision attacks against certificates (Thanks to some X.509 extensions).
SHA1 has also been shown to be vulnerable to a PDF chosen prefix attack (

The reason NIST pushed for development of SHA3 was concern that a preimage attack might eventually be found agains the SHA2 family of hash algorithms.

While SHA512 may have double the number of bytes it may not help much against a SHA2 preimage attack,. (Some papers  suggest that the double word size of SHA512 it may be more vulnerable than SHA256 to some attacks)

It is currently believed that SHA256 has 256 bits of second preimage strength.   That could always turn out to be wrong as SHA2 has some similarities to SHA1, and yes post quantum that is reduced to 128bits.

To have a safe future option we would probably want to go with SHA3-512.   However I don’t see that getting much traction in the near term.

Practical things people should do run more along the lines of:
1: Put at least 64 bits of entropy into the certificate serial number if using self signed or a local CA.  Commercial CA need to do that now.
2: Rotate certificates on a regular basis,  using a registered JWKS URI

My concern is that people will see a bigger number and decide it is better if we define it in the spec.
We may be getting people to do additional work and increasing token size without a good reason by putting it in the spec directly.

I have yet to see any real discussion on using bigger hashes for signing certificates, or creating thumbprints in other places.

John B.

On Thu, Apr 19, 2018 at 1:23 PM, Brian Campbell <<>> wrote:
Okay, so I retract the idea of metadata indicating the hash alg/cnf method (based on John pointing out that it doesn't really make sense).
That still leaves the question of whether or not to define additional confirmation methods in this document (and if so, what they would be though x5t#S384 and x5t#S512 seem the most likely).
There's some reasonable rational for both adding one or two new hash alg confirmation methods in the doc now vs. sticking with just SHA256 for now. I'll note again that the doc doesn't preclude using or later defining other confirmation methods.
I'm kind of on the fence about it, to be honest. But that doesn't really matter because the draft should reflect rough WG consensus. So I'm looking to get a rough gauge of rough consensus. At this point there's one comment out of WGLC asking for additional confirmation method(s). I don't think that makes for consensus. But I'd ask others from the WG to chime in, if appropriate, to help me better gauge consensus.

On Fri, Apr 13, 2018 at 4:49 AM, Neil Madden <<>> wrote:
I’m not particularly wedded to SHA-512, just that it should be possible to use something else. At the moment, the draft seems pretty wedded to SHA-256. SHA-512 may be overkill, but it is fast (faster than SHA-256 on many 64-bit machines) and provides a very wide security margin against any future crypto advances (quantum or otherwise). I’d also be happy with SHA-384, SHA3-512, Blake2 etc but SHA-512 seems pretty widely available.

I don’t think short-lived access tokens is a help if the likelihood is that certs will be reused for many access tokens.

Public Web PKI certs tend to only use SHA-256 as it has broad support, and I gather there were some compatibility issues with SHA-512 certs in TLS. There are a handful of SHA-384 certs - e.g., the Comodo CA certs for are signed with SHA-384 (although with RSA-2048, which NSA estimates at only ~112-bit security). SHA-512 is used on some internal networks where there is more control over components being used, which is also where people are mostly likely to care about security beyond 128-bit level (eg government internal networks).

By the way, I just mentioned quantum attacks as an example of something that might weaken the hash in future. Obviously, quantum attacks completely destroy RSA, ECDSA etc, so SHA-512 would not solve this on its own, but it provides a considerable margin to hedge against future quantum *or classical* advances while allowing the paranoid to pick a stronger security level now.. We have customers that ask for 256-bit AES already.

(I also misremembered the quantum attack - “Serious Cryptography” by Aumasson tells me the best known quantum attack against collision resistance is O(2^n/3) - so ~2^85 for SHA-256 but also needs O(2^85) space so is impractical. I don’t know if that is the last word though).

As for SHA-1, doesn’t that prove the point? SHA-1 is pretty broken now with practical collisions having been demonstrated. The kind of attacks on CA certs demonstrated for MD5 [1] are probably not too far off for SHA-1 now. As far as I am aware, we’re nowhere near those kinds of attacks on SHA-256, but I’d prefer that there was a backup plan in place already rather than waiting to see (and waiting for everyone to have hard-coded SHA-256 everywhere).

Now I have to get back to my daughter’s birthday party… :-)



On Thursday, Apr 12, 2018 at 10:07 pm, John Bradley <<>> wrote:
The WG discusses RS meta-data as part of one of Dick’s proposals.   I am unclear on who is going to work on it in what draft.

If the client is doing mtls to both the Token endpoint and RS the information in the confirmation method is not relevant to the client as long as the AS and RS are in agreement like with most tokens.

The hash on the certificate and length of the signing key are equally or more vulnerable to any sort of attack.
At least with AT the tokens are not long lived.

Doing anything better than SHA256 only makes sense if the cert is signed by something stronger like SHA512 with a 2048bit RSA key.   That seems sort of unlikely in the near term.

I prefer to wait to see what general fix is proposed before we jump the gun with a bandade for a small part of the overall problem.

People are typically using SHA1 fingerprints.  We added SHA256 for JWT and got push back on that as overkill.
I don’t think this is the correct place to be deciding this.

We could say that if new thumbprints are defined the AS and RS can decide to use them as necessary.
That is sort of the situation we have now.

The correct solution may be a thousand rounds of PBKDF2 or something like that to make finding collisions more difficult rather than longer hashes.

John B.

> On Apr 12, 2018, at 5:20 PM, Brian Campbell <<>> wrote:
> That's true about it being opaque to the client. I was thinking of client metadata (config or registration) as a way for the AS to decide if to bind the AT to a cert. And moving from a boolean to a conf method as an extension of that. It would be more meaningful in RS discovery, if there was such a thing.
> I don’t know that SHA512 would be the best choice either but it is something that is stronger and could be included now. If there's consensus to do more than SHA256 in this doc.
> On Thu, Apr 12, 2018 at 1:52 PM, John Bradley <<>> wrote:
> Inline
> Snip
>> 12. The use of only SHA-256 fingerprints means that the security strength of the sender-constrained access tokens is limited by the collision resistance of SHA-256 - roughly “128-bit security" - without a new specification for a new thumbprint algorithm. An implication of this is that is is fairly pointless for the protected resource TLS stack to ever negotiate cipher suites/keys with a higher level of security. In more crystal ball territory, if a practical quantum computer becomes a possibility within the lifetime of this spec, then the expected collision resistance of SHA-256 would drop quadratically, allowing an attacker to find a colliding certificate in ~2^64 effort. If we are going to pick just one thumbprint hash algorithm, I would prefer we pick SHA-512.
>> The idea behind haveing just one thumbprint hash algorithm was to keep things simple. And SHA-256 seems good enough for the reasonably foreseeable future (and space aware). Also a new little spec to register a different hash algorithm, should the need arise, didn't seem particularity onerous.
>> That was the thinking anyway. Maybe it is too short sighted though?
>> I do think SHA-256 should stay regardless.
>> But the draft could also define SHA-512 (and maybe others). What do you and WG folks think about that?
>> *** Yes please.
>> It would probably then be useful for the metadata in §3.3 and §3.4 to change from just boolean values to something to convey what hash alg/cnf method the client expects and the list of what the server supports. That's maybe something that should be done anyway. That'd be a breaking change to the metadata. But there's already another potential breaking change identified earlier in this message. So maybe it's worth doing...
>> How do folks feel about making this kind of change?
> The confirmation method is opaque to the client.  I don’t think adding hash algs to discovery will really help.
> The AS selection needs to be based on what the RS can support.
> If anyplace it should be in RS discovery.
> As a practical matter you art going to find a client certificate with more than a SHA256 hash anytime in the near future.
> So for a short lived access token 128bits of collision resistance is quite good.   We are going to have issues with certificates long before this becomes a problem.
> SHA256 is appropriate for AES128 256bit elliptic curves and 3072bit RSA keys, but again that is over the long term.
> We are using short lived access tokens.  People should rotate the certificate more often than once a year if this is a real issue.
> I am not against new hash for the fingerprint, but I also don’t know that SHA512 would be the best choice if we are concerned about quantum crypto resistance.   That is a issue beyond mtls and should be addressed by CFRG etc.
> Regards
> John B.
> CONFIDENTIALITY NOTICE: This email may contain confidential and privileged material for the sole use of the intended recipient(s). Any review, use, distribution or disclosure by others is strictly prohibited.  If you have received this communication in error, please notify the sender immediately by e-mail and delete the message and any file attachments from your computer. Thank you.

CONFIDENTIALITY NOTICE: This email may contain confidential and privileged material for the sole use of the intended recipient(s). Any review, use, distribution or disclosure by others is strictly prohibited..  If you have received this communication in error, please notify the sender immediately by e-mail and delete the message and any file attachments from your computer. Thank you.