Quantcast

catch content of an encrypted error message

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

catch content of an encrypted error message

Jan Hoeft

Using METRO 2.3 in Netbeans with WS-Security I try to read error messages of an encrypted webservice.

The communication works fine until my payload contains errors. Then the server sends an encrypted error message with the information what went wrong. My client tries to decrypt it and understands that the message got another structure than expected and throws an XMLSignatureException:

javax.xml.crypto.dsig.XMLSignatureException: 
WSS1717: Error occurred while doing digest verification of body/payload

The error message that was send by the server is hidden.

The exception is thrown here in line 146:
http://grepcode.com/file/repo1.maven.org/maven2/org.glassfish.metro/webservices-rt/2.3/com/sun/xml/ws/security/opt/impl/incoming/processor/StreamingPayLoadDigester.java?av=f#146

If I enable the finest logging level, I can read the information that is logged on line 141.

Is ist possible to read the canonicalizedData of the xml stream when I catch the exception?

Thanks
Jan

Loading...