~sircmpwn/aerc2#319:
outgoing: add oauth authentication method

My organisation uses gmail and does not allow one to enable 2FA which is required for app passwords; could oauth be implemented for outgoing mail too?

Status
REPORTED
Submitter
~tmplt
Assigned to
No-one
Submitted
30 days ago
Updated
28 days ago
Labels
feature smtp

~tmplt 30 days ago

An alternative would be to support msmtp as an outgoing messenger, which supports oauth (together with getmail-gmail-xoauth-tokens).

~labrat 29 days ago

msmtp already works, man aerc-sendmail

Also you can probably hack up a script and plug it into outgoing-cred-cmd that does the token exchange

~tmplt 29 days ago

On Sat Nov 16, 2019 at 10:37 AM ~labrat wrote:

msmtp already works, man aerc-sendmail Would that be just outgoing = /path/to/msmtp? I'm getting a confusing EOF error without the mail being sent. I tried using the below script as outgoing to see what aerc actually calls the executable with (in case I need to write some wrapper), but there is no ~/{options,stdin} after the mail has been sent. Am I missing something?

# sendmail-dummy.sh, with +x
echo -- "$@" > ~/options
while IFS= read -r line
do
    echo "$line" >> ~/stdin
done < /dev/stdin

~labrat 28 days ago

On Sat, Nov 16, 2019 at 01:46:50PM -0000, ~tmplt wrote:

Would that be just outgoing = /path/to/msmtp?

Well, depends on what you want to do. I've set mine to outgoing = /bin/msmtp --read-envelope-from

Am I missing something?

Probably

~tmplt 28 days ago

On Sun Nov 17, 2019 at 9:21 AM ~labrat wrote:

I've set mine to outgoing = /bin/msmtp --read-envelope-from

That does it, thanks.

Register here or Log in to comment, or comment via email.