I have just setup my debian mailserver using postfix, dovecot and SASL as explained in this excellent tutorial. I have used postfixadmin to setup a virtual list of aliases for sending user@domain.com to their email (for example, user@gmail.com). This works for receiving but for sending out with their new email I need to authenticate them. Question is, where does this authentication come from? Because they're aliases they do not have an account on the server! Can anyone help?


You need to do three things, create a file (or DB) with domain username:password style entries, postmap (or create a query that will find the info) that file, then tell postfix to use those entries when sending to servers who need them:

smtp_sasl_auth_enable = yes # you should have this already
smtp_sasl_password_maps = hash:/etc/postfix/smtp_sasl_passwd # this is the postmap variety smtp_sasl_password_maps = mysql:/etc/postfix/mysql_sasl_passwd # MySQL version

Read more Here

  • I have smtpd_sasl_auth_enable = yes, but not without the d! – ingh.am Mar 18 '13 at 15:12
  • Yeah, just create a table, and follow the model of other tables and queries.. I'm trying to find out what postfix wants in terms of responses. – NickW Mar 18 '13 at 15:15
  • Cool thanks. I'm probably going to use the postmap just because our Mysql server is not localhost. Trying not to complicate things! – ingh.am Mar 18 '13 at 15:19
  • There's something for you to follow here: anothersysadmin.wordpress.com/2009/02/06/… in the comments :) – NickW Mar 18 '13 at 15:22
  • BTW, the link in the comments was a mysql statement, what I wrote in the answer will work fine for the postmap command. – NickW Mar 18 '13 at 15:24

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.