Combination View Flat View Tree View
donino pienni
System.getProperties() with SecurityManager enabled
May 8, 2014 12:34 AM

donino pienni

Rank: Youngling

Posts: 0

Join Date: July 2, 2011

Recent Posts

Hi everyone,

We use a third-party library in a portlet application which gets a snapshot of all system properties:

1Properties systemProperties = System.getProperties();
3properties.putAll(systemProperties);  //properties is a static variable in this library

in i have set:


When security-manager-enabled is set to "generate", it does not add anything more in pacl-policy. The generator does not seem to see it, and everything works finely. But when i turn security-manager-enabled to true, i get an exception such:

1  Caused by: Access denied ("java.util.PropertyPermission" "*" "read,write")
2    at
3    at
4    at
5    at
6    at
7    at java.lang.SecurityManager.checkPropertiesAccess(
8    at java.lang.System.getProperties(

Is this "System.getProperties" strictly forbidden, even if we give a read access on all properties?
Is there a possible workaround, or should we have to change the source code of this library?

Dmitry Kovalev
RE: System.getProperties() with SecurityManager enabled
March 27, 2017 12:28 AM

Dmitry Kovalev

Rank: Youngling

Posts: 1

Join Date: April 1, 2015

Recent Posts

Hi Donino!

Have you solve this problem? What is the result of your research?
I have the same situation....


To access the Developer Forum, please login to your account if you are already a registered developer or register to become a developer.