Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for OAuth authentication #34

Open
robstewart57 opened this issue Oct 6, 2021 · 2 comments
Open

Support for OAuth authentication #34

robstewart57 opened this issue Oct 6, 2021 · 2 comments
Assignees

Comments

@robstewart57
Copy link

This library supports PLAIN, LOGIN and CRAM_MD5 authentication mechanisms.

This issue is a feature request for OAuth2 based authentication for sending emails with this library, with a XOAUTH2 constructor for AuthType and supporting functions in Network/Mail/SMTP.hs.

Such that the SMTP client transmits this to the SMTP server:

AUTH XOAUTH2 <oauth token>

rather than providing a username and password as with LOGIN. Instead, a username and OAuth token would be provided.

It might be that this library would need to encode this information in SASL XOAUTH2 format.

@typetetris typetetris self-assigned this Oct 6, 2021
@typetetris
Copy link
Collaborator

I don't have access to Office365 nor any mail server using SASL XOAUTH2.

How could I test this against a real server after implementation? Are there freely available mail services providing this OAuth2 authentication?

@robstewart57
Copy link
Author

Hi @typetetris ,

I've opened a pull request that implements OAuth authentication for this library.

PR: #38

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants