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

后端 未结 5 1389
遇见更好的自我
遇见更好的自我 2021-01-05 00:01

I have XAMPP on Windows7. after update the pear.php.net channel with:

pear channel-update pear.php.net

and try for installing new packages,

5条回答
  •  清歌不尽
    2021-01-05 00:46

    In my mac, and based of chintan reply, I did it:

    /Applications/XAMPP/bin/php -r "print_r(openssl_get_cert_locations());"
    

    ... to show the default_cert_file

    Array
    (
        [default_cert_file] => /Applications/XAMPP/xamppfiles/share/openssl/cert.pem
        [default_cert_file_env] => SSL_CERT_FILE
        [default_cert_dir] => /Applications/XAMPP/xamppfiles/share/openssl/certs
        [default_cert_dir_env] => SSL_CERT_DIR
        [default_private_dir] => /Applications/XAMPP/xamppfiles/share/openssl/private
        [default_default_cert_area] => /Applications/XAMPP/xamppfiles/share/openssl
        [ini_cafile] => /Applications/XAMPP/xamppfiles/share/curl/curl-ca-bundle.crt
        [ini_capath] => 
    )
    

    Then a get the last version of cacert.pem:

    wget http://curl.haxx.se/ca/cacert.pem
    

    And then I moved it to the correct place of default_cert_file:

    sudo mv cacert.pem /Applications/XAMPP/xamppfiles/share/openssl/cert.pem
    

提交回复
热议问题