Re: Comments on draft-ietf-httpbis-encryption-encoding-04

Martin Thomson <> Sat, 12 November 2016 07:01 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id B18CA1299BD for <>; Fri, 11 Nov 2016 23:01:05 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -8.498
X-Spam-Status: No, score=-8.498 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.001, RCVD_IN_DNSWL_HI=-5, RP_MATCHES_RCVD=-1.497, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (2048-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id 06DJ3eEPA1Mn for <>; Fri, 11 Nov 2016 23:01:04 -0800 (PST)
Received: from ( []) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id A87921299B8 for <>; Fri, 11 Nov 2016 23:01:04 -0800 (PST)
Received: from lists by with local (Exim 4.80) (envelope-from <>) id 1c5SFo-0000Kc-Gs for; Sat, 12 Nov 2016 06:57:32 +0000
Resent-Date: Sat, 12 Nov 2016 06:57:32 +0000
Resent-Message-Id: <>
Received: from ([]) by with esmtps (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from <>) id 1c5SFi-0000JG-2h for; Sat, 12 Nov 2016 06:57:26 +0000
Received: from ([]) by with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from <>) id 1c5SFc-0007Ij-8m for; Sat, 12 Nov 2016 06:57:20 +0000
Received: by with SMTP id w33so21886810qtc.3 for <>; Fri, 11 Nov 2016 22:56:59 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=QK57IrPwQ37Mmy3/r5NbVAwOZ6MfGwx6MJU1Oh6d5Dw=; b=V2aQrzlWOmIYF7M3QHvAEOj2voFgaTAEZlz1o2DGXqbvM7USCI37oSkvy/Y0gCSMWu hQBd/p5YpoKbm4Jer1yG9RG16D/PWizYQzV2+hJzF103qD+QMZb6id/rlnK9tDs8bFNm TewYbwFQPii8IHczo33xYmkv/ELC4dYeaCdtJ8mmCe0OiXH+TSu6zR9yCLMD01AN/j+L iITRAdv8UcSyu2WrEVvDOL7QgL//DUcsKnAZSfsidm1V6hIMSkupGk0M3T4apUFdQePC aL5MBGPUI4GOczEchdR+Rq4rLdC9W0FAt3J2hZUTnmvbSWZbDMTNYioyrroCxdNxwTRp NSog==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=QK57IrPwQ37Mmy3/r5NbVAwOZ6MfGwx6MJU1Oh6d5Dw=; b=G347MI5cv6mo5sxjgtxmtoZ0TDNYWQ0UUDkOBdeDKZ79Cq/lfkszm3r5/GD7qaMqRV MDcdWR4BlrNHTL0YQdOblrZl/exXfYrV1IK6c4MPiulNSixD4wDmAbALIEIWsZMG6quy zK3c7KOFkvM3Ioxc68b/OrRp6zuDCInXiH9/wTqxXcBIkddD3hAKovPIK+rU62XaWGma wWJb3fcAAzCPpsuu2/r9FNmlj1mTrJsdihbANzhOwoNhA/ad3JfXk6Br0+SwVxPd3iHW 4sZMmQ289Rzng6DdysZxTsrIENrsI2KcPfWcMqOeWVR5uORSvQZdR3YzUZ/ZNXvaeHBu SiUg==
X-Gm-Message-State: ABUngvcfWuT2NjyKSIOkD3zd4KShaQoqgHuXHjnkQU6IdvBhsnAfST3Pd9By7ke1CcywUg0sICiSbWvQpN3JGQ==
X-Received: by with SMTP id v23mr5795731qtb.143.1478933814205; Fri, 11 Nov 2016 22:56:54 -0800 (PST)
MIME-Version: 1.0
Received: by with HTTP; Fri, 11 Nov 2016 22:56:53 -0800 (PST)
In-Reply-To: <>
References: <>
From: Martin Thomson <>
Date: Sat, 12 Nov 2016 15:56:53 +0900
Message-ID: <>
To: Eric Rescorla <>
Cc: HTTP Working Group <>
Content-Type: text/plain; charset=UTF-8
Received-SPF: pass client-ip=;;
X-W3C-Hub-Spam-Status: No, score=-6.4
X-W3C-Hub-Spam-Report: AWL=0.347, 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, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001, W3C_AA=-1, W3C_DB=-1, W3C_IRA=-1, W3C_WL=-1
X-W3C-Scan-Sig: 1c5SFc-0007Ij-8m 939822ee0f175de7b387b6f4c5bba46a
Subject: Re: Comments on draft-ietf-httpbis-encryption-encoding-04
Archived-At: <>
X-Mailing-List: <> archive/latest/32867
Precedence: list
List-Id: <>
List-Help: <>
List-Post: <>
List-Unsubscribe: <>

On 12 November 2016 at 15:30, Eric Rescorla <> wrote:
> S 2.1.
>   The "rs" or record size parameter contains an unsigned 32-bit
>   integer in network byte order that describes the record size in
>   octets.  Note that it is therefore impossible to exceed the
>   2^36-31 limit on plaintext input to AEAD_AES_128_GCM.  Values
>   smaller than 3 are invalid.
> I don't believe that this is correct, because the limit is on the
> total number of bytes with the same key, not on the total number
> of bytes with one nonce.

This is just P_MAX from RFC 5116.

> S 2.2.
>    Why are you using the terminal 0x00 here? I don't see anywhere
>    else you HMAC on cek_info without it.

I like null-terminating my context strings.

> S 3.
> This whole Crypto-Key thing seems like a menace. As has been noted,
> it's a terrible idea to provide Crypto-Key and encrypted data
> for the same key in the same HTTP message, but that's the only
> thing you see to support:
>    The value or values provided in the Crypto-Key header field is valid
>    only for the current HTTP message unless additional information
>    indicates a greater scope.
> Do we have a concrete use case for Crypto-Key? If not, I would remove
> it. If so, I would consider writing a different spec.

Maybe we can discuss this in the meeting, I don't have any objection
to this.  I like deleting code.


These seem sensible.  I'll do what I can to sort them out when I get some time.