[exim] a tool to relay to Gmail using AUTH XOAUTH2

Páxina inicial
Borrar esta mensaxe
Responder a esta mensaxe
Autor: J. R. Okajima
Data:  
Para: exim-users
CC: hooanon05g
Asunto: [exim] a tool to relay to Gmail using AUTH XOAUTH2
Hello exim-users,

I am developing a small external tool for exim. If possible, I'd ask
you some comments. And if you are interested, I'd also ask some trial
and tests. If anyone comes up, I will open a new project on github and
make it public for anyone to use.

Here is a description about the tool.
- behaves like a pipe or a hook.
  exim delivers a mail to localhost:10025, and this tool is listening on
  that port.
- accepting, the tool connects to smtp.gmail.com:smtps via stunnel(1) so
  that the tool can relay the SMTP session from exim.
- the tool handles MAIL FROM <sender@???> only.
  + obtain a refresh-token of the sender's from an external file (like
    exim's passwd.client file).
  + obtain an access-token from accounts.google.com using the
    refresh-token, client-id and client-secret.
    client-id and client-secret are pre-obtained from Google API Console
    (see below).
  + issue AUTH XOAUTH2 using the access-token and sender@???.
  + finally issue the original MAIL FROM <sender@???>.
  + all other smtp commands and replies in the session are not handled
    and the tool just read/write between exim and smtp.gmail.com
    transparently.
- unnecessary to allow "Less secure app access" for sender@???.



J. R. Okajima