From: Wietse Venema on 14 Feb 2010 14:17 Geert Hendrickx: > On Sun, Feb 14, 2010 at 07:42:58PM +0100, Stefan Palme wrote: > > > > > check_recipient_access hash:/etc/postfix/recipients > > > check_recipient_access pcre:/etc/postfix/recipients_default > > > > > > // REJECT rejected for testing purposes > > > > Thanks for the hint. But the content of "recipients_default" must also be > > stored in LDAP (because some admin with LDAP access privileges will > > define the default behaviour), so I can not use regular expression > > lookups, but only the lookups as defined by the access(5) syntax. > > > > If all recipients are in the same domain, you can specify a catch-all > address with the domain-default action: > > > user1(a)example.com action1 > user2(a)example.com action2 > @example.com REJECT foobar Minor correction: user1(a)example.com action1 user2(a)example.com action2 example.com REJECT foobar (the @domain notation is used mainly in address rewriting maps). Wietse
From: mouss on 14 Feb 2010 17:44 Stefan Palme a �crit : >> check_recipient_access hash:/etc/postfix/recipients >> check_recipient_access pcre:/etc/postfix/recipients_default >> >> // REJECT rejected for testing purposes > > Thanks for the hint. But the content of "recipients_default" must > also be stored in LDAP (because some admin with LDAP access privileges > will define the default behaviour), so I can not use regular expression > lookups, but only the lookups as defined by the access(5) syntax. > if it's in ldap, then do it in ldap instead of pcre. make your ldap query return the "default behaviour" whatever the key is.
From: Stefan Palme on 14 Feb 2010 18:15 On Sun, 2010-02-14 at 23:44 +0100, mouss wrote: > Stefan Palme a �crit : > >> check_recipient_access hash:/etc/postfix/recipients > >> check_recipient_access pcre:/etc/postfix/recipients_default > >> > >> // REJECT rejected for testing purposes > > > > Thanks for the hint. But the content of "recipients_default" must > > also be stored in LDAP (because some admin with LDAP access privileges > > will define the default behaviour), so I can not use regular expression > > lookups, but only the lookups as defined by the access(5) syntax. > > > > if it's in ldap, then do it in ldap instead of pcre. make your ldap > query return the "default behaviour" whatever the key is. Something like this? check_recipient_access ldap:/etc/postfix/recipients.cf check_recipient_access ldap:/etc/postfix/recipients_default.cf with /etc/postfix/recipients_default.cf: search_base = ou=postfix,dc=example,dc=com query_filter = (&(objectClass=postfixConfiguration)(cn=DEFAULT_BEHAVIOUR)) Nice idea... Have to take a look at this. Thanks a lot! -stefan-
From: Stan Hoeppner on 14 Feb 2010 21:29 Wietse Venema put forth on 2/14/2010 12:52 PM: > regexp:/etc/postfix/recipients.pcre ^^^^^^ ^^^^ Wietse is this a typo or am I about to learn something new about regexp/pcre interchangeability/compatibility in Postfix? I'm assuming in the example above that the .pcre file actually contains pcre syntax, not regexp syntax. -- Stan
From: Ralf Hildebrandt on 15 Feb 2010 03:32 * Stan Hoeppner <stan(a)hardwarefreak.com>: > Wietse Venema put forth on 2/14/2010 12:52 PM: > > > regexp:/etc/postfix/recipients.pcre > > ^^^^^^ ^^^^ > > Wietse is this a typo or am I about to learn something new about regexp/pcre > interchangeability/compatibility in Postfix? I'm assuming in the example above > that the .pcre file actually contains pcre syntax, not regexp syntax. It's a naming issue only. One would OF COURSE name pcre files .pcre and regexp files .regexp (or similar). -- Ralf Hildebrandt Geschäftsbereich IT | Abteilung Netzwerk Charité - Universitätsmedizin Berlin Campus Benjamin Franklin Hindenburgdamm 30 | D-12203 Berlin Tel. +49 30 450 570 155 | Fax: +49 30 450 570 962 ralf.hildebrandt(a)charite.de | http://www.charite.de
First
|
Prev
|
Next
|
Last
Pages: 1 2 3 Prev: Restrictions on localhost Next: how to deny mail from specific domain |