Re: [Json] The names within an object SHOULD be unique.

Paul Hoffman <paul.hoffman@vpnc.org> Mon, 10 June 2013 17:01 UTC

Return-Path: <paul.hoffman@vpnc.org>
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 869D821F995B for <json@ietfa.amsl.com>; Mon, 10 Jun 2013 10:01:47 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -102.408
X-Spam-Level:
X-Spam-Status: No, score=-102.408 tagged_above=-999 required=5 tests=[AWL=0.191, BAYES_00=-2.599, 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 4E47wuoj9p4c for <json@ietfa.amsl.com>; Mon, 10 Jun 2013 10:01:47 -0700 (PDT)
Received: from hoffman.proper.com (IPv6.Hoffman.Proper.COM [IPv6:2605:8e00:100:41::81]) by ietfa.amsl.com (Postfix) with ESMTP id 2218A21F994C for <json@ietf.org>; Mon, 10 Jun 2013 10:01:45 -0700 (PDT)
Received: from [10.20.30.90] (50-0-66-165.dsl.dynamic.sonic.net [50.0.66.165]) (authenticated bits=0) by hoffman.proper.com (8.14.5/8.14.5) with ESMTP id r5AH1b1F043408 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Mon, 10 Jun 2013 10:01:38 -0700 (MST) (envelope-from paul.hoffman@vpnc.org)
Content-Type: text/plain; charset="us-ascii"
Mime-Version: 1.0 (Mac OS X Mail 6.5 \(1508\))
From: Paul Hoffman <paul.hoffman@vpnc.org>
In-Reply-To: <CA+mHimOBfb1RZhp6rYpL83rnHhrjNTeTeomi4hAv9avsYROE5A@mail.gmail.com>
Date: Mon, 10 Jun 2013 10:01:37 -0700
Content-Transfer-Encoding: quoted-printable
Message-Id: <62F282B7-11AA-44F8-A03B-201F2DAE51B5@vpnc.org>
References: <51AF8479.5080002@crockford.com> <CAK3OfOgtYoPRZ-Gj5G8AnNipDyxYs=6_KD=rQTxKbhDPX6FZNA@mail.gmail.com> <51b1168c.e686440a.5339.5fc4SMTPIN_ADDED_BROKEN@mx.google.com> <CAK3OfOhL3zXHfg9EEDWLXhjLQ1aBvvxikKAiR+nUpDHJaVh+Qg@mail.gmail.com> <51B1B47C.9060009@drees.name> <C86A9758-5BEF-415C-BD17-DC5E757FAA7E@yahoo.com> <51B1E909.2010402@drees.name> <CA+mHimN9=VZu4RRWcnk2F_uMi-+E-LDN2stb1MFNDP+o1R0WSg@mail.gmail.com> <51B1FE6A.80409@drees.name> <CA+mHimNuDwTF96v0PnEvFusCw-KEFT6QF4R9UeZ+8nbETB7oBw@mail.gmail.com> <51B45FAA.4070900@drees.name> <CA+mHimOBfb1RZhp6rYpL83rnHhrjNTeTeomi4hAv9avsYROE5A@mail.gmail.com>
To: Stephen Dolan <stephen.dolan@cl.cam.ac.uk>
X-Mailer: Apple Mail (2.1508)
Cc: json@ietf.org
Subject: Re: [Json] The names within an object SHOULD be unique.
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: Mon, 10 Jun 2013 17:01:48 -0000

<no hat>

On Jun 10, 2013, at 9:55 AM, Stephen Dolan <stephen.dolan@cl.cam.ac.uk> wrote:

> The issue is, that currently there exists a JSON document which one
> RFC-conforming correct JSON parser can say is indistinguishable from
> {a: true}, and another equally RFC-conforming correct JSON parser can
> say is indistinguishable from {a: false}.
> 
> While my example might not have been great, this still seems easily
> exploitable: two parsers parsing a supposedly standard format can be
> tricked into seeing completely different results from the same input.
> Surely it would be better if we could say that one of those parsers
> was not RFC-conforming?

Stated that narrowly, yes. But given your first paragraph, the comparison might be more fully stated as "would it be better if we could says that one of these parsers was not RFC-conforming if making such a statement caused what was a stored valid JSON text now non-valid".

--Paul Hoffman