Lines 49-54
Link Here
|
49 |
import javax.net.ssl.SSLException; |
49 |
import javax.net.ssl.SSLException; |
50 |
import javax.net.ssl.SSLServerSocket; |
50 |
import javax.net.ssl.SSLServerSocket; |
51 |
import javax.net.ssl.SSLServerSocketFactory; |
51 |
import javax.net.ssl.SSLServerSocketFactory; |
|
|
52 |
import javax.net.ssl.SSLSessionContext; |
52 |
import javax.net.ssl.SSLSocket; |
53 |
import javax.net.ssl.SSLSocket; |
53 |
import javax.net.ssl.TrustManager; |
54 |
import javax.net.ssl.TrustManager; |
54 |
import javax.net.ssl.TrustManagerFactory; |
55 |
import javax.net.ssl.TrustManagerFactory; |
Lines 74-79
Link Here
|
74 |
* @author EKR -- renamed to JSSESocketFactory |
75 |
* @author EKR -- renamed to JSSESocketFactory |
75 |
* @author Jan Luehe |
76 |
* @author Jan Luehe |
76 |
* @author Bill Barker |
77 |
* @author Bill Barker |
|
|
78 |
* @author Chris Elving |
77 |
*/ |
79 |
*/ |
78 |
public class JSSESocketFactory |
80 |
public class JSSESocketFactory |
79 |
extends org.apache.tomcat.util.net.ServerSocketFactory { |
81 |
extends org.apache.tomcat.util.net.ServerSocketFactory { |
Lines 380-385
Link Here
|
380 |
getTrustManagers(keystoreType, trustAlgorithm), |
382 |
getTrustManagers(keystoreType, trustAlgorithm), |
381 |
new SecureRandom()); |
383 |
new SecureRandom()); |
382 |
|
384 |
|
|
|
385 |
// Configure the optional server SSLSessionContext |
386 |
String sslSessionCacheSize = (String) attributes.get("sslSessionCacheSize"); |
387 |
String sslSessionTimeout = (String) attributes.get("sslSessionTimeout"); |
388 |
if (sslSessionCacheSize != null || sslSessionTimeout != null) { |
389 |
SSLSessionContext sessionContext = context.getServerSessionContext(); |
390 |
if (sessionContext != null) { |
391 |
if (sslSessionCacheSize != null) |
392 |
sessionContext.setSessionCacheSize(Integer.parseInt(sslSessionCacheSize)); |
393 |
if (sslSessionTimeout != null) |
394 |
sessionContext.setSessionTimeout(Integer.parseInt(sslSessionTimeout)); |
395 |
} else { |
396 |
log.error(protocol + |
397 |
" does not have a server SSL session context"); |
398 |
} |
399 |
} |
400 |
|
383 |
// create proxy |
401 |
// create proxy |
384 |
sslProxy = context.getServerSocketFactory(); |
402 |
sslProxy = context.getServerSocketFactory(); |
385 |
|
403 |
|