Derby
  1. Derby
  2. DERBY-6091

SystemPrivilegesPermissionTest fails on JDK 8 EA

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Invalid
    • Affects Version/s: 10.10.1.1
    • Fix Version/s: None
    • Component/s: Test
    • Labels:
      None
    • Environment:
      1.8.0-ea-b77
    • Urgency:
      Blocker

      Description

      When using an early access build of JDK 8, I see the following failure in SystemPrivilegesPermissionTest:

      java.security.AccessControlException: access denied ("org.apache.derby.security.DatabasePermission" "directory:dir" "create")
      at java.security.AccessControlContext.checkPermission(AccessControlContext.java:364)
      at java.security.AccessController.checkPermission(AccessController.java:560)
      at org.apache.derbyTesting.unitTests.junit.SystemPrivilegesPermissionTest$CreateDatabaseAction.run(SystemPrivilegesPermissionTest.java:714)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.Subject.doAsPrivileged(Subject.java:474)
      at org.apache.derbyTesting.unitTests.junit.SystemPrivilegesPermissionTest$RunAsPrivilegedUserAction.run(SystemPrivilegesPermissionTest.java:788)
      at java.security.AccessController.doPrivileged(Native Method)
      at org.apache.derbyTesting.unitTests.junit.SystemPrivilegesPermissionTest.execute(SystemPrivilegesPermissionTest.java:566)
      at org.apache.derbyTesting.unitTests.junit.SystemPrivilegesPermissionTest.policyTestDatabasePermissionGrants(SystemPrivilegesPermissionTest.java:550)
      at org.apache.derbyTesting.junit.BaseTestCase.runBare(BaseTestCase.java:117)
      at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
      at junit.extensions.TestSetup$1.protect(TestSetup.java:23)
      at junit.extensions.TestSetup.run(TestSetup.java:27)

      1. AccessDenied.java
        6 kB
        Rick Hillegas

        Activity

        Hide
        Dag H. Wanvik added a comment -

        I see this running on Windows, too. (1.8.0-ea-b76).

        Show
        Dag H. Wanvik added a comment - I see this running on Windows, too. (1.8.0-ea-b76).
        Hide
        Rick Hillegas added a comment -

        I have seen this error as well. Attaching AccessDenied.java, a simple test which runs fine on JDK 7 but which fails on Open JDK 8. This test does not use any Derby code. That suggests to me that the defect is in Open JDK 8.

        Show
        Rick Hillegas added a comment - I have seen this error as well. Attaching AccessDenied.java, a simple test which runs fine on JDK 7 but which fails on Open JDK 8. This test does not use any Derby code. That suggests to me that the defect is in Open JDK 8.
        Hide
        Rick Hillegas added a comment -

        I have logged an Open JDK bug to track this problem. I expect that a public version of this bug report will turn up at the following address eventually: http://bugs.sun.com/view_bug.do?bug_id=8008908

        Show
        Rick Hillegas added a comment - I have logged an Open JDK bug to track this problem. I expect that a public version of this bug report will turn up at the following address eventually: http://bugs.sun.com/view_bug.do?bug_id=8008908
        Hide
        Rick Hillegas added a comment -

        Raising the urgency to a Blocker for the 10.10.1 release. I'd like to see a clean test run on Open JDK 8 before we produce a release.

        Show
        Rick Hillegas added a comment - Raising the urgency to a Blocker for the 10.10.1 release. I'd like to see a clean test run on Open JDK 8 before we produce a release.
        Hide
        Knut Anders Hatlen added a comment -

        A fix has been checked in to OpenJDK for the bug Rick filed. I built new JDK binaries from sources that included the fix, and now the test passes. Closing this bug as invalid as it turned out to be a JVM issue.

        Show
        Knut Anders Hatlen added a comment - A fix has been checked in to OpenJDK for the bug Rick filed. I built new JDK binaries from sources that included the fix, and now the test passes. Closing this bug as invalid as it turned out to be a JVM issue.

          People

          • Assignee:
            Unassigned
            Reporter:
            Knut Anders Hatlen
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development