Re: Wellknown suffix proposal: csp.txt

Mark Nottingham <mnot@mnot.net> Fri, 22 May 2020 02:35 UTC

Return-Path: <mnot@mnot.net>
X-Original-To: wellknown-uri-review@ietfa.amsl.com
Delivered-To: wellknown-uri-review@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 031673A0DD8 for <wellknown-uri-review@ietfa.amsl.com>; Thu, 21 May 2020 19:35:22 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.097
X-Spam-Level:
X-Spam-Status: No, score=-2.097 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_BLOCKED=0.001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=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=mnot.net header.b=NGnlBYh7; dkim=pass (2048-bit key) header.d=messagingengine.com header.b=cJvcbDXc
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 vMnya9KK-S8a for <wellknown-uri-review@ietfa.amsl.com>; Thu, 21 May 2020 19:35:19 -0700 (PDT)
Received: from wout1-smtp.messagingengine.com (wout1-smtp.messagingengine.com [64.147.123.24]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id A0E8D3A0DDB for <wellknown-uri-review@ietf.org>; Thu, 21 May 2020 19:35:19 -0700 (PDT)
Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id B5A10AAC; Thu, 21 May 2020 22:35:18 -0400 (EDT)
Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Thu, 21 May 2020 22:35:18 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mnot.net; h= content-type:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; s=fm2; bh=W 55wZRaWHpMnqs8+oU1deeKULDNfGT0U83x6jUGetOk=; b=NGnlBYh7dEJ86P4iU FeiJFeuf0pR/Al7Lru1RuFrCv8vHuNMkV5QSTORt7dLvU7cSZFuS+LhXVc1KMpH0 Tws8CcDWJl39ROzS79yD/6WHX6iHU0fDQ6ZvSPkubzemUsBYfi8SjGW7CUBKdaYU PycyUuKj1LHp6o3cxUUTyTlBLhkSE3+J2A+D/YL5H99xzGhCkkfr69OZHca0Trbx UcrGUVHvlOvYjftywx+HU6SYhBfnmNHJHpul0pWmElzPZQ79I2vtQ3Bso5ahzViZ LL7w1rJhopypAeHkrL2nVFUtuUtBjGyg7TmwuDqyP1Tgtx7w9LJXjuxRu7JIppBt hyJiw==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=W55wZRaWHpMnqs8+oU1deeKULDNfGT0U83x6jUGet Ok=; b=cJvcbDXcECHnxcpckMvuEm6lhjGg/q7nrgm0RFasMK58+5hvwhcsKkD1z 2FBRT9Ta1t9mrp8v6Q+j+B6r2rHRIHUG9IwGlzFxLOyk5dIRWcAU5tze9KM0yx5t kIrZhlI+WDfn1J94ZCEFMlZ2WXuYz5ZwmsvKpq23bAxuj8rb6Eu/5OypMsfPL+h1 CkRDj/XsgcTRMt9QEqWhP1iejA+FNn2E3MgxyAz8QXCUeRDHzFByjslmmcxTM+46 moMUOkBaaZkHFFWdEatRHt1v14OA8I93+R49cW4/z3V7NZgA40ae1uRvi/A9qlnR nAvEavKCqPqZRrG0RrpXM6EUbQlWw==
X-ME-Sender: <xms:ZTrHXuZsxDpSJpY70pMsBaJqIm43ljYtuM6BnAU4BFna62fkoUDPmg>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedrudduvddgheelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpegtggfuhfgjfffgkfhfvffosehtqh hmtdhhtddvnecuhfhrohhmpeforghrkhcupfhothhtihhnghhhrghmuceomhhnohhtsehm nhhothdrnhgvtheqnecuggftrfgrthhtvghrnhephfdvieetieetvdelvdegfeehgfeihf ettdfgkefhueejheffgeffffejgfelhfeinecuffhomhgrihhnpegvgigrmhhplhgvrdgt ohhmpdhivghtfhdrohhrghdpmhhnohhtrdhnvghtnecukfhppeduudelrddujedrudehke drvdehudenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhm pehmnhhothesmhhnohhtrdhnvght
X-ME-Proxy: <xmx:ZTrHXhYed5_eS1vO2z7oWswENTzd1hBwRFgHuTHfPH-dFMa_Rz0cDg> <xmx:ZTrHXo_rZ7IK91c5eB6Oj8l9OUkBfOpoMwwRuyrOYBcBYjEY2vznjA> <xmx:ZTrHXgoymcJzikB1_unzejszXW9gogAXYtAs2GAZMObYfhyHaBxprg> <xmx:ZjrHXqC0nMj6kuSk32DBHWyVQC8URkgYftzgzUTKd5DeAnwLWDRrvQ>
Received: from macbook-air.mnot.net (119-17-158-251.77119e.mel.static.aussiebb.net [119.17.158.251]) by mail.messagingengine.com (Postfix) with ESMTPA id DDC5530664A6; Thu, 21 May 2020 22:35:16 -0400 (EDT)
Content-Type: text/plain; charset=us-ascii
Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.80.23.2.2\))
Subject: Re: Wellknown suffix proposal: csp.txt
From: Mark Nottingham <mnot@mnot.net>
In-Reply-To: <CAGHJ3LnuX97y+_2at=hLc43HvZzw_LKJRnwADGZB1J4hTksEEA@mail.gmail.com>
Date: Fri, 22 May 2020 12:35:14 +1000
Cc: wellknown-uri-review@ietf.org
Content-Transfer-Encoding: quoted-printable
Message-Id: <92C71FFA-37E8-451B-838B-AB9387CCD23E@mnot.net>
References: <CAGHJ3LnuX97y+_2at=hLc43HvZzw_LKJRnwADGZB1J4hTksEEA@mail.gmail.com>
To: hiburn 8 <daniel@hiburn8.org>
X-Mailer: Apple Mail (2.3608.80.23.2.2)
Archived-At: <https://mailarchive.ietf.org/arch/msg/wellknown-uri-review/zy6WDtRXkHLqLCzzJ6VqZgsondw>
X-BeenThere: wellknown-uri-review@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Well-Known URI review list <wellknown-uri-review.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/wellknown-uri-review>, <mailto:wellknown-uri-review-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/wellknown-uri-review/>
List-Post: <mailto:wellknown-uri-review@ietf.org>
List-Help: <mailto:wellknown-uri-review-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/wellknown-uri-review>, <mailto:wellknown-uri-review-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 22 May 2020 02:35:22 -0000

Hello,

Thanks for the request.

The specification needs to be referred to using a URL, not inline. Generally, it's best to use an RFC or other publication by a standards body, or an organisational page (so that it's more likely to be stable over time).

That said, is this being run through the W3C WebAppSec Working Group? If not, we'd want to check with them before granting the registration; while registering this with a more specific name (e.g., `hiburn8-csp.txt`) wouldn't be a problem, consuming `csp.txt` without buy-in from them would be problematic.

Cheers,


> On 22 May 2020, at 12:25 pm, hiburn 8 <daniel@hiburn8.org> wrote:
> 
> URI suffix:  csp.txt
> 
> Description: 
> The csp.txt suffix should point to a plaintext file. This file describes the required Content-Security-Policy 
> (CSP) directives necessary for other origins to embed its content.
> This would be of use for site administrators to quickly allow content from other origins, without
> being required to first determine the CSP attributes that permit access to the content,
> while maintaining the most restrictive/secure policy. This would also allow site owners to quickly resolve 
> content issues; for example, when an allowed javascript file is modified to require additional content from 
> another domain which is not permitted by CSP.
> 
> Specification:
> There is only one mandatory field for a csp.txt, 'Content-Security-Policy'.
> The value of which is identical to the attributes of a Content-Security-Policy (rfc7762) header.
> Example:
> 
> ------------------This line is not included----------------------------
> Content-Security-Policy: font-src example.com; connect-src example.com
> 
> 
> 
> ------------------This line is not included----------------------------
> 
> 
> 
> 
> Optionally, the 'Path' field indicates the coverage of the 'Content-Security-Policy' field.
> It describes an absolute or relative path where the CSP attributes apply.
> This is useful if there are different content services on different paths, which can then be added to a CSP
> selectively. Likewise, the 'Path' field can show the same information for subdomains. An omitted 'Path' field 
> is identical to 'Path: /'
> 
> 
> Example:
> 
> ------------------This line is not included----------------------------
> Path: /fonts
> Content-Security-Policy: font-src example.com;
> Path: /scripts
> Content-Security-Policy: script-src example.com; connect-src example.com
> Path: iframe.example.com
> Content-Security-Policy: frame-src example
> 
> ------------------This line is not included----------------------------
> 
> 
> 
> Additional Info: The main purpose for proposing this suffix is to tackle the management overhead of 
> CSPs [Which is a pain in my ass], as well as make CSPs generally more secure.
> 
> - Daniel Reece @hbrn8
> 
> 
> 
>   
> 
> _______________________________________________
> wellknown-uri-review mailing list
> wellknown-uri-review@ietf.org
> https://www.ietf.org/mailman/listinfo/wellknown-uri-review

--
Mark Nottingham   https://www.mnot.net/