Enough-Software / enough_mail

IMAP, POP3 and SMTP clients for Dart developers. Contains both low level as well as a high level API.
Mozilla Public License 2.0
100 stars 56 forks source link

Enough Mail with 2FA Accounts #212

Closed joaobaronisilva closed 1 year ago

joaobaronisilva commented 1 year ago

Hello my friends.

I would like to know if it is possible to login using an account that has 2FA enabled. I recently ran some tests, including using what Gmail calls App Passwords (https://support.google.com/accounts/answer/185833?hl=en), but they only work once, and you need to generate a new one at every login.

Ty

robert-virkus commented 1 year ago

Hey, you should use Oauth-based authentication, as users are actively discouraged to use app passwords. This requires certification by Google, here's an entry point for that process: https://developers.google.com/gmail/api/auth/about-auth?hl=en