Author: jfrederic.clere(a)jboss.com
Date: 2007-12-07 10:04:29 -0500 (Fri, 07 Dec 2007)
New Revision: 372
Modified:
trunk/java/org/apache/catalina/core/AprLifecycleListener.java
trunk/java/org/apache/tomcat/jni/SSL.java
Log:
Don't load the entropy but sets the name of file the entropy is collected from.
Modified: trunk/java/org/apache/catalina/core/AprLifecycleListener.java
===================================================================
--- trunk/java/org/apache/catalina/core/AprLifecycleListener.java 2007-12-06 18:16:40 UTC
(rev 371)
+++ trunk/java/org/apache/catalina/core/AprLifecycleListener.java 2007-12-07 15:04:29 UTC
(rev 372)
@@ -205,17 +205,17 @@
//only once per VM
return;
}
- String methodName = "initialize";
+ String methodName = "randSet";
Class paramTypes[] = new Class[1];
paramTypes[0] = String.class;
Object paramValues[] = new Object[1];
- paramValues[0] = "on".equalsIgnoreCase(SSLEngine)?null:SSLEngine;
+ paramValues[0] = SSLRandomSeed;
Class clazz = Class.forName("org.apache.tomcat.jni.SSL");
Method method = clazz.getMethod(methodName, paramTypes);
method.invoke(null, paramValues);
- methodName = "randLoad";
- paramValues[0] = SSLRandomSeed;
+ methodName = "initialize";
+ paramValues[0] = "on".equalsIgnoreCase(SSLEngine)?null:SSLEngine;
method = clazz.getMethod(methodName, paramTypes);
method.invoke(null, paramValues);
Modified: trunk/java/org/apache/tomcat/jni/SSL.java
===================================================================
--- trunk/java/org/apache/tomcat/jni/SSL.java 2007-12-06 18:16:40 UTC (rev 371)
+++ trunk/java/org/apache/tomcat/jni/SSL.java 2007-12-07 15:04:29 UTC (rev 372)
@@ -227,6 +227,12 @@
public static native int initialize(String engine);
/**
+ * Set source of entropy to use in SSL
+ * @param filename Filename containing random data
+ */
+ public static native boolean randSet(String filename);
+
+ /**
* Add content of the file to the PRNG
* @param filename Filename containing random data.
* If null the default file will be tested.
Show replies by date