javax.net.ssl.SSLPeerUnverifiedException: Host name 's3.amazonaws.com' does not match the certificate subject provided by the peer (CN=s3.amazonaws.com, O=Amazon.com Inc., L=Seattle, ST=Washington, C=US)

Apache's JIRA Issue Tracker | Richard DiCroce | 2 years ago
  1. 0

    I tried to use HttpClient to download this file: https://github.com/activescott/lessmsi/releases/download/v1.2.0/lessmsi-v1.2.0.zip My browser and other tools have no problem with it. HttpClient 4.3.6 is also fine, but 4.4 fails with this exception: {code} javax.net.ssl.SSLPeerUnverifiedException: Host name 's3.amazonaws.com' does not match the certificate subject provided by the peer (CN=s3.amazonaws.com, O=Amazon.com Inc., L=Seattle, ST=Washington, C=US) at org.apache.http.conn.ssl.SSLConnectionSocketFactory.verifyHostname(SSLConnectionSocketFactory.java:466) at org.apache.http.conn.ssl.SSLConnectionSocketFactory.createLayeredSocket(SSLConnectionSocketFactory.java:396) at org.apache.http.conn.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:354) at org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:134) at org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:353) at org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:380) at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:236) at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:184) at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88) at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110) at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184) at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82) at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:107) at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:55) at org.apache.http.client.fluent.Request.execute(Request.java:151) at com.sg.maven.relpkg.UnpackUtil.unpackJDK(UnpackUtil.java:55) at com.sg.maven.relpkg.ReleasePackageBuilder.build(ReleasePackageBuilder.java:151) at com.sg.maven.relpkg.Main.main(Main.java:84) {code}

    Apache's JIRA Issue Tracker | 2 years ago | Richard DiCroce
    javax.net.ssl.SSLPeerUnverifiedException: Host name 's3.amazonaws.com' does not match the certificate subject provided by the peer (CN=s3.amazonaws.com, O=Amazon.com Inc., L=Seattle, ST=Washington, C=US)
  2. 0

    Host verification fails for https://www.apis.google.com/ in spring social

    Stack Overflow | 2 years ago | Balaban Mario
    javax.net.ssl.SSLPeerUnverifiedException: Host name 'www.googleapis.com' does not match the certificate subject provided by the peer (CN=*.storage.googleapis.com, O=Google Inc, L=Mountain View, ST=California, C=US) This is the stack trace: Caused by: javax.net.ssl.SSLPeerUnverifiedException: Host name 'www.googleapis.com' does not match the certificate subject provided by the peer (CN=*.storage.googleapis.com, O=Google Inc, L=Mountain View, ST=California, C=US)
  3. 0

    javax.net.ssl.SSLPeerUnverifiedException: Host name does not match the certificate subject provided by the peer

    Stack Overflow | 11 months ago
    javax.net.ssl.SSLPeerUnverifiedException: Host name 'XXXXXXXXX' does not match the certificate subject provided by the peer (CN=localhost, O=WSO2, L=Mountain View, ST=CA, C=US)
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Can't call EWS service with API Java SSL and certificates

    Stack Overflow | 2 years ago | alibenmessaoud
    microsoft.exchange.webservices.data.core.exception.service.remote.ServiceRequestException: The request failed. The request failed. Host name '192.168.1.59' does not match the certificate subject provided by the peer (CN=WIN-NS09AI4QBB8)
  6. 0

    The request failed.Host name does not match the certificate subject provided by the peer

    GitHub | 1 year ago | 805728578
    com.wafersystems.exchange.core.exception.service.remote.ServiceRequestException: The request failed. The request failed. Host name '192.168.0.168' does not match the certificate subject provided by the peer (CN=exchange)

  1. Arne Jans 1 times, last 9 months ago
2 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. javax.net.ssl.SSLPeerUnverifiedException

    Host name 's3.amazonaws.com' does not match the certificate subject provided by the peer (CN=s3.amazonaws.com, O=Amazon.com Inc., L=Seattle, ST=Washington, C=US)

    at org.apache.http.conn.ssl.SSLConnectionSocketFactory.verifyHostname()
  2. Apache HttpClient
    CloseableHttpClient.execute
    1. org.apache.http.conn.ssl.SSLConnectionSocketFactory.verifyHostname(SSLConnectionSocketFactory.java:466)
    2. org.apache.http.conn.ssl.SSLConnectionSocketFactory.createLayeredSocket(SSLConnectionSocketFactory.java:396)
    3. org.apache.http.conn.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:354)
    4. org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:134)
    5. org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:353)
    6. org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:380)
    7. org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:236)
    8. org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:184)
    9. org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88)
    10. org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110)
    11. org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184)
    12. org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
    13. org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:107)
    14. org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:55)
    14 frames
  3. Apache HttpClient Fluent API
    Request.execute
    1. org.apache.http.client.fluent.Request.execute(Request.java:151)
    1 frame
  4. com.sg.maven
    Main.main
    1. com.sg.maven.relpkg.UnpackUtil.unpackJDK(UnpackUtil.java:55)
    2. com.sg.maven.relpkg.ReleasePackageBuilder.build(ReleasePackageBuilder.java:151)
    3. com.sg.maven.relpkg.Main.main(Main.java:84)
    3 frames