You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by rnewson <gi...@git.apache.org> on 2015/09/22 00:40:48 UTC

[GitHub] couchdb-chttpd pull request: Reject database names with path segme...

GitHub user rnewson opened a pull request:

    https://github.com/apache/couchdb-chttpd/pull/75

    Reject database names with path segments over 128 characters

    COUCHDB-2821

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/cloudant/couchdb-chttpd 2821-dbname-length

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/couchdb-chttpd/pull/75.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #75
    
----
commit 8fcf4ba517f9fd1b9ec5c0665f88e7a81d45b391
Author: Robert Newson <rn...@apache.org>
Date:   2015-09-21T22:40:11Z

    Reject database names with path segments over 128 characters
    
    COUCHDB-2821

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-chttpd pull request: Reject database names with path segme...

Posted by eiri <gi...@git.apache.org>.
Github user eiri commented on a diff in the pull request:

    https://github.com/apache/couchdb-chttpd/pull/75#discussion_r40036522
  
    --- Diff: src/chttpd.erl ---
    @@ -820,6 +820,10 @@ error_info({error, {illegal_database_name, Name}}) ->
         {400, <<"illegal_database_name">>, Message};
     error_info({_DocID,{illegal_docid,DocID}}) ->
         {400, <<"illegal_docid">>,DocID};
    +error_info({error, {database_name_too_long, DbName}}) ->
    +    {400, database_name_too_long,
    --- End diff --
    
    Is the second tuple's element is intentionally an atom? It seems to be a binary at the rest of the responses.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-chttpd pull request: Reject database names with path segme...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the pull request:

    https://github.com/apache/couchdb-chttpd/pull/75#issuecomment-142200536
  
    (there is something really wrong with couch_log)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-chttpd pull request: Reject database names with path segme...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on a diff in the pull request:

    https://github.com/apache/couchdb-chttpd/pull/75#discussion_r40057952
  
    --- Diff: src/chttpd.erl ---
    @@ -820,6 +820,10 @@ error_info({error, {illegal_database_name, Name}}) ->
         {400, <<"illegal_database_name">>, Message};
     error_info({_DocID,{illegal_docid,DocID}}) ->
         {400, <<"illegal_docid">>,DocID};
    +error_info({error, {database_name_too_long, DbName}}) ->
    +    {400, database_name_too_long,
    --- End diff --
    
    Suddenly, atoms here works as expected. Not sure why we use binaries for else.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-chttpd pull request: Reject database names with path segme...

Posted by rnewson <gi...@git.apache.org>.
Github user rnewson commented on a diff in the pull request:

    https://github.com/apache/couchdb-chttpd/pull/75#discussion_r40067596
  
    --- Diff: src/chttpd.erl ---
    @@ -820,6 +820,10 @@ error_info({error, {illegal_database_name, Name}}) ->
         {400, <<"illegal_database_name">>, Message};
     error_info({_DocID,{illegal_docid,DocID}}) ->
         {400, <<"illegal_docid">>,DocID};
    +error_info({error, {database_name_too_long, DbName}}) ->
    +    {400, database_name_too_long,
    --- End diff --
    
    I can change to a binary, old habits.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-chttpd pull request: Reject database names with path segme...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the pull request:

    https://github.com/apache/couchdb-chttpd/pull/75#issuecomment-142200459
  
    +1


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-chttpd pull request: Reject database names with path segme...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/couchdb-chttpd/pull/75


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---