title: curl: (35) Cannot communicate securely with peer: no common encryption algorithm(s)
body: <p>Our application is deployed to AWS infrastructure for a long time. </p>
  
  <p>We are using ClaudFlare for caching and CDN.
  We have two applications - Java(Tomcat 8) and WordPress(PHP Nginx + FastCGI).</p>
  
  <p>For Java application we use EC2 instances with OpenJDK 8. Also, we have WordPress on another EC2 instance.</p>
  
  <p>Java application communicates with WordPress via direct calls on https protocol.</p>
  
  <p>We use Puppet for our AWS infrastructure provisioning.</p>
  
  <p>Everything worked properly but a few days ago our Java application was unable to connect via https to WordPress with a following exception:</p>
  
  <pre><code>Received fatal alert: handshake_failure
  javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
  </code></pre>
  
  <p>also, we was unable to connect to the same WordPress url via curl with a following error:</p>
  
  <pre><code>curl: (35) Cannot communicate securely with peer: no common encryption algorithm(s).
  </code></pre>
  
  <p>It was strange because absolutely nothing was changed on our side. </p>
  
  <p>Just for experiment - we have disabled ClaudFlare and our system started working properly. Right after that we have enabled ClaudFlare and system failed again.</p>
  
  <p>Only switching from OpenJDK to OracleJDK completely fixed the issue.</p>
  
  <p>CloudFlare told us that nothing has changed with SSL on their end.</p>
  
  <p>So I'm wondering what can be a reason of this issue ? May be something has been changed at AWS end(infrastructure or some software packages)</p>