db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lily...@apache.org
Subject svn commit: r982401 - in /db/derby/code/branches/10.5: ./ java/drda/org/apache/derby/drda/ java/engine/org/apache/derby/iapi/services/i18n/ java/engine/org/apache/derby/impl/store/raw/data/ java/engine/org/apache/derby/loc/ java/testing/org/apache/derb...
Date Wed, 04 Aug 2010 20:57:04 GMT
Author: lilywei
Date: Wed Aug  4 20:57:03 2010
New Revision: 982401

URL: http://svn.apache.org/viewvc?rev=982401&view=rev
Log:
DERBY-4715 Write jvm information and path of derby.jar to derby.log
Merged by svn merge -c 965647 ../trunk/ and svn merge -c 967304 ../trunk/
Simple merge with no conflicts; no additional changes were necessary.
Originally submitted by Kathey Marsden and Lily Wei

Modified:
    db/derby/code/branches/10.5/   (props changed)
    db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/server.policy
    db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/template.policy
    db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/services/i18n/MessageService.java
    db/derby/code/branches/10.5/java/engine/org/apache/derby/impl/store/raw/data/BaseDataFileFactory.java
    db/derby/code/branches/10.5/java/engine/org/apache/derby/loc/messages.xml
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/GetCurrentPropertiesTest.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/NetworkServerControlApiTest.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ServerPropertiesTest.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/SysinfoTest.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/LDAPTests.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.initial.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.modified.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.unreloadable.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/unit/fillLog.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/derby_tests.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/nwsvr.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/AssertFailureTest.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest.policy
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest1.policy

Propchange: db/derby/code/branches/10.5/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Wed Aug  4 20:57:03 2010
@@ -1,2 +1,2 @@
 /db/derby/code/branches/10.6:942027,957000,962738,965351
-/db/derby/code/trunk:757811,769596,769602,769606,769962,772090,772337,772449,772534,774281,777105,779681,782991,785131,785139,785163,785570,785662,788369,788670,788674,788968,789264,790218,791027,792434,793089,793588,794106,794303,794955,795166,795459,796020,796027,796316,796372,797147,798347,798742,800523,803548,803948,805696,808494,808850,809643,810860,812669,816531,816536,819006,822289,823659,824694,827505,829022,829410,830545,831304,831319,832379,833430,835286,881074,881444,882732,884163,885421,885659,887246,888311,892912,897161,898635,901165,901648,901760,902857,903108,905224,908418,908586,909176,910481,910511,911315,911793,915733,916075,916897,918152,918359,921028,927430,928065,929085,934474,936215,938959,940462,940469,942286,942476,942480,942587,946794,948045,948069,951346,951366,952138,952581,954748,955001,955634,956075,956445,956659,958163,959550,962716
+/db/derby/code/trunk:757811,769596,769602,769606,769962,772090,772337,772449,772534,774281,777105,779681,782991,785131,785139,785163,785570,785662,788369,788670,788674,788968,789264,790218,791027,792434,793089,793588,794106,794303,794955,795166,795459,796020,796027,796316,796372,797147,798347,798742,800523,803548,803948,805696,808494,808850,809643,810860,812669,816531,816536,819006,822289,823659,824694,827505,829022,829410,830545,831304,831319,832379,833430,835286,881074,881444,882732,884163,885421,885659,887246,888311,892912,897161,898635,901165,901648,901760,902857,903108,905224,908418,908586,909176,910481,910511,911315,911793,915733,916075,916897,918152,918359,921028,927430,928065,929085,934474,936215,938959,940462,940469,942286,942476,942480,942587,946794,948045,948069,951346,951366,952138,952581,954748,955001,955634,956075,956445,956659,958163,959550,962716,965647,967304

Modified: db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/server.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/server.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/server.policy (original)
+++ db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/server.policy Wed Aug  4 20:57:03
2010
@@ -89,6 +89,9 @@ grant codeBase "${derby.install.url}derb
   permission org.apache.derby.security.SystemPermission "engine", "monitor";
   permission org.apache.derby.security.SystemPermission "server", "monitor";
 
+  // getProtectionDomain is an optional permission needed for printing classpath
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
 };
 
 grant codeBase "${derby.install.url}derbynet.jar"

Modified: db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/template.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/template.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/template.policy (original)
+++ db/derby/code/branches/10.5/java/drda/org/apache/derby/drda/template.policy Wed Aug  4
20:57:03 2010
@@ -76,6 +76,10 @@ grant codeBase "${derby.install.url}derb
 //
   permission javax.management.MBeanTrustPermission "register";
 
+  // getProtectionDomain is an optional permission needed for printing classpath
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
+
 };
 
 grant codeBase "${derby.install.url}derbynet.jar"

Modified: db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/services/i18n/MessageService.java
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/services/i18n/MessageService.java?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/services/i18n/MessageService.java
(original)
+++ db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/services/i18n/MessageService.java
Wed Aug  4 20:57:03 2010
@@ -81,6 +81,9 @@ public final class MessageService {
 	public static String getTextMessage(String messageID, Object a1, Object a2, Object a3, Object
a4) {
 		return getCompleteMessage(messageID, new Object[]{a1, a2, a3, a4});
 	}
+    public static String getTextMessage(String messageID, Object a1, Object a2, Object a3,
Object a4, Object a5) {
+        return getCompleteMessage(messageID, new Object[]{a1, a2, a3, a4, a5});
+    }
 
 	/**
 	  Transform the message from messageID to the actual error, warning, or

Modified: db/derby/code/branches/10.5/java/engine/org/apache/derby/impl/store/raw/data/BaseDataFileFactory.java
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/engine/org/apache/derby/impl/store/raw/data/BaseDataFileFactory.java?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/engine/org/apache/derby/impl/store/raw/data/BaseDataFileFactory.java
(original)
+++ db/derby/code/branches/10.5/java/engine/org/apache/derby/impl/store/raw/data/BaseDataFileFactory.java
Wed Aug  4 20:57:03 2010
@@ -91,8 +91,13 @@ import java.util.Enumeration;
 
 import java.io.File;
 import java.io.IOException;
+import java.io.UnsupportedEncodingException;
+
+import java.net.URL;
+import java.net.URLDecoder;
 
 import java.security.AccessController;
+import java.security.CodeSource;
 import java.security.PrivilegedAction;
 import java.security.PrivilegedExceptionAction;
 import java.security.PrivilegedActionException;
@@ -137,6 +142,10 @@ public class BaseDataFileFactory
 	private     LogFactory	    logFactory;
 
 	private     ProductVersionHolder jbmsVersion;
+	
+	private     String          jvmVersion;
+	
+	private     String          jarCPath;
 
 	private     RawStoreFactory	rawStoreFactory; // associated raw store factory
 
@@ -261,6 +270,10 @@ public class BaseDataFileFactory
     {
 
 		jbmsVersion = Monitor.getMonitor().getEngineVersion();
+		
+		jvmVersion = buildJvmVersion();
+		
+		jarCPath = jarClassPath(getClass());
 
 		dataDirectory = startParams.getProperty(PersistentService.ROOT);
 
@@ -360,10 +373,13 @@ public class BaseDataFileFactory
 			   MessageService.getTextMessage(MessageId.STORE_BOOT_MSG,
                                              jbmsVersion,
                                              identifier,
-                                             dataDirectory + " " + readOnlyMsg,
                                              // cast to Object so we get object hash code
-                                             (Object) this.getClass().getClassLoader()
+                                             dataDirectory + " " + readOnlyMsg,
+                                             (Object) this.getClass().getClassLoader(),
+                                             jarCPath
                                              ));
+		//Log the JVM version info
+		logMsg(jvmVersion);
 
         if (logBootTrace)
            Monitor.logThrowable(new Throwable("boot trace"));
@@ -2144,8 +2160,70 @@ public class BaseDataFileFactory
         containerEncrypter.removeOldVersionOfContainers(inRecovery);
         containerEncrypter = null;
     }
-
-
+ 
+    
+    /**
+     * Return a jar file by asking the class's 
+     * class loader for the location where the class was loaded from. 
+     * If no value, it returns null
+     * @param cls the Class to ask to print the class name of an object
+     *
+     * @return the ClassPath of a jar file
+     **/
+    private static String jarClassPath(final Class cls)
+    {
+        return (String)AccessController.doPrivileged( new PrivilegedAction()
+        {
+          public Object run()
+          {
+              CodeSource cs = null;
+              try {
+                  cs = cls.getProtectionDomain().getCodeSource();
+              }
+              catch (SecurityException se) {
+                  return se.getMessage();
+              }
+  
+              if ( cs == null )
+                  return null;        
+      
+              URL result = cs.getLocation ();
+      
+              return result.toString();
+          }
+        });
+    }
+    
+    
+    /**
+     * Return values of system properties that identify the JVM. 
+     * Will catch SecurityExceptions and note them for displaying information.
+     * @return the Java system property value from the JVM or a string capturing a
+     * security exception.
+     */
+    private static String buildJvmVersion () {
+        return (String)AccessController.doPrivileged( new PrivilegedAction()
+        {
+           public Object run()
+           {      
+             String jvmversion = "";
+             try {
+                 String currentProp  = PropertyUtil.getSystemProperty("java.vendor");
+                 if ( currentProp != null)
+                     jvmversion = "java.vendor=" + currentProp;
+                 if ((currentProp = PropertyUtil.getSystemProperty("java.runtime.version"))
!= null)
+                     jvmversion += "\njava.runtime.version=" + currentProp;
+                 if ((currentProp = PropertyUtil.getSystemProperty("java.fullversion")) !=
null)
+                     jvmversion += "\njava.fullversion=" + currentProp ;         
+              }
+              catch (SecurityException se) {
+                   return se.getMessage();
+              }
+              return jvmversion;
+            }
+        });
+    } // end of buildjvmVersion
+        
 	/**
 		Returns the encryption block size used by the algorithm at time of
 		creation of an encrypted database

Modified: db/derby/code/branches/10.5/java/engine/org/apache/derby/loc/messages.xml
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/engine/org/apache/derby/loc/messages.xml?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/engine/org/apache/derby/loc/messages.xml (original)
+++ db/derby/code/branches/10.5/java/engine/org/apache/derby/loc/messages.xml Wed Aug  4 20:57:03
2010
@@ -7295,13 +7295,14 @@ MessageId.java.
             <msg>
                 <name>D001</name>
                 <text>:
- Booting Derby version {0}: instance {1} 
-on database directory {2}  with class loader {3}
-</text>
+Booting Derby version {0}: instance {1} 
+on database directory {2} with class loader {3} 
+Loaded from {4}</text>
                 <arg>derbyVersion</arg>
                 <arg>id</arg>
                 <arg>directoryName</arg>
                 <arg>classloader</arg>
+                <arg>JarClassPath</arg>
             </msg>
 
             <msg>

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/GetCurrentPropertiesTest.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/GetCurrentPropertiesTest.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/GetCurrentPropertiesTest.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/GetCurrentPropertiesTest.policy
Wed Aug  4 20:57:03 2010
@@ -59,6 +59,10 @@ grant codeBase "${derbyTesting.codejar}d
   permission java.lang.RuntimePermission "createClassLoader";
   permission java.security.SecurityPermission "getPolicy";
   
+  // getProtectionDomain is an optional permission needed for printing classpath
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
+
   permission java.io.FilePermission "${derby.system.home}${/}derby.properties", "read";
   permission java.io.FilePermission "${derby.system.home}${/}derby.log", "read, write, delete";
   // [DERBY-2000] The write permission was added to allow creation of the

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/NetworkServerControlApiTest.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/NetworkServerControlApiTest.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/NetworkServerControlApiTest.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/NetworkServerControlApiTest.policy
Wed Aug  4 20:57:03 2010
@@ -59,6 +59,10 @@ grant codeBase "${derbyTesting.codejar}d
   permission java.lang.RuntimePermission "createClassLoader";
   permission java.security.SecurityPermission "getPolicy";
   
+  // getProtectionDomain is an optional permission needed for printing classpath
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
+
   permission java.io.FilePermission "${derby.system.home}${/}derby.properties", "read";
   permission java.io.FilePermission "${derby.system.home}${/}derby.log", "read, write, delete";
   // [DERBY-2000] The write permission was added to allow creation of the

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ServerPropertiesTest.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ServerPropertiesTest.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ServerPropertiesTest.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/ServerPropertiesTest.policy
Wed Aug  4 20:57:03 2010
@@ -58,6 +58,10 @@ grant codeBase "${derbyTesting.codejar}d
 
   permission java.lang.RuntimePermission "createClassLoader";
   permission java.security.SecurityPermission "getPolicy";
+
+  // getProectionDomain is an optional permission needed for printing classpath
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
   
   permission java.io.FilePermission "${derby.system.home}${/}derby.properties", "read";
   permission java.io.FilePermission "${derby.system.home}${/}derby.log", "read, write, delete";

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/SysinfoTest.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/SysinfoTest.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/SysinfoTest.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/SysinfoTest.policy
Wed Aug  4 20:57:03 2010
@@ -61,6 +61,10 @@ grant codeBase "${derbyTesting.codejar}d
 
   permission java.lang.RuntimePermission "createClassLoader";
 
+  // getProtectionDomain is an optional permission needed for printing classpath
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
+
   // permissions so that we can set the context class loader to
   // null for daemon threads to avoid class loader leak.
   // DERBY-3745

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/LDAPTests.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/LDAPTests.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/LDAPTests.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/LDAPTests.policy
Wed Aug  4 20:57:03 2010
@@ -49,7 +49,7 @@
 //
 grant codeBase "${derbyTesting.codejar}derby.jar" {
   permission java.util.PropertyPermission "derby.*", "read";
-permission java.util.PropertyPermission "derby.storage.jvmInstanceId", 
+  permission java.util.PropertyPermission "derby.storage.jvmInstanceId", 
       "write"; 
   permission java.util.PropertyPermission "java.class.path", "read";//sysinfo
   permission java.util.PropertyPermission "java.runtime.version", "read";//sysinfo
@@ -62,6 +62,10 @@ permission java.util.PropertyPermission 
   permission java.lang.RuntimePermission "createClassLoader";
   permission java.security.SecurityPermission "getPolicy";
   
+  // getProtectionDomain is an optional permission needed for printing classpath 
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
+  
   permission java.io.FilePermission "${derby.system.home}${/}derby.properties", "read";
   permission java.io.FilePermission "${derby.system.home}${/}derby.log", "read, write, delete";
   // [DERBY-2000] The write permission was added to allow creation of the

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.initial.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.initial.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.initial.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.initial.policy
Wed Aug  4 20:57:03 2010
@@ -30,6 +30,9 @@ grant codeBase "${derbyTesting.codejar}d
   permission java.io.FilePermission "${derby.system.home}","read";
   permission java.io.FilePermission "${derby.system.home}${/}-", "read,write,delete";
 
+// getProtectionDomain is an optional permission needed for printing classpath information
+// to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
 //
 // This permission lets a DBA reload this policy file while the server
 // is still running.

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.modified.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.modified.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.modified.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.modified.policy
Wed Aug  4 20:57:03 2010
@@ -30,6 +30,9 @@ grant codeBase "${derbyTesting.codejar}d
   permission java.io.FilePermission "${derby.system.home}","read";
   permission java.io.FilePermission "${derby.system.home}${/}-", "read,write,delete";
 
+// getProtectionDomain is an optional permission needed for printing classpath
+// information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
 //
 // This permission lets a DBA reload this policy file while the server
 // is still running.

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.unreloadable.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.unreloadable.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.unreloadable.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/lang/SecurityPolicyReloadingTest.unreloadable.policy
Wed Aug  4 20:57:03 2010
@@ -58,6 +58,10 @@ permission java.util.PropertyPermission 
 
   permission java.lang.RuntimePermission "createClassLoader";
 
+  // getProtectionDomain is an optional permission needed for printing classpath 
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
+
   //
   // This permission deliberately omitted.
   //

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/unit/fillLog.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/unit/fillLog.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/unit/fillLog.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/unit/fillLog.policy
Wed Aug  4 20:57:03 2010
@@ -1,5 +1,5 @@
 //
-// *  Derby - Class org.apache.derbyTesting.functionTests.tests.lang.SimpleTest
+// *  Derby - Class org.apache.derbyTesting.functionTests.tests.unit.fillLog.policy
 // *  
 // * Licensed to the Apache Software Foundation (ASF) under one
 // * or more contributor license agreements.  See the NOTICE file

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/derby_tests.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/derby_tests.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/derby_tests.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/derby_tests.policy
Wed Aug  4 20:57:03 2010
@@ -47,7 +47,7 @@
 //
 grant codeBase "${derbyTesting.codejar}derby.jar" {
   permission java.util.PropertyPermission "derby.*", "read";
-permission java.util.PropertyPermission "derby.storage.jvmInstanceId", 
+  permission java.util.PropertyPermission "derby.storage.jvmInstanceId", 
       "write"; 
   // The next two properties are used to determine if the VM is 32 or 64 bit.
   permission java.util.PropertyPermission "sun.arch.data.model", "read";
@@ -62,6 +62,10 @@ permission java.util.PropertyPermission 
 
   permission java.lang.RuntimePermission "createClassLoader";
 
+  // getProtectionDomain is an optional permission needed for printing classpath
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
+
   // permissions so that we can set the context class loader to
   // null for daemon threads to avoid class loader leak.
   // DERBY-3745

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/nwsvr.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/nwsvr.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/nwsvr.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/util/nwsvr.policy
Wed Aug  4 20:57:03 2010
@@ -32,6 +32,10 @@ permission java.util.PropertyPermission 
 
 permission java.lang.RuntimePermission "createClassLoader";
 
+// getProectionDomain is an optional permission needed to printing classpath 
+// information to derby.log
+permission java.lang.RuntimePermission "getProtectionDomain";
+
 // These permissions are needed to load the JCE for encryption with JDK131.
 // JDK14 has the JCE  preloaded
 permission java.security.SecurityPermission "createAccessControlContext";

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/AssertFailureTest.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/AssertFailureTest.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/AssertFailureTest.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/AssertFailureTest.policy
Wed Aug  4 20:57:03 2010
@@ -97,6 +97,10 @@ grant codeBase "${derbyTesting.codejar}d
   permission java.lang.RuntimePermission "getStackTrace";
   permission java.lang.RuntimePermission "modifyThreadGroup";
 //-----------------------------------------------------------------------------
+
+// getProtectionDomain is an optional permission needed for printing classpath 
+// information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
 };
 
 

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest.policy
Wed Aug  4 20:57:03 2010
@@ -99,6 +99,10 @@ grant codeBase "${derbyTesting.codejar}d
   // Because this unit test involves some relative and absolute sample paths,
   // we liberally grant read access to all files.
   permission java.io.FilePermission "<<ALL FILES>>", "read";
+  
+  // getProtectionDomain is an optional permission needed for printing classpath 
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
 };
 
 //

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest1.policy
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest1.policy?rev=982401&r1=982400&r2=982401&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest1.policy
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/unitTests/junit/SystemPrivilegesPermissionTest1.policy
Wed Aug  4 20:57:03 2010
@@ -79,6 +79,10 @@ grant codeBase "${derbyTesting.codejar}d
   // Because this unit test involves some relative and absolute sample paths,
   // we liberally grant read access to all files.
   permission java.io.FilePermission "<<ALL FILES>>", "read";
+
+  // getProtectionDomain is an optional permission needed for printing classpath 
+  // information to derby.log
+  permission java.lang.RuntimePermission "getProtectionDomain";
 };
 
 //



Mime
View raw message