Hi This statement in my code connection.setCredentials(creds); is generating the following error. Any suggestion to debug it is appreciated -
Failure to initialize mapper Mar 5, 2004 1:25:13 PM com.sun.xml.registry.uddi.UDDIMapper initJAXBObjectFactory SEVERE: Exiting unable to initial JAXB context java.lang.SecurityException: class "javax.xml.namespace.NamespaceContext"'s signer information does not match signer information of other classes in the same package at java.lang.ClassLoader.checkCerts(Unknown Source) at java.lang.ClassLoader.defineClass(Unknown Source) at java.security.SecureClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.access$100(Unknown Source) at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClassInternal(Unknown Source) at java.lang.ClassLoader.defineClass0(Native Method) at java.lang.ClassLoader.defineClass(Unknown Source) at java.security.SecureClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.access$100(Unknown Source) at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClassInternal(Unknown Source) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Unknown Source) at com.sun.xml.registry.uddi.bindings_v2.impl.runtime.GrammarInfoFacade.class$(Unknown Source) at com.sun.xml.registry.uddi.bindings_v2.impl.runtime.GrammarInfoFacade.createGrammarInfoFacade(Unknown Source) at com.sun.xml.registry.uddi.bindings_v2.impl.runtime.DefaultJAXBContextImpl.<init>(Unknown Source) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Unknown Source) at com.sun.xml.bind.ContextFactory_1_0_1.createContext(ContextFactory_1_0_1.java:50) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:96) at javax.xml.bind.ContextFinder.searchcontextPath(ContextFinder.java:229) at javax.xml.bind.ContextFinder.find(ContextFinder.java:149) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:281) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:238) at com.sun.xml.registry.uddi.UDDIMapper.initJAXBObjectFactory(Unknown Source) at com.sun.xml.registry.uddi.UDDIMapper.<init>(Unknown Source) at com.sun.xml.registry.uddi.RegistryServiceImpl.<init>(Unknown Source) at com.sun.xml.registry.uddi.ConnectionImpl.<init>(Unknown Source) at com.sun.xml.registry.uddi.ConnectionFactoryImpl.createConnection(Unknown Source) at com.sun.xml.registry.common.ConnectionFactoryImpl.createConnection(Unknown Source) at arithmetic.PublishConcept.makeConnection(PublishConcept.java:94) at arithmetic.PublishConcept.main(PublishConcept.java:52) --------------- linked to ------------------ javax.xml.bind.JAXBException - with linked exception: [java.lang.SecurityException: class "javax.xml.namespace.NamespaceContext"'s signer information does not match signer information of other classes in the same packag e] at com.sun.xml.registry.uddi.bindings_v2.impl.runtime.GrammarInfoFacade.createGrammarInfoFacade(Unknown Source) at com.sun.xml.registry.uddi.bindings_v2.impl.runtime.DefaultJAXBContextImpl.<init>(Unknown Source) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Unknown Source) at com.sun.xml.bind.ContextFactory_1_0_1.createContext(ContextFactory_1_0_1.java:50) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:96) at javax.xml.bind.ContextFinder.searchcontextPath(ContextFinder.java:229) at javax.xml.bind.ContextFinder.find(ContextFinder.java:149) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:281) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:238) at com.sun.xml.registry.uddi.UDDIMapper.initJAXBObjectFactory(Unknown Source) at com.sun.xml.registry.uddi.UDDIMapper.<init>(Unknown Source) at com.sun.xml.registry.uddi.RegistryServiceImpl.<init>(Unknown Source) at com.sun.xml.registry.uddi.ConnectionImpl.<init>(Unknown Source) at com.sun.xml.registry.uddi.ConnectionFactoryImpl.createConnection(Unknown Source) at com.sun.xml.registry.common.ConnectionFactoryImpl.createConnection(Unknown Source) at arithmetic.PublishConcept.makeConnection(PublishConcept.java:94) at arithmetic.PublishConcept.main(PublishConcept.java:52) --------------- linked to ------------------ javax.xml.bind.JAXBException - with linked exception: [javax.xml.bind.JAXBException - with linked exception: [java.lang.SecurityException: class "javax.xml.namespace.NamespaceContext"'s signer information does not match signer information of other classes in the same packag e]] at com.sun.xml.bind.ContextFactory_1_0_1.createContext(ContextFactory_1_0_1.java:56) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:96) at javax.xml.bind.ContextFinder.searchcontextPath(ContextFinder.java:229) at javax.xml.bind.ContextFinder.find(ContextFinder.java:149) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:281) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:238) at com.sun.xml.registry.uddi.UDDIMapper.initJAXBObjectFactory(Unknown Source) at com.sun.xml.registry.uddi.UDDIMapper.<init>(Unknown Source) at com.sun.xml.registry.uddi.RegistryServiceImpl.<init>(Unknown Source) at com.sun.xml.registry.uddi.ConnectionImpl.<init>(Unknown Source) at com.sun.xml.registry.uddi.ConnectionFactoryImpl.createConnection(Unknown Source) at com.sun.xml.registry.common.ConnectionFactoryImpl.createConnection(Unknown Source) at arithmetic.PublishConcept.makeConnection(PublishConcept.java:94) at arithmetic.PublishConcept.main(PublishConcept.java:52) D:\> [ March 05, 2004: Message edited by: Kituz Greenluv ]
-Kituz
[SCJP, SCWCD, SCBCD, SCDJWS, SCEA 1/3]
Robin Mulkers
Greenhorn
Joined: Sep 19, 2002
Posts: 5
posted
0
Hi, you have classes in the package javax.xml.namespace that are spread over different jar files in your classpath. Some of these jar files are signed, some are not or signed by another company. Simply remove the signature from the signed jar files or manage your classpath in order to avoid this situation.
Best regards. Robin
Steve Kritzler
Greenhorn
Joined: Apr 14, 2005
Posts: 9
posted
0
Hello,
I'm getting the same problem running JAXB to "inflate" the contents of an XML file into objects...
I was wondering how one goes about removing the signature from the jar files, or better still, how to look at the signing of the jars to see how they re signed and which are different. Sorry if this too high-level a question for this forum.
Thanks for your help...
Robin Mulkers
Greenhorn
Joined: Sep 19, 2002
Posts: 5
posted
0
Removing a signature from a Jar file like JAXB is easy. Just go to the meta-inf folder, find the Manifest.mf file and remove all the paired lines Name & SHA1-Digest. Save that and update the jar file with the changes. THer might be also other security related certificates in the meta-inf folder that can be removed too.
But pay attention to what you are doing!
Downloaded Java executables from vendors like SUN, BEA or IBM are always legally protected. Check the licence to see exactly what you can do with that software. JAXB in particular comes with an "evaluation purposes only" licence.
If I remember well, there was a conflict within the javax.xml.namespace package where there were classes signed by Sun and unsigned classes.
Maybe just removing the conflicting jar file (xml-namespace.jar or something similar) was solving the problem I had because an implementation of the class in that jar file was existing already somewhere else.