Skip to content
Advertisement

How to ignore SSL certificate errors in Apache HttpClient 4.0

How do I bypass invalid SSL certificate errors with Apache HttpClient 4.0?

Advertisement

Answer

You need to create a SSLContext with your own TrustManager and create HTTPS scheme using this context. Here is the code,

JavaScript
User contributions licensed under: CC BY-SA
9 People found this is helpful
Advertisement