對此主題進行了廣泛的調查,但仍然沒有設法迫使新版本OpenSSL
與OSX El Capitan上的ZendServer v.8.5.2協同工作。Zend-Server 8.5,沒有設法更新OpenSSL for PHP
史前史:默認情況下,似乎ZendServer和埃爾卡皮坦openssl-0.9.8zc。新版本的PHP 5.6.15在此版本的OpenSSL和Composer-PHP中無法正常工作。我遇到了錯誤:
無法找到有效的CA證書文件。你必須設置一個有效的'cafile'選項。 SSL/TLS保護需要有效的CA證書文件。 ...
[Composer \ Downloader \ TransportException]
配置的cafile無效或無法讀取。
我做的OpenSSL版本啤酒的更新,然後確定它在系統中正確註冊:
brew unlink openssl && brew link --force openssl
但在現實中,似乎ZendServer對其進行訪問有它的自己的本地副本OpenSSL的LIB二進制文件目錄:
在/ usr /本地/的Zend /斌/ OpenSSL的
openssl.cafile
是空的,所以我決定把它指向新的路徑,因爲它是在一些教程建議:USR /本地/ etc/OpenSSL的/ cert.pem
在結果:
似乎系統指向OpenSSL的正確版本:
$ openssl version
OpenSSL 1.0.2f 28 Jan 2016
$ openssl version -d
OPENSSLDIR: "/usr/local/etc/openssl"
同時which
是指向Zend的OpenSSL版本:
$ which -a openssl
/usr/local/zend/bin/openssl
/usr/local/bin/openssl
/usr/bin/openssl
和PHP似乎仍然有老默認配置,通過路徑不中我的系統存在了:
$ php -i | grep openssl
Configure Command => './configure' '--prefix=/usr/local/zend' '--with-config-file-path=/usr/local/zend/etc' '--with-config-file-scan-dir=/usr/local/zend/etc/conf.d' '--disable-debug' '--enable-inline-optimization' '--disable-all' '--enable-libxml' '--enable-session' '--enable-spl' '--enable-xml' '--enable-hash' '--enable-reflection' '--with-pear' '--with-apxs2=/usr/local/zend/apache2/bin/apxs' '--with-layout=GNU' '--enable-filter' '--with-pcre-regex' '--with-zlib' '--enable-simplexml' '--enable-dom' '--with-libxml-dir=/usr/local' '--with-openssl=/usr/local/openssl-0.9.8zc' '--enable-pdo' '--with-pdo-sqlite' '--with-pdo-mysql=mysqlnd' '--with-libedit' '--with-pdo-pgsql' '--with-iconv' '--with-sqlite3' '--disable-phar' '--enable-xmlwriter' '--enable-xmlreader' '--enable-mysqlnd' '--enable-json' 'CC=gcc' 'CFLAGS=-fPIC '-O2' '-pipe' '-g' '-fno-common' '-g'' 'CPPFLAGS=-fPIC 'CXXFLAGS=-fPIC 'CXX=g++' 'LDFLAGS='
openssl
Openssl default config => /usr/local/openssl-0.9.8zc/ssl/openssl.cnf
openssl.cafile => /usr/local/etc/openssl/cert.pem => /usr/local/etc/openssl/cert.pem
openssl.capath => no value => no value
我還沒有發現任何方式改變默認Zend的PHP的OpenSSL配置爲Zend Server 8.5.2,並將其指向OSX中新鮮的OpenSSL。
作曲家仍然拋出相同的錯誤,不起作用。 我在這裏和那裏爬行StackOverflow,還沒有找到解決方案,在我的情況下工作。任何幫助將不勝感激。
謝謝!
回答對自己:看來,當PHP編譯,這些庫建於到PHP所以升級SSL LIB文件將不會有任何影響,除非PHP重新編譯。聽起來,沒有辦法更新ZendServer中的OpenSSL庫,除非下載更新的版本(沒有更新的版本)。
中找到它似乎沒有辦法更新OpenSSL,以便在PHP不ZendServer對其進行訪問PHP和庫重新編譯。將嘗試擦除狀態,並重新配置OpenSSL默認配置,以便它們指向證書所在的正確位置。 – Farside
Stack Overflow是編程和開發問題的網站。這個問題似乎與題目無關,因爲它不涉及編程或開發。請參閱幫助中心的[我可以詢問哪些主題](http://stackoverflow.com/help/on-topic)。也許[超級用戶](http://superuser.com/)或[Apple Stack Exchange](http://apple.stackexchange.com/)會是一個更好的地方。另請參閱[我在哪裏發佈有關Dev Ops的問題?](http://meta.stackexchange.com/q/134306)。 – jww
@jww,對不起,我在這裏看到類似的問題,這就是爲什麼在這裏問。它更多的是關於PHP配置,以及在Composer開發過程中遇到的困難。 – Farside