
vulture at netvulture
Oct 5, 2009, 11:16 PM
Post #1 of 1
(452 views)
Permalink
|
|
Postfix smtp auth alias sending email FYI
|
|
The following is a view for MySQL that can be used with postfix to allow a user to authenticate as one user, but be able to send mail from on of the attached aliases. Aka, I authenticate as vulture [at] netvulture, but can send email as jfeally [at] netvulture With out this sender login map, you would be stuck with let the user send as anyone, or only as the user that authenticated. mysql: CREATE VIEW postfix_senders AS SELECT userid AS user, passwd as passwd, userid AS alias FROM dbmail_users UNION SELECT userid as user, passwd as passwd, alias as alias FROM dbmail_aliases JOIN dbmail_users ON (user_idnr=deliver_to); main.cf: smtpd_sender_restrictions = permit_mynetworks, check_helo_access hash:/etc/postfix/helo_access, reject_authenticated_sender_login_mismatch, permit_sasl_authenticated, reject_sender_login_mismatch, reject_unknown_sender_domain smtpd_sender_login_maps = mysql:/etc/postfix/dbmail_senders.cf postfix_senders.cf: user = dbmail password = dbmail dbname = dbmail hosts = a.b.c.d query = SELECT user FROM postfix_senders WHERE alias='%s' -- Scanned for viruses and dangerous content by MailScanner _______________________________________________ Dbmail-dev mailing list Dbmail-dev [at] dbmail http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail-dev
|