SSL 错误 curl/wget 未知协议/错误版本号

SSL 错误 curl/wget 未知协议/错误版本号

我一直尝试在命令行/cron 作业中使用本地托管的 https url,但遇到了这些错误。curl 输出类似。在其他服务器上使用时,相同的命令可以完美运行。

默认

[root@tejon ~]# wget -O /dev/null https://www.domain.com/cron/notification.php
--2013-05-27 10:33:38--  https://www.domain.com/cron/notification.php
Resolving www.domain.com... 173.45.38.60
Connecting to www.domain.com|173.45.38.60|:443... connected.
OpenSSL: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol
Unable to establish SSL connection.

TLSv1

[root@tejon ~]# wget --secure-protocol=TLSv1 -O /dev/null https://www.domain.com/cron/notification.php
--2013-05-27 10:45:59--  https://www.domain.com/cron/notification.php
Resolving www.domain.com... 173.45.38.60
Connecting to www.domain.com|173.45.38.60|:443... connected.
OpenSSL: error:1408F10B:SSL routines:SSL3_GET_RECORD:wrong version number
Unable to establish SSL connection.

SSLv2

[root@tejon ~]# wget --secure-protocol=SSLv2 -O /dev/null https://www.domain.com/cron/notification.php
--2013-05-27 10:47:18--  https://www.domain.com/cron/notification.php
Resolving www.domain.com... 173.45.38.60
Connecting to www.domain.com|173.45.38.60|:443... connected.

并且它会阻止输入,但是文件不会被执行。

SSLv3

[root@tejon ~]# wget --secure-protocol=SSLv3 -O /dev/null https://www.domain.com/cron/notification.php
--2013-05-27 10:43:23--  https://www.domain.com/cron/notification.php
Resolving www.domain.com... 173.45.38.60
Connecting to www.domain.com|173.45.38.60|:443... connected.
OpenSSL: error:1408F10B:SSL routines:SSL3_GET_RECORD:wrong version number
Unable to establish SSL connection.

答案1

由数据中心支持解决。

域名被添加到 /etc/hosts 不知道如何添加,一旦删除它就可以工作。

相关内容