title: TCPDF: getimagesize(): SSL operation failed with code 1 error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed
body: <p>I've been using TCPDF.
  In my local machine, TCPDF works fine, but it throws an error in the actual server. The error message is as follows.</p>
  
  <blockquote>
    <p>Message: getimagesize(): SSL operation failed with code 1. OpenSSL Error messages: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed</p>
    
    <p>Message: getimagesize(): Failed to enable crypto</p>
    
    <p>getimagesize(http:/test.com/images/sample.jpg): failed to open stream: operation failed</p>
  </blockquote>
  
  <p>If I understand them right, this application couldn't verify the SSL certificate of the server.</p>
  
  <p>So, following <a href="https://tcpdf.org/examples/example_052/" rel="nofollow noreferrer">this example</a>, I put get the signature in the following way.</p>
  
  <pre><code>$pdf  = new TCPDF();
  $certificate = '/blahblah/certs/certificate.crt';
  $pdf-&gt;setSignature($certificate, $certificate, 'pdfgen', '', 2, []);
  </code></pre>
  
  <p>Still, I'm seeing the same error.    </p>
  
  <p>When TCPDF throws this <code>"SSL operation failed with code 1"</code> error, what does it mean?</p>
  
  <p>Any help will be appreciated.</p>