Yash
Yash

Reputation: 51

Gmail Authentication for sending mail

The user will enter Gmail account id and password in my page and that will be authenticated by google. I require password since I want to send Email using Gmail SMTP protocol.

I can use google developer user Authentication but still, I need the password for sending emails.

What should I do?

Upvotes: 1

Views: 1131

Answers (1)

Linda Lawton - DaImTo
Linda Lawton - DaImTo

Reputation: 116868

Google does not allow for Login and password authentication any longer. This is called client login. If you want there login and password just store that and don't bother authenticating it you will be able to access the GMAIL SMTP servers using that.

Alternative would be to use Oauth2 and to use the Gmail API instead of going though the SMTP server. Note: Using Oauth2 to authenticate the user you will not get their password.

Upvotes: 1

Related Questions