4

I have the following postfix configuration:

 smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated
 myhostname = d*****.net
 alias_maps = hash:/etc/aliases
 alias_database = hash:/etc/aliases
 virtual_alias_maps = hash:/etc/postfix/virtual
 mydestination = d*****.net, gitlab, localhost.localdomain, , localhost
 relayhost =
 mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128

And the following dovecot 10-auth.conf:

disable_plaintext_auth = no

this is my mail log:

 Jun 11 14:34:24 D***** postfix/master[13209]: warning: process /usr/lib     /postfix/smtpd pid 1025 exit status 1
 Jun 11 14:34:24 D****** postfix/master[13209]: warning: /usr/lib/postfix/smtpd: bad command startup -- throttling
 Jun 11 14:35:24 D****** postfix/smtpd[1132]: fatal: in parameter smtpd_relay_restrictions or smtpd_recipient_restrictions, specify at least one working instance of: reject_unauth_destination, defer_unauth_destination, reject, defer, defer_if_permit or check_relay_domains

All I'm trying to do is enable plain text username/password authorization for SMTP. Any suggestions how to accomplish this?

2 Answers 2

8

Postfix is asking what to do when it receives email for not your domain.

smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated reject_unauth_destination

That should work and it also keeps you from relaying mail for spammers.

4

As per the last line of the posted log, you need to change your smtpd_relay_restrictions configuration to include one of the following (personally, I would use reject to explicitly reject anything I don't permit):

  • reject_unauth_destination
  • defer_unauth_destination
  • reject
  • defer
  • defer_if_permit
  • check_relay_domains

The smtpd_relay_restrictions option (as with most of the restriction options within Postfix) reads much the same as an iptables firewall chain - the first rule to match the content wins, and the last in the chain is used if no others match, so you must have a "catch-all" option defined as the last option in the chain.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .