postal icon indicating copy to clipboard operation
postal copied to clipboard

Unable to send email via SMTP

Open dhiraj-r opened this issue 5 years ago • 11 comments

Hi, I am unable to send emails via SMTP from external app. Apart from that everything else working fine. I am able to connect over web API and send emails. Also emails are going through postal web ui. Basically, the error I am getting is "Failed to authenticate on SMTP server with username "swhsv-mail" using 2 possible authenticators"

Port 25 is open for both outgoing and incoming traffic.

Thanks

dhiraj-r avatar Apr 04 '21 07:04 dhiraj-r

I am able to connect over web API and send emails.

Have you created a separate SMTP credential for use with SMTP?

willpower232 avatar Apr 05 '21 16:04 willpower232

Yes, I did. In fact, when I tested Postal with smpter.net it works flawlessly, but not working with EMA like Mailwizz.

dhiraj-r avatar Apr 05 '21 16:04 dhiraj-r

Ah good find. Have you tested with a secure connection from smtper.net?

It is possible that you need to specify what kind of authentication Mailwizz is using. You can see precise details by clicking on this link on the Credentials page

image

willpower232 avatar Apr 05 '21 16:04 willpower232

Secure connection from smtper.net is not working. I did the test with precise details. Basically, in Mailwizz it's failing to authenticate in the first place. I also couldn't see anything in the log s for Mailwizz or perhaps I have been looking at the wrong place.

dhiraj-r avatar Apr 05 '21 17:04 dhiraj-r

If you're able to have a look at smtp_server.log you should see what, if any, messages were sent from smtper.net and Mailwizz. There may be other messages from people poking around for port 25 so don't be disheartened at the first failure you see!

willpower232 avatar Apr 05 '21 17:04 willpower232

Yes, I could see people poking around. They were so many I am unable to locate relevant logs.

dhiraj-r avatar Apr 05 '21 17:04 dhiraj-r

did you set tls_enabled: true and fill out the certificates in the config file?

willpower232 avatar Apr 06 '21 08:04 willpower232

Yes, I did. I also installed Let's Encrypt certificate.

dhiraj-r avatar Apr 06 '21 11:04 dhiraj-r

Capture Though Postal says it support AUTH CRAM-MD5 PLAIN LOGIN but when CRAM-MD5 is tried, it says access denied and accept LOGIN. Do you think that would be the case with MailWizz or other SMTP software.

dhiraj-r avatar Apr 06 '21 13:04 dhiraj-r

Decoding your attempt at CRAM-MD5 it looks like you didn't specify the username as swdlv/swdlv (or whatever made the response didn't include some of the username). AUTH PLAIN is simpler in this case because Postal does not verify the username.

willpower232 avatar Apr 06 '21 16:04 willpower232

Yes, you are right. I also realized this. Thank you very much for your prompt reply.

dhiraj-r avatar Apr 06 '21 16:04 dhiraj-r