[TLS] Issue #964: Shortened HKDF labels

Eric Rescorla <ekr@rtfm.com> Mon, 24 April 2017 12:57 UTC

Return-Path: <ekr@rtfm.com>
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 6695B1270A7 for <tls@ietfa.amsl.com>; Mon, 24 Apr 2017 05:57:47 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.599
X-Spam-Level:
X-Spam-Status: No, score=-2.599 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=rtfm-com.20150623.gappssmtp.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 iA-Kx6eI9k6X for <tls@ietfa.amsl.com>; Mon, 24 Apr 2017 05:57:45 -0700 (PDT)
Received: from mail-yw0-x22a.google.com (mail-yw0-x22a.google.com [IPv6:2607:f8b0:4002:c05::22a]) (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 9D09D13151C for <tls@ietf.org>; Mon, 24 Apr 2017 05:57:39 -0700 (PDT)
Received: by mail-yw0-x22a.google.com with SMTP id k11so31862680ywb.1 for <tls@ietf.org>; Mon, 24 Apr 2017 05:57:39 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rtfm-com.20150623.gappssmtp.com; s=20150623; h=mime-version:from:date:message-id:subject:to; bh=FxK0ESmNqHzi0BttbjYvRl1THSODMm3mILCXRW4itrY=; b=C155KVwuX2zdYw3zk3QATFDjFQJGoZXGvp0v0dBp3ljPod2OaeWhe3KLE07ONlxkUQ wm9EEHmHeJr35VDIuG59fslRHL+4N//Cby9cPjZ+pKjELTDVqJg3FC8kOEVoHXK45Cjo aDkNCZ3lCzY1DN4+c/GblldYMlGfvV/3Khb+/4vUVSbCEyRXuD9xbFSAadNp/TkkrQ4Y l8ePCpXemPw6S1amWxrEY9JHHUg4eoukLt+ZUB7USoeLI8+c+QKzeFJjzKo1QU1VnAzc GS1TI4lJHwMrGeS5MypLoVnXp0Buod3TN/xB8JQQwygqgmi3QNkxddVxG4N5w7zrIaPj 0rxw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=FxK0ESmNqHzi0BttbjYvRl1THSODMm3mILCXRW4itrY=; b=n9ukDnbpaiAP8i/lUzwjRXN3EogjrG22YnXI2/sz93yLxXSKQtNSHMO1Gxzos928On niyJ2Xx5kO5at8w0/eHzngkBe9DueEgB5vggnRCpE9rqr90qRX1gd6RIHp38Y36JpGc1 Et0z8d5riKKXOLYKn8c4ahiNThWxK6SoYo8GInokzuoD83z11yKDAPh6SQuUrRt9l/Px j5o5otzYrYj05yxJuZrZRvgaS2A+HMVjsnQ4gpORBuPEBDKADlXxNcZy3l+74qxP7Ce/ L0lrHqnt3Eb7BMR5hzSf8CAIbXBipBODQ/Gd1mixGRJ4KDIK4eV/ECgDP0B/Nm12cykb eLpA==
X-Gm-Message-State: AN3rC/4Sj6aMkSe7ZfNpD98GJcV6jXLZNT5ek6dEepMoKiHNM8wqnD9Z 4KzCj50WJ2Ed9nAa7GJSyH97Y31UqtcdtC4=
X-Received: by 10.129.125.193 with SMTP id y184mr4424869ywc.120.1493038658689; Mon, 24 Apr 2017 05:57:38 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.129.113.7 with HTTP; Mon, 24 Apr 2017 05:56:58 -0700 (PDT)
From: Eric Rescorla <ekr@rtfm.com>
Date: Mon, 24 Apr 2017 05:56:58 -0700
Message-ID: <CABcZeBP_0d+14_3SQ3sk+knytxpo4yxq5eYwGn++GC8H9BpUfw@mail.gmail.com>
To: "tls@ietf.org" <tls@ietf.org>
Content-Type: multipart/alternative; boundary="001a11492bfce360c5054de92607"
Archived-At: <https://mailarchive.ietf.org/arch/msg/tls/EndQR7fMQ1_OARTNK_VYibKCzlM>
Subject: [TLS] Issue #964: Shortened HKDF labels
X-BeenThere: tls@ietf.org
X-Mailman-Version: 2.1.22
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: <https://mailarchive.ietf.org/arch/browse/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: Mon, 24 Apr 2017 12:57:47 -0000

https://github.com/tlswg/tls13-spec/issues/964

Hi folks,

It was raised during the WG meeting in Chicago that some of the labels have
gotten a bit long and after checking it seems like many of them push us into
two hash blocks, which seems silly.

Here is a proposed set of new labels, which, while slightly less clear, all
fit
into the 18 byte limit which Ilari (and I agree) says is what we have.

external binder # was external psk binder key
resumption binder # was resumption psk binder key
client e. traffic # was client early traffic
e. exporter master # was early exporter master secret
client hs traffic # was client handshake traffic secret
server hs traffic # was server handshake traffic secret
client app traffic # was client application traffic secret
server app traffic # was server application traffic secret
exporter master # was exporter master secret
resumption # was resumption master secret
key # was key
iv # was iv
finished # was finished
traffic key update  # was application traffic secret
exporter # was exporter

Note that this actually pushes us into multiple hash blocks anyway if we
compute > 1 output block, but I don't believe that ever happens except
for very silly uses of exporters. I would appreciate a double check that
haven't accidentally made one >18 or duplicated or something.

If anyone has strong opinions about these, please let me know by Wednesday.
Otherwise, I'll merge them into the draft.

-Ekr