Re: fsockopen - certificate verify failed - how to importcertificate /disable the check
| From: | Christoph Becker | Date: | Wed, 17 Feb 2016 12:15:47 +0000 |
| Subject: | Re: fsockopen - certificate verify failed - how to importcertificate /disable the check | ||
| References: | 1 2 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-31385@lists.php.net to get a copy of this message | ||
Martin Tille wrote:
> I tried different things with no luck. I started with an empty
> cacert.pem file to check if it is used. Yes it is. I copied the
> certificate for my server from the firefox certificate store, still my
> server didn't worked and then it complains when trying to connect to
> ssl://google.com what was working before.
> When I use the cacert.pem from
> https://curl.haxx.se/docs/caextract.html
> and test ssl://google.com and other servers these went well but not my
> self signed server which certificate I added at the bottom of the
> downloaded file.
There may be a bug, which you can report on <https://bugs.php.net/> (if
that's not already happened).
> Dear PHP devolpers, if you change verify_peer from false to true per
> default then test if it works with self signed certificates.
Consider to contribute respective test cases, see
<http://qa.php.net/write-test.php>. :)
> If anybody stumbles upon this. You can't solve it with fsockopen because
> you can't set a stream context.
Consider to make a respective feature request on <https://bugs.php.net/>.
--
Christoph M. Becker