1

I have to limit the number the emails sent from 1 sender to 1 recipient doesn't matter of domain. For this purpose I to use postfwd.

id=RATE01 ; action=rate(sender/5/300/450 4.7.1 sorry, max 5 requests per 5 minutes)

This will limit senderA@ to send 5 emails for 5min totally for all recipients.

id=RATE02 ; action=rate(recipient/5/300/450 4.7.1 sorry, max 5 requests per 5 minutes)

This will limit recipientB@ to get 5 emails for 5min from all senders

The question is how I can define limitation based on sender to recipient. Something like senderA can send 5 email to every user on my domain.

Dave M
  • 4,494
  • 21
  • 30
  • 30

1 Answers1

0

Looks like I found some kind of solution but, not sure this is best

id=CLASS100; recipient=table:/etc/postfix/virtual/accounts_postfwd.cf; action=jump(CLASS101)
id=CLASS101; action=rate(sender/3/300/450 4.7.1 sorry, max 3 requests per 5 minutes for user $$sender)
id=CLASS199; action=DUNNO

accounts_postfwd.cf contain list of all my users

Please suggest if you have better idea how to realise this.