Hi, Class(es) referenced by Proxy at compile time, are out of synch with class(es) the JVM is attempting to load at runtime.
Here is a scenario that can cause the VerifyError. I'm not an expert on this by any means. But we were running into this at my shop. Scenario - You own and modify package A, which uses public constructors, methods for classes in package B. Package A is compiled and a jar created. At compile time, package A must have access to package B, in order to compile successfully. The class path used by the compiler finds package B, and the methods in Package A are compiled into byte code. The important point here is that the generated bytecode is sensitive to the details of the referenced constructors and methods, in terms of the class hierarchy, the types of objects that are used as parameters for the constructors and methods, etc. At runtime, as the JVM is attempting to run package A, it tries to load the referenced package B classes. (Perhaps the runtime classpath finds a package B jar that is out of synch with the B classes available to the compiler per the compiler's classpath when Package A was compiled?) As it loads them it does some verifying. It checks to see that the Package B object types used in the signatures of the referenced constructors and methods are the same as the object types at compile time. It also apparently is sensitive to the superclass hierarchy, and can complain about the fact that Package B class X is now 3 subclasses down from the class Object, when it used to be something other than 3. See http://java.sun.com/docs/books/jls/second_edition/html/binaryComp.doc.html for an in-depth discussion of the kinds of changes to java code that can cause verify errors. Hope this helps. This can be a tough problem to resolve. -----Original Message----- From: Sreedhar Gupta [mailto:[EMAIL PROTECTED]] Sent: Monday, May 13, 2002 5:04 AM To: [EMAIL PROTECTED] Cc: Sreedhar Gupta Subject: Run Time Exception in log4j when using with xmlsec ... Hi, I am writing a sample application to sign and verify the SOAP messages with 3 Signer, Verifier and Proxy. 1. Signer is a class with one public Sign method which takes the SOAP message as String, sign it and send. 2. Verifier will do it in reverse. 3. Proxy is a main program which creates a SOAP message (Hard coded)in String format, a. calls Sign method of Signer. b. The Sign method signs the SOAP message and give it back to Proxy component. c. The Proxy component then passes the Signed SOAP message to Verifier to verify. When i compile all the files, compiling with out any error. But when i run the Proxy program (main controller program), i am getting the following error: Exception in thread "main" java.lang.VerifyError: (class: org/apache/log4j/LogManager, method: <clin it> signature: ()V) Incompatible argument to function at org.apache.log4j.xml.DOMConfigurator.configure(DOMConfigurator.java:542) at org.apache.xml.security.Init.init(Unknown Source) at org.apache.xml.security.Init.<clinit>(Unknown Source) at org.apache.xml.security.signature.XMLSignature.<clinit>(Unknown Source) at amro.security.SOAPSigner.SignEnvelope(SOAPSigner.java:80) at amro.security.SecurityProxy.Sign(SecurityProxy.java:99) at amro.security.SecurityProxy.main(SecurityProxy.java:201) ********************************************************************* Disclaimer: The information in this e-mail and any attachments is confidential / privileged. It is intended solely for the addressee or addressees. If you are not the addressee indicated in this message, you may not copy or deliver this message to anyone. In such case, you should destroy this message and kindly notify the sender by reply email. Please advise immediately if you or your employer does not consent to Internet email for messages of this kind. ********************************************************************* -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> __________________________________________________________________ This information is intended only for the use of the addressee(s) and may contain privileged, confidential or proprietary information. If you are not the intended recipient, or the employee or agent responsible for delivering the message to the intended recipient, you are hereby notified that any dissemination, distribution, displaying, copying, or use of this information is strictly prohibited. If you have received this communication in error, please notify us immediately at [EMAIL PROTECTED] or by telephone at (800) 533-0472, and return the information to the sender with all copies deleted and destroyed. Thank you. -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>