diff --git a/pom.xml b/pom.xml index bf36ebb659..d0845c83fc 100644 --- a/pom.xml +++ b/pom.xml @@ -71,6 +71,8 @@ 2.8.9 4.5.13 4.4.16 + 5.2.1 + 5.2.1 3.1-HTTPCLIENT-1265 2.12.2 2.0.7 @@ -370,6 +372,16 @@ commons-httpclient ${dependency.commons-httpclient.version} + + org.apache.httpcomponents.client5 + httpclient5 + ${dependency.httpcomponents-httpclient5.version} + + + org.apache.httpcomponents.core5 + httpcore5 + ${dependency.httpcomponents-httpcore5.version} + commons-logging commons-logging diff --git a/repository/pom.xml b/repository/pom.xml index 1750127e5e..1f8cbf6f94 100644 --- a/repository/pom.xml +++ b/repository/pom.xml @@ -65,6 +65,15 @@ httpmime + + org.apache.httpcomponents.client5 + httpclient5 + + + org.apache.httpcomponents.core5 + httpcore5 + + org.apache.commons commons-dbcp2 diff --git a/repository/src/main/java/org/alfresco/repo/security/authentication/identityservice/IdentityServiceFacadeFactoryBean.java b/repository/src/main/java/org/alfresco/repo/security/authentication/identityservice/IdentityServiceFacadeFactoryBean.java index 7f6a965fd8..24486446ad 100644 --- a/repository/src/main/java/org/alfresco/repo/security/authentication/identityservice/IdentityServiceFacadeFactoryBean.java +++ b/repository/src/main/java/org/alfresco/repo/security/authentication/identityservice/IdentityServiceFacadeFactoryBean.java @@ -62,14 +62,17 @@ import com.nimbusds.openid.connect.sdk.op.OIDCProviderMetadata; import org.alfresco.repo.security.authentication.identityservice.IdentityServiceFacade.IdentityServiceFacadeException; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import org.apache.http.client.HttpClient; -import org.apache.http.client.config.RequestConfig; -import org.apache.http.conn.ssl.NoopHostnameVerifier; -import org.apache.http.conn.ssl.TrustAllStrategy; -import org.apache.http.impl.client.HttpClientBuilder; -import org.apache.http.impl.client.HttpClients; -import org.apache.http.ssl.SSLContextBuilder; -import org.apache.http.ssl.SSLContexts; +import org.apache.hc.client5.http.classic.HttpClient; +import org.apache.hc.client5.http.config.ConnectionConfig; +import org.apache.hc.client5.http.impl.classic.HttpClientBuilder; +import org.apache.hc.client5.http.impl.classic.HttpClients; +import org.apache.hc.client5.http.impl.io.PoolingHttpClientConnectionManagerBuilder; +import org.apache.hc.client5.http.ssl.NoopHostnameVerifier; +import org.apache.hc.client5.http.ssl.SSLConnectionSocketFactory; +import org.apache.hc.client5.http.ssl.SSLConnectionSocketFactoryBuilder; +import org.apache.hc.client5.http.ssl.TrustAllStrategy; +import org.apache.hc.core5.ssl.SSLContextBuilder; +import org.apache.hc.core5.ssl.SSLContexts; import org.springframework.beans.factory.FactoryBean; import org.springframework.http.HttpStatus; import org.springframework.http.RequestEntity; @@ -230,8 +233,7 @@ public class IdentityServiceFacadeFactoryBean implements FactoryBean