Re: [Acme] Hash algorithms for challenges

Martin Thomson <martin.thomson@gmail.com> Wed, 08 March 2017 03:57 UTC

Return-Path: <martin.thomson@gmail.com>
X-Original-To: acme@ietfa.amsl.com
Delivered-To: acme@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id C99F7129418 for <acme@ietfa.amsl.com>; Tue, 7 Mar 2017 19:57:29 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.7
X-Spam-Level:
X-Spam-Status: No, score=-2.7 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, 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 xrj1m91d7OdI for <acme@ietfa.amsl.com>; Tue, 7 Mar 2017 19:57:28 -0800 (PST)
Received: from mail-qk0-x232.google.com (mail-qk0-x232.google.com [IPv6:2607:f8b0:400d:c09::232]) (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 12895124281 for <acme@ietf.org>; Tue, 7 Mar 2017 19:57:28 -0800 (PST)
Received: by mail-qk0-x232.google.com with SMTP id p64so43031432qke.1 for <acme@ietf.org>; Tue, 07 Mar 2017 19:57:28 -0800 (PST)
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=KStkK98iTycmeXK5G1y6AUODZfhMA/9sYAN244JEFmk=; b=G5T+v6wMs0LLFJ3rETjNkDeOFuyplRvWrNwqkOn9ZbaqYQ4pz3TMHLviTEJywFadzs 4SGYjoaiKMMLdj4jmBebVmHOVcGtpbJkBLKAJyJbZ0WxGhTtpO6nDXU0ispZWfLeqZah ifqGfgnpfql668oEba9zLWLZTm45EBxQPoMmiRyipb0MFj2NCjBEaTzPV7Yrhfnztisa TH5/+G3Hz2600vgvpB4AphUj82dzQvr3JcYkP2ffm0nIYhm6Tx14P/AVRGqaKaOx9gy0 IbdLHaYyDzktlaVqx2GMs/ouKvaGk/9Bb/lPCqqLMWhxFSiXx319NgX+UCrYoS1QkVvI HzFw==
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=KStkK98iTycmeXK5G1y6AUODZfhMA/9sYAN244JEFmk=; b=M2bm8e8g3zO4CwFhE6yDrUjkkLZMukzCD/J9VqfOZjRoSjqWMdGn7vDbX9536sRH3V r/q7Xbzh/KAsWtbLGwajh9O3maGIFWozhExsffVe82+DxTyvcGua8aZNxGMnnF/YrT8k kzD228uGwic1XUvSOE3mURqdHtFGm/UvwlSyK31mVH29+wvgWJLv5w+JquutjHlXxlrN ORiJLX5LbwiVWMXF/no0EN0TyyBA9TDljgmAzwj3CNNUAGv9DgkQxMIpdb7o8rc3RXeP xG+e79ga4osQnv2N8mb69p4e2WV1Y6A7o2CtGQaxnxzCG/B3hgSIq9mrbe3G30D/r5hS 4KGg==
X-Gm-Message-State: AMke39m+26VUpXp5SwpiPCAZDupooVsb2L9XXxq35PhXhz3aj65ZDKvi/OemMvUij25aCWyxiFUtE0bzn00EBA==
X-Received: by 10.237.34.250 with SMTP id q55mr5241626qtc.144.1488945447200; Tue, 07 Mar 2017 19:57:27 -0800 (PST)
MIME-Version: 1.0
Received: by 10.140.19.112 with HTTP; Tue, 7 Mar 2017 19:57:26 -0800 (PST)
In-Reply-To: <CAMmAzE+yqFXWVcgHmBGaGR21sx0a0-VUBogoFLxFcrvoFrwkYw@mail.gmail.com>
References: <CAMmAzE+yqFXWVcgHmBGaGR21sx0a0-VUBogoFLxFcrvoFrwkYw@mail.gmail.com>
From: Martin Thomson <martin.thomson@gmail.com>
Date: Wed, 08 Mar 2017 14:57:26 +1100
Message-ID: <CABkgnnV5T-eXmb3b+e67tVqBZSDH6=Zrg2fbENh-ggQA5oU3wQ@mail.gmail.com>
To: Logan Widick <logan.widick@gmail.com>
Content-Type: text/plain; charset="UTF-8"
Archived-At: <https://mailarchive.ietf.org/arch/msg/acme/IgbABAN0PBGbMatycDd_T9Jlrd8>
Cc: "acme@ietf.org" <acme@ietf.org>
Subject: Re: [Acme] Hash algorithms for challenges
X-BeenThere: acme@ietf.org
X-Mailman-Version: 2.1.17
Precedence: list
List-Id: Automated Certificate Management Environment <acme.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/acme>, <mailto:acme-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/acme/>
List-Post: <mailto:acme@ietf.org>
List-Help: <mailto:acme-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/acme>, <mailto:acme-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 08 Mar 2017 03:57:30 -0000

I would rather see new challenges defined with a new hash function
than introduce orthogonal hash negotiation.

On 8 March 2017 at 09:40, Logan Widick <logan.widick@gmail.com> wrote:
> I noticed that the challenges in the draft seem to be tied to the same
> hash algorithm (SHA-256). Would it be possible to have the the server
> include an array of supported hash algorithms, and then have the
> client specify which one of the server's supported algorithms is used
> in the response? This way, the hash algorithms can be changed when
> needed without changing the challenges themselves.
>
> For example, consider the following directory, modified to include the
> server's supported hash algorithms:
> {
>   "new-nonce": "https://example.com/acme/new-nonce",
>   //other standard URIs here
>   "meta": {
>     "terms-of-service": "https://example.com/acme/terms",
>     "website": "https://www.example.com/",
>     "caa-identities": ["example.com"],
>     "hash-algorithms": ["SHA-256", "SHA-512"]
> },
>
> Alternatively, the server's hash algorithms could be included in the
> challenges, like this:
> {
>    "type": "http-01",
>    "url": "https://example.com/authz/1234/0",
>    "token": "DGyRejmCefe7v4NfDGDKfA",
>    "hash-algorithms":["SHA-256", "SHA-512"]
> }
>
> Then, the client indicates the preferred hash algorithm (from the
> server's list) in the response:
> {
>   "protected": base64url({
>     "alg": "ES256",
>     "kid": "https://example.com/acme/acct/1",
>     "nonce": "Q_s3MWoqT05TrdkM2MTDcw",
>     "url": "https://example.com/acme/authz/asdf/0"
>   }),
>   "payload": base64url({
>     "type": "http-01",
>     "keyAuthorization": "IlirfxKKXA...vb29HhjjLPSggwiE",
>     "hash-algorithm": "SHA-256"
>   }),
>   "signature": "9cbg5JO1Gf5YLjjz...SpkUfcdPai9uVYYQ"
> }
>
> For compatibility with existing implementations, the default hash
> algorithm if none is specified could be SHA-256.
>
> Sincerely,
>
> Logan Widick
>
> _______________________________________________
> Acme mailing list
> Acme@ietf.org
> https://www.ietf.org/mailman/listinfo/acme