• Icon: Sub-task Sub-task
    • Resolution: Done
    • Icon: Major Major
    • None
    • None
    • OpenJDK8 -> OpenJDK11
    • None
    • Sprint 215 AMM, Sprint 217 AMM

      The implementation of java.lang.SecurityManager.checkMemberAccess(java.lang.Class,int) relies on an assumption that the caller is at a stack depth of 4, which is not something that can be enforced, making the code error-prone.

      When
      a Java class uses java.lang.SecurityManager.checkMemberAccess(java.lang.Class,int)

      Perform
      add a hint to replace the call with java.lang.SecurityManager.checkPermission(new RuntimePermission("accessDeclaredMembers"))

        1. rule-id-00041.png
          98 kB
          Karishma Punwatkar
        2. rule-id-00130.png
          110 kB
          Karishma Punwatkar
        3. runFinalizer-and-SecurityManager.png
          193 kB
          Karishma Punwatkar

              rhn-support-kpunwatk Karishma Punwatkar
              rhn-engineering-ahughes Andrew Hughes
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: