经过开发人员的研究,钉钉版无法正常运行原来和curl有关系,需要重新编译curl,更换编译参数,更换ssl_version NSS为openssl,详细操作步骤如下:
1.查看本机curl 版本
curl -V
curl 7.29.0 (x86_64-unknown-linux-gnu) libcurl/7.29.0 OpenSSL/1.0.2k zlib/1.2.7 libidn/1.28
Protocols: tftp ftp telnet dict http file https ftps
Features: IDN IPv6 Largefile NTLM SSL libz
2.下载
wget -c http://curl.haxx.se/download/archeology/curl-7.29.0.tar.gz
3.解压
tar -zxf curl-7.29.0.tar.gz
4.编译安装
cd curl-7.29.0
./configure --without-nss --with-ssl
make && make install
说明:–without-nss 禁用nss, –with-ssl启用openssl的支持.
5.将curl的库载入动态共享文件,并重新加载
echo "/usr/local/lib" >> /etc/ld.so.conf
ldconfig
这一部很重要,否则php的curl就是不会支持openssl
6.查看新安装后curl的版本
curl -V
curl 7.29.0 (x86_64-unknown-linux-gnu) libcurl/7.29.0 OpenSSL/1.0.2k zlib/1.2.7 libidn/1.28
Protocols: tftp ftp telnet dict http file https ftps
Features: IDN IPv6 Largefile NTLM SSL libz
7.重启你的httpd/nginx服务和php服务器
service nginx restart #或service httpd restart
service php-fpm restart