You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Julian Reschke (JIRA)" <ji...@apache.org> on 2016/10/06 10:26:20 UTC

[jira] [Commented] (JCR-4027) NPE in JcrRemotingServlet.canHandle() when content-type is missing

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

Julian Reschke commented on JCR-4027:
-------------------------------------

The code currently also does a string prefix match for the content type, which will allow false negatives:

{noformat}
curl -u admin:admin -v --header "Content-Type: multipart/form-datay" --referer http://localhost:8080 -X POST http://localhost:8080/server/default/jcr%3aroot/
{noformat}

> NPE in JcrRemotingServlet.canHandle() when content-type is missing
> ------------------------------------------------------------------
>
>                 Key: JCR-4027
>                 URL: https://issues.apache.org/jira/browse/JCR-4027
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-webdav
>    Affects Versions: 2.4.6, 2.6.6, 2.8.2, 2.12.4, 2.10.4, 2.13.3
>            Reporter: Julian Reschke
>            Assignee: Julian Reschke
>            Priority: Minor
>
> {noformat}
> java.lang.NullPointerException
>         at org.apache.jackrabbit.server.remoting.davex.JcrRemotingServlet.canHandle(JcrRemotingServlet.java:482)
>         at org.apache.jackrabbit.server.remoting.davex.JcrRemotingServlet.doPost(JcrRemotingServlet.java:412)
>         at org.apache.jackrabbit.webdav.server.AbstractWebdavServlet.execute(AbstractWebdavServlet.java:354)
>         at org.apache.jackrabbit.webdav.server.AbstractWebdavServlet.service(AbstractWebdavServlet.java:291)
> {noformat}
> Can be tested with jackrabbit-standalone on port 8080 with:
> {noformat}
> curl -u admin:admin -v --header "Content-Type:" --referer http://localhost:8080 -X POST http://localhost:8080/server/default/jcr%3aroot/
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)