On Sun, Jul 24, 2022 at 03:11:06PM -0400, Wietse Venema wrote:

> Durga Prasad Malyala:
> > Hello all,
> > I am using https://gitlab.com/openstrike/ratelimit-policyd to do
> > ratelimting of high volume senders. The software is good but I want to
> > ratelimit/quota sending only to external domains whereas mails to same
> > domain need to be unlimited/unrestricted.
> > When receiving the mail the software gets recipient attribute/value -
> > only if there is single recipient. If there is more than one recipient
> 
> You will have to move your check_policy_service call to the
> smtpd_recipient_restrictions. Then, Postfix will send one recipient
> per RCPT TO command.
> 

You can *also* run it during smtpd_data_restrictions, at which point
you'll have accumulated the complete message envelope, and can flush
the state for the current SMTP transaction after making any final
go/no-go decision on the message as a whole.

-- 
    Viktor.

Reply via email to