Re: [websec] Richard Barnes' Yes on draft-ietf-websec-key-pinning-19: (with COMMENT)

Richard Barnes <> Wed, 06 August 2014 20:22 UTC

Return-Path: <>
Received: from localhost ( []) by (Postfix) with ESMTP id 72D8A1A00FC for <>; Wed, 6 Aug 2014 13:22:49 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -1.977
X-Spam-Status: No, score=-1.977 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=unavailable
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id araL0fDwpdkr for <>; Wed, 6 Aug 2014 13:22:43 -0700 (PDT)
Received: from ( []) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 7EFA21A00A7 for <>; Wed, 6 Aug 2014 13:22:42 -0700 (PDT)
Received: by with SMTP id e131so2018945oig.4 for <>; Wed, 06 Aug 2014 13:22:42 -0700 (PDT)
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:date :message-id:subject:from:to:cc:content-type; bh=NSKv3buq5HNj8JpSd4OOq3yJutyvXTBuYuiAu+J6msA=; b=hzh8pDjsDK8/q2UoCuCiOU7wsJKBlrHs3LSFKMih/yvMNU10ZRYEKSWi+2SKquBOUC Rq0CSP+S5ebpD7wfahjqvn4ZABrxiSR4bZwgqRjVVZauDTRPUZt7sScBRZJeg3Ke3ODc ichkGGymrJonh94jm+Eboyxs96hUlYe73XYAl4tbjcfUvXL3By2UcmAelSQpsSrvrAWZ 8TpT2yK7+f4f61J8pgbM5OShgyFe4v6E2GvF3kLbMuWgMJDM3D4lMY26csbGCP166NKM hC6Sb8emchRsxW8FHuzI6dmm7UgI+M9wOVm8tw3d9emBIOuXvGPG7NwiyLVeERzuCX91 WfQQ==
X-Gm-Message-State: ALoCoQmHehg73b58L0Uyt9uTqQnN5cuoVEgXnu+gpcgujKnd6VAEB437F2bCNWzceHPhY3Tu3pzx
MIME-Version: 1.0
X-Received: by with SMTP id q17mr18251040obe.83.1407356561985; Wed, 06 Aug 2014 13:22:41 -0700 (PDT)
Received: by with HTTP; Wed, 6 Aug 2014 13:22:41 -0700 (PDT)
In-Reply-To: <>
References: <> <>
Date: Wed, 06 Aug 2014 16:22:41 -0400
Message-ID: <>
From: Richard Barnes <>
To: Ryan Sleevi <>
Content-Type: multipart/alternative; boundary="e89a8f50221cf426f604fffbbbf7"
Cc:, "<>" <>, The IESG <>, "" <>
Subject: Re: [websec] Richard Barnes' Yes on draft-ietf-websec-key-pinning-19: (with COMMENT)
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Web Application Security Minus Authentication and Transport <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Wed, 06 Aug 2014 20:22:49 -0000

On Wed, Aug 6, 2014 at 4:00 PM, Ryan Sleevi <> wrote:

> On Wed, Aug 6, 2014 at 12:23 PM, Richard Barnes <> wrote:
>> Richard Barnes has entered the following ballot position for
>> draft-ietf-websec-key-pinning-19: Yes
>> When responding, please keep the subject line intact and reply to all
>> email addresses included in the To and CC lines. (Feel free to cut this
>> introductory paragraph, however.)
>> Please refer to
>> for more information about IESG DISCUSS and COMMENT positions.
>> The document, along with other ballot positions, can be found here:
>> ----------------------------------------------------------------------
>> ----------------------------------------------------------------------
>> This is an important document, and overall clearly written.  There are a
>> few points that it would be good to clean up.
>> Introduction: "At least one UA..."
>> FWIW, this is now "At least two UAs..."  Firefox also has a manual pin
>> list as of version 32, currently in Beta.
>> Introduction: "but is possible to pin keys without requiring HSTS"
>> -> "but it is ... and vice versa."
>> Section 2.2.2. "Pinned Hosts SHOULD NOT include..."
>> This applies not just to Pinned Hosts, but to any web host, right?
>> Section 2.3.1. "If a UA receives more than one PKP header field ... only
>> the first PKP-RO header field (if present)"
>> This seems problematic in light of the fact that HTTP recipients are
>> allowed to coalesce the values of multiple header fields.
>> So, for example, if header coalescing were done at a lower layer in the
>> HTTP stack than HPKP, then the pinning code wouldn't be able to
>> distinguish "first" vs. "rest".  On the other hand, maybe this is a use
>> case for using semicolons as separators, since the combined header field
>> would not be valid.  In either case, there's a need for updated text.
> Note, same issue applies to,
> which is the source of this language.
> This appears to be RFC 7230 changing the rules that RFC 2616 set out,
> incompatibly.
> RFC 2616 reads
> "Multiple message-header fields with the same field-name MAY be present in
> a message if and only if the entire field-value for that header field is
> defined as a comma-separated list [i.e., #(values)]"
> In this respect, both this draft and 6797 are compliant with 2616.
> RFC 7230 changes this, incompatibly, to read
> "A sender MUST NOT generate ... unless it's defined as a comma-separated
> list [i.e., #(values)] or the header field is a well-known exception"
> "A recipient MAY combine multiple header fields with the same field name,
> ..., without changing the semantics of the message, by appending each
> subsequent field value to the combined field value in order, separated by
> comma."
> So this is clearly something that 7230 changed from 2616, in a way that
> provides a more liberal interpretation than 2616 allows.
> As addressed earlier on review, because semi-colons are used, if a
> recipient did coalesce, then such a header injection would cause the
> pinning header to be ignored (as invalid), rather than processed. That
> still seems to be acceptable behaviour - e.g. no language change required.

Fair enough.  I hadn't seen your response to Pete.

> Section 2.5. "at least one Pin that does NOT refer to an SPKI in the
> certificate chain"
> I understand the motivation for this, but this doesn't actually force the
> site to have a backup pin -- they can just make up a pin value.  It seems
> like it would be more effective to make the recommendation in Section 4.3
> stronger.

I'm not sure what you see as a viable change. There's no way that a UA can
> confirm a Backup Pin is a valid backup pin, short of requiring the key be
> online and capable of proving itself, which is precisely what having a
> backup pin is to help you avoid.

I guess I'm just saying that forcing the server to present a backup pin is
kind of ineffective, precisely because the UA can't verify that it's
actually a backup pin.  So I'm not sure that having this requirement will
result in much more backup pinning than the recommendations in 4.3,
especially if those recommendations were made stronger or more prominent.

But if the WG thinks the requirement for a backup pin is worth the effort,
it is specified interoperably, so I'm not going to stand in the way.