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

Signed applet with all-permissions throws AccessControlException with JRE8

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P3 P3
    • 8u60
    • 8u25
    • deploy
    • x86_64
    • windows_7

      FULL PRODUCT VERSION :
      Java 8 update 25 build: 1.8.0_25-b18

      ADDITIONAL OS VERSION INFORMATION :
      Microsoft Windows [Version 6.1.7601]

      A DESCRIPTION OF THE PROBLEM :
      Signed applet with Permissions: all-permissions in MANIFEST.MF file does not load after update to JDK 8u25
      Exception: java.security.AccessControlException: access denied("java.net.SocketPermission" "X.XXX.XX.250:7122" "connect,resolve")

      Was working fine with JDK7u60 and earlier versions

      Log for JDK8u25:

      Java7 tab key workaround enabled
      basic: Applet initialized
      basic: Starting applet
      basic: completed perf rollup
      basic: Applet made visible
      basic: Applet started
      basic: Told clients applet is started
      security: Grant liveconnect connect perm for http://X.XXX.XX.250/xxx045/xxx.shtml : java.security.Permissions@141bd84 (
       ("java.util.PropertyPermission" "java.specification.version" "read")
       ("java.util.PropertyPermission" "path.separator" "read")
       ("java.util.PropertyPermission" "java.vm.vendor" "read")
       ("java.util.PropertyPermission" "os.version" "read")
       ("java.util.PropertyPermission" "browser.version" "read")
       ("java.util.PropertyPermission" "java.vendor.url" "read")
       ("java.util.PropertyPermission" "browser" "read")
       ("java.util.PropertyPermission" "browser.vendor" "read")
       ("java.util.PropertyPermission" "os.name" "read")
       ("java.util.PropertyPermission" "java.vm.specification.version" "read")
       ("java.util.PropertyPermission" "java.vm.name" "read")
       ("java.util.PropertyPermission" "javaws.*" "read,write")
       ("java.util.PropertyPermission" "javaplugin.vm.options" "read")
       ("java.util.PropertyPermission" "mrj.version" "read")
       ("java.util.PropertyPermission" "java.version" "read")
       ("java.util.PropertyPermission" "jnlp.*" "read,write")
       ("java.util.PropertyPermission" "javaplugin.version" "read")
       ("java.util.PropertyPermission" "os.arch" "read")
       ("java.util.PropertyPermission" "java.specification.vendor" "read")
       ("java.util.PropertyPermission" "java.vm.specification.name" "read")
       ("java.util.PropertyPermission" "file.separator" "read")
       ("java.util.PropertyPermission" "line.separator" "read")
       ("java.util.PropertyPermission" "java.vendor" "read")
       ("java.util.PropertyPermission" "java.specification.name" "read")
       ("java.util.PropertyPermission" "java.vm.specification.vendor" "read")
       ("java.util.PropertyPermission" "java.vm.version" "read")
       ("java.util.PropertyPermission" "javapi.*" "read,write")
       ("java.util.PropertyPermission" "java.class.version" "read")
       ("java.util.PropertyPermission" "http.agent" "read")
       ("com.sun.deploy.security.SecureCookiePermission" "origin.http://X.XXX.XX.250:80")
       ("java.net.URLPermission" "http://X.XXX.XX.250:80/-" "*:*")
       ("java.net.URLPermission" "http://X.XXX.XX.250:80" "*:*")
       ("java.net.SocketPermission" "localhost:0" "listen,resolve")
       ("java.lang.RuntimePermission" "accessClassInPackage.sun.audio")
       ("java.lang.RuntimePermission" "stopThread")
      )

      security: Javascript from a non secure page is accessing privileged code. Consider using HTTPS protocol when using Javascript -> Java liveconnect calls.
      network: Cache entry not found [url: http://X.XXX.XX.250:7122/crossdomain.xml, version: null]
      network: Connecting http://X.XXX.XX.250:7122/crossdomain.xml with proxy=DIRECT
      network: Connecting http://X.XXX.XX.250:7122/ with proxy=DIRECT
      network: Connecting http://X.XXX.XX.250:7122/ with proxy=DIRECT
      java.net.SocketException: Unexpected end of file from server
      at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)
      at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)
      at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)
      at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection.access$200(Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection$9.run(Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection$9.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.security.AccessController.doPrivileged(Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
      at com.sun.deploy.net.CrossDomainXML.check(Unknown Source)
      at com.sun.deploy.net.CrossDomainXML.check(Unknown Source)
      at sun.plugin2.applet.SecurityManagerHelper.checkConnectHelper(Unknown Source)
      at sun.plugin2.applet.AWTAppletSecurityManager.checkConnect(Unknown Source)
      at java.net.Socket.connect(Unknown Source)
      at java.net.Socket.connect(Unknown Source)
      at java.net.Socket.<init>(Unknown Source)
      at java.net.Socket.<init>(Unknown Source)
      at SockIO.doConnect(SockIO.java:211)
      at SockIO.run(SockIO.java:333)
      at java.lang.Thread.run(Unknown Source)

      REGRESSION. Last worked in version 7u60

      ADDITIONAL REGRESSION INFORMATION:
      1.7.0_60-b19

      Log for JDK7u60:

      Java7 tab key workaround enabled
      basic: Applet initialized
      basic: Starting applet
      basic: completed perf rollup
      basic: Applet made visible
      basic: Applet started
      basic: Told clients applet is started
      security: Javascript from a non secure page is accessing privileged code. Consider using HTTPS protocol when using Javascript -> Java liveconnect calls.
      network: Connecting http://X.XXX.XX.250:7122/ with proxy=DIRECT
      network: Cache entry not found [url: http://X.XXX.XX.181/crossdomain.xml, version: null]
      network: Connecting http://X.XXX.XX.181/crossdomain.xml with proxy=DIRECT
      network: Connecting http://X.XXX.XX.181:80/ with proxy=DIRECT
      java.net.ConnectException: Connection refused: connect
      at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)
      at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
      at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
      at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
      at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
      at java.net.PlainSocketImpl.connect(Unknown Source)
      at java.net.SocksSocketImpl.connect(Unknown Source)
      at java.net.Socket.connect(Unknown Source)
      at sun.net.NetworkClient.doConnect(Unknown Source)
      at sun.net.www.http.HttpClient.openServer(Unknown Source)
      at sun.net.www.http.HttpClient.openServer(Unknown Source)
      at sun.net.www.http.HttpClient.&lt;init&gt;(Unknown Source)
      at sun.net.www.http.HttpClient.New(Unknown Source)
      at sun.net.www.http.HttpClient.New(Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown Source)
      at com.sun.deploy.net.CrossDomainXML$3.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at com.sun.deploy.net.CrossDomainXML.privilegedConnect(Unknown Source)
      at com.sun.deploy.net.CrossDomainXML.check(Unknown Source)
      at com.sun.deploy.net.CrossDomainXML.check(Unknown Source)
      at sun.plugin2.applet.SecurityManagerHelper.checkConnectHelper(Unknown Source)
      at sun.plugin2.applet.AWTAppletSecurityManager.checkConnect(Unknown Source)
      at java.net.Socket.getLocalAddress(Unknown Source)
      at SockIO.doConnect(SockIO.java:217)
      at SockIO.run(SockIO.java:333)
      at java.lang.Thread.run(Unknown Source)


      REPRODUCIBILITY :
      This bug can be reproduced always.

      CUSTOMER SUBMITTED WORKAROUND :
      Updating the java.policy file to give all permissions loads the applet. But this is not recommended.

            dtitov Daniil Titov (Inactive)
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: