Lines 23-29
Link Here
|
23 |
|
23 |
|
24 |
import org.apache.catalina.Lifecycle; |
24 |
import org.apache.catalina.Lifecycle; |
25 |
import org.apache.catalina.LifecycleEvent; |
25 |
import org.apache.catalina.LifecycleEvent; |
|
|
26 |
import org.apache.catalina.LifecycleException; |
26 |
import org.apache.catalina.LifecycleListener; |
27 |
import org.apache.catalina.LifecycleListener; |
|
|
28 |
import org.apache.catalina.LifecycleState; |
27 |
import org.apache.juli.logging.Log; |
29 |
import org.apache.juli.logging.Log; |
28 |
import org.apache.juli.logging.LogFactory; |
30 |
import org.apache.juli.logging.LogFactory; |
29 |
import org.apache.tomcat.jni.Library; |
31 |
import org.apache.tomcat.jni.Library; |
Lines 38-57
Link Here
|
38 |
* |
40 |
* |
39 |
* @author Remy Maucherat |
41 |
* @author Remy Maucherat |
40 |
* @author Filip Hanik |
42 |
* @author Filip Hanik |
|
|
43 |
* @author cbeckey@gmail.com added FIPS Mode and group library loading |
41 |
* @version $Id$ |
44 |
* @version $Id$ |
42 |
* @since 4.1 |
45 |
* @since 4.1 |
43 |
*/ |
46 |
*/ |
44 |
|
47 |
|
45 |
public class AprLifecycleListener |
48 |
public class AprLifecycleListener |
46 |
implements LifecycleListener { |
49 |
implements LifecycleListener |
|
|
50 |
{ |
47 |
|
51 |
|
48 |
private static final Log log = LogFactory.getLog(AprLifecycleListener.class); |
52 |
private static final Log log = LogFactory.getLog(AprLifecycleListener.class); |
49 |
private static boolean instanceCreated = false; |
53 |
private static boolean instanceCreated = false; |
|
|
54 |
|
50 |
/** |
55 |
/** |
51 |
* The string manager for this package. |
56 |
* The string manager for this package. |
52 |
*/ |
57 |
*/ |
53 |
protected static final StringManager sm = |
58 |
protected static final StringManager stringManager = StringManager.getManager(Constants.Package); |
54 |
StringManager.getManager(Constants.Package); |
|
|
55 |
|
59 |
|
56 |
|
60 |
|
57 |
// ---------------------------------------------- Constants |
61 |
// ---------------------------------------------- Constants |
Lines 66-74
Link Here
|
66 |
|
70 |
|
67 |
// ---------------------------------------------- Properties |
71 |
// ---------------------------------------------- Properties |
68 |
protected static String SSLEngine = "on"; //default on |
72 |
protected static String SSLEngine = "on"; //default on |
|
|
73 |
protected static String FIPSMode = "off"; //default off, valid only when SSLEngine is 'on' |
69 |
protected static String SSLRandomSeed = "builtin"; |
74 |
protected static String SSLRandomSeed = "builtin"; |
70 |
protected static boolean sslInitialized = false; |
75 |
protected static boolean sslInitialized = false; |
71 |
protected static boolean aprInitialized = false; |
76 |
protected static boolean aprInitialized = false; |
|
|
77 |
protected static boolean fipsModeActive = false; |
72 |
protected static boolean sslAvailable = false; |
78 |
protected static boolean sslAvailable = false; |
73 |
protected static boolean aprAvailable = false; |
79 |
protected static boolean aprAvailable = false; |
74 |
|
80 |
|
Lines 78-90
Link Here
|
78 |
//https://issues.apache.org/bugzilla/show_bug.cgi?id=48613 |
84 |
//https://issues.apache.org/bugzilla/show_bug.cgi?id=48613 |
79 |
if (instanceCreated) { |
85 |
if (instanceCreated) { |
80 |
synchronized (lock) { |
86 |
synchronized (lock) { |
81 |
init(); |
87 |
initializeAPR(); |
82 |
} |
88 |
} |
83 |
} |
89 |
} |
84 |
return aprAvailable; |
90 |
return aprAvailable; |
85 |
} |
91 |
} |
86 |
|
92 |
|
87 |
public AprLifecycleListener() { |
93 |
public AprLifecycleListener() |
|
|
94 |
{ |
88 |
instanceCreated = true; |
95 |
instanceCreated = true; |
89 |
} |
96 |
} |
90 |
|
97 |
|
Lines 96-125
Link Here
|
96 |
* @param event The event that has occurred |
103 |
* @param event The event that has occurred |
97 |
*/ |
104 |
*/ |
98 |
@Override |
105 |
@Override |
99 |
public void lifecycleEvent(LifecycleEvent event) { |
106 |
public void lifecycleEvent(LifecycleEvent event) |
100 |
|
107 |
{ |
101 |
if (Lifecycle.BEFORE_INIT_EVENT.equals(event.getType())) { |
108 |
if (Lifecycle.BEFORE_INIT_EVENT.equals(event.getType())) |
102 |
synchronized (lock) { |
109 |
{ |
103 |
init(); |
110 |
synchronized (lock) |
104 |
if (aprAvailable) { |
111 |
{ |
105 |
try { |
112 |
initializeAPR(); |
|
|
113 |
if (aprAvailable) |
114 |
try |
115 |
{ |
106 |
initializeSSL(); |
116 |
initializeSSL(); |
107 |
} catch (Throwable t) { |
117 |
} |
|
|
118 |
catch (Throwable t) |
119 |
{ |
108 |
ExceptionUtils.handleThrowable(t); |
120 |
ExceptionUtils.handleThrowable(t); |
109 |
log.info(sm.getString("aprListener.sslInit")); |
121 |
log.info(stringManager.getString("aprListener.sslInit")); |
110 |
} |
122 |
} |
111 |
} |
|
|
112 |
} |
123 |
} |
113 |
} else if (Lifecycle.AFTER_DESTROY_EVENT.equals(event.getType())) { |
124 |
} |
114 |
synchronized (lock) { |
125 |
else if (Lifecycle.AFTER_DESTROY_EVENT.equals(event.getType())) |
115 |
if (!aprAvailable) { |
126 |
{ |
|
|
127 |
synchronized (lock) |
128 |
{ |
129 |
if (!aprAvailable) |
116 |
return; |
130 |
return; |
117 |
} |
131 |
|
118 |
try { |
132 |
try |
|
|
133 |
{ |
119 |
terminateAPR(); |
134 |
terminateAPR(); |
120 |
} catch (Throwable t) { |
135 |
} |
|
|
136 |
catch (Throwable t) |
137 |
{ |
121 |
ExceptionUtils.handleThrowable(t); |
138 |
ExceptionUtils.handleThrowable(t); |
122 |
log.info(sm.getString("aprListener.aprDestroy")); |
139 |
log.info(stringManager.getString("aprListener.aprDestroy")); |
123 |
} |
140 |
} |
124 |
} |
141 |
} |
125 |
} |
142 |
} |
Lines 127-179
Link Here
|
127 |
} |
144 |
} |
128 |
|
145 |
|
129 |
private static void terminateAPR() |
146 |
private static void terminateAPR() |
130 |
throws ClassNotFoundException, NoSuchMethodException, |
147 |
throws ClassNotFoundException, NoSuchMethodException, IllegalAccessException, InvocationTargetException |
131 |
IllegalAccessException, InvocationTargetException |
|
|
132 |
{ |
148 |
{ |
133 |
String methodName = "terminate"; |
149 |
String methodName = "terminate"; |
134 |
Method method = Class.forName("org.apache.tomcat.jni.Library") |
150 |
Method method = Class.forName("org.apache.tomcat.jni.Library").getMethod(methodName, (Class [])null); |
135 |
.getMethod(methodName, (Class [])null); |
|
|
136 |
method.invoke(null, (Object []) null); |
151 |
method.invoke(null, (Object []) null); |
137 |
aprAvailable = false; |
152 |
aprAvailable = false; |
138 |
aprInitialized = false; |
153 |
aprInitialized = false; |
|
|
154 |
fipsModeActive = false; |
155 |
sslAvailable = false; // Well we cleaned the pool in terminate. |
139 |
sslInitialized = false; // Well we cleaned the pool in terminate. |
156 |
sslInitialized = false; // Well we cleaned the pool in terminate. |
140 |
} |
157 |
} |
141 |
|
158 |
|
142 |
private static void init() |
159 |
private static void initializeAPR() |
143 |
{ |
160 |
{ |
144 |
int major = 0; |
161 |
int major = 0; |
145 |
int minor = 0; |
162 |
int minor = 0; |
146 |
int patch = 0; |
163 |
int patch = 0; |
|
|
164 |
|
165 |
// installed version |
147 |
int apver = 0; |
166 |
int apver = 0; |
|
|
167 |
|
168 |
// required version |
148 |
int rqver = TCN_REQUIRED_MAJOR * 1000 + TCN_REQUIRED_MINOR * 100 + TCN_REQUIRED_PATCH; |
169 |
int rqver = TCN_REQUIRED_MAJOR * 1000 + TCN_REQUIRED_MINOR * 100 + TCN_REQUIRED_PATCH; |
|
|
170 |
|
171 |
// recommended version |
149 |
int rcver = TCN_REQUIRED_MAJOR * 1000 + TCN_REQUIRED_MINOR * 100 + TCN_RECOMMENDED_PV; |
172 |
int rcver = TCN_REQUIRED_MAJOR * 1000 + TCN_REQUIRED_MINOR * 100 + TCN_RECOMMENDED_PV; |
150 |
|
173 |
|
151 |
if (aprInitialized) { |
174 |
if (aprInitialized) |
152 |
return; |
175 |
return; |
153 |
} |
176 |
|
154 |
aprInitialized = true; |
177 |
aprInitialized = true; // aprInitialized indicates whether initialization has been attempted |
|
|
178 |
// aprAvailable indicates whether initialization has succeeded |
155 |
|
179 |
|
156 |
try { |
180 |
try |
|
|
181 |
{ |
182 |
Class<?> clazz = Class.forName("org.apache.tomcat.jni.Library"); |
157 |
String methodName = "initialize"; |
183 |
String methodName = "initialize"; |
158 |
Class<?> paramTypes[] = new Class[1]; |
184 |
Class<?> paramTypes[] = new Class[]{String.class}; |
159 |
paramTypes[0] = String.class; |
185 |
Object paramValues[] = new Object[]{null}; |
160 |
Object paramValues[] = new Object[1]; |
|
|
161 |
paramValues[0] = null; |
162 |
Class<?> clazz = Class.forName("org.apache.tomcat.jni.Library"); |
163 |
Method method = clazz.getMethod(methodName, paramTypes); |
186 |
Method method = clazz.getMethod(methodName, paramTypes); |
164 |
method.invoke(null, paramValues); |
187 |
method.invoke(null, paramValues); // invoke the static "initialize" method |
|
|
188 |
|
165 |
major = clazz.getField("TCN_MAJOR_VERSION").getInt(null); |
189 |
major = clazz.getField("TCN_MAJOR_VERSION").getInt(null); |
166 |
minor = clazz.getField("TCN_MINOR_VERSION").getInt(null); |
190 |
minor = clazz.getField("TCN_MINOR_VERSION").getInt(null); |
167 |
patch = clazz.getField("TCN_PATCH_VERSION").getInt(null); |
191 |
patch = clazz.getField("TCN_PATCH_VERSION").getInt(null); |
168 |
apver = major * 1000 + minor * 100 + patch; |
192 |
apver = major * 1000 + minor * 100 + patch; |
169 |
} catch (Throwable t) { |
193 |
} |
|
|
194 |
catch (Throwable t) |
195 |
{ |
170 |
ExceptionUtils.handleThrowable(t); |
196 |
ExceptionUtils.handleThrowable(t); |
171 |
log.info(sm.getString("aprListener.aprInit", |
197 |
log.info(stringManager.getString("aprListener.aprInit", |
172 |
System.getProperty("java.library.path"))); |
198 |
System.getProperty("java.library.path"))); |
173 |
return; |
199 |
return; |
174 |
} |
200 |
} |
175 |
if (apver < rqver) { |
201 |
if (apver < rqver) |
176 |
log.error(sm.getString("aprListener.tcnInvalid", major + "." |
202 |
{ |
|
|
203 |
log.error(stringManager.getString("aprListener.tcnInvalid", major + "." |
177 |
+ minor + "." + patch, |
204 |
+ minor + "." + patch, |
178 |
TCN_REQUIRED_MAJOR + "." + |
205 |
TCN_REQUIRED_MAJOR + "." + |
179 |
TCN_REQUIRED_MINOR + "." + |
206 |
TCN_REQUIRED_MINOR + "." + |
Lines 187-224
Link Here
|
187 |
} |
214 |
} |
188 |
return; |
215 |
return; |
189 |
} |
216 |
} |
190 |
if (apver < rcver) { |
217 |
if (apver < rcver) |
191 |
log.info(sm.getString("aprListener.tcnVersion", major + "." |
218 |
{ |
|
|
219 |
log.info(stringManager.getString("aprListener.tcnVersion", major + "." |
192 |
+ minor + "." + patch, |
220 |
+ minor + "." + patch, |
193 |
TCN_REQUIRED_MAJOR + "." + |
221 |
TCN_REQUIRED_MAJOR + "." + |
194 |
TCN_RECOMMENDED_MINOR + "." + |
222 |
TCN_RECOMMENDED_MINOR + "." + |
195 |
TCN_RECOMMENDED_PV)); |
223 |
TCN_RECOMMENDED_PV)); |
196 |
} |
224 |
} |
197 |
|
225 |
|
198 |
log.info(sm.getString("aprListener.tcnValid", major + "." |
226 |
log.info(stringManager.getString("aprListener.tcnValid", major + "." |
199 |
+ minor + "." + patch)); |
227 |
+ minor + "." + patch)); |
200 |
|
228 |
|
201 |
// Log APR flags |
229 |
// Log APR flags |
202 |
log.info(sm.getString("aprListener.flags", |
230 |
log.info(stringManager.getString("aprListener.flags", |
203 |
Boolean.valueOf(Library.APR_HAVE_IPV6), |
231 |
Boolean.valueOf(Library.APR_HAVE_IPV6), |
204 |
Boolean.valueOf(Library.APR_HAS_SENDFILE), |
232 |
Boolean.valueOf(Library.APR_HAS_SENDFILE), |
205 |
Boolean.valueOf(Library.APR_HAS_SO_ACCEPTFILTER), |
233 |
Boolean.valueOf(Library.APR_HAS_SO_ACCEPTFILTER), |
206 |
Boolean.valueOf(Library.APR_HAS_RANDOM))); |
234 |
Boolean.valueOf(Library.APR_HAS_RANDOM))); |
|
|
235 |
|
236 |
// initialization is complete and the library version(s) are compatible |
207 |
aprAvailable = true; |
237 |
aprAvailable = true; |
208 |
} |
238 |
} |
209 |
|
239 |
|
|
|
240 |
/** |
241 |
* |
242 |
* @throws ClassNotFoundException |
243 |
* @throws NoSuchMethodException |
244 |
* @throws IllegalAccessException |
245 |
* @throws InvocationTargetException |
246 |
*/ |
210 |
private static void initializeSSL() |
247 |
private static void initializeSSL() |
211 |
throws ClassNotFoundException, NoSuchMethodException, |
248 |
throws ClassNotFoundException, NoSuchMethodException, IllegalAccessException, InvocationTargetException |
212 |
IllegalAccessException, InvocationTargetException |
|
|
213 |
{ |
249 |
{ |
214 |
|
250 |
if ("off".equalsIgnoreCase(SSLEngine)) |
215 |
if ("off".equalsIgnoreCase(SSLEngine)) { |
|
|
216 |
return; |
251 |
return; |
217 |
} |
252 |
|
218 |
if (sslInitialized) { |
253 |
//only once per VM |
219 |
//only once per VM |
254 |
if (sslInitialized) |
220 |
return; |
255 |
return; |
221 |
} |
|
|
222 |
sslInitialized = true; |
256 |
sslInitialized = true; |
223 |
|
257 |
|
224 |
String methodName = "randSet"; |
258 |
String methodName = "randSet"; |
Lines 230-258
Link Here
|
230 |
Method method = clazz.getMethod(methodName, paramTypes); |
264 |
Method method = clazz.getMethod(methodName, paramTypes); |
231 |
method.invoke(null, paramValues); |
265 |
method.invoke(null, paramValues); |
232 |
|
266 |
|
233 |
|
|
|
234 |
methodName = "initialize"; |
267 |
methodName = "initialize"; |
235 |
paramValues[0] = "on".equalsIgnoreCase(SSLEngine)?null:SSLEngine; |
268 |
paramValues[0] = "on".equalsIgnoreCase(SSLEngine)?null:SSLEngine; |
236 |
method = clazz.getMethod(methodName, paramTypes); |
269 |
method = clazz.getMethod(methodName, paramTypes); |
237 |
method.invoke(null, paramValues); |
270 |
method.invoke(null, paramValues); |
238 |
|
271 |
|
|
|
272 |
boolean initializeFIPS = isFIPSModeOn(); |
273 |
if(initializeFIPS) |
274 |
{ |
275 |
log.info( stringManager.getString("aprListener.initializingFIPS") ); |
276 |
boolean success = initializeFIPS(); |
277 |
if(success) |
278 |
log.info( stringManager.getString("aprListener.initializeFIPSSuccess") ); |
279 |
else |
280 |
{ |
281 |
String msg = stringManager.getString("aprListener.initializeFIPSFailed"); |
282 |
log.info( msg ); |
283 |
|
284 |
// do not allow SSL to be called if FIPS was requested but did not initialize |
285 |
throw new InvocationTargetException(null, msg); |
286 |
} |
287 |
} |
288 |
|
239 |
sslAvailable = true; |
289 |
sslAvailable = true; |
240 |
} |
290 |
} |
241 |
|
291 |
|
242 |
public String getSSLEngine() { |
292 |
/** |
|
|
293 |
* Initialize FIPS mode in a way that won't crash if the FIPS libtcnative |
294 |
* and associated libraries are not available. |
295 |
* |
296 |
* @param initializeFIPS |
297 |
* @return |
298 |
*/ |
299 |
private static boolean initializeFIPS() |
300 |
throws NoSuchMethodException |
301 |
{ |
302 |
try |
303 |
{ |
304 |
Class<?> clazz = Class.forName("org.apache.tomcat.jni.SSL"); |
305 |
String methodName = "fipsModeSet"; |
306 |
Method method = clazz.getMethod(methodName, new Class[]{Integer.class}); |
307 |
Object[] fipsParamValues = new Object[]{Integer.valueOf(1)}; |
308 |
Object result = method.invoke(null, fipsParamValues); |
309 |
if(result instanceof Integer) |
310 |
{ |
311 |
fipsModeActive = ((Integer) result).intValue() > 0; |
312 |
return fipsModeActive; // success is a return value greater than zero |
313 |
} |
314 |
else |
315 |
log.info( stringManager.getString("aprListener.fipsModeSetInvalid") ); |
316 |
} |
317 |
catch(InvocationTargetException itX) |
318 |
{ |
319 |
log.info( stringManager.getString("aprListener.fipsModeUnavailable") + "\n" + itX.getMessage() ); |
320 |
} |
321 |
catch (Throwable t) |
322 |
{ |
323 |
if (!log.isDebugEnabled()) |
324 |
log.debug(stringManager.getString("aprListener.aprInit", System.getProperty("java.library.path")), t); |
325 |
else |
326 |
log.info(stringManager.getString("aprListener.aprInit", System.getProperty("java.library.path"))); |
327 |
} |
328 |
return false; |
329 |
} |
330 |
|
331 |
/** |
332 |
* Determine if the SSL property is set in the AprLifecycleListener configuration (i.e. SSL is requested to be available) |
333 |
* |
334 |
* @return |
335 |
*/ |
336 |
public static boolean isSSLOn() |
337 |
{ |
338 |
return ! "off".equalsIgnoreCase(AprLifecycleListener.SSLEngine); |
339 |
} |
340 |
|
341 |
/** |
342 |
* Determine if the FIPSMode property is set in the AprLifecycleListener configuration (i.e. FIPS mode must be on) |
343 |
* |
344 |
* @return |
345 |
*/ |
346 |
public static boolean isFIPSModeOn() |
347 |
{ |
348 |
return "on".equalsIgnoreCase(AprLifecycleListener.FIPSMode); |
349 |
} |
350 |
|
351 |
/** |
352 |
* If FIPS mode has been requested and was successfully initialized then return TRUE, |
353 |
* else return FALSE |
354 |
* |
355 |
* @return |
356 |
*/ |
357 |
public boolean isFIPSModeActive() |
358 |
{ |
359 |
return fipsModeActive; |
360 |
} |
361 |
|
362 |
public String getSSLEngine() |
363 |
{ |
243 |
return SSLEngine; |
364 |
return SSLEngine; |
244 |
} |
365 |
} |
245 |
|
366 |
|
246 |
public void setSSLEngine(String SSLEngine) { |
367 |
/** |
247 |
AprLifecycleListener.SSLEngine = SSLEngine; |
368 |
* The SSLEngine must be set before SSL is initialized, else this will have no effect. |
|
|
369 |
* |
370 |
* @param SSLEngine |
371 |
*/ |
372 |
public void setSSLEngine(String SSLEngine) |
373 |
{ |
374 |
if(! sslInitialized) // added so that the random seem class being used is consistent with that returned from getSSLEngine |
375 |
AprLifecycleListener.SSLEngine = SSLEngine; |
248 |
} |
376 |
} |
249 |
|
377 |
|
250 |
public String getSSLRandomSeed() { |
378 |
public String getFIPSMode() |
|
|
379 |
{ |
380 |
return AprLifecycleListener.FIPSMode; |
381 |
} |
382 |
|
383 |
/** |
384 |
* FIPSMode must be set before SSL is initialized, else this will have no effect. |
385 |
* |
386 |
* @param FIPSMode |
387 |
*/ |
388 |
public void setFIPSMode(String FIPSMode) |
389 |
{ |
390 |
if(! sslInitialized) // added so that the random seem class being used is consistent with that returned from getFIPSMode |
391 |
AprLifecycleListener.FIPSMode = FIPSMode; |
392 |
} |
393 |
|
394 |
public String getSSLRandomSeed() |
395 |
{ |
251 |
return SSLRandomSeed; |
396 |
return SSLRandomSeed; |
252 |
} |
397 |
} |
253 |
|
398 |
|
254 |
public void setSSLRandomSeed(String SSLRandomSeed) { |
399 |
/** |
255 |
AprLifecycleListener.SSLRandomSeed = SSLRandomSeed; |
400 |
* SSLRandomSeed must be set before this instance is initialized, else this will have no effect. |
|
|
401 |
* |
402 |
* @param SSLRandomSeed |
403 |
*/ |
404 |
public void setSSLRandomSeed(String SSLRandomSeed) |
405 |
{ |
406 |
if(! sslInitialized) // added so that the random seem class being used is consistent with that returned from getSSLRandomSeed() |
407 |
AprLifecycleListener.SSLRandomSeed = SSLRandomSeed; |
256 |
} |
408 |
} |
257 |
|
409 |
|
|
|
410 |
/** |
411 |
* This is not a production method, it is just a simple way to test |
412 |
* that the APR libraries can be loaded and that the versions are usable. |
413 |
* |
414 |
* @param argv |
415 |
*/ |
416 |
public static void main(String[] argv) |
417 |
{ |
418 |
System.out.println( "Loading APR libraries from " + System.getProperty("java.library.path") ); |
419 |
AprLifecycleListener lifecycleListener = new AprLifecycleListener(); |
420 |
Lifecycle lifecycle = new Lifecycle() |
421 |
{ |
422 |
private LifecycleState state = LifecycleState.NEW; |
423 |
|
424 |
@Override |
425 |
public void stop() throws LifecycleException{state = LifecycleState.STOPPED;} |
426 |
|
427 |
@Override |
428 |
public void start() throws LifecycleException{state = LifecycleState.STARTED;} |
429 |
|
430 |
@Override |
431 |
public void removeLifecycleListener(LifecycleListener listener){} |
432 |
|
433 |
@Override |
434 |
public LifecycleListener[] findLifecycleListeners(){return null;} |
435 |
|
436 |
@Override |
437 |
public void addLifecycleListener(LifecycleListener listener){} |
438 |
|
439 |
@Override |
440 |
public void init() throws LifecycleException {state = LifecycleState.INITIALIZED;} |
441 |
|
442 |
@Override |
443 |
public void destroy() throws LifecycleException {state = LifecycleState.DESTROYED;} |
444 |
|
445 |
@Override |
446 |
public LifecycleState getState() {return state;} |
447 |
|
448 |
@Override |
449 |
public String getStateName() {return state.toString();} |
450 |
}; |
451 |
|
452 |
LifecycleEvent initEvent = new LifecycleEvent(lifecycle, Lifecycle.BEFORE_INIT_EVENT, null); |
453 |
LifecycleEvent destroyEvent = new LifecycleEvent(lifecycle, Lifecycle.AFTER_DESTROY_EVENT, null); |
454 |
|
455 |
lifecycleListener.setSSLEngine("on"); |
456 |
lifecycleListener.setFIPSMode("on"); |
457 |
lifecycleListener.lifecycleEvent(initEvent); |
458 |
|
459 |
lifecycleListener.lifecycleEvent(destroyEvent); |
460 |
} |
258 |
} |
461 |
} |