security AccessControlException creating classLoader in web start
-----------------------------------------------------------------

                 Key: JRUBY-2122
                 URL: http://jira.codehaus.org/browse/JRUBY-2122
             Project: JRuby
          Issue Type: Bug
          Components: Core Classes/Modules
    Affects Versions: JRuby 1.1RC2
         Environment: MacOS 10.4.11, Java 1.5.0_13, JRuby trunk 5946
            Reporter: Stephen Bannasch



Running my sample signed jruby web start application described in [JRUBY-2040] 
now generates an AccessControlException.

Does anyone have a suggestion about how I could make this into a test which 
could be included in the jruby test suite?

Running the web start sample from the command line starts the sample, the 
window displays, and then the app immediately exits. The following strack trace 
is extracted from the java web start logs located here (MacOS X 10.4.11): 

{noformat}
~/Library/Caches/Java/log/javaws.log.x
{noformat}

{noformat}
Exception in thread "Thread-8" 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:201)
at java.security.SecureClassLoader.<init>(SecureClassLoader.java:53)
at java.net.URLClassLoader.<init>(URLClassLoader.java:82)
at org.jruby.util.JRubyClassLoader.<init>(JRubyClassLoader.java:12)
at 
org.jruby.runtime.callback.InvocationCallbackFactory.<init>(InvocationCallbackFactory.java:102)
at org.jruby.runtime.CallbackFactory.createFactory(CallbackFactory.java:171)
{noformat}

The sample in  [JRUBY-2040] has been simplified so that only the 
jruby-complete.jar is included. The stack trace above was generated with this 
jnlp:

{code}
<?xml version="1.0" encoding="UTF-8"?>
<jnlp spec="1.0+" codebase="file:.">
  <information>
    <title>JRuby IRB Console</title>
    <vendor>The JRuby Team</vendor>
    <description>Sample WebStart Application with JRuby</description>
    <description kind="short">JRuby IRB Console Sample</description>
    <homepage href="http://jruby.codehaus.org/"/>
    <icon kind="splash" href="black_box.png"/>
    <offline-allowed/>
  </information>
  <security>
    <all-permissions/>
  </security>
  <resources>
    <j2se version="1.5+"/>
    <jar href="signed-jars/jruby-complete.jar" download="eager" main="false"/>
    <!-- <jar href="signed-jars/jrubygems-0.4-SNAPSHOT.jar" download="eager" 
main="false"/>
    <jar href="signed-jars/gems.jar" download="eager" main="false"/>
    <jar href="signed-jars/blog.jar" download="eager" main="false"/> -->
  </resources>
  <application-desc main-class="org.jruby.demo.IRBConsole">
  </application-desc>
</jnlp>
{code}


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to