camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrac...@apache.org
Subject svn commit: r641800 - /activemq/camel/trunk/components/camel-jetty/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java
Date Thu, 27 Mar 2008 12:56:10 GMT
Author: jstrachan
Date: Thu Mar 27 05:56:02 2008
New Revision: 641800

URL: http://svn.apache.org/viewvc?rev=641800&view=rev
Log:
applied patch from Gary Tully with thanks! See http://www.nabble.com/Password-error-for-https-endpoint-connection-tp16128569s22882p16309438.html

Modified:
    activemq/camel/trunk/components/camel-jetty/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java

Modified: activemq/camel/trunk/components/camel-jetty/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-jetty/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java?rev=641800&r1=641799&r2=641800&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-jetty/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java
(original)
+++ activemq/camel/trunk/components/camel-jetty/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java
Thu Mar 27 05:56:02 2008
@@ -65,6 +65,8 @@
     private Server server;
     private final HashMap<String, ConnectorRef> connectors = new HashMap<String,
ConnectorRef>();
     private HttpClient httpClient;
+    private String sslKeyPassword = "";
+    private String sslPassword = "";
 
     @Override
     protected Endpoint<HttpExchange> createEndpoint(String uri, String remaining, Map
parameters) throws Exception {
@@ -89,7 +91,10 @@
             if (connectorRef == null) {
                 Connector connector;
                 if ("https".equals(endpoint.getProtocol())) {
-                    connector = new SslSocketConnector();
+                    SslSocketConnector socketConnector = new SslSocketConnector();
+                    socketConnector.setPassword(sslPassword);
+                    socketConnector.setKeyPassword(sslKeyPassword);
+                    connector = socketConnector;
                 } else {
                     connector = new SelectChannelConnector();
                 }
@@ -145,6 +150,22 @@
 
     public void setServer(Server server) {
         this.server = server;
+    }
+
+    public String getSslKeyPassword() {
+        return sslKeyPassword;
+    }
+
+    public void setSslKeyPassword(String sslKeyPassword) {
+        this.sslKeyPassword = sslKeyPassword;
+    }
+
+    public String getSslPassword() {
+        return sslPassword;
+    }
+
+    public void setSslPassword(String sslPassword) {
+        this.sslPassword = sslPassword;
     }
 
     // Implementation methods



Mime
View raw message