What mechanism does Gmail use for user authentication?

主宰稳场 提交于 2019-12-05 12:28:33

To quote Google's documentation for authenticating to GMail's SMTP:

Outgoing Mail (SMTP) Server - requires TLS: smtp.gmail.com (use authentication)
Use Authentication: Yes
Use STARTTLS: Yes (some clients call this SSL)
Port: 465 or 587

the authentication in this case is "Plain".

To find out what authentication mechanisms an SMTP server supports, send the EHLO command. If you haven't built your own SMTP client yet, you can test this using TELNET. The server will respond with the ESMTP extensions that it supports, including AUTH. For example, if you send the EHLO command to smtp.gmail.com, you will find that it currently supports 4 mechanisms:

SERVER: 220 mx.google.com ESMTP c10sm612924yhk.4
CLIENT: EHLO AR93684-PC.local
SERVER: 250-mx.google.com at your service, [75.189.236.125]
SERVER: 250-SIZE 35882577
SERVER: 250-8BITMIME
SERVER: 250-AUTH LOGIN PLAIN XOAUTH XOAUTH2
SERVER: 250 ENHANCEDSTATUSCODES

So the answer to your question is Login, Plain, XOAuth, and XOAuth2.

Note that XOAuth has been deprecated in favor of XOAuth2: https://developers.google.com/accounts/docs/OAuth2

Fabricio
Mail Sender: SMTP
SMTP Server: smtp.gmail.com
Authentication: LOGIN
User: yourzuser@gmail.com
Pass: gess???
security: TLS
port: 587

at least this work for me :D cheers

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!