bpstrngr
bpstrngr

Reputation: 419

SSL broken after pear channel-update pear.php.net

I installed php7.2.2 from source, and started obtaining mssql extension by pecl install sqlsrv. It responded to pecl search sqlsrv, but notified me to run pear channel-update pear.php.net, after which both search and install failed to work with this error message:

Connection to `ssl://pecl.php.net:443' failed: Unable to find the socket transport "ssl" - did you forget to enable it when you configured PHP?

I read all kinds of suggestions like http://forums.devshed.com/php-development-5/ssl-issue-pear-channel-update-pear-php-net-970623.html and SSL issue after pear channel-update pear.php.net , but I have no "openssl.so" library anywhere (somewhere I read php7 deprecated it), php -r "print_r(openssl_get_cert_locations());" finds the function undefined, and referencing a downloaded openssl.cafile=/opt/php/lib/php/extensions/no-debug-non-zts-20170718/cacert.pem from http://curl.haxx.se/ca/cacert.pem in php.ini (unsurprisingly) proves futile. What is going on if it worked fine before that silly update?

Upvotes: 2

Views: 4696

Answers (1)

user9957751
user9957751

Reputation: 31

I have had a similar problem with OpenSUSE LEAP 15.0.

After pear list-updates, I've got a warning saying that I had to update the PECL channel protocol. After pear channel-update pecl.php.net, whenever I try to install or update a PECL extensión I get the following error.

Connection to `ssl://pecl.php.net:443' failed: Unable to find the socket transport "ssl" - did you forget to enable it when you configured PHP?

However, PEAR is working fine.

Checking the differences between PEAR and PECL commands, I've seen that in PECL the last line that runs PHP uses the -n option that tells PHP not to use php.ini. The OpenSSL extension is not enabled and, therefore, the SSL and TLS socket transports are not registered.

I don't know if this is intentional but, I think, it is a little inconsistent.

Upvotes: 3

Related Questions