ConfigImpl needs write permissions for standard java util
Why does the typesafe conf need write permissions for the "standard" java propertypermission that should be world readable?
Caused by: java.security.AccessControlException: access denied ("java.util.PropertyPermission" "*" "read,write")
at java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
at java.security.AccessController.checkPermission(AccessController.java:884)
at java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
at java.lang.SecurityManager.checkPropertiesAccess(SecurityManager.java:1262)
at java.lang.System.getProperties(System.java:630)
at com.typesafe.config.impl.ConfigImpl.getSystemProperties(ConfigImpl.java:301)
at com.typesafe.config.impl.ConfigImpl.loadSystemProperties(ConfigImpl.java:310)
at com.typesafe.config.impl.ConfigImpl.access$000(ConfigImpl.java:34)
at com.typesafe.config.impl.ConfigImpl$SystemPropertiesHolder.
It looks like we're calling System.getProperties and that checks for read-write permission. Maybe because the returned Properties object is mutable. I can't think of any way to avoid this, we need all the system properties, so System.getProperty won't work. I don't see a Java API to get a read-only view.
Thank you for the quick response.