Re: [Json] JSON: encodings

"Martin J. Dürst" <duerst@it.aoyama.ac.jp> Thu, 14 November 2013 05:19 UTC

Return-Path: <duerst@it.aoyama.ac.jp>
X-Original-To: json@ietfa.amsl.com
Delivered-To: json@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id EAF2C21E81B1; Wed, 13 Nov 2013 21:19:45 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -103.649
X-Spam-Level:
X-Spam-Status: No, score=-103.649 tagged_above=-999 required=5 tests=[AWL=0.141, BAYES_00=-2.599, HELO_EQ_JP=1.244, HOST_EQ_JP=1.265, MIME_8BIT_HEADER=0.3, RCVD_IN_DNSWL_MED=-4, USER_IN_WHITELIST=-100]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dG2UZOAotZXm; Wed, 13 Nov 2013 21:19:39 -0800 (PST)
Received: from scintmta02.scbb.aoyama.ac.jp (scintmta02.scbb.aoyama.ac.jp [133.2.253.34]) by ietfa.amsl.com (Postfix) with ESMTP id 2A4BB21E81B0; Wed, 13 Nov 2013 21:19:38 -0800 (PST)
Received: from scmse02.scbb.aoyama.ac.jp ([133.2.253.231]) by scintmta02.scbb.aoyama.ac.jp (secret/secret) with SMTP id rAE5JHms021064; Thu, 14 Nov 2013 14:19:17 +0900
Received: from (unknown [133.2.206.134]) by scmse02.scbb.aoyama.ac.jp with smtp id 1aa6_71f5_4eda3790_4cec_11e3_a617_001e6722eec2; Thu, 14 Nov 2013 14:19:16 +0900
Received: from [IPv6:::1] (unknown [133.2.210.1]) by itmail2.it.aoyama.ac.jp (Postfix) with ESMTP id 75CC8BFF5D; Thu, 14 Nov 2013 14:19:16 +0900 (JST)
Message-ID: <52845D45.9020604@it.aoyama.ac.jp>
Date: Thu, 14 Nov 2013 14:19:01 +0900
From: "\"Martin J. Dürst\"" <duerst@it.aoyama.ac.jp>
Organization: Aoyama Gakuin University
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.9) Gecko/20100722 Eudora/3.0.4
MIME-Version: 1.0
To: Julian Reschke <julian.reschke@gmx.de>
References: <CEA92E3C.2CD06%jhildebr@cisco.com> <5283E447.1070707@gmx.de>
In-Reply-To: <5283E447.1070707@gmx.de>
Content-Type: text/plain; charset="UTF-8"; format="flowed"
Content-Transfer-Encoding: 7bit
Cc: IETF Discussion <ietf@ietf.org>, Paul Hoffman <paul.hoffman@vpnc.org>, JSON WG <json@ietf.org>, Henri Sivonen <hsivonen@hsivonen.fi>, "Joe Hildebrand (jhildebr)" <jhildebr@cisco.com>, Anne van Kesteren <annevk@annevk.nl>
Subject: Re: [Json] JSON: encodings
X-BeenThere: json@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: "JavaScript Object Notation \(JSON\) WG mailing list" <json.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/json>, <mailto:json-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/json>
List-Post: <mailto:json@ietf.org>
List-Help: <mailto:json-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/json>, <mailto:json-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 14 Nov 2013 05:19:46 -0000

On 2013/11/14 5:42, Julian Reschke wrote:
> On 2013-11-13 21:38, Joe Hildebrand (jhildebr) wrote:
>> On 11/12/13 8:28 AM, "Paul Hoffman" <paul.hoffman@vpnc.org> wrote:
>>
>>> [[ Adding the JSON WG to this thread ]]
>>>
>>> On Nov 11, 2013, at 10:58 PM, Anne van Kesteren <annevk@annevk.nl>
>>> wrote:
>>>
>>>> Supporting encodings other than UTF-8 in new formats is not good.
>>>>
>>>> Supporting UTF-32 is actively harmful as support for it has been
>>>> removed or is being removed from clients. You ought to actively
>>>> recommend against it.
>>>>
>>>> In general ASCII incompatible encodings have very bad security
>>>> characteristics, the IETF would do well to steer away from them, just
>>>> like the W3C has.
>>
>> Although I hate UTF-32 with the heat of a several moderately-sized stars
>> and completely agree that UTF-8 is the one true path, I don't think we
>> can
>> completely remove UTF-32 from the bis draft. There may be existing
>> conformant JSON documents stored in UTF-32 that would be made unparseable
>> by this change.
>
> +0.5
>
>> What I think we *could* do is put a stronger recommendation for UTF-8 in
>> section 8.1, rather than just saying it's the default.
>
> +10

What about something like:

OLD

    JSON text SHALL be encoded in Unicode.  The default encoding is
    UTF-8.

NEW

    JSON text SHALL be encoded in Unicode.  The default encoding is
    UTF-8.  The vast majority of JSON text is encoded in UTF-8, and
    UTF-8 is the preferred encoding when creating JSON text.  UTF-32
    is not widely supported, and JSON texts encoded in UTF-32 are
    very difficult to find if they exist at all.

Regards,   Martin.