You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2019/05/24 08:01:25 UTC
[camel] 01/02: Revert "Fixing camel-ahc errors with Jetty upgrade"
This is an automated email from the ASF dual-hosted git repository.
acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git
commit 3026b8f40d4b6bf744217f117f9c3d9f85846536
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri May 24 09:59:54 2019 +0200
Revert "Fixing camel-ahc errors with Jetty upgrade"
This reverts commit 1ad7fc1ec4ff7455c0991f84b5ada92c955611b8.
Upgrading Jetty breaks cometd karaf feature, which in turns breaks Saleforce Karaf feature
---
.../java/org/apache/camel/component/jetty/JettyHttpComponent.java | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/components/camel-jetty-common/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java b/components/camel-jetty-common/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java
index 86b4845..0891248 100644
--- a/components/camel-jetty-common/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java
+++ b/components/camel-jetty-common/src/main/java/org/apache/camel/component/jetty/JettyHttpComponent.java
@@ -626,8 +626,7 @@ public abstract class JettyHttpComponent extends HttpCommonComponent implements
throw new RuntimeCamelException(e);
}
} else if ("https".equals(endpoint.getProtocol())) {
- sslcf = new SslContextFactory();
- sslcf.setEndpointIdentificationAlgorithm(null);
+ sslcf = new SslContextFactory.Server();
String keystoreProperty = System.getProperty(JETTY_SSL_KEYSTORE);
if (keystoreProperty != null) {
sslcf.setKeyStorePath(keystoreProperty);
@@ -656,10 +655,7 @@ public abstract class JettyHttpComponent extends HttpCommonComponent implements
protected abstract AbstractConnector createConnectorJettyInternal(Server server, JettyHttpEndpoint endpoint, SslContextFactory sslcf);
private SslContextFactory createSslContextFactory(SSLContextParameters ssl, boolean client) throws GeneralSecurityException, IOException {
- SslContextFactory answer = new SslContextFactory();
- if (!client) {
- answer.setEndpointIdentificationAlgorithm(null);
- }
+ SslContextFactory answer = client ? new SslContextFactory.Client() : new SslContextFactory.Server();
if (ssl != null) {
answer.setSslContext(ssl.createSSLContext(getCamelContext()));
}