Re: [TLS] Comments/Questions on draft-gutmann-tls-encrypt-then-mac-00.txt

"Blumenthal, Uri - 0558 - MITLL" <uri@ll.mit.edu> Tue, 24 September 2013 16:48 UTC

Return-Path: <prvs=29794e2de3=uri@ll.mit.edu>
X-Original-To: tls@ietfa.amsl.com
Delivered-To: tls@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id A924721F9926 for <tls@ietfa.amsl.com>; Tue, 24 Sep 2013 09:48:41 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -5.688
X-Spam-Level:
X-Spam-Status: No, score=-5.688 tagged_above=-999 required=5 tests=[AWL=0.310, BAYES_00=-2.599, J_CHICKENPOX_73=0.6, RCVD_IN_DNSWL_MED=-4, UNPARSEABLE_RELAY=0.001]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id wfWJSgf6SGuR for <tls@ietfa.amsl.com>; Tue, 24 Sep 2013 09:48:36 -0700 (PDT)
Received: from mx2.ll.mit.edu (MX2.LL.MIT.EDU [129.55.12.46]) by ietfa.amsl.com (Postfix) with ESMTP id 4388821F8EA8 for <tls@ietf.org>; Tue, 24 Sep 2013 09:48:35 -0700 (PDT)
Received: from LLE2K7-HUB01.mitll.ad.local (LLE2K7-HUB01.mitll.ad.local) by mx2.ll.mit.edu (unknown) with ESMTP id r8OGfQtV015279; Tue, 24 Sep 2013 12:48:32 -0400
From: "Blumenthal, Uri - 0558 - MITLL" <uri@ll.mit.edu>
To: "c.kahlo@ageto.net" <c.kahlo@ageto.net>
Date: Tue, 24 Sep 2013 12:47:19 -0400
Thread-Topic: [TLS] Comments/Questions on draft-gutmann-tls-encrypt-then-mac-00.txt
Thread-Index: Ac65RbwNsJb/zWgpRD+74ryZpM1bpQ==
Message-ID: <7966A10B-9B28-4CF3-AB1C-74CCE617ED90@ll.mit.edu>
References: <CABcZeBN+0hX1-cb0V4AyaO3FrwaGrtjbRO3BGOV0KBSjRkNwkw@mail.gmail.com> <523c738f.0733cc0a.41a0.3096@mx.google.com> <523F383A.20803@drh-consultancy.co.uk> <523FE7B6.10501@gnutls.org> <524038fa.c402cd0a.127a.ffffc841@mx.google.com> <524047D1.7040601@gnutls.org> <52406827.c664cc0a.2ad0.ffffd7f7@mx.google.com>
In-Reply-To: <52406827.c664cc0a.2ad0.ffffd7f7@mx.google.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach: yes
X-MS-TNEF-Correlator:
acceptlanguage: en-US
Content-Type: multipart/signed; boundary="Apple-Mail=_CB6D0B73-9B00-4505-8F99-10A544240BFA"; protocol="application/pgp-signature"; micalg=pgp-sha1
MIME-Version: 1.0
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.10.8794, 1.0.431, 0.0.0000 definitions=2013-09-24_07:2013-09-23, 2013-09-24, 1970-01-01 signatures=0
X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 suspectscore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=7.0.1-1305240000 definitions=main-1309240089
Cc: Team Neuer Personalausweis <npa@ageto.net>, "tls@ietf.org" <tls@ietf.org>
Subject: Re: [TLS] Comments/Questions on draft-gutmann-tls-encrypt-then-mac-00.txt
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: "This is the mailing list for the Transport Layer Security working group of the IETF." <tls.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/tls>, <mailto:tls-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/tls>
List-Post: <mailto:tls@ietf.org>
List-Help: <mailto:tls-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/tls>, <mailto:tls-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 24 Sep 2013 16:48:41 -0000

> We've had a lot of discussions about this. Strictly speaking if a non-
> truncated HMac reveals (too much) information of the internal state of
> the hash algorithm something totally went wrong with the hash function.

There are two issues. One is how much info the non-truncated MAC reveals. Another one is that it enables key guessing with just one valid message+MAC pair.

> As a result of this BSI TR-03116-4 chapter 2.3, 1st bullet states
> "do not use truncated_hmac". I'm sorry again for the lack of an english
> translation at the moment. The Federal Office for Information Security
> will probably provide one later.

I wonder what their reasoning is.

> In THEORY a truncated_hmac offers an option for attacks as only a fraction of the original HMac has to match.

Certainly.  It reduces the collision-creating space from square root of full MAC size to square root of truncated MAC size. For the benefit of requiring 2^(# of truncated bits) valid MACs to successfully forge a MAC. 

With modern MACs and keys either attack should not be practical. Still, I personally prefer to truncate, though not necessarily all the way down to 96 bits.