使用gmail端口587的openssl客户端SMTP,< crlf>后的无响应(250 OK)。< crlf> [英] openssl client SMTP with gmail port 587, no response (250 OK) from after <crlf>.<crlf>

查看:250
本文介绍了使用gmail端口587的openssl客户端SMTP,< crlf>后的无响应(250 OK)。< crlf>的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直试图使用openssl与smtp.gmail.com端口587或465建立连接:
openssl s_client -host smtp.gmail.com -port 587 -starttls smtp



以及认证,邮件发送,rcpt和数据都是成功的。但我的问题是,在我写之后。在新行中,服务器没有250 OK响应。



这里是过程:

pre > CONNECTED(00000003)
depth = 1 / C = US / O = Google Inc / CN = Google互联网管理局
验证错误:num = 20:无法取得本地发卡行证书
验证回报:0
---
证书链
0 s:/ C = US / ST = California / L = Mountain View / O = Google Inc / CN = smtp .gmail.com
i:/ C = US / O = Google Inc / CN = Google互联网管理局
1 s:/ C = US / O = Google Inc / CN = Google互联网管理局
i :/ C = US / O = Equifax / OU = Equifax安全证书授权
---
服务器证书
----- BEGIN CERTIFICATE -----
(证书)
----- END CERTIFICATE -----
subject = / C = US / ST = California / L = Mountain View / O = Google Inc / CN = smtp.gmail.com
issuer = / C = US / O = Google Inc / CN = Google互联网管理局
---
未发送客户证书CA名称
---
SSL握手已经重新广告1910字节并写入338字节
---
新的TLSv1 / SSLv3密码是RC4-MD5
服务器公钥是1024位
支持安全重协商
压缩:NONE
扩展:NONE
SSL-Session:
协议:TLSv1
密码:RC4-MD5
会话ID:28E597C0025A93C82AD4A7C517F699B37D106D760597467B522C1041F1BC17C8
Session- ID-ctx:
主密钥:1CC83A8A4B7864DF9BBD9E9742B4E5A5937941EB2A28B88A1D4214920B77AC976D3ADC2DA7B60CF8BD6BC2B0712A42A2
Key-Arg:无
开始时间:1296911515
超时:300(秒)
验证返回码:20(无法获得本地发行人证书)
---
250 ENHANCEDSTATUSCODES
ehlo
250-mx.google.com为您服务,[121.94.150.147]
250 -SIZE 35651584
250-8BITMIME
250-AUTH LOGIN PLAIN XOAUTH
250 ENHANCEDSTATUSCODES
验证登录
334 VXNlcm5hbWU6
<我的电子邮件>
334 UGFzc3dvcmQ6
<我的密码>
235 2.7.0已接受
邮件来自:< email>
250 2.1.0确定t14sm1471936icd.10
转至:< email>
250 2.1.5确定t14sm1471936icd.10
数据
来自:某人< email>
354继续t14sm1471936icd.10
至:someone< email>
主题:测试
测试
测试2


451 4.4.2超时 - 关闭连接。 t14sm1471936icd.10
read:errno = 0

我在win7 32中使用cygwin。



我一直在搜索谷歌上所有可能的关键字,但没有解决方案出来。
请帮助!

解决方案

也许在命令行中添加'-crlf'选项:

  openssl s_client -host smtp.gmail.com -port 587 -starttls smtp -crlf 


I've been trying to use openssl to establish a connection with smtp.gmail.com port 587 or 465 with: openssl s_client -host smtp.gmail.com -port 587 -starttls smtp

and the authentication, mail from, rcpt to, and data were all successful. but my problem is, after i write . in a new line, no 250 OK response from the server.

here is the process:

    CONNECTED(00000003)
    depth=1 /C=US/O=Google Inc/CN=Google Internet Authority
    verify error:num=20:unable to get local issuer certificate
    verify return:0
    ---
    Certificate chain
     0 s:/C=US/ST=California/L=Mountain View/O=Google Inc/CN=smtp.gmail.com
       i:/C=US/O=Google Inc/CN=Google Internet Authority
     1 s:/C=US/O=Google Inc/CN=Google Internet Authority
       i:/C=US/O=Equifax/OU=Equifax Secure Certificate Authority
    ---
    Server certificate
    -----BEGIN CERTIFICATE-----
    (certification)
    -----END CERTIFICATE-----
    subject=/C=US/ST=California/L=Mountain View/O=Google Inc/CN=smtp.gmail.com
    issuer=/C=US/O=Google Inc/CN=Google Internet Authority
    ---
    No client certificate CA names sent
    ---
    SSL handshake has read 1910 bytes and written 338 bytes
    ---
    New, TLSv1/SSLv3, Cipher is RC4-MD5
    Server public key is 1024 bit
    Secure Renegotiation IS supported
    Compression: NONE
    Expansion: NONE
    SSL-Session:
        Protocol  : TLSv1
        Cipher    : RC4-MD5
        Session-ID: 28E597C0025A93C82AD4A7C517F699B37D106D760597467B522C1041F1BC17C8
        Session-ID-ctx:
        Master-Key: 1CC83A8A4B7864DF9BBD9E9742B4E5A5937941EB2A28B88A1D4214920B77AC976D3ADC2DA7B60CF8BD6BC2B0712A42A2
        Key-Arg   : None
        Start Time: 1296911515
        Timeout   : 300 (sec)
        Verify return code: 20 (unable to get local issuer certificate)
    ---
    250 ENHANCEDSTATUSCODES
    ehlo
    250-mx.google.com at your service, [121.94.150.147]
    250-SIZE 35651584
    250-8BITMIME
    250-AUTH LOGIN PLAIN XOAUTH
    250 ENHANCEDSTATUSCODES
    auth login
    334 VXNlcm5hbWU6
    <my email>
    334 UGFzc3dvcmQ6
    <my password>
    235 2.7.0 Accepted
    mail from:<email>
    250 2.1.0 OK t14sm1471936icd.10
    rcpt to:<email>
    250 2.1.5 OK t14sm1471936icd.10
    data
    from: someone <email>
    354  Go ahead t14sm1471936icd.10
    to : someone <email>
    subject: test
    test
    test2
    .

451 4.4.2 Timeout - closing connection. t14sm1471936icd.10
read:errno=0

I am using cygwin in win7 32.

I've been searching for all of the possible keywords on google but no solution comes out. PLEASE HELP!

解决方案

Maybe add the '-crlf' option to the comand line :

openssl s_client -host smtp.gmail.com -port 587 -starttls smtp -crlf

这篇关于使用gmail端口587的openssl客户端SMTP,&lt; crlf&gt;后的无响应(250 OK)。&lt; crlf&gt;的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆