0 votes

Hello Support,

In the article "OAuth 2.0 with Gmail over IMAP for service account" (https://www.limilabs.com/blog/oauth2-gmail-imap-service-account), you show how to access Gmail account of any domain user using OAuth 2.0.

In our application, we have implemented OAuth 2.0 for Exchange Online. Beginning September 30, 2024, all third-party apps that use Google accounts will have to be configured to use OAuth.

Instead of following right now the solution that you describe above for Google accounts (due to time restrictions), would it be possible to obtain OAuth2 tokens for Gmail accounts using Azure as the authentication platform?

Thank you in advance.

by

1 Answer

0 votes
 
Best answer

No, it is not directly possible to obtain OAuth2 tokens for Gmail accounts using Azure as the authentication platform.

Azure Active Directory (Azure AD) and Google OAuth2 are separate identity and authentication systems. When working with Gmail, OAuth tokens must be obtained via Google's authentication system.

Depending on your scenario maybe you could implement a Single Sign-On (SSO) solution. Google supports SSO through SAML or OpenID Connect (OIDC) with Azure AD as an Identity Provider (IdP). This might be more complex, than implementing Gmail 2.0 OAuth access.

by (300k points)
...