Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/amazon-s3/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
OpenSSL错误警报握手失败_Openssl - Fatal编程技术网

OpenSSL错误警报握手失败

OpenSSL错误警报握手失败,openssl,Openssl,当尝试连接到某些网站时,OpenSSL无法连接。我在OpenSSL的s\u客户端中遇到此错误: $ openssl s_client -connect www.airvistara.com:443 -debug CONNECTED(00000003) write to 0x600060cf0 [0x600076e90] (346 bytes => 346 (0x15A)) 0000 - 16 03 01 01 55 01 00 01-51 03 03 b7 94 61 d2 52 ..

当尝试连接到某些网站时,OpenSSL无法连接。我在OpenSSL的
s\u客户端中遇到此错误:

$ openssl s_client -connect www.airvistara.com:443 -debug
CONNECTED(00000003)
write to 0x600060cf0 [0x600076e90] (346 bytes => 346 (0x15A))
0000 - 16 03 01 01 55 01 00 01-51 03 03 b7 94 61 d2 52   ....U...Q....a.R
0010 - 8e fa c5 5e 3d d0 0b 62-91 14 c3 21 d5 62 3a e8   ...^=..b...!.b:.
0020 - 27 1c 99 12 0c e8 1d e8-ea cf 15 00 00 b4 c0 30   '..............0
0030 - c0 2c c0 28 c0 24 c0 14-c0 0a 00 a5 00 a3 00 a1   .,.(.$..........
0040 - 00 9f 00 6b 00 6a 00 69-00 68 00 39 00 38 00 37   ...k.j.i.h.9.8.7
0050 - 00 36 00 88 00 87 00 86-00 85 c0 32 c0 2e c0 2a   .6.........2...*
0060 - c0 26 c0 0f c0 05 00 9d-00 3d 00 35 00 84 c0 2f   .&.......=.5.../
0070 - c0 2b c0 27 c0 23 c0 13-c0 09 00 a4 00 a2 00 a0   .+.'.#..........
0080 - 00 9e 00 67 00 40 00 3f-00 3e 00 33 00 32 00 31   ...g.@.?.>.3.2.1
0090 - 00 30 00 9a 00 99 00 98-00 97 00 45 00 44 00 43   .0.........E.D.C
00a0 - 00 42 c0 31 c0 2d c0 29-c0 25 c0 0e c0 04 00 9c   .B.1.-.).%......
00b0 - 00 3c 00 2f 00 96 00 41-c0 11 c0 07 c0 0c c0 02   .<./...A........
00c0 - 00 05 00 04 c0 12 c0 08-00 16 00 13 00 10 00 0d   ................
00d0 - c0 0d c0 03 00 0a 00 15-00 12 00 0f 00 0c 00 09   ................
00e0 - 00 ff 02 01 00 00 73 00-0b 00 04 03 00 01 02 00   ......s.........
00f0 - 0a 00 3a 00 38 00 0e 00-0d 00 19 00 1c 00 0b 00   ..:.8...........
0100 - 0c 00 1b 00 18 00 09 00-0a 00 1a 00 16 00 17 00   ................
0110 - 08 00 06 00 07 00 14 00-15 00 04 00 05 00 12 00   ................
0120 - 13 00 01 00 02 00 03 00-0f 00 10 00 11 00 23 00   ..............#.
0130 - 00 00 0d 00 20 00 1e 06-01 06 02 06 03 05 01 05   .... ...........
0140 - 02 05 03 04 01 04 02 04-03 03 01 03 02 03 03 02   ................
0150 - 01 02 02 02 03 00 0f 00-01 01                     ..........
read from 0x600060cf0 [0x60007c3f0] (7 bytes => 7 (0x7))
0000 - 15 03 03 00 02 02 28                              ......(
2348672:error:14077410:SSL routines:SSL23_GET_SERVER_HELLO:sslv3 alert handsha
 failure:s23_clnt.c:769:
...
$openssl s_客户端-连接www.airvistara.com:443-debug
已连接(00000003)
写入0x600060cf0[0x600076e90](346字节=>346(0x15A))
0000-16 03 01 01 55 01 00 01-51 03 03 b7 94 61 d2 52…U…Q…a.R
0010-8e fa c5 5e 3d d0 0b 62-91 14 c3 21 d5 62 3a e8…^=…b。。。!。b:。
0020-27 1c 99 12 0c e8 1d e8 ea cf 15 00 00 b4 c0 30'..0
0030-C02CC028C024C014-C00A000A500A3 00A1.,.($)。。。。。。。。。。
0040-00 9f 00 6b 00 6a 00 69-00 68 00 39 00 38 00 37…k.j.i.h.9.8.7
0050-00 36 00 88 00 87 00 86-00 85 c0 32 c0 2 E c0 2a.6………2*
0060-c0 26 c0 0f c0 05 00 9d-00 3d 00 35 00 84 c0 2f.&……..5/
0070-c0 2b c0 27 c0 23 c0 13-c0 09 00 a4 00 a2 00 a0.+。#。。。。。。。。。。
0080-00 9e 00 67 00 40 00 3f-00 3e 00 33 00 32 00 31…g.@?.>.3.2.1
0090-00 30 00 9a 00 99 00 98-00 97 00 45 00 44 00 43.0…..东德州
00a0-00 42 c0 31 c0 2d c0 29-c0 25 c0 0e c0 04 00 9c.B.1.-).%。。。。。。
00b0-00 3c 00 2f 00 96 00 41-c0 11 c0 07 c0 0c c0 02。7(0x7))
0000 - 15 03 03 00 02 02 28                              ......(
2348672:错误:14077410:SSL例程:SSL23\U GET\U SERVER\U HELLO:sslv3 alert handsha
故障:s23\u clnt.c:769:
...
我的强项不是SSL,所以请提供一些指导。客户端软件几乎适用于所有站点,但也有一些站点会出现此错误

客户端软件几乎适用于所有站点,但也有一些站点会出现此错误

正如jww所评论的那样,如果使用,则不会出现此错误

所有现代浏览器都支持SNI,但除此之外,旧版本的Java(高达JDK6)、python(高达2.7.9)、Android上的一些常用库等都不支持SNI

由于SNI越来越成为一种需求(所有Cloudflare FreeSL仅适用于SNI),因此应修复客户端软件以获得SNI支持。

使用此方法

 $ openssl s_client -connect www.example.com:443 -servername www.example.com
    CONNECTED(00000003)
    ...
       Cipher    : ECDHE-ECDSA-AES128-GCM-SHA256

可能是-servername选项在OpenSSL 0.9.8中不可用,但在OpenSSL 1.0.1中应该可用。

Stack Overflow是一个用于编程和开发问题的网站。这个问题似乎与主题无关,因为它与编程或开发无关。请参阅帮助中心。也许或者是一个更好的提问地点。另外请参阅。要回答您的问题,请将TLS 1.0或更高版本与SNI一起使用。以下操作与预期一样有效:
openssl s_client-connect www.airvistara.com:443-tls1-servername www.airvistara.com
-servername
登记SNI扩展。感谢jww和Steffen,这回答了我的问题。还有一个问题。您是如何确定SNI是SNI的问题?正如您从
openssl s_客户端
输出中所看到的,它在没有
-servername
选项的情况下失败,并在中成功。除此之外,我有自己的SSL分析工具。这提供了(除其他外):
SSL升级在没有SNI的情况下失败。理想情况下,这应该是公认的答案。