You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Paul Bonser (JIRA)" <ji...@apache.org> on 2010/04/22 04:05:49 UTC

[jira] Created: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

Keys and document IDs are improperly escaped in document list
-------------------------------------------------------------

                 Key: COUCHDB-748
                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
             Project: CouchDB
          Issue Type: Bug
          Components: Futon
            Reporter: Paul Bonser
            Priority: Minor


In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.

The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Attachment:     (was: escape_id.patch)

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Attachment:     (was: escape_id.patch)

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Attachment: escape_id.patch

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch, escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Attachment:     (was: escape_id.patch)

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Attachment: escape_id.patch

Use the html() function instead of the text() function, and escape the ID.

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Description: 
In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.

Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.

The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

  was:
In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.

The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.


> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch, escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

Posted by "Jan Lehnardt (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-748?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12879005#action_12879005 ] 

Jan Lehnardt commented on COUCHDB-748:
--------------------------------------

Patch no longer applies cleanly to trunk. Can you update it?

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Chris Anderson closed COUCHDB-748.
----------------------------------

    Resolution: Fixed

thanks. applied in r957622

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Attachment:     (was: escape_id.patch)

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Attachment: escape_id.patch

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Attachment: escape_id.patch

Updated to patch latest trunk.

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-748) Keys and document IDs are improperly escaped in document list

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

Paul Bonser updated COUCHDB-748:
--------------------------------

    Attachment: escape_id.patch

Didn't need to change the .text lines, and $.couch.encodeDocId takes care of escaping for the URL

> Keys and document IDs are improperly escaped in document list
> -------------------------------------------------------------
>
>                 Key: COUCHDB-748
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-748
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Futon
>            Reporter: Paul Bonser
>            Priority: Minor
>         Attachments: escape_id.patch
>
>
> In the Futon document list, as generated by $.futon.CouchDatabasePage.updateDocumentListing, "<", ">", and "&" are double-encoded for row keys and left unencoded for document IDs.
> Also, Firefox (maybe other browsers) seems to get confused when there are single-quotes inside a URL, so it seems they need to be escaped, too.
> The double-encoding is caused by the fact that the jQuery text() function encodes those characters when they were already encoded by $.futon.formatJson, and the lack of encoding is caused by simply using the raw id.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.