无法找到安全性较低的应用程序设置

问题描述 投票:1回答:2

我们在Nodemailer中使用我们的Gmail凭证来发送开发中的测试邮件。今天我们尝试用和昨天一样的配置发送了一封,收到了以下错误。

2020-05-04T10:17:35.547Z Error: Invalid login: 535-5.7.8 Username and Password not accepted. Learn more at
04/05/2020 12:17:35 535 5.7.8 https://support.google.com/mail/?p=BadCredentials s18sm19281474wra.94 - gsmtp
04/05/2020 12:17:35 at SMTPConnection._formatError (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:784:19)
04/05/2020 12:17:35 at SMTPConnection._actionAUTHComplete (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:1523:34)
04/05/2020 12:17:35 at SMTPConnection.<anonymous> (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:550:26)
04/05/2020 12:17:35 at SMTPConnection._processResponse (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:942:20)
04/05/2020 12:17:35 at SMTPConnection._onData (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:749:14)
04/05/2020 12:17:35 at TLSSocket.SMTPConnection._onSocketData (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:195:44)
04/05/2020 12:17:35 at TLSSocket.emit (events.js:310:20)
04/05/2020 12:17:35 at addChunk (_stream_readable.js:286:12)
04/05/2020 12:17:35 at readableAddChunk (_stream_readable.js:268:9)
04/05/2020 12:17:35 at TLSSocket.Readable.push (_stream_readable.js:209:10)
04/05/2020 12:17:35 2020-05-04T10:17:34.439Z RES e77bea28-7092-4ec5-81b7-8230bd068e5a POST /projects/111/items 201 1117
04/05/2020 12:17:35 2020-05-04T10:17:35.588Z Error: Invalid login: 535-5.7.8 Username and Password not accepted. Learn more at
04/05/2020 12:17:35 535 5.7.8 https://support.google.com/mail/?p=BadCredentials p7sm18057972wrf.31 - gsmtp
04/05/2020 12:17:35 at SMTPConnection._formatError (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:784:19)
04/05/2020 12:17:35 at SMTPConnection._actionAUTHComplete (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:1523:34)
04/05/2020 12:17:35 at SMTPConnection.<anonymous> (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:550:26)
04/05/2020 12:17:35 at SMTPConnection._processResponse (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:942:20)
04/05/2020 12:17:35 at SMTPConnection._onData (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:749:14)
04/05/2020 12:17:35 at TLSSocket.SMTPConnection._onSocketData (/home/node/backend/node_modules/nodemailer/lib/smtp-connection/index.js:195:44)
04/05/2020 12:17:35 at TLSSocket.emit (events.js:310:20)
04/05/2020 12:17:35 at addChunk (_stream_readable.js:286:12)

我做了一些研究,发现我应该打开 "不那么安全的应用程序",但我找不到设置。

当我访问 https:/myaccount.google.comlesssecureapps。我得到 "设置无法读取"

node.js email smtp gmail nodemailer
2个回答
4
投票

这是Google方面的一个临时问题。 到11:44UTC,我们又恢复了。 https:/twitter.comgsuitestatus1257266044957319169?s=20。


4
投票

我们设法使用App Passwords快速修复它。对于使用Less Secure Apps登录的人来说,这是一个微不足道的修复方法。你只需要设置2FA(如果你还没有),并使用生成的App密码从你的应用程序登录,而不是标准密码。

https:/support.google.comaccountsanswer185833

这比迁移到OAuth更容易,往往是唯一的选择,对于任何急于在生产中解决这个问题的人来说。


3
投票

如果你是Gsuite管理员,你需要迁移到oAuth.我不知道google是暂时禁用LSA还是永久禁用。

https:/gsuiteupdates.googleblog.com201912less-secure-apps-oauth-google-username-password-incorrect.html。

LSA又恢复了安全设置,估计是有段时间停机了。

© www.soinside.com 2019 - 2024. All rights reserved.