Gmail Error :The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.5.1 Authentication Required

后端 未结 25 2392
悲&欢浪女
悲&欢浪女 2020-11-22 02:12

I am using following code to send email. The Code works correctly in my local Machine. But on Production server i am getting the error message

var fromAddres         


        
25条回答
  •  爱一瞬间的悲伤
    2020-11-22 03:01

    You might need to create/generate a specific APP password from gmail. you app or script will then use this new password instead of your regular password. Your regular password will still work fine for you.

    That is what did it for me. I still used the same email account but had to generate a new app specific password.

    https://support.google.com/accounts/answer/185833?hl=en

    Basically you can do it here: https://security.google.com/settings/security/apppasswords

提交回复
热议问题