Discussion:
SMTP connection problems
(too old to reply)
p***@gmail.com
2018-12-03 06:30:53 UTC
Permalink
My SSL/TLS imap email server works fine except I cannot send mail via it's SMTPS 465 port. The email server is set up at VPS and my Thunderbird email client is located at my home.

Here is the /var/log/mail.log where I can clearly see there is some kind of protocol problem. Any idea what's wrong with the setup (ip addresses and the host names are not real) ?

Dec 3 06:17:26 site postfix/smtpd[5797]: connect from 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]
Dec 3 06:17:26 site postfix/smtpd[5797]: smtp_stream_setup: maxtime=300 enable_deadline=0
Dec 3 06:17:26 site postfix/smtpd[5797]: match_hostname: smtpd_client_event_limit_exceptions: 85-76-50-50-nat.elisa-mobile.fi ~? 85.76.50.50
Dec 3 06:17:26 site postfix/smtpd[5797]: match_hostaddr: smtpd_client_event_limit_exceptions: 85.76.50.50 ~? 85.76.50.50
Dec 3 06:17:26 site postfix/smtpd[5797]: > 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]: 220 site.com ESMTP Postfix (Debian/GNU)
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_create: SASL service=smtp, realm=(null)
Dec 3 06:17:26 site postfix/smtpd[5797]: name_mask: noanonymous
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_connect: Connecting
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_connect: auth reply: VERSION?1?1
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_connect: auth reply: MECH?PLAIN?plaintext
Dec 3 06:17:26 site postfix/smtpd[5797]: name_mask: plaintext
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_connect: auth reply: MECH?LOGIN?plaintext
Dec 3 06:17:26 site postfix/smtpd[5797]: name_mask: plaintext
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_connect: auth reply: SPID?5800
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_connect: auth reply: CUID?1
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_connect: auth reply: COOKIE?0018bc1a643935885b35cef25ed0c77c
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_connect: auth reply: DONE
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_mech_filter: keep mechanism: PLAIN
Dec 3 06:17:26 site postfix/smtpd[5797]: xsasl_dovecot_server_mech_filter: keep mechanism: LOGIN
Dec 3 06:17:26 site postfix/smtpd[5797]: watchdog_pat: 0x7f2866c38740
Dec 3 06:17:26 site postfix/smtpd[5797]: < 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]: ???
Dec 3 06:17:26 site postfix/smtpd[5797]: > 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]: 500 5.5.2 Error: bad UTF-8 syntax
Dec 3 06:17:26 site postfix/smtpd[5797]: watchdog_pat: 0x7f2866c38740
Dec 3 06:17:26 site postfix/smtpd[5797]: < 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]: ??????
Dec 3 06:17:26 site postfix/smtpd[5797]: > 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]: 500 5.5.2 Error: bad UTF-8 syntax
Dec 3 06:17:26 site postfix/smtpd[5797]: watchdog_pat: 0x7f2866c38740
Dec 3 06:17:26 site postfix/smtpd[5797]: < 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]: ?
Dec 3 06:17:26 site postfix/smtpd[5797]: > 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]: 500 5.5.2 Error: bad UTF-8 syntax
Dec 3 06:17:26 site postfix/smtpd[5797]: watchdog_pat: 0x7f2866c38740
Dec 3 06:17:26 site postfix/smtpd[5797]: < 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]:
Dec 3 06:17:26 site postfix/smtpd[5797]: > 85-76-50-50-nat.elisa-mobile.fi[85.76.50.50]: 500 5.5.2 Error: bad syntax
Jonathan N. Little
2018-12-04 15:43:18 UTC
Permalink
Post by p***@gmail.com
My SSL/TLS imap email server works fine except I cannot send mail via it's SMTPS 465 port. The email server is set up at VPS and my Thunderbird email client is located at my home.
Not sure if this will address your exact problem, however SMTPS 465 port
is not typically used but rather the submission port 587 for sending
mail. <http://www.postfix.org/SOHO_README.html>
--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
p***@gmail.com
2018-12-04 16:17:21 UTC
Permalink
Post by Jonathan N. Little
Not sure if this will address your exact problem, however SMTPS 465 port
is not typically used but rather the submission port 587 for sending
mail. <http://www.postfix.org/SOHO_README.html>
I found the problem in my /etc/postfix/master.cf configuration file. I had to enable the following lines:
-o smtpd_tls_wrappermode=yes
-o smtpd_sasl_auth_enable=yes
-o smtpd_relay_restrictions=permit_sasl_authenticated,reject

So it's now working without any problems.

Edit:
After reading more about the SMTP ports and the recommendations it seems the 587 port really is the one which should be used.
Continue reading on narkive:
Loading...