Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8097025

access denied ("java.lang.RuntimePermission" "accessClassInPackage.com.sun.javafx.tk") in Sandbox Applet

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3
    • Resolution: Not an Issue
    • Affects Version/s: 8u20
    • Fix Version/s: None
    • Component/s: javafx
    • Labels:
    • Environment:

      Java-Plug-in 11.20.2.26
      JRE-Version verwenden 1.8.0_20-b26 Java HotSpot(TM) Client VM
      Google Chrome: Version 37.0.2062.124 m

    • Subcomponent:

      Description

      When calling "com.sun.javafx.tk.Toolkit.getToolkit()" in a Sandbox-Applet in a browser the following Exception occurs:

      java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
      at com.sun.deploy.uitoolkit.impl.awt.AWTAppletAdapter.runOnEDTAndWait(Unknown Source)
      at com.sun.deploy.uitoolkit.impl.awt.AWTAppletAdapter.instantiateApplet(Unknown Source)
      at sun.plugin2.applet.Plugin2Manager.initAppletAdapter(Unknown Source)
      at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)
      Caused by: java.lang.reflect.InvocationTargetException
      at com.sun.deploy.uitoolkit.impl.awt.OldPluginAWTUtil.invokeAndWait(Unknown Source)
      ... 5 more
      Caused by: java.security.AccessControlException: access denied ("java.lang.RuntimePermission" "accessClassInPackage.com.sun.javafx.tk")
      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.checkPackageAccess(Unknown Source)
      at sun.plugin2.applet.SecurityManagerHelper.checkPackageAccessHelper(Unknown Source)
      at sun.plugin2.applet.AWTAppletSecurityManager.checkPackageAccess(Unknown Source)
      at java.lang.ClassLoader$1.run(Unknown Source)
      at java.lang.ClassLoader$1.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.lang.ClassLoader.checkPackageAccess(Unknown Source)
      at java.lang.ClassLoader.defineClass1(Native Method)
      at java.lang.ClassLoader.defineClass(Unknown Source)
      at java.security.SecureClassLoader.defineClass(Unknown Source)
      at java.net.URLClassLoader.defineClass(Unknown Source)
      at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.defineClassHelper(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.access$100(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader$2.run(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader$2.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.plugin2.applet.Plugin2ClassLoader.findClassHelper(Unknown Source)
      at sun.plugin2.applet.JNLP2ClassLoader.findClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
      at java.lang.ClassLoader.loadClass(Unknown Source)
      at java.lang.Class.getDeclaredConstructors0(Native Method)
      at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)
      at java.lang.Class.getConstructor0(Unknown Source)
      at java.lang.Class.newInstance(Unknown Source)
      at com.sun.deploy.uitoolkit.impl.awt.AWTAppletAdapter$1.run(Unknown Source)
      at java.awt.event.InvocationEvent.dispatch(Unknown Source)
      at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
      at java.awt.EventQueue.access$400(Unknown Source)
      at java.awt.EventQueue$3.run(Unknown Source)
      at java.awt.EventQueue$3.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)
      at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)
      at java.awt.EventQueue$4.run(Unknown Source)
      at java.awt.EventQueue$4.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)
      at java.awt.EventQueue.dispatchEvent(Unknown Source)
      at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
      at java.awt.EventDispatchThread.pumpEventsForFilter(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)

        Attachments

          Activity

            People

            Assignee:
            vadim Vadim Pakhnushev
            Reporter:
            fleitenbejfx Frederic Leitenberger (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported: