On 28/05/2012 19:47, Ricardo Oliveira wrote:
I'm using Policy 2.0.12 with Postfix 2.7.0 on Linux and I have a few
questions regarding Policies in general and also the Quotas and
AccessControl modules.
My objective is to control senders like this:
If the sender IP is allowed AND the sender domain is allowed -> Check
the quota: if in quota OK, else DEFER
Else REJECT
So I created a policy which is applied to two groups (one containing
the allowed IPs and one containing the allowed domains), and created
an AccessControl entry which applies to this policy.
This part works perfectly: if the user is not in the allowed IP group
or the sender domain is not in the domain group, the email is rejected.
The problem occurs when I apply the Quota rule.
The behavior I'm seeing is that when I apply the Quota rule to the
aforementioned policy (with the AccessControl enabled), it simply
ignores the quota and accepts all email.
Moreover, if I disable the AccessControl rule pointing to the policy,
the Quota starts being enforced, as it should have in the first place.
So I tried something else: defined two policies, one for Quota, with
priority 0 which checks for sender addresses and domains and another
one for AccessControl with priority 1 which defaults to REJECT and
matches any email. This also fails as the email is caught on the
second policy and promptly rejected.
From reading the policyd documentation, I had the impression this
shouldn't happen because rules were checked according to priority, and
I assumed it would stop processing as soon as it got a decision, but
it seems not to be the case.
Can anyone help me understand why this happens and the best way to do
this?
Could you enable full debugging in policyd and show us the logs, config
and database set up?
_______________________________________________
Users mailing list
[email protected]
http://lists.policyd.org/mailman/listinfo/users