You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by "Kurian Abraham (JIRA)" <ji...@apache.org> on 2014/09/17 19:53:33 UTC

[jira] [Comment Edited] (HTTPCLIENT-1553) SSLSocketFactory null argument exception in HttpClientBuilder.build() if system properties are not used.

    [ https://issues.apache.org/jira/browse/HTTPCLIENT-1553?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14137611#comment-14137611 ] 

Kurian Abraham edited comment on HTTPCLIENT-1553 at 9/17/14 5:52 PM:
---------------------------------------------------------------------

This should probably use SSLConnectionFactory.getSystemSocketFactory() and SSLConnectionFactory.getSocketFactory() instead of hardcoding SSLCertificateSocketFactory. That will also incorporate the other SSL socket timeout bugfix fix into HttpClientBuilder other wise it will still use an indefinite timeout.


was (Author: kathampy):
This should probably use SSLConnectionFactory.getSocketFactory() instead of hardcoding SSLCertificateSocketFactory. That will also incorporate the other SSL socket timeout bugfix fix into HttpClientBuilder other wise it will still use an indefinite timeout.

> SSLSocketFactory null argument exception in HttpClientBuilder.build() if system properties are not used.
> --------------------------------------------------------------------------------------------------------
>
>                 Key: HTTPCLIENT-1553
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1553
>             Project: HttpComponents HttpClient
>          Issue Type: Bug
>          Components: Android Port
>    Affects Versions: 4.3.5
>            Reporter: Kurian Abraham
>              Labels: easyfix
>             Fix For: 4.3.5.1-android
>
>
> The outer systemProperties check is unnecessary and causes it to fail.
> if (systemProperties) {
>     if (systemProperties) {
>         sslSocketFactory = new SSLConnectionSocketFactory(
>                 (SSLSocketFactory) SSLCertificateSocketFactory.getDefault(0),
>                  supportedProtocols, supportedCipherSuites, hostnameVerifier);
>     } else {
>         sslSocketFactory = new SSLConnectionSocketFactory(
>                 (SSLSocketFactory) SSLCertificateSocketFactory.getDefault(0),
>                 hostnameVerifier);
>     }
> }



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org