Maintenance Notice

The bugs.java.com site will be undergoing maintenance on 15th Dec 2017 21:00 PST to 16th Dec 2017 1:00 AM PST.
JDK-6463155 : JCK-runtime-6.0: api/java_net/distributed/index.html#NetDistributed fails under plugin
  • Type: Bug
  • Component: deploy
  • Sub-Component: plugin
  • Affected Version: 6
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2006-08-23
  • Updated: 2012-03-22
  • Resolved: 2006-09-19
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availabitlity Release.

To download the current JDK release, click here.
JDK 6
6 b99Fixed
Related Reports
Relates :  
Description
JCK            : JCK 6.0 b29
J2SE           : FAIL - since JDK_6.0_b90
                 PASS - JDK_6.0_b89
Platform[s]    : seems to be all

The test fails only under plugin.

Failing tests:
===================
api/java_net/distributed/index.html#NetDistributed[distributed2004]

Jtr file:
===================
attached

How to reproduce:
===================
1) Use attached script. Open "start.sh" for edit and specify correct paths for the following parameters:
JRE_HOME, JCK_HOME, SYSTEM_OS_ARCH and BROWSER.
2) Specify correct JDK plugin for the browser - make $BROWSER_HOME/plugins/libjavaplugin_oji.so symbolic link to $JDK_HOME/jre/

Test output:
===================
----------messages:(1/270)----------
command: com.sun.javatest.agent.ActiveAgentCommand com.sun.jck.lib.ExecJCKTestSameJVMCmd -loadDir /net/stt-13/export1/stt/jck_promotions/6.0/beta/b27/binaries/JCK-runtime-60/classes javasoft.sqe.tests.api.java.net.distributed.NetDistributedTests -msgSwitch stt-07:56484
----------out1:(20/731)----------
distributed2001: Passed. OKAY
distributed2002: Passed. OKAY
distributed2003: Passed. OKAY
distributed2004: Failed. Unexpected SecurityException: java.security.AccessControlException: access denied (java.io.FilePermission /tmp/jar_cache11908.tmp read)
distributed2005: Passed. OKAY
...
distributed2020: Passed. OKAY
----------out2:(63/4480)----------
Executing command via localhost,port=56437,localport=1944
****************** 2001 *****************
****************** 2002 *****************
****************** 2003 *****************
****************** 2004 *****************
java.security.AccessControlException: access denied (java.io.FilePermission /tmp/jar_cache11908.tmp read)
	at java.security.AccessControlContext.checkPermission(AccessControlContext.java:323)
	at java.security.AccessController.checkPermission(AccessController.java:546)
	at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
	at java.lang.SecurityManager.checkRead(SecurityManager.java:871)
	at java.io.File.exists(File.java:731)
	at sun.plugin.net.protocol.jar.CachedJarURLConnection.getJarFile(CachedJarURLConnection.java:108)
	at javasoft.sqe.tests.api.java.net.distributed.NetDistributedTests$4.run(NetDistributedTests.java:715)
	at javasoft.sqe.jck.lib.SecurityTestRunner.runTestWithTCKSM(SecurityTestRunner.java:278)
	at javasoft.sqe.jck.lib.SecurityTestRunner.runTestWithPermissions(SecurityTestRunner.java:235)
	at javasoft.sqe.jck.lib.SecurityTestRunner.runTestWithAllPermissions(SecurityTestRunner.java:157)
	at javasoft.sqe.jck.lib.AllPermissionSM.testRun(AllPermissionSM.java:86)
	at javasoft.sqe.tests.api.java.net.distributed.NetDistributedTests.distributed2004(NetDistributedTests.java:740)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:589)
	at javasoft.sqe.javatest.lib.TestCases.invokeTestCases(TestCases.java:173)
	at com.sun.jck.lib.DistributedMultiTest.go(DistributedMultiTest.java:57)
	at javasoft.sqe.tests.api.java.net.distributed.NetDistributedTests.go(NetDistributedTests.java:77)
	at com.sun.jck.lib.DistributedTest.run(DistributedTest.java:71)
	at com.sun.jck.lib.DistributedMultiTest.run(DistributedMultiTest.java:35)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:589)
	at com.sun.jck.lib.ExecJCKTestSameJVMCmd$Version2Test.execute(ExecJCKTestSameJVMCmd.java:461)
	at com.sun.jck.lib.ExecJCKTestSameJVMCmd$StandardTest.run(ExecJCKTestSameJVMCmd.java:373)
	at com.sun.jck.lib.ExecJCKTestSameJVMCmd.execute(ExecJCKTestSameJVMCmd.java:241)
	at com.sun.jck.lib.ExecJCKTestSameJVMCmd.run(ExecJCKTestSameJVMCmd.java:142)
	at com.sun.javatest.agent.Agent$Task.executeCommand(Agent.java:818)
	at com.sun.javatest.agent.Agent$Task.execute(Agent.java:749)
	at com.sun.javatest.agent.Agent$Task.handleRequest(Agent.java:610)
	at com.sun.javatest.agent.Agent.handleRequestsUntilClosed(Agent.java:377)
	at com.sun.javatest.agent.Agent.access$000(Agent.java:41)
	at com.sun.javatest.agent.Agent$1.run(Agent.java:253)
	at java.lang.Thread.run(Thread.java:619)
****************** 2005 *****************
****************** 2006 *****************
...
****************** 2016 *****************
correctly failed to setup test: java.security.AccessControlException: access denied (java.net.SocketPermission localhost:1024- listen,resolve)
****************** 2017 *****************
correctly failed to setup test: java.security.AccessControlException: access denied (java.net.SocketPermission localhost:1024- listen,resolve)
****************** 2018 *****************
correctly failed to setup test: java.security.AccessControlException: access denied (java.net.SocketPermission localhost:1024- listen,resolve)
****************** 2019 *****************
correctly failed to setup test: java.security.AccessControlException: access denied (java.net.SocketPermission localhost:1024- listen,resolve)
****************** 2020 *****************
correctly failed to setup test: java.security.AccessControlException: access denied (java.net.SocketPermission localhost:1024- listen,resolve)
result: Failed. test cases: 20; passed: 19; failed: 1; first test case failure: distributed2004

Comments
EVALUATION The root cause is because com.sun.jck.lib.DistributedMultiTest is loaded by a URLClassLoader created in com/sun/jck/lib/ExecJCKTestSameJVMCmd.run method; instead of loaded by the PluginClassLoader. Therefore this class won't have the pluginversion.read permission, and in turn causes the AccessControlException later in the stack. This is a special case we run into here, where the Applet uses a custom class loader to load some classes, and in turn call back into our very own plugin code later in the stack. I will add the doPriviledged block in com.sun.deploy.Environment, where we read in javaplugin.version property, so plugin will works in this scenario as well.
2006-09-07

EVALUATION Did more investigation to find out the permission for each classes involved in the call stack. As you can see below, at the begining of the stack, the classes still have the read permission for the javaplugin.version property. but as soon as we get to com.sun.jck.lib.DistributedMultiTest, we lost that permission. Also, this class is loaded by URLClassLoader, instead of PluginClassLoader (which grants the permission to read the plugin property). This is why we run into security exception when we try to read the javaplugin.version property later in the stack. Why DistributedMultiTest is not loaded by the PluginClassLoader ? class: class com.sun.deploy.Environment$1 pc: java.security.Permissions@bc8e1e ( (java.security.AllPermission <all permissions> <all actions>) ) pd.getClassLoader: null cs: null class: class com.sun.deploy.Environment pc: java.security.Permissions@bc8e1e ( (java.security.AllPermission <all permissions> <all actions>) ) pd.getClassLoader: null cs: null class: class com.sun.deploy.cache.Cache pc: java.security.Permissions@bc8e1e ( (java.security.AllPermission <all permissions> <all actions>) ) pd.getClassLoader: null cs: null class: class com.sun.deploy.net.DownloadEngine pc: java.security.Permissions@bc8e1e ( (java.security.AllPermission <all permissions> <all actions>) ) pd.getClassLoader: null cs: null class: class com.sun.deploy.cache.DeployCacheHandler pc: java.security.Permissions@bc8e1e ( (java.security.AllPermission <all permissions> <all actions>) ) pd.getClassLoader: null cs: null class: class sun.net.www.protocol.http.HttpURLConnection pc: java.security.Permissions@bc8e1e ( (java.security.AllPermission <all permissions> <all actions>) ) pd.getClassLoader: null cs: null class: class sun.net.www.protocol.http.HttpURLConnection pc: java.security.Permissions@bc8e1e ( (java.security.AllPermission <all permissions> <all actions>) ) pd.getClassLoader: null cs: null class: class sun.net.www.protocol.http.HttpURLConnection pc: java.security.Permissions@bc8e1e ( (java.security.AllPermission <all permissions> <all actions>) ) pd.getClassLoader: null cs: null class: class javasoft.sqe.tests.api.java.net.distributed.NetDistributedTests$1 pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class javasoft.sqe.jck.lib.SecurityTestRunner pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class javasoft.sqe.jck.lib.SecurityTestRunner pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class javasoft.sqe.jck.lib.SecurityTestRunner pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class javasoft.sqe.jck.lib.AllPermissionSM pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class javasoft.sqe.tests.api.java.net.distributed.NetDistributedTests pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class javasoft.sqe.javatest.lib.TestCases pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class com.sun.jck.lib.DistributedMultiTest pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class javasoft.sqe.tests.api.java.net.distributed.NetDistributedTests pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class com.sun.jck.lib.DistributedTest pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class com.sun.jck.lib.DistributedMultiTest pc: java.security.Permissions@12452e8 ( (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) ) pd.getClassLoader: java.net.URLClassLoader@182da3d cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class com.sun.jck.lib.ExecJCKTestSameJVMCmd$Version2Test pc: java.security.Permissions@1bf3d87 ( (java.lang.RuntimePermission accessClassInPackage.sun.audio) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.net.SocketPermission capoon connect,accept,resolve) (java.net.SocketPermission localhost connect,accept,resolve) (java.util.PropertyPermission javaplugin.version read) (java.util.PropertyPermission browser.version read) (java.util.PropertyPermission http.agent read) (java.util.PropertyPermission browser read) (java.util.PropertyPermission browser.vendor read) ) pd.getClassLoader: sun.plugin.security.PluginClassLoader@169e11 cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class com.sun.jck.lib.ExecJCKTestSameJVMCmd$StandardTest pc: java.security.Permissions@1bf3d87 ( (java.lang.RuntimePermission accessClassInPackage.sun.audio) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.net.SocketPermission capoon connect,accept,resolve) (java.net.SocketPermission localhost connect,accept,resolve) (java.util.PropertyPermission javaplugin.version read) (java.util.PropertyPermission browser.version read) (java.util.PropertyPermission http.agent read) (java.util.PropertyPermission browser read) (java.util.PropertyPermission browser.vendor read) ) pd.getClassLoader: sun.plugin.security.PluginClassLoader@169e11 cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class com.sun.jck.lib.ExecJCKTestSameJVMCmd pc: java.security.Permissions@1bf3d87 ( (java.lang.RuntimePermission accessClassInPackage.sun.audio) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.net.SocketPermission capoon connect,accept,resolve) (java.net.SocketPermission localhost connect,accept,resolve) (java.util.PropertyPermission javaplugin.version read) (java.util.PropertyPermission browser.version read) (java.util.PropertyPermission http.agent read) (java.util.PropertyPermission browser read) (java.util.PropertyPermission browser.vendor read) ) pd.getClassLoader: sun.plugin.security.PluginClassLoader@169e11 cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class com.sun.jck.lib.ExecJCKTestSameJVMCmd pc: java.security.Permissions@1bf3d87 ( (java.lang.RuntimePermission accessClassInPackage.sun.audio) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.net.SocketPermission capoon connect,accept,resolve) (java.net.SocketPermission localhost connect,accept,resolve) (java.util.PropertyPermission javaplugin.version read) (java.util.PropertyPermission browser.version read) (java.util.PropertyPermission http.agent read) (java.util.PropertyPermission browser read) (java.util.PropertyPermission browser.vendor read) ) pd.getClassLoader: sun.plugin.security.PluginClassLoader@169e11 cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/ class: class com.sun.javatest.agent.Agent$Task pc: java.security.Permissions@9cbd4b ( (java.lang.RuntimePermission accessClassInPackage.sun.audio) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/- read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.net.SocketPermission capoon connect,accept,resolve) (java.net.SocketPermission localhost connect,accept,resolve) (java.util.PropertyPermission javaplugin.version read) (java.util.PropertyPermission browser.version read) (java.util.PropertyPermission http.agent read) (java.util.PropertyPermission browser read) (java.util.PropertyPermission browser.vendor read) ) pd.getClassLoader: sun.plugin.security.PluginClassLoader@169e11 cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar class: class com.sun.javatest.agent.Agent$Task pc: java.security.Permissions@9cbd4b ( (java.lang.RuntimePermission accessClassInPackage.sun.audio) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/- read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.net.SocketPermission capoon connect,accept,resolve) (java.net.SocketPermission localhost connect,accept,resolve) (java.util.PropertyPermission javaplugin.version read) (java.util.PropertyPermission browser.version read) (java.util.PropertyPermission http.agent read) (java.util.PropertyPermission browser read) (java.util.PropertyPermission browser.vendor read) ) pd.getClassLoader: sun.plugin.security.PluginClassLoader@169e11 cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar class: class com.sun.javatest.agent.Agent$Task pc: java.security.Permissions@9cbd4b ( (java.lang.RuntimePermission accessClassInPackage.sun.audio) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/- read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.net.SocketPermission capoon connect,accept,resolve) (java.net.SocketPermission localhost connect,accept,resolve) (java.util.PropertyPermission javaplugin.version read) (java.util.PropertyPermission browser.version read) (java.util.PropertyPermission http.agent read) (java.util.PropertyPermission browser read) (java.util.PropertyPermission browser.vendor read) ) pd.getClassLoader: sun.plugin.security.PluginClassLoader@169e11 cs: (file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar <no signer certificates>) cs.getLocation(): file:/net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar class: class com.sun.javatest.agent.Agent pc: java.security.Permissions@9cbd4b ( (java.lang.RuntimePermission accessClassInPackage.sun.audio) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/javatest.jar read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/lib/- read) (java.io.FilePermission /net/jsqalab/export/testsuites/JCK/jck6.0/b29/JCK-runtime-60/classes/- read) (java.net.SocketPermission capoon connect,accept,resolve) (java.net.SocketPermission localhost connect,accept,resolve) (java.util.PropertyPermission javaplugin.version read) (java.util.PropertyPermission browser.version read) (java.util.PropertyPermission http.agent read) (java.util.PropertyPermission browser read) (java.util.PropertyPermission browser.vendor read) )
2006-09-06

EVALUATION After more investigation, I don't think it's our bug in plugin. Plugin already specifically grant read permission to system property "javaplugin.version" via PluginClassLoader. A simple HelloWorld sandbox applet can read that property without problem. In the JCK test, when it gets run, it replaces our own security manager and security policy with there specific manager, which does not have the permission to read javaplugin.version, and therefore the problem. In the trace stack, you can see: java.lang.ExceptionInInitializerError at com.sun.deploy.cache.Cache.getCacheEntry(Cache.java:1134) at com.sun.deploy.net.DownloadEngine.isUpdateAvailable(DownloadEngine.java:668) at com.sun.deploy.cache.DeployCacheHandler.get(DeployCacheHandler.java:126) at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:685) at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:658) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:981) at javasoft.sqe.tests.api.java.net.distributed.NetDistributedTests$1.run(NetDistributedTests.java:437) at javasoft.sqe.jck.lib.SecurityTestRunner.runTestWithTCKSM(SecurityTestRunner.java:278) at javasoft.sqe.jck.lib.SecurityTestRunner.runTestWithPermissions(SecurityTestRunner.java:235) at javasoft.sqe.jck.lib.SecurityTestRunner.runTestWithAllPermissions(SecurityTestRunner.java:157) at javasoft.sqe.jck.lib.AllPermissionSM.testRun(AllPermissionSM.java:86) at javasoft.sqe.tests.api.java.net.distributed.NetDistributedTests.distributed2001(NetDistributedTests.java:480) The call to SecurityTestRunner.runTestWithTCKSM will actually replace the current plugin security manager and policy with the TCK specific one. So when it calls into plugin code, it does not have the read permission for javaplugin.version anymore, and hence the security exception.
2006-09-06

SUGGESTED FIX http://web-east.east/deployment/www/webrevs/ngthomas/6463155/new/webrev/
2006-09-05

EVALUATION another doPrivileged block is needed for the com.sun.deploy.Environment static initializer, where we access javaplugin.version system property
2006-09-05

SUGGESTED FIX http://web-east.east/deployment/www/webrevs/ngthomas/6463155/webrev/
2006-08-23

EVALUATION we need doPrivileged block for both cache and no-cache case in CachedJarURLConnection.getJarFile; as this will be call in directly from applet code.
2006-08-23

EVALUATION this is caused by fix for 6418268.
2006-08-23