[apps-discuss] draft-pbryan-zyp-json-pointer: name syntax for non-ASCII

Julian Reschke <julian.reschke@gmx.de> Mon, 21 November 2011 14:13 UTC

Return-Path: <julian.reschke@gmx.de>
X-Original-To: apps-discuss@ietfa.amsl.com
Delivered-To: apps-discuss@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id C21A321F8B66 for <apps-discuss@ietfa.amsl.com>; Mon, 21 Nov 2011 06:13:14 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -104.133
X-Spam-Level:
X-Spam-Status: No, score=-104.133 tagged_above=-999 required=5 tests=[AWL=-1.534, 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 DkzqTG3kUF17 for <apps-discuss@ietfa.amsl.com>; Mon, 21 Nov 2011 06:13:10 -0800 (PST)
Received: from mailout-de.gmx.net (mailout-de.gmx.net [213.165.64.22]) by ietfa.amsl.com (Postfix) with SMTP id 0B88C21F8B40 for <apps-discuss@ietf.org>; Mon, 21 Nov 2011 06:13:08 -0800 (PST)
Received: (qmail invoked by alias); 21 Nov 2011 14:13:07 -0000
Received: from mail.greenbytes.de (EHLO [192.168.1.140]) [217.91.35.233] by mail.gmx.net (mp070) with SMTP; 21 Nov 2011 15:13:07 +0100
X-Authenticated: #1915285
X-Provags-ID: V01U2FsdGVkX18i/GwELvkinPWmo5UIpa+ydCdVgEbv1EUwzB5CRt 1Iv6BFw5yc/GB7
Message-ID: <4ECA5C66.1040305@gmx.de>
Date: Mon, 21 Nov 2011 15:12:54 +0100
From: Julian Reschke <julian.reschke@gmx.de>
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0) Gecko/20111105 Thunderbird/8.0
MIME-Version: 1.0
To: IETF Apps Discuss <apps-discuss@ietf.org>
Content-Type: text/plain; charset="ISO-8859-1"; format="flowed"
Content-Transfer-Encoding: 7bit
X-Y-GMX-Trusted: 0
Cc: draft-pbryan-zyp-json-pointer@tools.ietf.org
Subject: [apps-discuss] draft-pbryan-zyp-json-pointer: name syntax for non-ASCII
X-BeenThere: apps-discuss@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: General discussion of application-layer protocols <apps-discuss.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/apps-discuss>
List-Post: <mailto:apps-discuss@ietf.org>
List-Help: <mailto:apps-discuss-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 21 Nov 2011 14:13:14 -0000

Hi there.

In 
<https://tools.ietf.org/html/draft-pbryan-zyp-json-pointer-02#section-3> 
we have:

    A JSON Pointer is a sequence of zero or more reference tokens, each
    prefixed by a "/" (%x2F) character.  Each reference token is a
    sequence of unreserved and/or percent-encoded characters, per
    [RFC3986].

    json-pointer = *( "/" reference-token )
    reference-token = *( unreserved / pct-encoded )

    Characters in reference tokens that are not unreserved SHOULD be
    percent-encoded, per [RFC3986], and MUST be so encoded as "%2F" if
    the character is "/" to avoid being interpreted as a reference token
    prefix.

    It is an error condition if a JSON Pointer does not conform to this
    syntax.

This doesn't seem to consider the case where the reference token 
contains non-ASCII characters, which can happen with JSON.

There seem to be to obvious ways to address this:

(1) Allow non-ASCII characters in the pointer (which would make the 
pointers be more IRI-like, and I think that's consistent with XPath), or

(2) Require UTF-8 encoding.

I believe (1) makes more sense here.

Best regards, Julian