You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by ANTHONY ZIOLKOWSKI <az...@rogers.com> on 2006/05/03 20:35:51 UTC

Axis client logging from web applet causes security error

I have written my first web service. It works fine in all the ways I want except one - running from an applet in a web browser. As far as I can tell from the trace below this is caused by the Axis code accessing the file system to do logging which, of course, isn't allowed cause it's outside the applets sandbox. I did read a post about signing the applet and changing policies for the browser, but other than signing the applet, forcing the user to do anything is out of the question.
 
So how do I access my axis-developed web service from my applet? Is there any way of disabling the logging so it doesn;t play iwth the localfile system?
 
Stack trace:
Exception in thread "AWT-EventQueue-2" java.lang.ExceptionInInitializerError
 at org.apache.commons.discovery.jdk.JDKHooks.<clinit>(JDKHooks.java:75)
 at org.apache.commons.discovery.tools.DiscoverSingleton.find(DiscoverSingleton.java:412)
 at org.apache.commons.discovery.tools.DiscoverSingleton.find(DiscoverSingleton.java:378)
 at org.apache.axis.components.logger.LogFactory$1.run(LogFactory.java:45)
 at java.security.AccessController.doPrivileged(Native Method)
 at org.apache.axis.components.logger.LogFactory.getLogFactory(LogFactory.java:41)
 at org.apache.axis.components.logger.LogFactory.<clinit>(LogFactory.java:33)
 at org.apache.axis.handlers.BasicHandler.<clinit>(BasicHandler.java:43)
 at org.apache.axis.client.Service.getAxisClient(Service.java:104)
 at org.apache.axis.client.Service.<init>(Service.java:113)
 at com.zeesol.bizservice.client.BizService_ServiceLocator.<init>(BizService_ServiceLocator.java:12)
 at com.mazuma.applets.BaseRunner$1.actionPerformed(BaseRunner.java:156)
 at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
 at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
 at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
 at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
 at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
 at java.awt.Component.processMouseEvent(Unknown Source)
 at javax.swing.JComponent.processMouseEvent(Unknown Source)
 at java.awt.Component.processEvent(Unknown Source)
 at java.awt.Container.processEvent(Unknown Source)
 at java.awt.Component.dispatchEventImpl(Unknown Source)
 at java.awt.Container.dispatchEventImpl(Unknown Source)
 at java.awt.Component.dispatchEvent(Unknown Source)
 at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
 at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
 at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
 at java.awt.Container.dispatchEventImpl(Unknown Source)
 at java.awt.Component.dispatchEvent(Unknown Source)
 at java.awt.EventQueue.dispatchEvent(Unknown Source)
 at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
 at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
 at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
 at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
 at java.awt.EventDispatchThread.run(Unknown Source)
Caused by: java.security.AccessControlException: access denied (java.lang.RuntimePermission createClassLoader)
 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.checkCreateClassLoader(Unknown Source)
 at java.lang.ClassLoader.<init>(Unknown Source)
 at org.apache.commons.discovery.jdk.PsuedoSystemClassLoader.<init>(PsuedoSystemClassLoader.java:73)
 at org.apache.commons.discovery.jdk.JDK12Hooks.findSystemClassLoader(JDK12Hooks.java:215)
 at org.apache.commons.discovery.jdk.JDK12Hooks.<clinit>(JDK12Hooks.java:73)
 ... 35 more