Re: [Cfrg] AES-GCM weakness

David McGrew <> Mon, 18 July 2011 21:18 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 1E77E21F86C7 for <>; Mon, 18 Jul 2011 14:18:26 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -104.449
X-Spam-Status: No, score=-104.449 tagged_above=-999 required=5 tests=[AWL=-2.150, BAYES_00=-2.599, MIME_8BIT_HEADER=0.3, USER_IN_WHITELIST=-100]
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id eBEBb357mnaQ for <>; Mon, 18 Jul 2011 14:18:22 -0700 (PDT)
Received: from ( []) by (Postfix) with ESMTP id 4EA7021F86C4 for <>; Mon, 18 Jul 2011 14:18:22 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple;;; l=3202; q=dns/txt; s=iport; t=1311023902; x=1312233502; h=cc:message-id:from:to:in-reply-to: content-transfer-encoding:mime-version:subject:date: references; bh=/RUO/279Papb7tiaZJYCStJKrXJRbHsS9IU+CBiF5Og=; b=LHuNjEr+zr+cNvddlI8r/frq7ypRdd+wWjX81YC/RxErK2h/2p6awOeY b/qxKQJWym9SM+6v8/DhhTCjONKx+vLEHo5tw50luztExL1AwIJ2Trr1i z0v+ALWNYxr8vBhU3bmkseM+qp8Y2IfZ3gEcv+a4Sas0unGEt3dcegYFr 8=;
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: Av8EAMChJE6rRDoG/2dsb2JhbABThANGozN3iHylLY0ckR2BK4QCMF8Eh1SLEpB2
X-IronPort-AV: E=Sophos;i="4.67,223,1309737600"; d="scan'208";a="4110287"
Received: from ([]) by with ESMTP; 18 Jul 2011 21:18:21 +0000
Received: from ( []) by (8.14.3/8.14.3) with ESMTP id p6ILIKbm005494; Mon, 18 Jul 2011 21:18:20 GMT
Message-Id: <>
From: David McGrew <>
To: =?ISO-8859-1?Q?J=E9r=E9mie_Crenne?= <>
In-Reply-To: <000001cc4583$5f371720$1da54560$>
Content-Type: text/plain; charset=UTF-8; format=flowed; delsp=yes
Content-Transfer-Encoding: quoted-printable
Mime-Version: 1.0 (Apple Message framework v936)
Date: Mon, 18 Jul 2011 14:18:19 -0700
References: <> <000001cc4583$5f371720$1da54560$>
X-Mailer: Apple Mail (2.936)
Subject: Re: [Cfrg] AES-GCM weakness
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Crypto Forum Research Group <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Mon, 18 Jul 2011 21:18:26 -0000

Hi Jérémie, provides some interesting insights  
into how polynomial hash based authentication works, but it does *not*  
describe any way of attacking GCM that improves on what was known  
before GCM was adopted.

"GCM, GHASH and Weak Keys" describes a particular way of forging a  
message, given a valid message, which works with probability of about  
n/2^128 for messages that are n*128 bits long.  Observation 1 reads:  
"Let n be a number satisfying gcd(2^128 − 1, n) = n. Blindly swapping  
Xi and Xj , where i ≡ j (mod n) will result in a successful forgery  
with probability of at least n/2^128."

This corresponds to the original security analysis, from "The Security  
and Performance of the Galois/Counter Mode (GCM) of  
Operation" (Indocrypt 2004).  Lemma 2 from that reference(GHASH is  
almost xor universal) reads: "The function GHASH is (n + 1)/2^128  
almost xor universal when its second and third inputs are restricted  
so that their lengths sum to n*128 or fewer bits ..."   Here I have  
set w=128 and l=n*128 so that the notations are similar.

The newer work does describe an optimal attack, which is interesting,  
though see also the attacks described by Ferguson in his comments to  
NIST [1], and [2].  But it does not describe a way to attack GCM that  
works with higher chance of success than was previously known.

SGCM, described in, I don't think is a  
good idea, because it shares GCM's least desirable property (a broken  
implementation that repeats IVs will give away its authentication key)  
and it is not backwards compatible with GCM.   If that algorithm is  
extended, it would be much more worthwhile to have a different method  
of encrypting the hash, as suggested by Joux (Section 5 of [3]) and as  
done by the CWC authors [4].  It might be useful to have an additional  
ECB encryption of the tag, which could be described as a post- 
processing step for GCM as it is currently specified.







On Jul 18, 2011, at 12:46 PM, Jérémie Crenne wrote:

> Hi everybody,
> What is the feeling of the community about the recent potential AES- 
> weakness due to weak keys ? I'm still considering the usage of AES- 
> GCM to be
> an attractive mode for hardware implementations. I'm a little bit  
> concerned
> about this since the "new" proposition described here would require
> significant addition of logic.
> Thanks,
> Jérémie
> _______________________________________________
> Cfrg mailing list