SSL Exception when connecting to Twitter


we are using the version 3.2.0 of twitter4j library. Since 14. october we have the problem with the authentication. The error message is “Caused by: peer not authenticated”.

After update the twitter api to the version 4.0.2, we get the following error message: “Caused by: PKIX path building failed: unable to find valid certification path to requested target”.

Can you give us some tips to solve this problem?


I’m not certain, but this could be related to our recent change away from SSLv3 to TLS? The date certainly matches the time at which that change occurred.


I am not sure about this. We have the log file saved only until 14.10. Have your some solutions for us, which we can try?


I’d take a look at example solutions for fixing the SSL POODLE vulnerability in Java code like this one. You should exclude SSL from your certificate options.