title: Php SoapClient verify_peer=>true fails with ca-signed certificate
body: <p>When doing a soap request to a https soap server using php:s SoapClient fails with a SoapFault:</p>
  
  <pre>
  faultstring: Could not connect to host
  faultcode: HTTP
  </pre>
  
  <p>I have to be sure that the soap servers ssl certificate is valid so i am using</p>
  
  <pre><code> &lt;?php
   $soap=new SoapClient("mwsdl.wsdl"
             ,array(
                    "location"=&gt;"https:examplesoapserver.com"
                    ,"trace"=&gt;1
                    ,"stream_context"=&gt;stream_context_create(array(
                           "ssl"=&gt;array(
                                        "verify_peer"=&gt;true
                                        ,"allow_self_signed"=&gt;false
                                        )
                                )
                             )
                          )
                       );
  </code></pre>
  
  <p>But this gives me the SoapFault.</p>
  
  <p>I have tested with different settings:</p>
  
  <pre>OK
  location: has self-signed certificate
  verify_peer=>true
  allow_self_signed=>true</pre>
  
  <pre>OK (without setting verify_peer)
  location: has self-signed certificate
  allow_self_signed=>false</pre>
  
  <pre>NOT OK
  location: has self-signed certificate
  verify_peer=>true
  allow_self_signed=>false</pre>
  
  <pre>OK (without setting verify_peer)
  location: ca-signed certificate
  allow_self_signed=>false</pre>
  
  <pre>NOT OK
  location: ca-signed certificate
  verify_peer=>true
  allow_self_signed=>false</pre>
  
  <p>I have:</p>
  
  <pre>php version: 5.3.3
  CentOS 6.4
  Apache/2.2.15</pre>
  
  <p>Ask for more details if it helps figuring out the problem.</p>
  
  <p>Thank you in advance for any help!</p>