On 23/01/2015 17:14, Noel Jones wrote:
On 1/23/2015 7:42 AM, Chris Robinson wrote:
Hi all,
Is there any way to use the postfix policy delegation mechanism to
filter the transport:destination differently for individual
recipients in a multi-recipient message?
The FILTER action is a per-message (not per-recipient) action. If
multiple FILTER actions trigger on a message, the last one wins.
Maybe you could use a policy service to send big mail to a second
postfix instance on the same box. That second postfix instance could
then deliver mail either locally or directly without a FILTER
action. Maybe your best choices are to either deliver all mail
directly or live with the smaller limit.
Maybe postfix isn't the right tool. Some other MTA may offer the
detailed delivery controls you're looking for. I don't know; you'll
need to research that yourself.
-- Noel Jones
Hi Noel,
The SMTPD_POLICY_README states:
"The policy server replies with any action that is allowed in a Postfix SMTPD access(5)
<http://www.postfix.org/access.5.html> table".
In access(5) under OTHER ACTIONS it states:
"FILTER transport:destination
...
Note 3: the purpose of the FILTER command is to override message routing... Other options are using the recipient-dependent
transport_maps..."
So instead of a postfwd rule with an action "FILTER smtp:" is it not possible to create a special transport map for this rule that
treats local and external recipients differently, and have the action "FILTER ????" where ???? is some way of telling postfix to
consult that transport map. If ???? must be a transport:destination then maybe ???? could be an entry in master.cf that was a
unique version of smtp which had a postconf parameter to point it at the special transport map.
Is something like this feasible?
Chris Robinson