axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 25406] New: - \007 in string causes client exception
Date Wed, 10 Dec 2003 15:45:06 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25406>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25406

\007 in string causes client exception

           Summary: \007 in string causes client exception
           Product: Axis
           Version: 1.1
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Serialization/Deserialization
        AssignedTo: axis-dev@ws.apache.org
        ReportedBy: herold@cotagesoft.com


With a simple web service such as:

import java.rmi.RemoteException;
class BellTest{
  public String bell() throws RemoteException {
    return "\007";
  }
}

Axis does not encode the \007 in the returned string, resulting in a byte 0x07 
in the transmitted SOAP response.  0x07 is not an valid XML character.  
However \007 is a perfectly valid character in a Java string.

If you generate wsdl, then generate client stub, and call this service using 
the stub, the client will get an XML parser exception when deserialzing the 
returned string.  I will attach a stack trace, albeit from my test program 
with different names/line numbers

Mime
View raw message