John Allen: > Is there a way of negating a smtpd condition. > For example if I were to apply c "check_sender_access sql_lookup" under > submission in master.cf would it be possible to say something like > !check_check_acess ... under smtpd restrctions > > The idea being that if example.com is allowed access via submission they > are denied access via smtpd.
The Postfix design is not optimized for negation. You could use pipemap:{sql_lookup, map-that-replaces-permit-with-reject}, plus a static:reject map to provide the answer if there was none in the original map. check_something_access unionmap:{ pipemap:{ sql_lookup, map-that-replaces-permit-with-reject }, static:{reject and this is why} } Requires Postfix 3.0 or later. Wietse