title: Impossible SSL CAS-certificates with phpCAS and examples. It only works without SSL server verification
body: <p>I am doing a CAS integration with a project that I am doing with my university. The final integration should be made with symfony2, however first I need to make the example code working.</p>
  
  <p>I finally get working the <em>example_simple.php</em> example with <em>phpCAS 1.3.2</em> , however the directive:</p>
  
  <pre><code>phpCAS::setNoCasServerValidation();
  </code></pre>
  
  <p>is the enabled one. I think I should use instead:</p>
  
  <pre><code>phpCAS::setCasServerCACert($cas_server_ca_cert_path);
  </code></pre>
  
  <p>However when I enable this second one (and disable the other) then the authorization does not work anymore. Here is the relevant output line error of the log:</p>
  
  <pre><code>could not open URL 'https://cas_server.fi/cas/serviceValidate?service=http%3A%2F%2Flocalhost%2Fphpcas2%2Fdocs%2Fexamples%2Fexample_simple.php&amp;ticket=ST-115606-M1Omd1cHWzbLbmxa1nYV-cas' to validate (CURL error #60: SSL certificate problem: unable to get local issuer certificate) [Client.php:2763]
  </code></pre>
  
  <p>The cas server provided me two .crt files:</p>
  
  <ul>
  <li>MYCASRootCA.crt</li>
  <li>MYCASLinuxSUBCA.crt</li>
  </ul>
  
  <p>And they are suppose to be installed in my system (Ubuntu 13.10). They are in different places, such a /etc/ssl/certs/MYCASLinuxSUBCA.pem but also:</p>
  
  <ul>
  <li>/usr/share/ca-certificates/lut/MYCASRootCA.crt</li>
  <li>/usr/share/ca-certificates/lut/MYCASLinuxSUBCA.crt</li>
  </ul>
  
  <p>So assuming that the variable $cas_server_ca_cert_path has to have one of these .crt files or .pem dirs (such a <em>/usr/share/ca-certificates/lut/MYCASLinuxSUBCA.crt</em>) I cannot make it work. What I am doing it wrong? My client-server (no the cas server) is in my localhost. Is it a problem? Should I avoid use setCasServerCACert command? Why is it happening?</p>
  
  <p>I've also tried to use the curl-ca-bundle.crt certificate provided by my XAMP instalation (Xampp 1.8.3).</p>
  
  <p>I am a little bit lost with certificates as you can see.</p>
  
  <p>I read about problems with phpCAS and recent Ubuntu versions in <a href="https://github.com/Jasig/phpCAS/issues?state=open" rel="nofollow">https://github.com/Jasig/phpCAS/issues?state=open</a>. However I cannot make this working with the master code, even without certification (by default).</p>
  
  <p>Any ideas would be appreciated...</p>