Re: [Json] "suffer fatal runtime exceptions"

R S <sayrer@gmail.com> Thu, 26 September 2013 18:51 UTC

Return-Path: <sayrer@gmail.com>
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 1994A21E8099 for <json@ietfa.amsl.com>; Thu, 26 Sep 2013 11:51:02 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.599
X-Spam-Level:
X-Spam-Status: No, score=-2.599 tagged_above=-999 required=5 tests=[AWL=0.000, BAYES_00=-2.599, HTML_MESSAGE=0.001, NO_RELAYS=-0.001]
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 jPufeGhXDUO0 for <json@ietfa.amsl.com>; Thu, 26 Sep 2013 11:51:01 -0700 (PDT)
Received: from mail-qc0-x230.google.com (mail-qc0-x230.google.com [IPv6:2607:f8b0:400d:c01::230]) by ietfa.amsl.com (Postfix) with ESMTP id 6304921E80A6 for <json@ietf.org>; Thu, 26 Sep 2013 11:50:57 -0700 (PDT)
Received: by mail-qc0-f176.google.com with SMTP id t7so1027609qcv.21 for <json@ietf.org>; Thu, 26 Sep 2013 11:50:56 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=2gWFZQ/95a9IvvvrTy13vB7XLscaLFeijtKHITzg7OU=; b=BI8KQBAnw4NcpxRnJ2KkBBX8rFSRC2adpsPjnG8qC/vBEhKBAOG/+GTMH5ClrJ08wq 98w1XRiU8IRpeJavkFI4iXEMbpWbXdJ9ffxTyp+iGxcYH7oLwlcVjTsDBgbDsfZEk0ag bqybm9SqwejM14SECDgHXThFHw8xnJSvwmPvNQJUEn6iiPMjZ1rG0zQIEb2RKlkHpqyQ n2Y0AK+h33yv9orrPs/Z2qxT5kdSQt8n5gDSUd7vGcM4TY9IE+MgyEaohm6CMgWkv9En nT8ewSPLlK5tyUFWYhrqU8NxjXhNj3ncZxtYqNrHiJ6sKHrrkMLyujSwGtOEI1K/WOxk 0K5A==
MIME-Version: 1.0
X-Received: by 10.49.81.237 with SMTP id d13mr3664991qey.44.1380221456409; Thu, 26 Sep 2013 11:50:56 -0700 (PDT)
Received: by 10.140.86.147 with HTTP; Thu, 26 Sep 2013 11:50:56 -0700 (PDT)
In-Reply-To: <30C5C3AF-2CC7-44FA-A164-74B6F46E1E7F@vpnc.org>
References: <BF7E36B9C495A6468E8EC573603ED9411EF1BB0B@xmb-aln-x11.cisco.com> <CAChr6SyznBktmOLpT-EiZ5Nm_0jZ16M0tOo4aZ_jhSDb=HHDqg@mail.gmail.com> <30C5C3AF-2CC7-44FA-A164-74B6F46E1E7F@vpnc.org>
Date: Thu, 26 Sep 2013 11:50:56 -0700
Message-ID: <CAChr6SzckwXkEpXrfzVS+dauhJiOxv6f=oh5zmQQWKXxb2BRTA@mail.gmail.com>
From: R S <sayrer@gmail.com>
To: Paul Hoffman <paul.hoffman@vpnc.org>
Content-Type: multipart/alternative; boundary="047d7b6d99929eea3e04e74dd900"
Cc: JSON WG <json@ietf.org>
Subject: Re: [Json] "suffer fatal runtime exceptions"
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, 26 Sep 2013 18:51:02 -0000

Leave this part:

However, the ABNF in this specification allows member names and string
values to contain bit sequences which cannot encode Unicode characters, for
example "\uDEAD" (a single unpaired UTF-16 surrogate). Instances of this
have been observed, for example when a library truncates a UTF-16 string
without checking whether the truncation split a surrogate pair.

Remove this part:

The behavior of software which receives JSON texts containing such values
is unpredictable; for example, implementations might return different
values for the length of a string value, or even suffer fatal runtime
exceptions.

- Rob



On Thu, Sep 26, 2013 at 11:38 AM, Paul Hoffman <paul.hoffman@vpnc.org>wrote:

> On Sep 26, 2013, at 10:31 AM, R S <sayrer@gmail.com> wrote:
>
> > I don't think we've seen a JSON implementation "suffer fatal runtime
> exceptions" in the presence of the aforementioned bit sequences. Carsten
> showed the Python 3 print function throwing an exception, but its standard
> JSON module parsed and then stringified them without error.
>
> Suggested wording differences are appreciated.
>
> --Paul Hoffman
> _______________________________________________
> json mailing list
> json@ietf.org
> https://www.ietf.org/mailman/listinfo/json
>