You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Jan Lehnardt (JIRA)" <ji...@apache.org> on 2011/05/16 11:52:47 UTC

[jira] [Created] (COUCHDB-1166) See if the U+2028 character breaks JSONP

See if the U+2028 character breaks JSONP
----------------------------------------

                 Key: COUCHDB-1166
                 URL: https://issues.apache.org/jira/browse/COUCHDB-1166
             Project: CouchDB
          Issue Type: Improvement
            Reporter: Jan Lehnardt
            Priority: Minor


We should see if we need to fix our JSON responses over JSONP according to http://timelessrepo.com/json-isnt-a-javascript-subset

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Resolved] (COUCHDB-1166) See if the U+2028 character breaks JSONP

Posted by "Paul Joseph Davis (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/COUCHDB-1166?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Joseph Davis resolved COUCHDB-1166.
----------------------------------------

    Resolution: Not A Problem

We \u escape all output. Mochijson2 is configurable to output utf8, but we don't expose that options.


Eshell V5.8.1  (abort with ^G)
1> Val = mochijson2:decode(<<"\"\\u2028\"">>).
<<226,128,168>>
2> mochijson2:encode(Val).
[34,"\\u2028",34]
3> 


> See if the U+2028 character breaks JSONP
> ----------------------------------------
>
>                 Key: COUCHDB-1166
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1166
>             Project: CouchDB
>          Issue Type: Improvement
>            Reporter: Jan Lehnardt
>            Priority: Minor
>
> We should see if we need to fix our JSON responses over JSONP according to http://timelessrepo.com/json-isnt-a-javascript-subset

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Assigned] (COUCHDB-1166) See if the U+2028 character breaks JSONP

Posted by "Randall Leeds (Assigned) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/COUCHDB-1166?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Randall Leeds reassigned COUCHDB-1166:
--------------------------------------

    Assignee: Paul Joseph Davis

Assigning to davisp after his last comment.
                
> See if the U+2028 character breaks JSONP
> ----------------------------------------
>
>                 Key: COUCHDB-1166
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1166
>             Project: CouchDB
>          Issue Type: Improvement
>            Reporter: Jan Lehnardt
>            Assignee: Paul Joseph Davis
>            Priority: Minor
>
> We should see if we need to fix our JSON responses over JSONP according to http://timelessrepo.com/json-isnt-a-javascript-subset

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Reopened] (COUCHDB-1166) See if the U+2028 character breaks JSONP

Posted by "Paul Joseph Davis (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/COUCHDB-1166?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Joseph Davis reopened COUCHDB-1166:
----------------------------------------


Whoops, forgot to check ejson. Pretty sure it escapes, but it's better to check.

> See if the U+2028 character breaks JSONP
> ----------------------------------------
>
>                 Key: COUCHDB-1166
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1166
>             Project: CouchDB
>          Issue Type: Improvement
>            Reporter: Jan Lehnardt
>            Priority: Minor
>
> We should see if we need to fix our JSON responses over JSONP according to http://timelessrepo.com/json-isnt-a-javascript-subset

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (COUCHDB-1166) See if the U+2028 character breaks JSONP

Posted by "Paul Joseph Davis (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-1166?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13168047#comment-13168047 ] 

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

Not paying much attention but I think that ejson has an issue here. we should think of a JS or Etap test for this to be safe I think.
                
> See if the U+2028 character breaks JSONP
> ----------------------------------------
>
>                 Key: COUCHDB-1166
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1166
>             Project: CouchDB
>          Issue Type: Improvement
>            Reporter: Jan Lehnardt
>            Assignee: Paul Joseph Davis
>            Priority: Minor
>
> We should see if we need to fix our JSON responses over JSONP according to http://timelessrepo.com/json-isnt-a-javascript-subset

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (COUCHDB-1166) See if the U+2028 character breaks JSONP

Posted by "Paul Joseph Davis (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-1166?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13034036#comment-13034036 ] 

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

Ruh roh.


1> Val = ejson:decode(<<"\"\\u2028\"">>).
<<226,128,168>>
2> ejson:encode(Val).
<<34,226,128,168,34>>

This is from the ejson that's in trunk.

> See if the U+2028 character breaks JSONP
> ----------------------------------------
>
>                 Key: COUCHDB-1166
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1166
>             Project: CouchDB
>          Issue Type: Improvement
>            Reporter: Jan Lehnardt
>            Priority: Minor
>
> We should see if we need to fix our JSON responses over JSONP according to http://timelessrepo.com/json-isnt-a-javascript-subset

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira