Manuel Mely:
> Hi there,
> 
> I?m at the moment in the concept stage for the implementation of custom
> policies which will be attached to several postfix instances.
> 
> A brief description of what i have now:
> 
> I have three postgres tables: mail_filter, mail_filter_rule and
> mail_filter_action
> 
> a filter (mail_filter entry) can have one or many rules (mail_filter_rule
> entries) as well as actions (mail_filter_action entries)
> 
> For example,
> 
> Filter 1, could be something like, mail from: f...@bar.org and rcpt to:
> b...@foo.org and in this time frame 14:00-19:00 could be (and now come the
> actions in to play), "blocked"

There is prior art in postfwd (www.postfwd.org) for inspecting SMTP
and blocking commands.

> Filter 2, could be something like, mail from: domainX.com and rcpt to:
> b...@foo.org and in this time frame 10:00-13:00 could be "remove attachments
> of mime type Y and notify someone"

If you want to inspect/modify content in addition to inspecting
SMTP commands, then that may be better done with a Milter, as Postfix
intentionally no significant content modification primitives built-in.
Milter protocol implementations exist for many languages.

        Wietse

Reply via email to