1

Topic: Bayes per User, per Domain, global

======== Required information ====
- iRedMail version: 0.9.2
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):
- Web server (Apache or Nginx):
- Linux/BSD distribution name and version:
- Related log if you're reporting an issue:
====

How does bayes in iRedMail work by default? Does it learn from Junk directory for each user? Does it feed a global database for all users? It's not working by default?

Is there a way to have a global, per domain and per user databases? I saw some instructions in your documentation how to configure bayes & MySql. That's not by default in iRedMail, right? Is there a better fine control with MySql?

I did a lot of reading but couldn't find final answers.


Thanks for your help.

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Bayes per User, per Domain, global

iRedMail doesn't have full bayes support. Let me explain:

*) iRedMail has below 2 settings in SA config file /etc/mail/spamassassin/local.cf:

use_bayes          1
bayes_auto_learn   1

So auto-learning is dependent on when SA want it to learn. You can follow this tutorial to see when SA auto-learn:
http://www.iredmail.org/docs/no.x-spam.headers.html

*) iRedMail doesn't enable Dovecot plugin `antispam` for auto-learning. this plugin will be triggered when user moves some mail from an imap folder to Junk folder (learn as spam. you can customize which folder is used to store Junk), OR, moves email out of Junk folder (learn as not spam).

*) iRedMail doesn't have any plugin for webmail (Roundcube or SOGo) to let user report spam.

3

Re: Bayes per User, per Domain, global

ZhangHuangbin wrote:

So auto-learning is dependent on when SA want it to learn.

I guess this is based on the amount of received emails? Can we say by default there is a global bayes database? Once a certaim amount of emails has been received SA takes bayes into account for scoring?

ZhangHuangbin wrote:

*) iRedMail doesn't enable Dovecot plugin `antispam` for auto-learning. this plugin will be triggered when user moves some mail from an imap folder to Junk folder (learn as spam. you can customize which folder is used to store Junk), OR, moves email out of Junk folder (learn as not spam).

*) iRedMail doesn't have any plugin for webmail (Roundcube or SOGo) to let user report spam.

These are two ways for user interaction? "Dovecot plugin 'antispam'" or "Roundcube PlugIn"? Another way would be cronjob with sa-learn, right?

Still my question: is it global, per domain or per user? I wish there would be something like global > domain > user.

4

Re: Bayes per User, per Domain, global

Peter wrote:

I guess this is based on the amount of received emails? Can we say by default there is a global bayes database? Once a certaim amount of emails has been received SA takes bayes into account for scoring?

I suggest checking SA official document.
SA has many rules, it will learn based on rules, and inserts mail headers about learning result.

Peter wrote:

These are two ways for user interaction? "Dovecot plugin 'antispam'" or "Roundcube PlugIn"? Another way would be cronjob with sa-learn, right?

*) Dovecot plugin 'antispam' is smarter, end users don't even know it exists. and i will integrate it in iRedMail in the future. But we don't have RHEL/CentOS RPM for this plugin.
*) Roundcube has third-party plugin "markasjunk2", it supports several ways for marking email as junk. e.g. call sa-learn immediately, or move to a imap folder (you can call sa-learn with cron job to scan this folder), or redirect email to a mailbox.

Peter wrote:

Still my question: is it global, per domain or per user? I wish there would be something like global > domain > user.

I think the answer is clear. There's a not-very-smart global setting, but no per-domain or per-user setting.