couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paul Joseph Davis (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (COUCHDB-1624) CouchDB shouldn't accept or serve JSON with control-characters
Date Fri, 07 Dec 2012 21:49:21 GMT

    [ https://issues.apache.org/jira/browse/COUCHDB-1624?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13526809#comment-13526809
] 

Paul Joseph Davis commented on COUCHDB-1624:
--------------------------------------------

[~breun] So the file you posted is valid UTF-8 but after having enough issues poking around
I want to ask if you can double check that you didn't run it through an editor that "fixed"
the problem for you.

That, said, there are two byte sequences in your file 0xC293 and a 0xC294 that are valid UTF-8.
While the JSON spec disallows a small number of bare characters in strings, these aren't in
that set and thus should be expected to roundtrip just fine through CouchDB.
                
> CouchDB shouldn't accept or serve JSON with control-characters
> --------------------------------------------------------------
>
>                 Key: COUCHDB-1624
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1624
>             Project: CouchDB
>          Issue Type: Bug
>    Affects Versions: 1.2
>            Reporter: Nils Breunese
>         Attachments: 10571721.json
>
>
> According to http://www.json.org/ control-characters are not valid characters in JSON.
Due to a character encoding bug one of our applications was sending JSON with control-characters
to CouchDB. CouchDB happily accepts this (invalid) JSON and also serves it, but then we started
getting problems in a client that uses the Svenson JSON library which (correctly) complains
about invalid characters in the JSON served by CouchDB.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message