zimbra 8.6 cbpolicyd : A Practical Example
Introduction
The cbpolicyd
service in Zimbra is a powerful policy daemon that helps administrators control email traffic, implement rate limiting, and prevent spam. By setting up cbpolicyd
with customized policies, you can enhance the security and efficiency of your email system. In this article, we will provide an example configuration for cbpolicyd
in Zimbra 8.6, guiding you through the process to help you optimize your email server's performance and security.
Links to below you maybe likes:
zimbra 8.6 cbpolicyd
How to use cbpolicyd to configure 120 message from sender in last 30s.
in order configure in zimbra cbpolicyd
policies -->policy_members -->quotas -->quotas_limits
To create zimbra-example.sql file
BEGIN TRANSACTION;
INSERT INTO "policies" (ID,Name,Priority,Description) VALUES(6,'Example CBPolicyd Policies', 0, 'Example CBPolicyd Policies');
INSERT INTO "policy_members" (ID,PolicyID,Source,Destination) VALUES(10,6, 'user@domain', '!%internal_domains');
INSERT INTO "quotas" (ID,PolicyID,Name,Track,Period,Verdict,Data) VALUES (14,10, 'Sender:user@domain','Sender:user@domain', 30, 'REJECT', 'Rejected from CBPolicyd: Too many messages from sender in last 30s');
INSERT INTO "quotas_limits" (ID,QuotasID,Type,CounterLimit) VALUES(16,14, 'MessageCount', 120);
COMMIT;
To import zimbra-example.sql file into cbpolicyd.sqlitedb
su - zimbra
cd /opt/zimbra/data/cbpolicyd/db
sqlite3 /opt/zimbra/data/cbpolicyd/db/cbpolicyd.sqlitedb < zimbra-example.sql
zmmtactl restart
zmcbpolicydctl restart
To check rules zimbra cbpolicyd
su - zimbra
cd /opt/zimbra/data/cbpolicyd/db
sqlite3 cbpolicyd.sqlitedb
sqlite> select * from policies;
sqlite> select * from policy_members;
sqlite> select * from quotas;
sqlite> select * from quotas_limits;
How to update "quotas_limits" 60 messages count. we are create zimbra-update.sql as bellow
BEGIN TRANSACTION;
delete from quotas_limits where ID=16;
INSERT INTO "quotas_limits" (ID,QuotasID,Type,CounterLimit) VALUES(16,14, 'MessageCount', 60);
COMMIT;
After, import databases and cbpolicyd restart.
sqlite3 /opt/zimbra/data/cbpolicyd/db/cbpolicyd.sqlitedb < zimbra-update.sql
zmcbpolicydctl restart
To check log of zimbra cbpolicyd
tailf /opt/zimbra/log/cbpolicyd.log | egrep ERROR
tailf /opt/zimbra/log/cbpolicyd.log
Conclusion
Implementing cbpolicyd
in Zimbra 8.6 can significantly improve your email system's security and efficiency. By following the example configuration provided in this guide, you can effectively manage email traffic and prevent abuse. We hope this article has been helpful and encourage you to explore our website for more tips and best practices in managing your Zimbra email system. thank you for reading the huuphan.com page!
Comments
Post a Comment