[jboss-user] [JBossWS] - jbossws in applet with jdk 1.5, signed jars, SecurityExcepti

suvigy do-not-reply at jboss.com
Sat Dec 15 19:16:25 EST 2007


Hi All!

 Is it possible to create webservice client in applet with wsconsume? I tried it, but I keep getting error, I signed all the jars as well as the applet:

java.lang.ExceptionInInitializerError
  | 	at org.jboss.ws.core.jaxws.DynamicWrapperGenerator.init(DynamicWrapperGenerator.java:67)
  | 	at org.jboss.ws.core.jaxws.DynamicWrapperGenerator.<init>(DynamicWrapperGenerator.java:62)
  | 	at org.jboss.ws.metadata.builder.jaxws.JAXWSMetaDataBuilder.initWrapperGenerator(JAXWSMetaDataBuilder.java:902)
  | 	at org.jboss.ws.metadata.builder.jaxws.JAXWSMetaDataBuilder.resetMetaDataBuilder(JAXWSMetaDataBuilder.java:908)
  | 	at org.jboss.ws.metadata.builder.jaxws.JAXWSClientMetaDataBuilder.rebuildEndpointMetaData(JAXWSClientMetaDataBuilder.java:273)
  | 	at org.jboss.ws.core.jaxws.spi.ServiceDelegateImpl.getPortInternal(ServiceDelegateImpl.java:262)
  | 	at org.jboss.ws.core.jaxws.spi.ServiceDelegateImpl.getPort(ServiceDelegateImpl.java:193)
  | 	at javax.xml.ws.Service.getPort(Service.java:116)
  | 	at applettest.ws.TestServiceService.getTestServicePort(TestServiceService.java:50)
  | 	at applettest.WSTest.init(WSTest.java:21)
  | 	at sun.applet.AppletPanel.run(Unknown Source)
  | 	at java.lang.Thread.run(Unknown Source)
  | Caused by: java.security.AccessControlException: access denied (java.lang.RuntimePermission accessDeclaredMembers)
  | 	at java.security.AccessControlContext.checkPermission(Unknown Source)
  | 	at java.security.AccessController.checkPermission(Unknown Source)
  | 	at java.lang.SecurityManager.checkPermission(Unknown Source)
  | 	at java.lang.SecurityManager.checkMemberAccess(Unknown Source)
  | 	at java.lang.Class.checkMemberAccess(Unknown Source)
  | 	at java.lang.Class.getDeclaredMethod(Unknown Source)
  | 	at javassist.ClassPool$1.run(ClassPool.java:78)
  | 	at java.security.AccessController.doPrivileged(Native Method)
  | 	at javassist.ClassPool.<clinit>(ClassPool.java:75)
  | 	... 12 more
  | 

It comes from the javassist, doesn't it?

My webservice is a simple Hello World Service:
@WebService
  | public class TestService {
  | 		
  | 		@WebMethod
  | 		public String hello(String name) {
  | 			return "Hello "+name+"!";
  | 		}
  | 
  | 		
  | }
  | 

The applet simply displays the return value in a label. It works fine as a normal application, but not in applet enviroment.
The included jars in the applet (the s beginning means that it is signed):

  |  <applet code="applettest.WSTest.class" archive="jar/sapplettest.jar,  jar/sjboss-jaxws.jar,jar/sjaxb-api.jar, jar/sjaxb-impl.jar, jar/sjaxb-xjc.jar, jar/sjboss-common-client.jar, jar/sjbossws-spi.jar, jar/sjboss-xml-binding.jar, jar/sxercesImpl.jar, jar/sjbossws-client.jar, jar/sjbossws-common.jar, jar/sjboss-jaxrpc, jar/sactivation.jar, jar/sjboss-saaj.jar jar/smail.jar, jar/swsdl4j.jar, jar/sconcurrent.jar, jar/spolicy.jar, jar/scommons-logging.jar, jar/slog4j.jar, jar/sjavassist.jar, jar/sstax-api.jar, jar/sgetopt.jar" width="200" height="200" >

On the client and server side I have jdk1.5.0_5
Jboss 4.2.2Ga
Is it actually possible to create jbossws client for applet? (And how about the jdk 1.6)

Any Idea?

Thnx
 George



View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4113189#4113189

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4113189



More information about the jboss-user mailing list