[CentOS] ssmtp config for gmail

Wed Oct 7 14:55:05 UTC 2015
Richard <lists-centos at listmail.innovate.net>


> Date: Wednesday, October 07, 2015 10:39:00 -0400
> From: Jerry Geis <geisj at pagestation.com>
>
> I have tried to setup ssmtp to relay through gmail.
> 
> root=my gmail address
> AuthUser=my gmail address
> AuthPass=my password
> FromLineOverride=YES
> mailhub=smtp.gmail.com:587
> UseSTARTTLS=YES
> TLS_CA_FILE=/etc/pki/tls/certs/ca-bundle.crt
> 
> I get this error:
> 
> Authorization failed (534 5.7.14
> https://support.google.com/mail/answer/78754 145sm16287775qhb.20 -
> gsmtp)
> 
> I am not using two step verification at this time. I can sign into
> my account just fine.
> 
> Am I missing a step?
> 
> Thanks
> 
> Jerry

I believe that your issue is the fourth bullet point in on the
support page they link to:

  -- Your mail app might not support the latest security
     standards. Learn how to allow less secure apps access
     to your account.


If you aren't using OAuth 2.0 (which you aren't in your context):

  <https://developers.google.com/gmail/oauth_overview?hl=en>

you need to set your gmail account to accept connections from "less
secure apps".

  <https://support.google.com/accounts/answer/6010255?hl=en>