cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joanne Kubischta (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CXF-4255) CXFNonSpringServlet throws IllegalArgumentException when the request URL ends with vertical line "|"
Date Mon, 23 Apr 2012 16:29:34 GMT

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

Joanne Kubischta commented on CXF-4255:
---------------------------------------

Overriding the invoke method of CXFNonSpringJAXRSServlet gives me the desired error handling.

Thanks Sergery for the input.
                
> CXFNonSpringServlet throws IllegalArgumentException when the request URL ends with vertical
line "|"
> ----------------------------------------------------------------------------------------------------
>
>                 Key: CXF-4255
>                 URL: https://issues.apache.org/jira/browse/CXF-4255
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.4.2
>         Environment: Linux+JBoss
> apache-cxf-2.6.0-20120405.jar with the rest of the jars from 2.4.2 release.
>            Reporter: Joanne Kubischta
>            Assignee: Sergey Beryozkin
>
> To reproduce, send a GET or POST request to JAX-RS to get a single user resource using
https://server:8443/api/rest/users/|
> It seems to take other special characters okay, encoded or not. I tried using ExceptionMapper
but has no effect.
> 2012-04-19 16:22:46,695|ERROR|http-0.0.0.0-8443-1:|org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/api/rest/users].[CXFServlet]|
Servlet
> .service() for servlet CXFServlet threw exception
> java.lang.IllegalArgumentException
>         at java.net.URI.create(Unknown Source)
>         at org.apache.cxf.transport.servlet.BaseUrlHelper.getBaseURL(BaseUrlHelper.java:49)
>         at org.apache.cxf.transport.servlet.ServletController.getBaseURL(ServletController.java:73)
>         at org.apache.cxf.transport.servlet.ServletController.updateDestination(ServletController.java:82)
>         at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:153)
>         at org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpringServlet.java:129)
>         at org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(AbstractHTTPServlet.java:187)
>         at org.apache.cxf.transport.servlet.AbstractHTTPServlet.doGet(AbstractHTTPServlet.java:115)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
>         at org.apache.cxf.transport.servlet.AbstractHTTPServlet.service(AbstractHTTPServlet.java:166)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at com.polycom.proximo.api.support.servlet.APIAuthorizationFilter.doFilter(APIAuthorizationFilter.java:59)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
>         at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
>         at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:525)
>         at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
>         at com.polycom.proximo.valve.ProximoErrorReportValve.invoke(ProximoErrorReportValve.java:42)
>         at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
>         at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:543)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
>         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
>         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)
>         at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>         at java.lang.Thread.run(Unknown Source)
> Caused by: java.net.URISyntaxException: Illegal character in path at index 71: https://server:8443/api/rest/users/|
>         at java.net.URI$Parser.fail(Unknown Source)
>         at java.net.URI$Parser.checkChars(Unknown Source)
>         at java.net.URI$Parser.parseHierarchical(Unknown Source)
>         at java.net.URI$Parser.parse(Unknown Source)
>         at java.net.URI.<init>(Unknown Source)

--
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

        

Mime
View raw message