YUN SSMTP does not work

Hello,

i would like to sent an email when e.g. a pir sensor fires

Therefore, I installed SSMTP according to instructions on the yun forum

opkg update
opkg install ssmtp

also adapted the conf file in /etc/ssmtp according to yun forum instructions

root=leonardo.timmermans@gmail.com
mailhub=smtp.gmail.com:587
rewriteDomain=
hostname=leonardo.timmermans@gmail.com
UseSTARTTLS=YES
AuthUser=leonardo.timmermans@gmail.com
AuthPass=xxxxxxx       
FromLineOverride=YES

Then made a little mail file test.txt

To: leonardo.timmermans@gmail.com
From: leonardo.timmermans@gmail.com
Subject: ARDUINO YUN ALARM ACHTERDEUR 

hello world

Then started ssmtp

ssmtp leonardo.timmermans@gmail.com < test.txt

But this gives an error
ssmtp: Authorization failed (534 5.7.14 Check Gmail through other email platforms - Gmail Help h4sm18505837wjx.41 - gsmtp)

Is anybody experiencing the same problem ? What am I doing wrong ??

Anyone can help ??

Best wishes
Leo

Hello,

I saw that one can change settings in ones google account so that access is granted to apps with 'lower security apps settings'
If you grant access to 'lower security apps, the ssmtp works with no error, but I think this is not the way to go ...

Should we than change to something else than ssmtp ???

Best wishes,
Leo

LeoTimmermans:
Hello,

I saw that one can change settings in ones google account so that access is granted to apps with 'lower security apps settings'
If you grant access to 'lower security apps, the ssmtp works with no error, but I think this is not the way to go ...

Should we than change to something else than ssmtp ???

Best wishes,
Leo

If I were you, set up dummy gmail account and grant access to 'lower security apps'.

Thank you Sonnyyu!

Was also thinking along this line.

Best wishes
Leo