You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Luis Rivera <lu...@hotmail.com> on 2005/08/03 01:12:30 UTC

RE: [jira] Resolved: (AXIS-2145) Axis Client crashes the applet unless new permi

Thanks Dims,

This is great news. I will test it as soon as I make sure I found the right 
buld (I think I had found it here 
http://cvs.apache.org/builds/jakarta-commons/nightly/commons-discovery/). I 
assume is the one dated 08/02/2005 right?

If this works it will save me a lot of time. I had actualy started replacing 
the AxisProperties and Engine classes with a version that didn't use the 
commons-discovery, which I found to be a lot more work than I wanted. So, 
hopefully this works and I can move on :).

--Luis R.

>From: "Davanum Srinivas (JIRA)" <ax...@ws.apache.org>
>Reply-To: axis-dev@ws.apache.org
>To: axis-dev@ws.apache.org
>Subject: [jira] Resolved: (AXIS-2145) Axis Client crashes the applet unless 
>new permissions are added to the policy file (or a custom security manager 
>is used)
>Date: Tue, 2 Aug 2005 19:22:36 +0200 (CEST)
>
>      [ http://issues.apache.org/jira/browse/AXIS-2145?page=all ]
>
>Davanum Srinivas resolved AXIS-2145:
>------------------------------------
>
>     Resolution: Fixed
>
>Please build commons-discovery from their SVN repo and build latest Axis 
>from CVS.
>
>No need for a null security manager. You do need to sign the applet if it 
>tries to connect to a webservice from another domain (not the one that it 
>was downloaded from).
>
>Please open new bugs if necessary.
>
>thanks,
>dims
>
> > Axis Client crashes the applet unless new permissions are added to the 
>policy file (or a custom security manager is used)
> > 
>-------------------------------------------------------------------------------------------------------------------------
> >
> >          Key: AXIS-2145
> >          URL: http://issues.apache.org/jira/browse/AXIS-2145
> >      Project: Apache Axis
> >         Type: Bug
> >   Components: Basic Architecture
> >     Versions: current (nightly)
> >  Environment: WindowsXP, Sun jdk1.5.0_03 (running client inside an 
>applet), Axis 1.2.1, commons-logging-1.0.4, commons-httpclient-3.0-rc3, 
>using ant 1.6.5 and a laptop IBM Thinkpad R51
> >     Reporter: Luis Rivera
> >     Priority: Blocker
> >  Attachments: ClassUtils.java
> >
> > To solve the following kind of exceptions,
> > 
>***********************************************************************************************************
> > 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:103)
> >         at org.apache.axis.client.Service.<init>(Service.java:112)
> >         at vcas.gui.wsdl.VCASLocator.<init>(Unknown Source)
> >         at vcas.gui.vss.VSSApplet.init(Unknown Source)
> >         at sun.applet.AppletPanel.run(AppletPanel.java:374)
> >         at java.lang.Thread.run(Thread.java:595)
> > Caused by: java.security.AccessControlException: access denied 
>(java.lang.RuntimePermission createClassLoader)
> >         at 
>java.security.AccessControlContext.checkPermission(AccessControlContext.java:264)
> >         at 
>java.security.AccessController.checkPermission(AccessController.java:427)
> >         at 
>java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
> >         at 
>java.lang.SecurityManager.checkCreateClassLoader(SecurityManager.java:594)
> >         at java.lang.ClassLoader.<init>(ClassLoader.java:225)
> >         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)
> >         ... 14 more
> > 
>*********************************************************************************************************************************
> > I had to add the following permissions to a custom policy file.
> > 
>********************************************************************************************************************************
> > 	permission java.lang.RuntimePermission	"createClassLoader";
> > 	permission java.lang.RuntimePermission	"getClassLoader";
> > 	permission 
>java.util.PropertyPermission	"org.apache.commons.discovery.log.level", 
>"read";
> > 	permission 
>java.util.PropertyPermission	"axis.EngineConfigFactory","read";
> > 	permission 
>java.util.PropertyPermission	"org.apache.axis.EngineConfigurationFactory","read";
> > 	permission java.util.PropertyPermission	"axis.ClientConfigFile","read";
> > 	permission java.util.PropertyPermission	"axis.ServerConfigFile","read";
> > 	permission java.util.PropertyPermission	"axis.xml.reuseParsers","read";
> > 	permission 
>java.util.PropertyPermission	"axis.attachments.implementation","read";
> > 
>********************************************************************************************************************************
> > So, I see that part of the problem is appache commons logger and other 
>libraries trying to read and write to files, including the commons logger 
>used by axis. I wanted to know if there is a simple way to prevent this or 
>if I there exist a version of the Axis library without these issues, so it 
>can happily work inside the sandbox with the default permissions, I would 
>be happy to try it.
> >        Thanks in advance,
> >        --Luis R.
>
>--
>This message is automatically generated by JIRA.
>-
>If you think it was sent incorrectly contact one of the administrators:
>    http://issues.apache.org/jira/secure/Administrators.jspa
>-
>For more information on JIRA, see:
>    http://www.atlassian.com/software/jira
>

_________________________________________________________________
On the road to retirement? Check out MSN Life Events for advice on how to 
get there! http://lifeevents.msn.com/category.aspx?cid=Retirement


Re: [jira] Resolved: (AXIS-2145) Axis Client crashes the applet unless new permi

Posted by Davanum Srinivas <da...@gmail.com>.
I'd say PLEASE build it yourself from SVN am not sure about whether
the code got into that build.

-- dims

On 8/2/05, Luis Rivera <lu...@hotmail.com> wrote:
> 
> Thanks Dims,
> 
> This is great news. I will test it as soon as I make sure I found the right
> buld (I think I had found it here
> http://cvs.apache.org/builds/jakarta-commons/nightly/commons-discovery/). I
> assume is the one dated 08/02/2005 right?
> 
> If this works it will save me a lot of time. I had actualy started replacing
> the AxisProperties and Engine classes with a version that didn't use the
> commons-discovery, which I found to be a lot more work than I wanted. So,
> hopefully this works and I can move on :).
> 
> --Luis R.
> 
> >From: "Davanum Srinivas (JIRA)" <ax...@ws.apache.org>
> >Reply-To: axis-dev@ws.apache.org
> >To: axis-dev@ws.apache.org
> >Subject: [jira] Resolved: (AXIS-2145) Axis Client crashes the applet unless
> >new permissions are added to the policy file (or a custom security manager
> >is used)
> >Date: Tue, 2 Aug 2005 19:22:36 +0200 (CEST)
> >
> >      [ http://issues.apache.org/jira/browse/AXIS-2145?page=all ]
> >
> >Davanum Srinivas resolved AXIS-2145:
> >------------------------------------
> >
> >     Resolution: Fixed
> >
> >Please build commons-discovery from their SVN repo and build latest Axis
> >from CVS.
> >
> >No need for a null security manager. You do need to sign the applet if it
> >tries to connect to a webservice from another domain (not the one that it
> >was downloaded from).
> >
> >Please open new bugs if necessary.
> >
> >thanks,
> >dims
> >
> > > Axis Client crashes the applet unless new permissions are added to the
> >policy file (or a custom security manager is used)
> > >
> >-------------------------------------------------------------------------------------------------------------------------
> > >
> > >          Key: AXIS-2145
> > >          URL: http://issues.apache.org/jira/browse/AXIS-2145
> > >      Project: Apache Axis
> > >         Type: Bug
> > >   Components: Basic Architecture
> > >     Versions: current (nightly)
> > >  Environment: WindowsXP, Sun jdk1.5.0_03 (running client inside an
> >applet), Axis 1.2.1, commons-logging-1.0.4, commons-httpclient-3.0-rc3,
> >using ant 1.6.5 and a laptop IBM Thinkpad R51
> > >     Reporter: Luis Rivera
> > >     Priority: Blocker
> > >  Attachments: ClassUtils.java
> > >
> > > To solve the following kind of exceptions,
> > >
> >***********************************************************************************************************
> > > 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:103)
> > >         at org.apache.axis.client.Service.<init>(Service.java:112)
> > >         at vcas.gui.wsdl.VCASLocator.<init>(Unknown Source)
> > >         at vcas.gui.vss.VSSApplet.init(Unknown Source)
> > >         at sun.applet.AppletPanel.run(AppletPanel.java:374)
> > >         at java.lang.Thread.run(Thread.java:595)
> > > Caused by: java.security.AccessControlException: access denied
> >(java.lang.RuntimePermission createClassLoader)
> > >         at
> >java.security.AccessControlContext.checkPermission(AccessControlContext.java:264)
> > >         at
> >java.security.AccessController.checkPermission(AccessController.java:427)
> > >         at
> >java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
> > >         at
> >java.lang.SecurityManager.checkCreateClassLoader(SecurityManager.java:594)
> > >         at java.lang.ClassLoader.<init>(ClassLoader.java:225)
> > >         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)
> > >         ... 14 more
> > >
> >*********************************************************************************************************************************
> > > I had to add the following permissions to a custom policy file.
> > >
> >********************************************************************************************************************************
> > >     permission java.lang.RuntimePermission  "createClassLoader";
> > >     permission java.lang.RuntimePermission  "getClassLoader";
> > >     permission
> >java.util.PropertyPermission   "org.apache.commons.discovery.log.level",
> >"read";
> > >     permission
> >java.util.PropertyPermission   "axis.EngineConfigFactory","read";
> > >     permission
> >java.util.PropertyPermission   "org.apache.axis.EngineConfigurationFactory","read";
> > >     permission java.util.PropertyPermission "axis.ClientConfigFile","read";
> > >     permission java.util.PropertyPermission "axis.ServerConfigFile","read";
> > >     permission java.util.PropertyPermission "axis.xml.reuseParsers","read";
> > >     permission
> >java.util.PropertyPermission   "axis.attachments.implementation","read";
> > >
> >********************************************************************************************************************************
> > > So, I see that part of the problem is appache commons logger and other
> >libraries trying to read and write to files, including the commons logger
> >used by axis. I wanted to know if there is a simple way to prevent this or
> >if I there exist a version of the Axis library without these issues, so it
> >can happily work inside the sandbox with the default permissions, I would
> >be happy to try it.
> > >        Thanks in advance,
> > >        --Luis R.
> >
> >--
> >This message is automatically generated by JIRA.
> >-
> >If you think it was sent incorrectly contact one of the administrators:
> >    http://issues.apache.org/jira/secure/Administrators.jspa
> >-
> >For more information on JIRA, see:
> >    http://www.atlassian.com/software/jira
> >
> 
> _________________________________________________________________
> On the road to retirement? Check out MSN Life Events for advice on how to
> get there! http://lifeevents.msn.com/category.aspx?cid=Retirement
> 
> 


-- 
Davanum Srinivas -http://blogs.cocoondev.org/dims/