我正在尝试使用Gmail的SMTP服务器,并且正在尝试生成SSL证书。我正在运行网站“ https://docs.bvstools.com/home/ssl-documentation/openssl”中提供的命令“ s_client -connect smtp.gmail.com:465”。虽然,此命令会生成证书,但还会给出无法获得证书的验证错误。我正在使用Windows10。是否缺少某些东西?
OpenSSL> s_client -connect smtp.gmail.com:465
CONNECTED(00000158)
depth=1 C = US, O = Google Trust Services, CN = Google Internet Authority G3
verify error:num=20:unable to get local issuer certificate
---
Certificate chain
0 s:/C=US/ST=California/L=Mountain View/O=Google LLC/CN=smtp.gmail.com
i:/C=US/O=Google Trust Services/CN=Google Internet Authority G3
1 s:/C=US/O=Google Trust Services/CN=Google Internet Authority G3
i:/OU=GlobalSign Root CA - R2/O=GlobalSign/CN=GlobalSign
---
Server certificate
-----BEGIN CERTIFICATE-----
LUGHcQkNZN4P1pucLJKGWMh+LRtr3G9BNS3EAaxoDV+2P//mSEKktsks/0Sv91By
e+CkrkjZUyUmzdNa6qk=
-----END CERTIFICATE-----
subject=/C=US/ST=California/L=Mountain View/O=Google LLC/CN=smtp.gmail.com
issuer=/C=US/O=Google Trust Services/CN=Google Internet Authority G3
---
No client certificate CA names sent
Peer signing digest: SHA256
Server Temp Key: X25519, 253 bits
---
SSL handshake has read 2962 bytes and written 261 bytes
Verification error: unable to get local issuer certificate
---
New, TLSv1.2, Cipher is ECDHE-RSA-CHACHA20-POLY1305
Server public key is 2048 bit
Secure Renegotiation IS supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
SSL-Session:
Protocol : TLSv1.2
Cipher : ECDHE-RSA-CHACHA20-POLY1305
Session-ID: A870AC76E02423FC7BCBA72F175F07E4ACD8088EDAEC9B86BE9F534CCDE9B575
Session-ID-ctx:
Master-Key: 90B7E4DF370FD67C9DD0ABDE23C01DC9126AF4AC13C0CA504B503B6FFCA320A7864DC9A706CA77B287AA09499D6BFAFE
PSK identity: None
PSK identity hint: None
SRP username: None
TLS session ticket lifetime hint: 100800 (seconds)
TLS session ticket:
0000 - 00 a2 db 74 d0 e4 33 63-1c 1a 41 c7 96 5d f3 f0 ...t..3c..A..]..
0010 - e5 bd ff d7 94 29 db 27-6a 43 40 c1 8c e7 5e f3 .....).'jC@...^.
0020 - a2 95 6f 3e 82 74 ac 83-f4 24 3f 75 c2 62 37 32 ..o>.t...$?u.b72
0030 - c4 d1 9c e7 f4 88 31 fb-36 02 ed 1b 9c e5 26 cf ......1.6.....&.
0040 - e1 61 6d 4b a1 e0 0b 82-53 31 be 58 99 f1 70 b3 .amK....S1.X..p.
0050 - 78 33 77 63 70 8e b5 73-84 11 f8 e9 3c d7 08 c6 x3wcp..s....<...
0060 - 26 a2 77 30 06 30 5b 5d-46 1c 55 f0 d4 2a b0 5f &.w0.0[]F.U..*._
0070 - ff 18 d4 03 ed d6 86 3e-0a e7 cc 37 0f a1 74 7f .......>...7..t.
0080 - f1 72 bc 9c 23 24 f6 29-7a 70 55 dc a5 97 25 73 .r..#$.)zpU...%s
0090 - 91 b5 f0 b9 9b 38 6a e4-11 a6 ba 6f 84 e5 36 a0 .....8j....o..6.
00a0 - 4c b5 d4 05 14 52 78 1f-1f a2 10 29 59 b7 b7 68 L....Rx....)Y..h
00b0 - a1 4c 0a 44 ed c7 3c 7e-87 99 d2 5b 88 3b c3 cd .L.D..<~...[.;..
00c0 - e3 18 5d b0 92 45 a9 17-b1 5f 2a 2c bb a7 15 fb ..]..E..._*,....
00d0 - ea f2 ed 2d 21 a7 c8 ec-de 12 ...-!.....
Start Time: 1556808643
Timeout : 7200 (sec)
Verify return code: 20 (unable to get local issuer certificate)
Extended master secret: yes
---
220 smtp.gmail.com ESMTP j67sm117121680pfc.72 - gsmtp