axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Marc F." <marc.mus...@gmail.com>
Subject Problem related to ADB when transferring a byte array
Date Thu, 20 Nov 2008 19:00:33 GMT

To demonstrate a possible bug in ADB Webservice I attached a zip file,
containing two aar files, and the source code as well.

There is a very simple service in those two aar files. Actually, this
service does the same thing in both aar files, but one is XML Beans version,
and the other is ADB version.

Basically the service consists on the following steps:
1)In the client side:
1.1)Build a XML content, according to a defined XML Schema.
1.2)Encript this XML content, using symmetric criptography, with AES
(Advanced Encryption Standard) and 128 bits key.
1.3)Send this encrypted XML content to the webservice.
1.4)Receive the result of the webservice call, which is another encrypted
XML content.
1.5)Decrypt the received encrypted XML content.
1.6)Validate the XML content against a defined XML schema.

2)In the server side (webservice side):
2.1)Receive the encrypted XML content sent by the client.
2.2)Decrypt the encrypted XML content.
2.3)Validate the XML content against a defined XML schema.
2.4)Extract a certain string from the XML content.
2.5)Build another XML content, adding the extracted string.
2.6)Encrypt the XML content.
2.7)Sent the encrypted XML content back to the client.

There are two classes that represent the client code:
com.bug.axis2.test.XMLBeansTestClass and com.bug.axis2.test.ADBTestClass.

The problem happens when the ADB version of the webservice is called. Just
run ADBTestClass in order to reproduce it. The problem is related to the
length of the byte array that is being transferred. Sometimes the webservice
receives a byte array with less elements than the expected. Sometimes the
client receives a byte array with less elements than the expected. But there
are times in which eveything works correctly. Please, have a look at the
source code of the com.bug.axis2.helpers.UtilClass, in the
generateRequestXML() method. Read the comments I let in this method, and
comment/uncomment the lines in order to reproduce those situations.

In XML Beans version of the webservice the problem never happens.

The source codes were compiled with Java 5, and the test was done using
Tomcat 5.5.26. But the problem is not related to the environment, neither to
the Java version. The problem is a possible bug in ADB.

Thank you, and sorry my poor English.

http://www.nabble.com/file/p20607870/Axis2BugADB.zip Axis2BugADB.zip 
-- 
View this message in context: http://www.nabble.com/Problem-related-to-ADB-when-transferring-a-byte-array-tp20607870p20607870.html
Sent from the Axis - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Mime
View raw message