From ebf60bb3cae7585d75cf9d40b557f3db789ffa10 Mon Sep 17 00:00:00 2001 From: "Frederick G. Oconer" Date: Wed, 30 Aug 2006 09:12:54 +0000 Subject: [PATCH] https://issues.apache.org/activemq/browse/AMQ-902 Bug: Compilation error on class HttpsTransportServer because setAlgorithm(String) was replaced in jetty-6.0.0rc2. Fix: Modified setting of algorithm with new methods. git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@438429 13f79535-47bb-0310-9956-ffa450edef68 --- .../transport/https/HttpsTransportServer.java | 46 ++++++++++++++----- 1 file changed, 35 insertions(+), 11 deletions(-) diff --git a/activemq-optional/src/main/java/org/apache/activemq/transport/https/HttpsTransportServer.java b/activemq-optional/src/main/java/org/apache/activemq/transport/https/HttpsTransportServer.java index eed3fa5cc4..623e5f3c01 100755 --- a/activemq-optional/src/main/java/org/apache/activemq/transport/https/HttpsTransportServer.java +++ b/activemq-optional/src/main/java/org/apache/activemq/transport/https/HttpsTransportServer.java @@ -28,7 +28,9 @@ public class HttpsTransportServer extends HttpTransportServer { private String keyStorePassword = System.getProperty( "javax.net.ssl.keyStorePassword" ); private String keyStore = System.getProperty( "javax.net.ssl.keyStore" ); private String keyStoreType = null; - private String certificateAlgorithm = null; + private String secureRandomCertficateAlgorithm = null; + private String trustCertificateAlgorithm = null; + private String keyCertificateAlgorithm = null; private String protocol = null; public HttpsTransportServer( URI uri ) { @@ -47,8 +49,14 @@ public class HttpsTransportServer extends HttpTransportServer { if ( keyStoreType != null ) { sslConnector.setKeystoreType( keyStoreType ); } - if ( certificateAlgorithm != null ) { - sslConnector.setAlgorithm( certificateAlgorithm ); + if ( secureRandomCertficateAlgorithm != null ) { + sslConnector.setSecureRandomAlgorithm( secureRandomCertficateAlgorithm ); + } + if ( keyCertificateAlgorithm != null ) { + sslConnector.setSslKeyManagerFactoryAlgorithm( keyCertificateAlgorithm ); + } + if ( trustCertificateAlgorithm != null ) { + sslConnector.setSslTrustManagerFactoryAlgorithm( trustCertificateAlgorithm ); } if ( protocol != null ) { sslConnector.setProtocol( protocol ); @@ -62,14 +70,6 @@ public class HttpsTransportServer extends HttpTransportServer { // Properties //-------------------------------------------------------------------------------- - public String getCertificateAlgorithm() { - return certificateAlgorithm; - } - - public void setCertificateAlgorithm( String certificateAlgorithm ) { - this.certificateAlgorithm = certificateAlgorithm; - } - public String getKeyStore() { return keyStore; } @@ -110,4 +110,28 @@ public class HttpsTransportServer extends HttpTransportServer { this.protocol = protocol; } + public String getSecureRandomCertficateAlgorithm() { + return secureRandomCertficateAlgorithm; + } + + public void setSecureRandomCertficateAlgorithm(String secureRandomCertficateAlgorithm) { + this.secureRandomCertficateAlgorithm = secureRandomCertficateAlgorithm; + } + + public String getKeyCertificateAlgorithm() { + return keyCertificateAlgorithm; + } + + public void setKeyCertificateAlgorithm(String keyCertificateAlgorithm) { + this.keyCertificateAlgorithm = keyCertificateAlgorithm; + } + + public String getTrustCertificateAlgorithm() { + return trustCertificateAlgorithm; + } + + public void setTrustCertificateAlgorithm(String trustCertificateAlgorithm) { + this.trustCertificateAlgorithm = trustCertificateAlgorithm; + } + }