Re: [dispatch] [media-types] 3rd WGLC - draft-ietf-dispatch-javascript-mjs - deadline 10th May

Graham Klyne <Graham.Klyne@oerc.ox.ac.uk> Tue, 18 May 2021 10:18 UTC

Return-Path: <Graham.Klyne@oerc.ox.ac.uk>
X-Original-To: dispatch@ietfa.amsl.com
Delivered-To: dispatch@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 941493A1673; Tue, 18 May 2021 03:18:43 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.821
X-Spam-Level:
X-Spam-Status: No, score=-1.821 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, NICE_REPLY_A=-0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_NEUTRAL=0.779, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=messagingengine.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 3TIj0JBg8xN2; Tue, 18 May 2021 03:18:38 -0700 (PDT)
Received: from forward4-smtp.messagingengine.com (forward4-smtp.messagingengine.com [66.111.4.238]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 887E13A1528; Tue, 18 May 2021 03:18:38 -0700 (PDT)
Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailforward.nyi.internal (Postfix) with ESMTP id 7B7CB1940A64; Tue, 18 May 2021 06:18:35 -0400 (EDT)
Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Tue, 18 May 2021 06:18:35 -0400
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=BPWVHuwFi/rht2Rc+kWiCHeTGw9X5VGBw0oKdVqUR HA=; b=e6vxmEgh9FSD/8yqDmLib4nzzuUE0JLSsQuuR5Bp2KotiHArl3N3UyQwe EdrmQlpNU/78iW8n+jay5i0rk6yVmmGkLFpzwu6O51aNU1ZLOHRdnaCzBruGP2WE I+7HL4+eYypex2o4qiYEl+ue+8iUMcyyAiIBD/1locwm7QaqX2H+giTrFcFrHMCj Cb06K45dWLFY5oRGeE+WqOxe5x/R3yZjVGik55C0IjxIE3MzAHQi/jvHe2nAMuyw lB57UgdG9P/l2c7VDEr/pVdnb1WyujUIY7HOnLMr6YaFpeV4qkC6f34GRPKFPUlj WcFdYl0x5kswteeErsmizpQTkvJ3g==
X-ME-Sender: <xms:epSjYLM6SG-UpOCMqLeW8Z4H2dzB44CYiZEh123fTZPdxbVTUo6fTA> <xme:epSjYF_sd-X65tpELnEcb2ueq7qxZbj43NTZ0XXeHcf4G08q6Bx9fdtuwK5CBCuUw jf7eO5bhBYaMSt3SGo>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrvdeijedgvdehucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepuffvfhfhohfkffgfgggjtgfgsehtkeertddtfeejnecuhfhrohhmpefirhgr hhgrmhcumfhlhihnvgcuoefirhgrhhgrmhdrmfhlhihnvgesohgvrhgtrdhogidrrggtrd hukheqnecuggftrfgrthhtvghrnhepvdfhheejkeevtdejkeekhefhvdfhteethedtvdel fffhgfdtfeegveeghfeiieffnecuffhomhgrihhnpehivghtfhdrohhrghdpfiefrdhorh hgpdhgihhthhhusgdrtghomhdpnhgrsggslhgvrdgtohhmnecukfhppeekuddrudejgedr uddvledrvdegnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrh homhepifhrrghhrghmrdfmlhihnhgvsehovghrtgdrohigrdgrtgdruhhk
X-ME-Proxy: <xmx:epSjYKRWYbOyzxzW8u4qtqVoxlEc7yNvm2FX98PAtCFhJ7gSNFF7nA> <xmx:epSjYPunXDCUNqUeVI4QhG_1JhOad7o5qM7_EzAbE4jYJUlL4vbAhw> <xmx:epSjYDfMBpgi3rPbk4kUi_w26yRStWS0V8NZB2vUXenMopyhUniwzw> <xmx:e5SjYK5E6Rcy1ka5MeunGl3VZkb06X5JqBOFYlhvMke-OZq1H2PjBA>
Received: from spare-94.atuin.ninebynine.org (gklyne38.plus.com [81.174.129.24]) by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 18 May 2021 06:18:33 -0400 (EDT)
To: Mathias Bynens <mths=40google.com@dmarc.ietf.org>, Myles Borins <mylesborins@github.com>, media-types@ietf.org
Cc: DISPATCH WG <dispatch@ietf.org>, "Matthew A. Miller" <linuxwolf+ietf@outer-planes.net>, Kirsty P <Kirsty.p@ncsc.gov.uk>
References: <LO2P123MB3599980BA2B5A5ACA59ECF6FD7429@LO2P123MB3599.GBRP123.PROD.OUTLOOK.COM> <LO2P123MB3599BFA8AB75D6A890E97622D7419@LO2P123MB3599.GBRP123.PROD.OUTLOOK.COM> <CADizRgZjLEngAW4AoPWQsgVXK2pmTk76Ctk5jTp84BbyhNPoVw@mail.gmail.com> <CAEisK4+2ch5BoCEatZoNLzOMT3=qZnsFDShRYML51kLdrEpczw@mail.gmail.com> <CADizRgYF39JEFzADdtNSnWsJc7PN1zPvbP-PQLx8Om2AUEDjhg@mail.gmail.com>
From: Graham Klyne <Graham.Klyne@oerc.ox.ac.uk>
Organization: OeRC, Oxford University
Message-ID: <05fa6f4f-ebcb-691c-8a02-69ba7a43c28b@oerc.ox.ac.uk>
Date: Tue, 18 May 2021 11:18:30 +0100
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.10.0
MIME-Version: 1.0
In-Reply-To: <CADizRgYF39JEFzADdtNSnWsJc7PN1zPvbP-PQLx8Om2AUEDjhg@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"; format="flowed"
Content-Language: en-GB
Content-Transfer-Encoding: 8bit
Archived-At: <https://mailarchive.ietf.org/arch/msg/dispatch/UXrD6Ns7H7IuB5jgsZMIuh1nx-o>
Subject: Re: [dispatch] [media-types] 3rd WGLC - draft-ietf-dispatch-javascript-mjs - deadline 10th May
X-BeenThere: dispatch@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: DISPATCH Working Group Mail List <dispatch.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/dispatch>, <mailto:dispatch-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/dispatch/>
List-Post: <mailto:dispatch@ietf.org>
List-Help: <mailto:dispatch-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/dispatch>, <mailto:dispatch-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 18 May 2021 10:18:44 -0000

I'm responding without knowledge of the history of this proposal, but recent 
experience with the node ecosystem leads me to a view that a common mechanism 
for distinguishing javascript modules is a Good Thing.  A couple of concerns 
occur to me:

1. I think that depending on the file extension to make the distinction between 
scrips and modules doesn't really sit well with usage on the Web if they are 
expected to be parsed differently.  I would have thought a different media type 
would be useful too (though it may be late to stop that horse from bolting).


I note the draft is about much more than the .js/.mjs distinction... a couple of 
other thoughts that struck me...


2. I couldn't understand the section on character encoding detection (sect 4.2), 
in particular this paragraph:

[[
        Implementations of this step MUST use these octet sequences to
        determine the character encoding scheme, even if the determined
        scheme is not supported.  If this step determines the character
        encoding scheme, the octet sequence representing the Unicode
        encoding form signature MUST be ignored when decoding the binary
        source text.
]]

I'm probably misunderstanding something here, but it seemed self-contradictory 
to me (if the unicode encoding signature is used to determine the encoding, it 
must be ignored...?)


3. Security considerations for Javascript (or any scripting language on the web) 
is clearly a massive topic, which I don't think a "security considerations" 
section alone can adequately address.  I think many useful points are covered 
there, but I would have liked to also see references to other documents that 
discuss security models for scripting on the web (e.g. 
https://datatracker.ietf.org/doc/html/rfc2046#section-4.5.2, 
https://www.w3.org/Security/wiki/Cross_Site_Attacks, 
https://www.w3.org/TR/CSP2/, etc -- this list isn't intended to be exhaustive or 
even representative - just examples of other work in the area that might be 
cited), or at least a nod to the existence of other work that should be noted.

#g
--


On 17/05/2021 10:21, Mathias Bynens wrote:
> Sharing with media-types@ietf.org <mailto:media-types@ietf.org> as requested. 
> Please review and voice your support or concerns!
> 
> On Tue, Apr 27, 2021 at 7:26 PM Myles Borins <mylesborins@github.com 
> <mailto:mylesborins@github.com>> wrote:
> 
>     Disclaimer: I am one of the authors of the draft.
> 
>     I would like to also express my support for this draft. It imho reflects
>     ecosystem usage, for example there are currently over 6 million files with
>     the .mjs extension on GitHub
>     <https://github.com/search?l=&q=extension%3Amjs&type=code>.
> 
>     The extension is supported in some mimetype collections and DBs, such as
>     that of the python programming language
>     <https://github.com/python/cpython/blob/master/Lib/mimetypes.py#L416>, but
>     still hasn't been adopted by industry standard tools such as apache
>     <http://apache-http-server.18135.x6.nabble.com/Bug-61383-New-mjs-files-should-be-part-of-mime-application-javascript-td5038697.html>.
>     The lack of consistency here makes for poor developer experiences and
>     inconsistent experiences across platforms + tools. This draft being accepted
>     would be an extremely strong signal to let folks know that they can
>     implement support for .mjs.
> 
>     Separate from the new extension that will be supported the updated draft
>     includes a number of additional improvements that reflect the current
>     reality of the web. This includes making "text/javascript" COMMON rather
>     than OBSOLETE and an update to the security considerations.
> 
>     Thank you everyone for your time and considerations regarding this matter.
> 
>     On Tue, Apr 27, 2021 at 10:17 AM Mathias Bynens <mths@google.com
>     <mailto:mths@google.com>> wrote:
> 
>         Disclaimer: I am one of the authors of this draft. Nevertheless, I
>         would like to express my support and speak to the importance of its
>         standardization.
> 
>         The draft supersedes the earlier RFC4329, providing updated
>         definitions to align with what has quickly become implementation
>         reality, both in web browsers as well as other popular JavaScript
>         environments such as Node.js.
> 
>         Thanks,
>         Mathias
> 
>         On Tue, Apr 27, 2021 at 3:49 PM Kirsty P <Kirsty.p@ncsc.gov.uk
>         <mailto:Kirsty.p@ncsc.gov.uk>> wrote:
>          > ________________________________
>          > From: Kirsty P
>          > Sent: 26 April 2021 16:25
>          > To: dispatch@ietf.org <mailto:dispatch@ietf.org> <dispatch@ietf.org
>         <mailto:dispatch@ietf.org>>
>          > Subject: 3rd WGLC - draft-ietf-dispatch-javascript-mjs - deadline
>         10th May
>          >
>          > Hi DISPATCH,
>          >
>          > Summary: draft-ietf-dispatch-javascript-mjs is now ready for its 3rd
>         WGLC (Working Group Last Call). Please send your comments and/or
>         expressions of support to the DISPATCH list.
>          >
>          > Longer: the draft was recently updated to address feedback from a
>         review and from the 2nd WGLC [1]. The authors posted an update to the
>         list with more information [2]. We (DISPATCH chairs) feel like all the
>         comments have been addressed, so it's time for 3rd WGLC.
>          >
>          > We need to hear positive noises and support for this draft from the
>         WG before progressing the -08 draft, so please email to signal your
>         endorsement, even if you have no comments to make. The draft can be
>         found on datatracker here:
>         https://datatracker.ietf.org/doc/draft-ietf-dispatch-javascript-mjs/
>         <https://datatracker.ietf.org/doc/draft-ietf-dispatch-javascript-mjs/>
>          >
>          > WGLC is open for 2 weeks - so will finish close-of-play on Monday
>         10th May.
>          >
>          > Kirsty
>          > (DISPATCH co-chair)
>          >
>          > [1]
>         https://mailarchive.ietf.org/arch/msg/dispatch/MOp48vAf_K4cjoS9XoFgxBUqXg0/
>         <https://mailarchive.ietf.org/arch/msg/dispatch/MOp48vAf_K4cjoS9XoFgxBUqXg0/>
>          > [2]
>         https://mailarchive.ietf.org/arch/msg/dispatch/TmuVIJS6Umh37oOhiIHv-5Mzkis/
>         <https://mailarchive.ietf.org/arch/msg/dispatch/TmuVIJS6Umh37oOhiIHv-5Mzkis/>
>          >
>          >
>          >
>          > This information is exempt under the Freedom of Information Act 2000
>         (FOIA) and may be exempt under other UK information legislation. Refer
>         any FOIA queries to ncscinfoleg@ncsc.gov.uk
>         <mailto:ncscinfoleg@ncsc.gov.uk>. All material is UK Crown Copyright ©
> 
> 
> _______________________________________________
> media-types mailing list
> media-types@ietf.org
> https://www.ietf.org/mailman/listinfo/media-types
> 

-- 
Graham Klyne
mailto:graham.klyne@oerc.ox.ac.uk
Skype/Twitter: @gklyne