db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d..@apache.org
Subject svn commit: r1619009 - in /db/derby/code/branches/10.11: ./ java/drda/org/apache/derby/drda/template.policy
Date Tue, 19 Aug 2014 22:59:49 GMT
Author: dag
Date: Tue Aug 19 22:59:48 2014
New Revision: 1619009

URL: http://svn.apache.org/r1619009
Log:
DERBY-6680 Other jar files may need to be granted permission to read derby.ui.* properties

Backported from trunk svn 1618881 and svn 1618930.

Patch derby-6680 adds a caveat to the template policy file to help
users avoid the issue seen by the user.


Modified:
    db/derby/code/branches/10.11/   (props changed)
    db/derby/code/branches/10.11/java/drda/org/apache/derby/drda/template.policy

Propchange: db/derby/code/branches/10.11/
------------------------------------------------------------------------------
  Merged /db/derby/code/trunk:r1618881,1618930

Modified: db/derby/code/branches/10.11/java/drda/org/apache/derby/drda/template.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.11/java/drda/org/apache/derby/drda/template.policy?rev=1619009&r1=1619008&r2=1619009&view=diff
==============================================================================
--- db/derby/code/branches/10.11/java/drda/org/apache/derby/drda/template.policy (original)
+++ db/derby/code/branches/10.11/java/drda/org/apache/derby/drda/template.policy Tue Aug 19
22:59:48 2014
@@ -24,7 +24,20 @@ grant codeBase "${derby.install.url}derb
   // These permissions are needed for everyday, embedded Derby usage.
   //
   permission java.lang.RuntimePermission "createClassLoader";
+
+  // Next, the permission to read "derby.*" properties is granted to
+  // derby.jar. This is necessary for the engine to read derby properties.
+  // 
+  // NOTE: This works under the assumption that derby.jar precedes
+  // derbytools.jar (and possibly derbyclient.jar) - if present. If that is
+  // *not* the case, i.e. derby.jar follows any of those other jars, you will
+  // need to *also* grant this permission to the first of those jar files in
+  // your classpath. The reason is that some Derby properties (derby.ui.locale,
+  // derby.ui.codeset) are read by the class LocalizedResource which is present
+  // in more than one jar file. The first jar in the path gets used to load
+  // the class and hence that jar needs the permission.
   permission java.util.PropertyPermission "derby.*", "read";
+
   permission java.util.PropertyPermission "user.dir", "read";
 
   // The next two properties are used to determine if the VM is 32 or 64 bit.



Mime
View raw message