0

I have setup a mail server with ubuntu, postfix, dovecot and mysql.

Tryng to send mail from the web interface mail goes out without any inconvenience. Trying with an email client from my laptop (using internet) I cannot. I get this error:

Feb 13 11:44:48 mail postfix/submission/smtpd[13066]: warning: unknown smtpd restriction: "permit_sasl_autenticated"

and following line is:

Feb 13 11:44:48 mail postfix/submission/smtpd[13066]: NOQUEUE: reject: RCPT from unknown[37.176.162.9]: 451 4.3.5 Server configuration error; from= to= proto=ESMTP helo=<[192.168.0.100]>

This second line is my message being rejected by the server.

I checked on /etc/postfix/main.cf and my TLS config is the following:

# TLS parameters
#smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem
#smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key
#smtpd_use_tls=yes
#smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
#smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache

smtpd_tls_cert_file=/etc/dovecot/cert.pem smtpd_tls_key_file=/etc/dovecot/private/cert.pem smtpd_use_tls=yes smtpd_tls_auth_only = yes

#Enabling SMTP for authenticated users, adn handing off autentication to Dovecot smtpd_sasl_type = dovecot smtpd_sasl_path = private/auth smtpd_sasl_auth_enable = yes

smtpd_recipient_restrictions =
        permit_sasl_authenticated,
        permit_mynetworks,
        reject_unauth_destination

# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.

smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination

As you can see there is not a permit_sasl_autenticated anywhere (and there is not in the whole file).

What is going on? CAn you help me to solve this?

EDIT - added a more complete section of my log:

Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: warning: hostname 217-221-73-77-static.albacom.net does not resolve to address 217.221.73.77: Name or service not known
Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: connect from unknown[217.221.73.77]
Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: disconnect from unknown[217.221.73.77]
Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: warning: hostname 217-221-73-77-static.albacom.net does not resolve to address 217.221.73.77: Name or service not known
Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: connect from unknown[217.221.73.77]
Feb 13 11:27:23 mail postfix/trivial-rewrite[12501]: warning: do not list domain montglane.it in BOTH mydestination and virtual_mailbox_domains
Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: warning: unknown smtpd restriction: "permit_sasl_autenticated"
Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: NOQUEUE: reject: RCPT from unknown[217.221.73.77]: 451 4.3.5 Server configuration error; from=<lelio@montglane.it> to=<lelio.faieta@gmail.c$
Feb 13 11:27:23 mail postfix/cleanup[12503]: D9AF313ED0D: message-id=<20170213102723.D9AF313ED0D@mail.montglane.it>
Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: disconnect from unknown[217.221.73.77]
Feb 13 11:27:23 mail postfix/oqmgr[3096]: D9AF313ED0D: from=<double-bounce@mail.montglane.it>, size=1329, nrcpt=1 (queue active)
Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: warning: hostname 217-221-73-77-static.albacom.net does not resolve to address 217.221.73.77: Name or service not known
Feb 13 11:27:23 mail postfix/submission/smtpd[12499]: connect from unknown[217.221.73.77]
Feb 13 11:26:49 mail dovecot: message repeated 3 times: [ auth: Warning: auth client 0 disconnected with 1 pending requests: EOF]
Feb 13 11:27:23 mail dovecot: lmtp(12507): Connect from local
Feb 13 11:27:24 mail dovecot: lmtp(12507, postmaster@liveslowsailfast.com): eXI0OAuKoVjbMAAAiLNN4A: msgid=<20170213102723.D9AF313ED0D@mail.montglane.it>: saved mail to INBOX
Feb 13 11:27:24 mail dovecot: lmtp(12507): Disconnect from local: Successful quit
Feb 13 11:27:24 mail postfix/lmtp[12506]: D9AF313ED0D: to=<postmaster@liveslowsailfast.com>, orig_to=<postmaster>, relay=mail.montglane.it[private/dovecot-lmtp], delay=0.15, delays=0.04/0.01/0.$
Feb 13 11:27:24 mail postfix/oqmgr[3096]: D9AF313ED0D: removed
Feb 13 11:27:24 mail postfix/submission/smtpd[12499]: warning: unknown smtpd restriction: "permit_sasl_autenticated"
Feb 13 11:27:24 mail postfix/submission/smtpd[12499]: NOQUEUE: reject: RCPT from unknown[217.221.73.77]: 451 4.3.5 Server configuration error; from=<lelio@montglane.it> to=<lelio.faieta@gmail.c$
Feb 13 11:27:24 mail postfix/cleanup[12503]: 2A96D13ED0D: message-id=<20170213102724.2A96D13ED0D@mail.montglane.it>
Feb 13 11:27:24 mail postfix/oqmgr[3096]: 2A96D13ED0D: from=<double-bounce@mail.montglane.it>, size=1329, nrcpt=1 (queue active)
Feb 13 11:27:24 mail postfix/submission/smtpd[12499]: disconnect from unknown[217.221.73.77]
Feb 13 11:27:24 mail dovecot: lmtp(12507): Connect from local
Feb 13 11:27:24 mail dovecot: lmtp(12507, postmaster@liveslowsailfast.com): fXI0OAuKoVjbMAAAiLNN4A: msgid=<20170213102724.2A96D13ED0D@mail.montglane.it>: saved mail to INBOX
Feb 13 11:27:24 mail postfix/lmtp[12506]: 2A96D13ED0D: to=<postmaster@liveslowsailfast.com>, orig_to=<postmaster>, relay=mail.montglane.it[private/dovecot-lmtp], delay=0.09, delays=0.02/0/0/0.0$
Feb 13 11:27:24 mail dovecot: lmtp(12507): Disconnect from local: Successful quit
Feb 13 11:27:24 mail postfix/oqmgr[3096]: 2A96D13ED0D: removed
  • You didn't post enough from the /var/log/mail.log to clearly identify the problem. At least 10 lines would be helpful. – L. D. James Feb 13 '17 at 11:28
  • thanks, @L.D.James I have added a more complete screenshot of my log. – Lelio Faieta Feb 13 '17 at 11:35
1

Add your authentication method to your /etc/master.cf file. Look for an entry similar to this:

#
# Postfix master process configuration file.  For details on the format
# of the file, see the master(5) manual page (command: "man 5 master").
#
# Do not forget to execute "postfix reload" after editing this file.
#
# ==========================================================================
# service type  private unpriv  chroot  wakeup  maxproc command + args
#               (yes)   (yes)   (yes)   (never) (100)
# ==========================================================================
smtp      inet  n       -       -       -       -       smtpd
-o content_filter=spamassassin
#smtp      inet  n       -       -       -       1       postscreen
#smtpd     pass  -       -       -       -       -       smtpd
#dnsblog   unix  -       -       -       -       0       dnsblog
#tlsproxy  unix  -       -       -       -       0       tlsproxy
submission inet n       -       -       -       -       smtpd
  -o syslog_name=postfix/submission
  -o smtpd_tls_security_level=encrypt
  -o smtpd_sasl_auth_enable=yes
  -o smtpd_client_restrictions=permit_sasl_authenticated,reject
#  -o milter_macro_daemon_name=ORIGINATING
#  -o syslog_name=postfix/smtps
#  -o smtpd_tls_wrappermode=yes
#  -o smtpd_sasl_auth_enable=yes
#  -o smtpd_client_restrictions=permit_sasl_authenticated,reject
#  -o milter_macro_daemon_name=ORIGINATING

After making changes to your Postfix configuration be sure to restart the service.

  • thanks! It works. That is where I had the typo about authenticate written as autenticated. That solved the issue. – Lelio Faieta Feb 13 '17 at 12:12
  • Great! Have a nice day! – L. D. James Feb 13 '17 at 12:13
  • I have this: # -o smtpd_client_restrictions=$mua_client_restrictions – Salim Ibrogimov Feb 16 '18 at 6:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.