[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] Equinox with OSGi security?

The eclipse.security is only used by the org.eclipse.equinox.launcher jar. The eclipse.security option is used by the launcher bootstrap code to indicate that it should setup a policy which grants itself and the framework ALLPermissions. Then it sets the java.security.manager to the value of eclipse.security. Later when the Framework launches it actually will install the SecurityManager to enable security.

When running without the launcher you need to do a bit more work to setup your policy file. You can use a very simple policy which grants AllPermissions to everything like this ...

###### BEGIN POLICY FILE ##########
grant {
permission java.security.AllPermission;
###### END POLICY FILE ##########

You would then launch equinox with the following command:

java -Djava.security.manager=org.eclipse.osgi.framework.internal.core.FrameworkSecurityManager -Djava.security.policy=policy -jar org.eclipse.osgi_3.4.0.v20080107.jar -console

The java.security.manager property tells the VM what security manager to load. The java.security.policy property tells the VM what policy to load to grant permissions. Note that the permissions granted to the bundles installed into the framework are controled by the PermissionAdmin and ConditionalPermissionAdmin services. By default these services will grant all bundles AllPermissions.



Inactive hide details for Marcel Offermans ---01/24/2008 10:42:26 AM---I would like to run Equinox with OSGi security (PermissiMarcel Offermans ---01/24/2008 10:42:26 AM---I would like to run Equinox with OSGi security (PermissionAdmin,


Marcel Offermans <marcel.offermans@xxxxxxxxxx>


Equinox development mailing list <equinox-dev@xxxxxxxxxxx>


01/24/2008 10:42 AM


[equinox-dev] Equinox with OSGi security?

I would like to run Equinox with OSGi security (PermissionAdmin,  
ConditionalPermissionAdmin) enabled.

I read the quickstart guide here:


I even found some reference to a property to set that should enable  


However, if I just run the Equinox framework like described in the  
quickstart guide with that property, I still do not get any security  
related service. Am I missing some piece of documentation here? It  
should not be too hard to run with security, right?

Greetings, Marcel

equinox-dev mailing list

GIF image

GIF image