Hello, I'm trying to run policyd on centos 6 with postfix.
I would like to limit the number of email sent per hour based on ip of
address sender.
I've enabled only default policy, in quota list I've have created this entry
MaxMsgSent      
Link to policy:Default  
Track:SenderIP:83.216.185.74/32         
Period:3600     
Verdict:REJECT  
Data    1       
Stop processing here:yes        
Comment                 
Disabled:no     

In quota limits I've create this entry 

Type    MessageCount    
Counter Limit   1       
Comment                 
Disabled        no


In postfix main.cf I've had these lines 
====================================================================
smtpd_sender_restrictions =
        reject_non_fqdn_sender,
        reject_non_fqdn_recipient,
        reject_unknown_recipient_domain,
        permit_mynetworks,
        check_policy_service inet:127.0.0.1:10031,
        reject_unauth_destination,
        reject_unauth_pipelining,
        reject_unknown_sender_domain,
        reject_non_fqdn_hostname,
        reject_invalid_hostname,
        reject_rbl_client zen.spamhaus.org,
        permit

smtpd_end_of_data_restrictions = check_policy_service inet:127.0.0.1:10031
====================================================================

But it seems it does not do anything

Here the cbpolicyd.log
============================================================================
===================
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE: Process Backgrounded
[2013/02/26-18:48:11 - 7928] [CBPOLICYD] NOTICE: Policyd v2 / Cluebringer -
v2.1.x-201211111115
[2013/02/26-18:48:11 - 7928] [CBPOLICYD] NOTICE: Initializing system
modules.
[2013/02/26-18:48:11 - 7928] [CBPOLICYD] NOTICE: System modules initialized.
[2013/02/26-18:48:11 - 7928] [CBPOLICYD] NOTICE: Module load started...
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE:   => AccessControl: enabled
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE:   => Accounting: enabled
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE:   => Amavis: disabled
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE:   => CheckHelo: enabled
[2013/02/26-18:48:11 - 7928] [CBPOLICYD] WARNING: Error loading plugin
modules/CheckSPF (Can't locate Mail/SPF.pm in @INC (@INC contains:
/usr/local/lib/cbpolicyd-2.1 /usr/lib/cbpolicyd-2.1 /usr/lib64/cbpolicyd-2.1
awitpt /usr/local/lib64/perl5 /usr/local/share/perl5
/usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5
/usr/share/perl5 .) at /usr/lib64/cbpolicyd-2.1/cbp/modules/CheckSPF.pm line
30.
BEGIN failed--compilation aborted at
/usr/lib64/cbpolicyd-2.1/cbp/modules/CheckSPF.pm line 30.
Compilation failed in require at (eval 24) line 2.
BEGIN failed--compilation aborted at (eval 24) line 2.
)
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE:   => Greylisting: enabled
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE:   => Quotas: enabled
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE:   => Protocol(Postfix): enabled
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE:   => Protocol(Bizanga): enabled
[2013/02/26-18:48:11 - 7928] [CBPOLICYD] NOTICE: Module load done.
[2013/02/26-18:48:11 - 7928] [CBPOLICYD] NOTICE: Session tracking is
ENABLED.
[2013/02/26-18:48:11 - 7928] [CBPOLICYD] DEBUG: Opening syslog, destination
= 'native', facility = 'mail'.
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE: 2013/02/26-18:48:11 cbp (type
Net::Server::PreFork) starting! pid(7928)
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE: Binding to TCP port 10031 on
host *
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE: Setting gid to "500 500"
[2013/02/26-18:48:11 - 7928] [CORE] NOTICE: Setting uid to "500"
[2013/02/26-18:48:11 - 7928] [CORE] INFO: Setting up serialization via flock
[2013/02/26-18:48:11 - 7928] [CORE] INFO: Beginning prefork (4 processes)
[2013/02/26-18:48:11 - 7928] [CORE] INFO: Starting "4" children
[2013/02/26-18:48:11 - 7930] [CORE] DEBUG: Child Preforked (7930)
[2013/02/26-18:48:11 - 7928] [CORE] DEBUG: Parent ready for children.
[2013/02/26-18:48:11 - 7930] [CBPOLICYD] DEBUG: Starting up caching engine
[2013/02/26-18:48:11 - 7933] [CORE] DEBUG: Child Preforked (7933)
[2013/02/26-18:48:11 - 7933] [CBPOLICYD] DEBUG: Starting up caching engine
[2013/02/26-18:48:11 - 7932] [CORE] DEBUG: Child Preforked (7932)
[2013/02/26-18:48:11 - 7932] [CBPOLICYD] DEBUG: Starting up caching engine
[2013/02/26-18:48:11 - 7931] [CORE] DEBUG: Child Preforked (7931)
[2013/02/26-18:48:11 - 7931] [CBPOLICYD] DEBUG: Starting up caching engine
============================================================================
===================

Any help will be veri appreciate.

Ps. Sorry for my worst english



Dr. Marcello Anderlini
[email protected]
---------------------------------------------
Database Informatica S.r.l.
Microsoft Certified Partner
Tel.  +39059775070
Fax. +39059779545
http://www.database.it 
http://www.facebook.com/DatabaseInformatica




_______________________________________________
Users mailing list
[email protected]
http://lists.policyd.org/mailman/listinfo/users_lists.policyd.org

Reply via email to