Re: Issue #356: Form-encode Expect-CT report bodies?

Martin Thomson <martin.thomson@gmail.com> Wed, 07 June 2017 13:43 UTC

Return-Path: <ietf-http-wg-request+bounce-httpbisa-archive-bis2juki=lists.ie@listhub.w3.org>
X-Original-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Delivered-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id EEB6B12EC5D for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Wed, 7 Jun 2017 06:43:50 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.501
X-Spam-Level:
X-Spam-Status: No, score=-6.501 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, RCVD_IN_SORBS_SPAM=0.5, RP_MATCHES_RCVD=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.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 0b8NSfo3NI2U for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Wed, 7 Jun 2017 06:43:49 -0700 (PDT)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) (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 D77BE12EC58 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Wed, 7 Jun 2017 06:43:48 -0700 (PDT)
Received: from lists by frink.w3.org with local (Exim 4.84_2) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1dIbCI-0008Ge-N3 for ietf-http-wg-dist@listhub.w3.org; Wed, 07 Jun 2017 13:40:30 +0000
Resent-Date: Wed, 07 Jun 2017 13:40:30 +0000
Resent-Message-Id: <E1dIbCI-0008Ge-N3@frink.w3.org>
Received: from titan.w3.org ([128.30.52.76]) by frink.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from <martin.thomson@gmail.com>) id 1dIbC9-0008Dz-S7 for ietf-http-wg@listhub.w3.org; Wed, 07 Jun 2017 13:40:21 +0000
Received: from mail-lf0-f45.google.com ([209.85.215.45]) by titan.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from <martin.thomson@gmail.com>) id 1dIbC2-0004dY-6f for ietf-http-wg@w3.org; Wed, 07 Jun 2017 13:40:15 +0000
Received: by mail-lf0-f45.google.com with SMTP id o83so5887745lff.3 for <ietf-http-wg@w3.org>; Wed, 07 Jun 2017 06:39:53 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=AmqFcNC4gxEKkchn1n0LjwNbsDKcEWlW2CnceLBnG0E=; b=AcLS0Bz4eB4gFSOPj9Qoqd1q9o6i89Ix2Dv0W2JbBbBny963/008GD0eZWUPWK0oAd SvIwDkhkyCfJrceXGgfKB12cFMvnwFxgWpOqVZnv6bIx+/NYOBAV4yRtB2GZHPuvQHi+ cv0tZSSmgywoSdS3XiJcYIFLNyyqoXak74U4uHh0g2uvYcW04dSUKWRy/OQSvNgakuHn FEB6hyL/FXepNm8yvDLjrM3o7yeUB9BSky23MhCGyr8FpiNKFhUn6taZA5O1q5QwLrur paOBoyrUmJ8HzkGomrBA/yf46yzHqzPn8C1Uarm6sG00d2AqYs9D/UiatARXL0QtMl1l K/ig==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=AmqFcNC4gxEKkchn1n0LjwNbsDKcEWlW2CnceLBnG0E=; b=lg/FjQUIwJ1jQRwXZbEeJdlt8RAdz0nmfNnYRPxVc4P1bRVtGXqBZiDO8t1Rldkxhz 5PZi0E2oy04c9EEl+qn3o3Dt9vSUwVDtQO3mL4szY3usyNMwvmgfIJIKjegTAmejVA+J m/Ts9uOFVBSC0/7hlRFMs0GvUtU6Bywe8wC51eqlAhT4VwmVXoxmuK59+F+XpNomUNxV CLKGfZM9FiMLWVINjg+/FldWWUGT47vJ/jzWQUhHYokB5177ieF3CDVSEqfzlnlUZSzg c5Fn1+RgwW34gsjgv72C9ZSczNT6mUXjCF0ThVcEP7ihTtcMgmySwdTdsmuNL4043tHm SjXg==
X-Gm-Message-State: AODbwcDUbK9nu8npDBoLT/uaHq71edAaEyJj/KzqLUdG0GmBcDgAms8k DTrpwMKLNlZ5pgLN9nc5HqX5TCn1Tg==
X-Received: by 10.25.148.66 with SMTP id w63mr5830314lfd.169.1496842786988; Wed, 07 Jun 2017 06:39:46 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.46.8.66 with HTTP; Wed, 7 Jun 2017 06:39:46 -0700 (PDT)
In-Reply-To: <CAOdDvNoStrOu=SSZJrKMsQFjG2YVtiLqMdvXP_1PKJ_a+58Mfw@mail.gmail.com>
References: <CAPP_2Sa+6eSAChgp8KrzabPJUkMmiKBhWp1dFhS0zOVnXrenLw@mail.gmail.com> <CAOdDvNoStrOu=SSZJrKMsQFjG2YVtiLqMdvXP_1PKJ_a+58Mfw@mail.gmail.com>
From: Martin Thomson <martin.thomson@gmail.com>
Date: Wed, 07 Jun 2017 15:39:46 +0200
Message-ID: <CABkgnnUVYB1Dqh4efe25bKx=-2iOBXHZg=3fgXjvbRn28b6nuw@mail.gmail.com>
To: Patrick McManus <mcmanus@ducksong.com>
Cc: Emily Stark <estark@google.com>, httpbis <ietf-http-wg@w3.org>
Content-Type: text/plain; charset="UTF-8"
Received-SPF: pass client-ip=209.85.215.45; envelope-from=martin.thomson@gmail.com; helo=mail-lf0-f45.google.com
X-W3C-Hub-Spam-Status: No, score=-6.0
X-W3C-Hub-Spam-Report: AWL=0.041, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, 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: titan.w3.org 1dIbC2-0004dY-6f eae39cbf6f9506e396c34038ba2f565f
X-Original-To: ietf-http-wg@w3.org
Subject: Re: Issue #356: Form-encode Expect-CT report bodies?
Archived-At: <http://www.w3.org/mid/CABkgnnUVYB1Dqh4efe25bKx=-2iOBXHZg=3fgXjvbRn28b6nuw@mail.gmail.com>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/33967
X-Loop: ietf-http-wg@w3.org
Resent-Sender: ietf-http-wg-request@w3.org
Precedence: list
List-Id: <ietf-http-wg.w3.org>
List-Help: <http://www.w3.org/Mail/>
List-Post: <mailto:ietf-http-wg@w3.org>
List-Unsubscribe: <mailto:ietf-http-wg-request@w3.org?subject=unsubscribe>

Can we go to first principles?

The URL is controlled by a site.  Though it doesn't include ambient
authority (I hope), it can still be used to poke at things on the same
side of the firewall as a client.  That would seem to qualify it for
CORS.

On 7 June 2017 at 12:23, Patrick McManus <mcmanus@ducksong.com> wrote:
> my gut reaction: why would an expect-ct report be more subject to cors than
> something like OCSP? (assuming it wasn't driven directly from content)
>
>
> On Tue, Jun 6, 2017 at 6:45 PM, Emily Stark <estark@google.com> wrote:
>>
>> I'm looking for some feedback on
>> https://github.com/httpwg/http-extensions/issues/356.
>>
>> Expect-CT violation reports are currently specified as POST requests with
>> JSON bodies. When implemented in a web browser, such reports should arguably
>> send CORS preflights, because the content type is not CORS-safelisted
>> (https://www.w3.org/TR/cors/#simple-header).
>>
>> But sending CORS preflights for these requests doesn't really make sense
>> from a web browser architecture perspective: CT compliance is checked as
>> part of certificate verification and connection setup, divorced from the
>> context one needs to send a CORS preflight (such as an Origin header). This
>> is not just a theoretical layering issue; implementing preflights for
>> Expect-CT reports in Chrome would be pretty challenging.
>>
>> I only see two options to resolve this, both of which seem bad to me:
>>
>> a) Leave the reporting part of the spec as it currently is, and leave it
>> up to the UA to decide whether further operations such as CORS preflights
>> are needed for sending reports. This would basically leave it to us in
>> Chrome to decide either that Expect-CT reports should not be subject to CORS
>> restrictions, or that we should not ship reporting. (I'm uncomfortable with
>> this option because it somewhat jeopardizes the only active implementation
>> effort that I know of.)
>>
>> b) The disgusting option: disguise Expect-CT reports as form submissions,
>> which are not subject to CORS preflighting. This would mean the report body
>> is sent as hostname=blah&port=443&... or we could even just send
>> expect-ct-report=<stringified JSON blob>.
>>
>> Thanks,
>> Emily
>
>