Does /home/myuser/.oauth2token have a bang-path in it? What does that path point to? Maybe something like :
#!/usr/local/bin/python3.7 Is whatever it points to executable? On Tue, Aug 11, 2020 at 10:27:42PM -0300, Marcelo Laia wrote: > On 11/08/20 at 08:14, Hokan wrote: > > > > Somebody wrote a blog post on how to do it: > > > > https://luxing.im/mutt-integration-with-gmail-using-oauth/ > > > > Hi, > > Thank you so much! It save my day. With your post, I could found more > information, because I use mutt+offlineimap+msmtp > > Offlineimap is run out of the box with OAuth2! A beautiful! > > But, msmtp is so hard to configure! > > I found this: > > https://github.com/tenllado/dotfiles/tree/master/config/msmtp > > I set up the system's keyring like this: > > secret-tool store --label=msmtp-oauth2 client-id client-id > Password: > > I copy and paste the "OAuth client ID" in the password prompt above. > > secret-tool store --label=msmtp-oauth2 client-secret client-secret > Password: > > I copy and paste the "Secret" in the password prompt above. > > secret-tool store --label=msmtp-oauth2 refresh refresh > Password: > > I copy and paste the "Refresh Token" in the password prompt above. > > Is this OK? > > My msmtprc is like this: > > account YZYZYZ > host smtp.gmail.com > from [email protected] > port 587 > protocol smtp > tls on > tls_trust_file /etc/ssl/certs/ca-certificates.crt > auth oauthbearer > user [email protected] > passwordeval /home/myuser/.oauth2token [email protected] YZYZYZ > > However, when I try to send a message, I got: > > sh: 1: /home/myuser/.oauth2token: Permission denied > msmtp: was not possible to read the stdout from "/home/myuser/.oauth2token > [email protected] YZYZYZ" > > Please, someone have a clue to solve this? > > Thank you! > -- Hokan Bicyclist Sysadmin
