Laravel无法使用2个可能的身份验证器在用户名“ xxxxxxxx”的SMTP服务器上进行身份验证

时间:2019-05-19 17:06:08

标签: laravel smtp

我正在Laravel中尝试重置密码电子邮件控制器。
我在.env文件中这样更改我的MAIL配置:

MAIL_DRIVER=smtp
MAIL_HOST=smtp.aruba.it
MAIL_PORT=465
MAIL_USERNAME=xxxxxxxxxxxx
MAIL_PASSWORD=xxxxxxxxxxxx
MAIL_ENCRYPTION=SSL

我收到此错误:

Swift_TransportException
Failed to authenticate on SMTP server with username 
"xxxxxxxxxxxx" using 2 possible authenticators. 
Authenticator LOGIN returned Expected response code 235 but got code 
"535", with message "535 5.7.0 ...authentication rejected ". 
Authenticator PLAIN returned Expected response code 235 but got code 
"535", with message "535 5.7.0 ...authentication rejected

我该如何解决?

2 个答案:

答案 0 :(得分:2)

MAIL_DRIVER=smtp
MAIL_HOST=smtp.mailtrap.io
MAIL_PORT=2525
MAIL_USERNAME=<mailtrap username>
MAIL_PASSWORD=<mailtrap passsword>
MAIL_ENCRYPTION=SSL


signup https://mailtrap.io  after signin they provide demo inbox then click on demo inbox. right hand side you get your username & password. just copy and paste

答案 1 :(得分:1)

MAIL_DRIVER=smtp
MAIL_HOST=smtp.aruba.it
MAIL_PORT=465 or 25 
MAIL_USERNAME=xxxxxxxxxxxx
MAIL_PASSWORD=xxxxxxxxxxxx      //in your aruba account. aren't they provided any password like mailtrap.
MAIL_ENCRYPTION=SSL ot tls
i am not sure about this but you can try once