After my regular updates and a reboot of my server I accessed a web page on it and got the following errors:
Warning: file_get_contents(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in
/var/www/domain.ca/public_html/page.php on line 51
Warning: file_get_contents(): Failed to enable crypto in /var/www/domain.ca/public_html/
page.php on line 51
Warning: file_get_contents(https://www.cryptopia.co.nz/api/GetMarkets/BTC): failed to open
stream: operation failed in /var/www/domain.ca/public_html/page.php on line 51
After some more testing, my other file_get_contents() works well. The only difference I saw with cryptopia is that they use a Comodo certificate. So I guess it's related to the issue but I didn't find a solution for this.
OS is Ubuntu Server 16.04.3 and PHP is version 7.0.22.
Any help is welcome!
Look like either Cryptopia or Comodo changed something on their sides as the issue resolved by itself after a few days.
Thanks to those who tried to help.
I will delete this question after a day or two to let commenters see this "solution".