How to disable sasl auth on port 25

port 25 is for smtp communication between MTAs. It should not have SASL auth enabled on this port. In postfix, we have to changes two files to implement this.

The first, in main.cf, comment out this line:

smtpd_sasl_auth_enable = yes

Just comment it out, the default value for this option is “no”.

The second, in master.cf, updates these two lines:

submission inet n       -       y       -       -       smtpd
  -o smtpd_sasl_auth_enable=yes

smtps     inet  n       -       y       -       -       smtpd
  -o smtpd_sasl_auth_enable=yes

The first line “submission” is for port 587. The second line “smtps” is for port 465. If you were not using port 465 (SMTPs), then the second line can be ignored.

Now restart postfix and it should work.

Comment