aries-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tim Mitchell (Created) (JIRA)" <j...@apache.org>
Subject [jira] [Created] (ARIES-816) Java 2 security AccesControlException when getting blueprint service
Date Wed, 25 Jan 2012 13:32:41 GMT
Java 2 security AccesControlException when getting blueprint service
--------------------------------------------------------------------

                 Key: ARIES-816
                 URL: https://issues.apache.org/jira/browse/ARIES-816
             Project: Aries
          Issue Type: Bug
          Components: Blueprint
    Affects Versions: blueprint.core-0.4
            Reporter: Tim Mitchell


When getting a blueprint service in a security application server using Apache Aries, we are
getting the following exception:

java.security.AccessControlException: Access denied (org.osgi.framework.ServicePermission
(service.id=61) get)
	at java.security.AccessController.checkPermission(AccessController.java:108)
	at java.lang.SecurityManager.checkPermission(SecurityManager.java:544)
	at com.ibm.ws.security.core.SecurityManager.checkPermission(SecurityManager.java:208)
	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.checkGetServicePermission(ServiceRegistry.java:986)
	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.getService(ServiceRegistry.java:428)
	at org.eclipse.osgi.framework.internal.core.BundleContextImpl.getService(BundleContextImpl.java:667)
	at org.apache.aries.blueprint.container.ReferenceRecipe.getService(ReferenceRecipe.java:202)
	at org.apache.aries.blueprint.container.ReferenceRecipe.access$000(ReferenceRecipe.java:50)
	at org.apache.aries.blueprint.container.ReferenceRecipe$ServiceDispatcher.call(ReferenceRecipe.java:227)

The blueprint ReferenceRecipe needs a doPrivileged block around the getService() call.

I have attached the diff.txt for the changes needed to the ReferenceRecipe class.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message