Arrays of objects from axis 1.4 are not properly deseralized when applying 
WSS4J on top of Axis 1.4. Note: 
-----------------------------------------------------------------------------------------------------------

                 Key: WSS-120
                 URL: https://issues.apache.org/jira/browse/WSS-120
             Project: WSS4J
          Issue Type: Bug
    Affects Versions: 1.5.3
         Environment: JDK1.6.0_05, eclipse 3.3, axis 1.4, wss4j 1.5.3
            Reporter: José Ferreiro
            Assignee: Ruchith Udayanga Fernando
            Priority: Blocker
             Fix For: 1.5.3


Hello,

I wrote this wsdl which is working fine when using Axis 1.4 for the server and 
the client.
I try to send an object and I receive the same object into an array serveral 
times.
This is working fine with Axis 1.4. The wsdl file follows below.
When I apply the handlers from WSS4J. then the problem arises.
I alradey checked it is not a problem of encryption or decripton. the proof is 
that I may exchange the previous wsdl but only sending an object and receving 
an object.
When I try to send the the response as an array I got the following error.

I need to go to the production phase because I invest a lot of time in trying 
to interoperate with .net in a secure way. Thing that I succeed. 
See blog 
http://magnot.blogspot.com/2008/04/secure-web-services-interoperability.html

I though I did the more difficult achieving interoperability with the JKS and 
PKCS12 but now I am not able to receive the response of arrays whenever I use 
the wss4j.

May you please help me?
I may collaborate in sending you the files or whatever information is necessary!
Thank you in advance.


ERROR.

Error I get at the client (whenever I receive an array of object)
- Verification successful for URI "#id-9135999"
- Verification successful for URI "#SigConf-7859095"
- Exception:
org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which 
is NOT expected, in something it was trying to deserialize.
        at 
org.apache.axis.encoding.ser.SimpleDeserializer.onStartChild(SimpleDeserializer.java:145)
        at 
org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
        at 
org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
        at 
org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
        at org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
        at org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
        at org.apache.axis.client.Call.invoke(Call.java:2467)
        at org.apache.axis.client.Call.invoke(Call.java:2366)
        at org.apache.axis.client.Call.invoke(Call.java:1812)
        at 
org.unece.tir.wss.itdbonlineplus.testscomplex.client.BasicComplexTypeSOAPSoapBindingStub.getBasicComplexType(BasicComplexTypeSOAPSoapBindingStub.java:201)
        at 
org.unece.tir.wss.itdbonlineplus.testscomplex.client.Tester.singleArrayExchange(Tester.java:42)
        at 
org.unece.tir.wss.itdbonlineplus.testscomplex.client.Tester.main(Tester.java:13)
; nested exception is: 
        org.xml.sax.SAXException: SimpleDeserializer encountered a child 
element, which is NOT expected, in something it was trying to deserialize.


WSDL file:



<?xml version="1.0" encoding="utf-8"?>
<!--

  
    Version: 1.0
    Author: Jose Ferreiro
    Last Updated: 01/02/2007
  -->
<wsdl:definitions name="TIR secure Web Services"
   targetNamespace="http://webservices.tir.unece.org/itdbonlineplus"; 
   xmlns:wsa="http://schemas.xmlsoap.org/ws/2003/03/addressing";
   xmlns:apachesoap="http://xml.apache.org/xml-soap"; 
   xmlns:impl="http://webservices.tir.unece.org/itdbonlineplus"; 
   xmlns:intf="http://webservices.tir.unece.org/itdbonlineplus"; 
   xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; 
   xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"; 
   xmlns:xsd="http://www.w3.org/2001/XMLSchema";>
   
  
   <wsdl:types>
      <schema 
         elementFormDefault="qualified" 
         targetNamespace="http://webservices.tir.unece.org/itdbonlineplus"; 
         xmlns="http://www.w3.org/2001/XMLSchema";>
            
           

            <complexType name="ComplexTypeRequest">
            <annotation>
               <documentation>
                    operation request element 
               </documentation>
            </annotation>            
               <sequence>
                  <element name="stringType"  type="xsd:string"    nillable 
="false" minOccurs="1" maxOccurs="1"/> 
                  <element name="integerType" type="xsd:int"       nillable 
="false" minOccurs="1" maxOccurs="1"/> 
                  <element name="doubleType"  type="xsd:double"    nillable 
="false" minOccurs="1" maxOccurs="1"/> 
                  <element name="booleanType" type="xsd:boolean"   nillable 
="false" minOccurs="1" maxOccurs="1"/> 
                  <element name="dataTimeType" type="xsd:dateTime" nillable 
="false" minOccurs="1" maxOccurs="1"/>  
               </sequence>
            </complexType>
 

            
            <!--complexType name="ComplexTypeResponse">
               <annotation>
                  <documentation>
                    operation response element
                  </documentation>
                </annotation>
               <sequence>
                  <element name="stringType"  type="xsd:string"    /> 
                  <element name="integerType" type="xsd:int"       /> 
                  <element name="doubleType"  type="xsd:double"    /> 
                  <element name="booleanType" type="xsd:boolean"   /> 
                  <element name="dataTimeType" type="xsd:dateTime" />  
               </sequence>
            </complexType-->
        
            
            <complexType name="ComplexTypeResponse">
               <annotation>
                  <documentation>
                    operation response element
                  </documentation>
                </annotation>
               <sequence>
                  <element name="resultItem" minOccurs="1" 
maxOccurs="unbounded" type="impl:resultItem">
                  </element>  
               </sequence>
            </complexType>
           
           <complexType name="resultItem">
                        <sequence>
                               <element name="stringType"  type="xsd:string"    
/> 
                               <element name="integerType" type="xsd:int"       
/> 
                               <element name="doubleType"  type="xsd:double"    
/> 
                               <element name="booleanType" type="xsd:boolean"   
/> 
                               <element name="dataTimeType" type="xsd:dateTime" 
/>
                            </sequence>
           </complexType>
           
        
        
         
           <complexType name="ComplexTypeRequestFault">
               <annotation>
                 <documentation>
                    fault element
                 </documentation>
               </annotation>
               <sequence>
                  <element name="errorCode"         type="xsd:int"    /> 
                  <element name="errorDescription"  type="xsd:string" /> 
               </sequence>
            </complexType>
            
          
            <complexType name="ComplexTypeRequestFault2">
               <annotation>
                  <documentation>
                    fault element
                  </documentation>
               </annotation>
               <sequence>
                  <element name="errorCode"         type="xsd:int"    nillable 
="false" minOccurs="1" maxOccurs="1"/> 
                  <element name="errorDescription"  type="xsd:string" nillable= 
"false" minOccurs="1" maxOccurs="1"/> 
               </sequence>
            </complexType>
            
             <element name="ComplexTypeRequest"                  
type="impl:ComplexTypeRequest"    >
                <annotation>
                   <documentation>
                      Container for the categorical subject and natural 
language subject classifications.
                   </documentation> 
                </annotation>
             </element>
              
             <element name="ComplexTypeResponse"                 
type="impl:ComplexTypeResponse"  /> 
             <element name="ComplexTypeRequestFault"  
type="impl:ComplexTypeRequestFault" /> 
             <element name="ComplexTypeRequestFault2" 
type="impl:ComplexTypeRequestFault2" /> 
      </schema>
   </wsdl:types>


 <wsdl:message name="BasicComplexTypeRequest">
    <wsdl:documentation>No arguments; we just want the list</wsdl:documentation>
    <wsdl:part element="impl:ComplexTypeRequest" name="ComplexTypeRequest" /> 
 </wsdl:message>

 <wsdl:message name="BasicComplexTypeResponse">
    <wsdl:part element="impl:ComplexTypeResponse" name="ComplexTypeResponse" /> 
 </wsdl:message>
 
 <wsdl:message name="ComplexTypeRequestFaultMessage">
    <wsdl:documentation>Error message if the request has invalid 
parameters</wsdl:documentation>
    <wsdl:part element="impl:ComplexTypeRequestFault" 
name="ComplexTypeRequestFault" /> 
 </wsdl:message>
 
  <wsdl:message name="ComplexTypeRequestFaultMessage2">
    <wsdl:documentation>Error message if the request has invalid 
parameters</wsdl:documentation>
    <wsdl:part element="impl:ComplexTypeRequestFault2" 
name="ComplexTypeRequestFault2" /> 
 </wsdl:message>
 
 
 
 <wsdl:portType name="BasicComplexPort">
     <wsdl:documentation>
       SERVICE "METHODS"  -  The actual set of operations the 
       service is capable of supporting.  For each we can have a 
       message that goes in and a message that comes out (though
       not always both; see for instance the background search 
       submission / notification operations).
       The "portType" section combines messages into operations.
           This will be like the "methods". Our operations are all
           query-response, so each operation has an input message
           and an output message. 
      </wsdl:documentation>
 
    <wsdl:operation name="getBasicComplexType">
       <wsdl:documentation>This wsdl is just an example to show how complex 
types may be used and nested.</wsdl:documentation> 
       <wsdl:input  name="BasicComplexTypeRequest"          
message="impl:BasicComplexTypeRequest"       /> 
       <wsdl:output name="BasicComplexTypeResponse"         
message="impl:BasicComplexTypeResponse"      /> 
       <wsdl:fault  name="ComplexTypeRequestFaultMessage"   
message="impl:ComplexTypeRequestFaultMessage"/> 
       <wsdl:fault  name="ComplexTypeRequestFaultMessage2"  
message="impl:ComplexTypeRequestFaultMessage2"/> 
    </wsdl:operation>
    
    
 </wsdl:portType>
 
 <wsdl:binding name="BasicComplexTypeSOAPSoapBinding" 
type="impl:BasicComplexPort">
 
    <wsdlsoap:binding style="document" 
transport="http://schemas.xmlsoap.org/soap/http"; /> 
    <wsdl:operation name="getBasicComplexType">
       <wsdlsoap:operation 
soapAction="http://BasicComplexType.wsdl.test/BasicComplexType"; /> 
       
        <wsdl:input name="BasicComplexTypeRequest">
           <wsdlsoap:body use="literal" /> 
        </wsdl:input>
       
        <wsdl:output name="BasicComplexTypeResponse">
          <wsdlsoap:body use="literal" /> 
        </wsdl:output>
        
        <wsdl:fault name="ComplexTypeRequestFaultMessage">
           <wsdlsoap:fault use="literal" />
        </wsdl:fault>  
        
        <wsdl:fault name="ComplexTypeRequestFaultMessage2">
           <wsdlsoap:fault use="literal" />
        </wsdl:fault>  
  
     </wsdl:operation>
     
    
     
 </wsdl:binding>
 
 <wsdl:service name="BasicComplexTypeExampleService">
    <wsdl:port name="Associations1" 
binding="impl:BasicComplexTypeSOAPSoapBinding" >
       <wsdlsoap:address 
location="http://ece-96242:8080/axis/services/Associations1"; /> 
    </wsdl:port>
 </wsdl:service>
 </wsdl:definitions>


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to