gmail stopped working for sending emails

For complex topics that regular users would not be interested in. For power users and database administrators.
Post Reply
User avatar
drtech
Posts: 1668
Joined: Wed Jun 20, 2007 8:44 am
Location: Springfield, MO
Contact:

gmail stopped working for sending emails

Post by drtech »

We have used password setup with gmail for sending out email for years, but it just stopped working, any ideas why? I didn't change any settings...it says SMTP server requires a secure connection....did something change with gmail or is on the OD end?


Error sending email
CodeBase.ODException
at OpenDentBusiness.Email.SendEmail.WireEmailUnsecure(BasicEmailAddress address, BasicEmailMessage emailMessage, NameValueCollection nameValueCollectionHeaders, AlternateView[] arrayAlternateViews) in C:\Users\drtec\source\git\opendental\OpenDentBusiness\Email\SendEmails.cs:line 38
at OpenDentBusiness.EmailMessages.SendEmailUnsecure(EmailMessage emailMessage, EmailAddress emailAddress, NameValueCollection nameValueCollectionHeaders, Boolean hasRetried, AlternateView[] alternateViewArray) in C:\Users\drtec\source\git\opendental\OpenDentBusiness\Data Interface\EmailMessages.cs:line 891
at OpenDentBusiness.EmailMessages.SendEmail(EmailMessage emailMessage, EmailAddress emailAddressSender, X509Certificate2 x509Certificate2Private, Boolean useDirect) in C:\Users\drtec\source\git\opendental\OpenDentBusiness\Data Interface\EmailMessages.cs:line 510
at OpenDental.FormEmailMessageEdit.butSend_Click(Object sender, EventArgs e) in C:\Users\drtec\source\git\opendental\OpenDental\Forms\FormEmailMessageEdit.cs:line 896
-------------------------------------------
Inner exception: The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.7.0 Authentication Required. For more information, go to
System.Net.Mail.SmtpException
at System.Net.Mail.MailCommand.CheckResponse(SmtpStatusCode statusCode, String response)
at System.Net.Mail.MailCommand.Send(SmtpConnection conn, Byte[] command, MailAddress from, Boolean allowUnicode)
at System.Net.Mail.SmtpTransport.SendMail(MailAddress sender, MailAddressCollection recipients, String deliveryNotify, Boolean allowUnicode, SmtpFailedRecipientException& exception)
at System.Net.Mail.SmtpClient.Send(MailMessage message)
at OpenDentBusiness.Email.SendEmail.WireEmailUnsecure(BasicEmailAddress address, BasicEmailMessage emailMessage, NameValueCollection nameValueCollectionHeaders, Int32 emailSendTimeoutMs, AlternateView[] arrayAlternateViews) in C:\Users\drtec\source\git\opendental\OpenDentBusiness\Email\SendEmails.cs:line 122
at OpenDentBusiness.Email.SendEmail.WireEmailUnsecure(BasicEmailAddress address, BasicEmailMessage emailMessage, NameValueCollection nameValueCollectionHeaders, AlternateView[] arrayAlternateViews) in C:\Users\drtec\source\git\opendental\OpenDentBusiness\Email\SendEmails.cs:line 31
David Fuchs
Dentist - Springfield, MO
Smile Dental http://www.887-smile.com
User avatar
drtech
Posts: 1668
Joined: Wed Jun 20, 2007 8:44 am
Location: Springfield, MO
Contact:

Re: gmail stopped working for sending emails

Post by drtech »

Grok saved the day: Looks like my app password was removed somehow in my google account. Since the normal password login isn't a possibility any more, as it isn't secure, this is the option that fixed it:


***************************************************************************
Alternative: Use an App Password (If OAuth Isn't Working)
If you prefer (or need) to stick with manual SMTP settings:

Enable 2-Step Verification on your Google account (if not already on): Go to myaccount.google.com > Security > 2-Step Verification.
Generate an App Password:
Go to myaccount.google.com > Security > App passwords (search for it if not visible).
Select "Mail" as the app and your device (or "Other" and name it "OpenDental").
Copy the 16-character password Google generates.

In OpenDental Email Address setup:
Username: Your full Gmail address.
Password: Paste the app password (not your regular Gmail password).
SMTP Server: smtp.gmail.com
Port: 587 (with STARTTLS) or 465 (implicit SSL)
Check Use SSL/TLS.

Save and test.

***************************************************************************
David Fuchs
Dentist - Springfield, MO
Smile Dental http://www.887-smile.com
Post Reply