db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Craig Russell (JIRA)" <j...@apache.org>
Subject [jira] Commented: (JDO-555) All calls to Class.getMethod and Method.invoke (among others) need to be invoked inside a doPrivileged block.
Date Wed, 16 Jul 2008 22:15:31 GMT

    [ https://issues.apache.org/jira/browse/JDO-555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12614127#action_12614127
] 

Craig Russell commented on JDO-555:
-----------------------------------

There's another area that isn't protected with doPrivileged that causes a number of exceptions:
    [java] 1) testPositive(org.apache.jdo.tck.query.api.ChangeQuery)java.security.AccessControlException:
access denied (java.lang.RuntimePermission accessDeclaredMembers)
    [java] 	at java.security.AccessControlContext.checkPermission(AccessControlContext.java:264)
    [java] 	at java.security.AccessController.checkPermission(AccessController.java:427)
    [java] 	at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
    [java] 	at java.lang.SecurityManager.checkMemberAccess(SecurityManager.java:1662)
    [java] 	at java.lang.Class.checkMemberAccess(Class.java:2125)
    [java] 	at java.lang.Class.getDeclaredFields(Class.java:1714)
    [java] 	at org.datanucleus.store.rdbms.query.ResultClassROF.populateDeclaredFieldsForUserType(ResultClassROF.java:329)
    [java] 	at org.datanucleus.store.rdbms.query.ResultClassROF.populateDeclaredFieldsForUserType(ResultClassROF.java:339)
    [java] 	at org.datanucleus.store.rdbms.query.ResultClassROF.<init>(ResultClassROF.java:122)
    [java] 	at org.datanucleus.store.rdbms.query.ResultExpressionsQueryable.newResultObjectFactory(ResultExpressionsQueryable.java:424)
    [java] 	at org.datanucleus.store.rdbms.query.JDOQLQuery.performExecute(JDOQLQuery.java:265)
    [java] 	at org.datanucleus.store.query.Query.executeQuery(Query.java:1344)
    [java] 	at org.datanucleus.store.rdbms.query.JDOQLQuery.executeQuery(JDOQLQuery.java:229)
    [java] 	at org.datanucleus.store.query.Query.executeWithArray(Query.java:1265)
    [java] 	at org.datanucleus.jdo.JDOQuery.executeWithArray(JDOQuery.java:308)
    [java] 	at org.apache.jdo.tck.query.QueryTest.execute(QueryTest.java:1257)
    [java] 	at org.apache.jdo.tck.query.QueryTest.executeJDOQuery(QueryTest.java:1161)
    [java] 	at org.apache.jdo.tck.query.api.ChangeQuery.testPositive(ChangeQuery.java:95)
    [java] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [java] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    [java] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    [java] 	at org.apache.jdo.tck.JDO_Test.runBare(JDO_Test.java:259)
    [java] 	at org.apache.jdo.tck.util.BatchTestRunner.doRun(BatchTestRunner.java:108)
    [java] 	at org.apache.jdo.tck.util.BatchTestRunner.start(BatchTestRunner.java:148)
    [java] 	at org.apache.jdo.tck.util.BatchTestRunner.main(BatchTestRunner.java:123)



> All calls to Class.getMethod and Method.invoke (among others) need to be invoked inside
a doPrivileged block.
> -------------------------------------------------------------------------------------------------------------
>
>                 Key: JDO-555
>                 URL: https://issues.apache.org/jira/browse/JDO-555
>             Project: JDO
>          Issue Type: Bug
>          Components: api2, api2-legacy
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Matthew T. Adams
>            Assignee: Andy Jefferson
>            Priority: Minor
>             Fix For: JDO 2 maintenance release 2
>
>         Attachments: ClassMetaData.java-patch, datanucleus.patch, datanucleus.patch,
jdo-555.patch, jdo-555.patch, jdo-555.patch, xmlbean.patch
>
>
> Discovered in review of patch to JDO-545.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message