Re: [jose] RFC 8037 "alg" quirkiness

Benjamin Kaduk <kaduk@mit.edu> Sat, 19 September 2020 04:01 UTC

Return-Path: <kaduk@mit.edu>
X-Original-To: jose@ietfa.amsl.com
Delivered-To: jose@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id E2F653A12C3 for <jose@ietfa.amsl.com>; Fri, 18 Sep 2020 21:01:36 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.918
X-Spam-Level:
X-Spam-Status: No, score=-1.918 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_BLOCKED=0.001, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=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 wpaz2ebfgRWI for <jose@ietfa.amsl.com>; Fri, 18 Sep 2020 21:01:35 -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 7F9513A12C2 for <jose@ietf.org>; Fri, 18 Sep 2020 21:01:35 -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 08J41RXu020169 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 19 Sep 2020 00:01:29 -0400
Date: Fri, 18 Sep 2020 21:01:27 -0700
From: Benjamin Kaduk <kaduk@mit.edu>
To: Anders Rundgren <anders.rundgren.net@gmail.com>
Cc: Ilari Liusvaara <ilariliusvaara@welho.com>, "jose@ietf.org" <jose@ietf.org>
Message-ID: <20200919040127.GK89563@kduck.mit.edu>
References: <1a84f81d-c7bd-9961-9f5c-e6c358fc1095@gmail.com> <3B2FF2C4-44EB-4462-868E-C6DD1DD3F1CA@forgerock.com> <20200916123043.GB1653297@LK-Perkele-VII> <f8b75958-0461-a824-1de4-d50332e49f8c@gmail.com> <9403cfeb-40aa-8e85-3193-b403ff685168@gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <9403cfeb-40aa-8e85-3193-b403ff685168@gmail.com>
User-Agent: Mutt/1.12.1 (2019-06-15)
Archived-At: <https://mailarchive.ietf.org/arch/msg/jose/G8PL9hXuyRO-sllfJs_7mZM5Csg>
Subject: Re: [jose] RFC 8037 "alg" quirkiness
X-BeenThere: jose@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Javascript Object Signing and Encryption <jose.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/jose>, <mailto:jose-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/jose/>
List-Post: <mailto:jose@ietf.org>
List-Help: <mailto:jose-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/jose>, <mailto:jose-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 19 Sep 2020 04:01:37 -0000

Hi Anders,

[The quoting seems to have gotten messed up; IIUC the context was the
following]

> >> - In general, using the same key with multiple algorithms is not
> >>     cryptographically safe. There can be algorithm pairs which interact
> >>     badly (for instance, Ed25519 and the original Ed25519ph).

On Thu, Sep 17, 2020 at 07:02:09AM +0200, Anders Rundgren wrote:
> Apparently the PKIX folks came to a different conclusion:
> 
> https://tools.ietf.org/html/rfc8410#section-3
> 
> "The same algorithm identifiers are used for identifying a public key,
>   a private key, and a signature (for the two EdDSA related OIDs)."

I'm not seeing how that's inconsistent with one-algorithm-per-key -- you
know from the context in which the OID appears whether you have a
signature, public, or private key, and that context is used to namespace
the following algorithm lookup.  Accordingly, there is no ambiguity as to
what the OID means, in that context.

-Ben