You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@servicemix.apache.org by "Jeff Peterson (JIRA)" <ji...@apache.org> on 2008/11/16 03:59:07 UTC

[jira] Issue Comment Edited: (SM-820) StringIndexOutOfBoundsException thrown if WS-addressing values are epmty

    [ https://issues.apache.org/activemq/browse/SM-820?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=47415#action_47415 ] 

jpeterson edited comment on SM-820 at 11/15/08 6:58 PM:
------------------------------------------------------------

Attached patch, including jUnit.  It appears that the WSA To header has the same problem so I included a jUnit and patch for that as well.  Patch is based on shared-libraries/trunk.

      was (Author: jpeterson):
    Attached patch, including jUnit.  It appears that the WSA To header has the same problem so I included a jUnit and patch for that as well.
  
> StringIndexOutOfBoundsException thrown if WS-addressing values are epmty
> ------------------------------------------------------------------------
>
>                 Key: SM-820
>                 URL: https://issues.apache.org/activemq/browse/SM-820
>             Project: ServiceMix
>          Issue Type: Bug
>          Components: servicemix-soap
>    Affects Versions: 3.1
>         Environment: W2K Server, JDK1.5_10
>            Reporter: Maxim Y. Tebenev
>         Attachments: SM-820.patch
>
>
> If WS-addressing tag Action is empty, SOAP component throws exception because AddressingHandler.split doesn't check for empty string and uses string.substring improperly.
> Here's the exception stack: 
> java.lang.StringIndexOutOfBoundsException: String index out of range: -1 
>         at java.lang.String.substring(String.java:1768) 
>         at org.apache.servicemix.soap.handlers.addressing.AddressingHandler.split(AddressingHandler. 
> java:154) 
>         at org.apache.servicemix.soap.handlers.addressing.AddressingHandler.onReceive(AddressingHand 
> ler.java:84) 
>         at org.apache.servicemix.soap.SoapHelper.onReceive(SoapHelper.java:111) 
>         at org.apache.servicemix.http.processors.ConsumerProcessor.process(ConsumerProcessor.java:17 
> 7) 
> ...

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