0

I'm trying to get Mutt working with Gmail using OAuth2.

I'm using Debian 10 and have compiled Mutt 2.2.1 with --enable-smtp.

I've created my tokens.

My muttrc contains:

set smtp_oauth_refresh_command="~/oauth2.py --quiet --user=my_user@gmail.com --client_id=my_client_id --client_secret=my_client_secret --refresh_token=my_refresh_token"
set smtp_authenticators="oauthbearer"
set smtp_url = "smtp://my_user@gmail.com@smtp.gmail.com:587/"
set from = "my_name@gmail.com" 
set use_from = yes
set realname = "my_realname"

When I try to send the message I get:

SMTP session failed: 530 5.7.0 Must issue a STARTTLS command first. v188-20020a1cacc5000000b00384b71a50d5sm10960779wme.24 - gsmtp
Could not send the message.

I've tried:

set ssl_starttls = yes
set ssl_force_tls = yes

But Mutt complains that these are unknown variables.

Any suggestions, please?

1 Answers1

0

OK, all I needed to do was re-compile Mutt adding:

--with-gnutls