# javax.net.ssl.SSLPeerUnverifiedException: peer not authenticated

**URL:** <https://community.hubspot.com/t/javax-net-ssl-sslpeerunverifiedexception-peer-not-authenticated/11893>\
**Category:** APIs & Integrations\
**Tags:** contacts\
**Created:** [December 22, 2017, 4:38pm UTC](https://community.hubspot.com/t/javax-net-ssl-sslpeerunverifiedexception-peer-not-authenticated/11893 "2017-12-22T16:38:34Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/system/32/124_2.png) [@system](https://community.hubspot.com/u/system)\
**Post date:** [December 22, 2017, 4:38pm UTC](https://community.hubspot.com/t/javax-net-ssl-sslpeerunverifiedexception-peer-not-authenticated/11893/1 "2017-12-22T16:38:34Z")

</div>

Hi there,

Trying to make a rest call to the following: [https://api.hubapi.com/contacts/v1/lists/recently\_updated/contacts/recent](https://api.hubapi.com/contacts/v1/lists/recently_updated/contacts/recent) (with some params and my api-key)  
results in a “javax.net.ssl.SSLPeerUnverifiedException: peer not authenticated” for the last 2 days.  
Call is made from a Groovy application running on tomcat7 on Ubuntu instance.  
Does someone have an idea?

Thanks in advance !

---

<div class="post-metadata">

**Author:** ![Derek\_Gervais](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/derek_gervais/32/17429_2.png) [@Derek\_Gervais](https://community.hubspot.com/u/Derek_Gervais)\
**Post date:** [December 22, 2017, 7:41pm UTC](https://community.hubspot.com/t/javax-net-ssl-sslpeerunverifiedexception-peer-not-authenticated/11893/2 "2017-12-22T19:41:21Z")

</div>

Hi [@Quent](https://community.hubspot.com/u/quent),

We recently made a change that would have switched the certificate authority that would be used for the SSL certificate at [api.hubapi.com](http://api.hubapi.com). If you’re having trouble validating the certificate, you may need to update the root CAs installed on your server.

---

<div class="post-metadata">

**Author:** ![system](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/system/32/124_2.png) [@system](https://community.hubspot.com/u/system)\
**Post date:** [December 28, 2017, 4:09pm UTC](https://community.hubspot.com/t/javax-net-ssl-sslpeerunverifiedexception-peer-not-authenticated/11893/3 "2017-12-28T16:09:51Z")

</div>

Hi [@Derek\_Gervais](https://community.hubspot.com/u/derek_gervais),

I tried to update the certificate on the server but still get the exception.  
Strange things is that it always has been working on my acceptance environment (without any changes) but not on production one.  
What’s the best way to get the api certificate?  
Thanks in advance,  
Quentin.

---

<div class="post-metadata">

**Author:** ![Derek\_Gervais](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/derek_gervais/32/17429_2.png) [@Derek\_Gervais](https://community.hubspot.com/u/Derek_Gervais)\
**Post date:** [January 8, 2018, 6:31pm UTC](https://community.hubspot.com/t/javax-net-ssl-sslpeerunverifiedexception-peer-not-authenticated/11893/4 "2018-01-08T18:31:52Z")

</div>

Hi [@Quent](https://community.hubspot.com/u/quent),

It’s possible that after updating the CAs, the service didn’t actually pick up on that update yet. If you haven’t already, you could try restarting the service so it’s using the updates and not the old cached CAs. It’s difficult to troubleshoot these issues since they’re very environment-specific. You can see the full chain of the certificate path up to the root CA at the link below; I’d recommend double-checking that the specific root CA is installed and up-to-date in your system.

> **[SSL Certificate Checker - Diagnostic Tool | DigiCert.com](https://www.digicert.com/help/?host=api.hubapi.com)**

---

<div class="post-metadata">

**Author:** ![prakashmani](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/prakashmani/32/63860_2.png) [@prakashmani](https://community.hubspot.com/u/prakashmani)\
**Post date:** [March 20, 2019, 7:05am UTC](https://community.hubspot.com/t/javax-net-ssl-sslpeerunverifiedexception-peer-not-authenticated/11893/5 "2019-03-20T07:05:55Z")

</div>

Hi,

I am randomly getting the below error. Few times, the call is successful and other times hubspot API says, **I/O error on POST request for “[https://api.hubapi.com/contacts/v1/contact/](https://api.hubapi.com/contacts/v1/contact/)”: peer not authenticated.**

-Prakash

---

<div class="post-metadata">

**Author:** ![Derek\_Gervais](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/derek_gervais/32/17429_2.png) [@Derek\_Gervais](https://community.hubspot.com/u/Derek_Gervais)\
**Post date:** [March 22, 2019, 5:45pm UTC](https://community.hubspot.com/t/javax-net-ssl-sslpeerunverifiedexception-peer-not-authenticated/11893/6 "2019-03-22T17:45:06Z")

</div>

Hi @prakashmani,

[This](https://stackoverflow.com/a/11750463)Stackoverflow topic might help here. To pull a quote from it:

`Assuming the server certificate is signed by a well-known CA, this is happeningbecause the set of CA certificates available to a modern browser is much largerthan the limited set that is shipped with the JDK/JRE.`
