Re: [Cfrg] erratum for hmac what do we think...

Taylor R Campbell <campbell+cfrg@mumble.net> Thu, 02 February 2017 21:57 UTC

Return-Path: <campbell@mumble.net>
X-Original-To: cfrg@ietfa.amsl.com
Delivered-To: cfrg@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 0DBB71299FD for <cfrg@ietfa.amsl.com>; Thu, 2 Feb 2017 13:57:01 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -5.1
X-Spam-Level:
X-Spam-Status: No, score=-5.1 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, RP_MATCHES_RCVD=-3.199, 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 ZRLvQEuIvi9e for <cfrg@ietfa.amsl.com>; Thu, 2 Feb 2017 13:56:59 -0800 (PST)
Received: from jupiter.mumble.net (jupiter.mumble.net [74.50.56.165]) (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 171A4129A18 for <cfrg@irtf.org>; Thu, 2 Feb 2017 13:56:33 -0800 (PST)
Received: by jupiter.mumble.net (Postfix, from userid 1014) id 7D72A60AA2; Thu, 2 Feb 2017 21:56:31 +0000 (UTC)
From: Taylor R Campbell <campbell+cfrg@mumble.net>
To: Stephen Farrell <stephen.farrell@cs.tcd.ie>
In-reply-to: <666efaf7-b660-e20b-8a8a-8949a64e9bed@cs.tcd.ie> (stephen.farrell@cs.tcd.ie)
Date: Thu, 02 Feb 2017 21:56:31 +0000
Sender: Taylor R Campbell <campbell@mumble.net>
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Message-Id: <20170202215631.7D72A60AA2@jupiter.mumble.net>
Archived-At: <https://mailarchive.ietf.org/arch/msg/cfrg/9iYAAXn0KbH2NzesleyL9GgLO1w>
Cc: cfrg@irtf.org
Subject: Re: [Cfrg] erratum for hmac what do we think...
X-BeenThere: cfrg@irtf.org
X-Mailman-Version: 2.1.17
Precedence: list
List-Id: Crypto Forum Research Group <cfrg.irtf.org>
List-Unsubscribe: <https://www.irtf.org/mailman/options/cfrg>, <mailto:cfrg-request@irtf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/cfrg/>
List-Post: <mailto:cfrg@irtf.org>
List-Help: <mailto:cfrg-request@irtf.org?subject=help>
List-Subscribe: <https://www.irtf.org/mailman/listinfo/cfrg>, <mailto:cfrg-request@irtf.org?subject=subscribe>
X-List-Received-Date: Thu, 02 Feb 2017 21:57:01 -0000

> Date: Thu, 2 Feb 2017 02:24:44 +0000
> From: Stephen Farrell <stephen.farrell@cs.tcd.ie>
> 
> There's an erratum posted for hmac [1] where I'd be
> interested in what folks here think.

Fix hash function H with block size b.  The alleged problem is that
for a key k, if |k| > b and h = H(k), then HMAC-H_h = HMAC-H_k.

What protocol would ever use HMAC-H with related keys of different
lengths like this for the same purpose?  What protocol would ever use
HMAC-H with keys of different lengths at all for the same purpose?

Needless flexibility like that strikes me as more likely to indicate a
deeper problem -- e.g., one reason that might happen is that the
protocol foolishly uses a password verbatim as an HMAC key.