diff --git a/Dockerfile b/Dockerfile index a362a424..2471e43a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -103,7 +103,7 @@ RUN \ chmod 755 -R /usr/lib/dovecot/sieve-pipe /usr/lib/dovecot/sieve-filter /usr/lib/dovecot/sieve-global # ––––––––––––––––––––––––––––––––––––––––––––––– -# ––– LDAP & Spamassassin's Cron –––––––––––––––– +# ––– LDAP & SpamAssassin's Cron –––––––––––––––– # ––––––––––––––––––––––––––––––––––––––––––––––– COPY target/dovecot/dovecot-ldap.conf.ext /etc/dovecot diff --git a/ENVIRONMENT.md b/ENVIRONMENT.md index f9d8d6ab..9fbfb885 100644 --- a/ENVIRONMENT.md +++ b/ENVIRONMENT.md @@ -281,14 +281,14 @@ Also note that by default the logs are lost when the container is recycled. To k Finally the logrotate interval **may** affect the period for generated reports. That is the case when the reports are triggered by log rotation. -#### Spamassassin +#### SpamAssassin ##### ENABLE_SPAMASSASSIN -- **0** => Spamassassin is disabled -- 1 => Spamassassin is enabled +- **0** => SpamAssassin is disabled +- 1 => SpamAssassin is enabled -**/!\\ Spam delivery:** when Spamassassin is enabled, messages marked as spam WILL NOT BE DELIVERED. +**/!\\ Spam delivery:** when SpamAssassin is enabled, messages marked as spam WILL NOT BE DELIVERED. Use `SPAMASSASSIN_SPAM_TO_INBOX=1` for receiving spam messages. ##### SPAMASSASSIN_SPAM_TO_INBOX @@ -307,29 +307,29 @@ Note: this setting needs `SPAMASSASSIN_SPAM_TO_INBOX=1` - **2.0** => add spam info headers if at, or above that level -Note: this spamassassin setting needs `ENABLE_SPAMASSASSIN=1` +Note: this SpamAssassin setting needs `ENABLE_SPAMASSASSIN=1` ##### SA_TAG2 - **6.31** => add 'spam detected' headers at that level -Note: this spamassassin setting needs `ENABLE_SPAMASSASSIN=1` +Note: this SpamAssassin setting needs `ENABLE_SPAMASSASSIN=1` ##### SA_KILL - **6.31** => triggers spam evasive actions -Note: this spamassassin setting needs `ENABLE_SPAMASSASSIN=1`. By default, the mailserver is configured to quarantine spam emails. If emails are quarantined, they are compressed and stored in a location dependent on the ONE_DIR setting above. If `ONE_DIR=1` the location is /var/mail-state/lib-amavis/virusmails/. If `ONE_DIR=0` it is /var/lib/amavis/virusmails/. These paths are inside the docker container. To inhibit this behaviour and deliver spam emails, set this to a very high value e.g. 100.0. +Note: this SpamAssassin setting needs `ENABLE_SPAMASSASSIN=1`. By default, the mailserver is configured to quarantine spam emails. If emails are quarantined, they are compressed and stored in a location dependent on the ONE_DIR setting above. If `ONE_DIR=1` the location is /var/mail-state/lib-amavis/virusmails/. If `ONE_DIR=0` it is /var/lib/amavis/virusmails/. These paths are inside the docker container. To inhibit this behaviour and deliver spam emails, set this to a very high value e.g. 100.0. ##### SA_SPAM_SUBJECT - **\*\*\*SPAM\*\*\*** => add tag to subject if spam detected -Note: this spamassassin setting needs `ENABLE_SPAMASSASSIN=1`. Add the spamassassin score to the subject line by inserting the keyword \_SCORE\_: **\*\*\*SPAM(\_SCORE\_)\*\*\***. +Note: this SpamAssassin setting needs `ENABLE_SPAMASSASSIN=1`. Add the SpamAssassin score to the subject line by inserting the keyword \_SCORE\_: **\*\*\*SPAM(\_SCORE\_)\*\*\***. ##### SA_SHORTCIRCUIT_BAYES_SPAM -- **1** => will activate spamassassin short circuiting for bayes spam detection. +- **1** => will activate SpamAssassin short circuiting for bayes spam detection. This will uncomment the respective line in ```/etc/spamassasin/local.cf``` @@ -337,7 +337,7 @@ Note: activate this only if you are confident in your bayes database for identif ##### SA_SHORTCIRCUIT_BAYES_HAM -- **1** => will activate spamassassin short circuiting for bayes ham detection +- **1** => will activate SpamAssassin short circuiting for bayes ham detection This will uncomment the respective line in ```/etc/spamassasin/local.cf``` diff --git a/README.md b/README.md index 330a23a1..0ce31474 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ A fullstack but simple mail server (SMTP, IMAP, LDAP, Antispam, Antivirus, etc.) - [Postfix](http://www.postfix.org) with SMTP or LDAP auth - [Dovecot](https://www.dovecot.org) for SASL, IMAP (or POP3), with LDAP Auth, Sieve and [quotas](https://docker-mailserver.github.io/docker-mailserver/edge/config/user-management/accounts#notes) - [Amavis](https://www.amavis.org/) -- [Spamassasin](http://spamassassin.apache.org/) supporting custom rules +- [SpamAssassin](http://spamassassin.apache.org/) supporting custom rules - [ClamAV](https://www.clamav.net/) with automatic updates - [OpenDKIM](http://www.opendkim.org) - [OpenDMARC](https://github.com/trusteddomainproject/OpenDMARC) diff --git a/docs/content/faq.md b/docs/content/faq.md index 256a6a55..b5e91d20 100644 --- a/docs/content/faq.md +++ b/docs/content/faq.md @@ -17,7 +17,7 @@ Mails are stored in `/var/mail/${domain}/${username}`. Since `v9.0.0` it is poss ### How to alter the running mailserver instance _without_ relaunching the container? -`docker-mailserver` aggregates multiple "sub-services", such as Postfix, Dovecot, Fail2ban, SpamAssasin, etc. In many cases, one may edit a sub-service's config and reload that very sub-service, without stopping and relaunching the whole mail server. +`docker-mailserver` aggregates multiple "sub-services", such as Postfix, Dovecot, Fail2ban, SpamAssassin, etc. In many cases, one may edit a sub-service's config and reload that very sub-service, without stopping and relaunching the whole mail server. In order to do so, you'll probably want to push your config updates to your server through a Docker volume, then restart the sub-service to apply your changes, using `supervisorctl`. For instance, after editing fail2ban's config: `supervisorctl restart fail2ban`. @@ -92,7 +92,7 @@ password: Please use `STARTTLS`. -### How can I manage my custom Spamassassin rules? +### How can I manage my custom SpamAssassin rules? Antispam rules are managed in `config/spamassassin-rules.cf`. @@ -124,9 +124,9 @@ warning: do not list domain example.com in BOTH mydestination and virtual_mailbo Plus of course mail delivery fails. -### Why are Spamassassin `x-headers` not inserted into my `sample.domain.com` subdomain emails? +### Why are SpamAssassin `x-headers` not inserted into my `sample.domain.com` subdomain emails? -In the default setup, amavis only applies Spamassassin x-headers into domains matching the template listed in the config file (`05-domain_id` in the amavis defaults). +In the default setup, amavis only applies SpamAssassin x-headers into domains matching the template listed in the config file (`05-domain_id` in the amavis defaults). The default setup `@local_domains_acl = ( ".$mydomain" );` does not match subdomains. To match subdomains, you can override the `@local_domains_acl` directive in the amavis user config file `50-user` with `@local_domains_maps = (".");` to match any sort of domain template. @@ -212,7 +212,7 @@ The following configuration works nicely: file: ./cron/sa-learn ``` -With the default settings, Spamassassin will require 200 mails trained for spam (for example with the method explained above) and 200 mails trained for ham (using the same command as above but using `--ham` and providing it with some ham mails). Until you provided these 200+200 mails, Spamassasin will not take the learned mails into account. For further reference, see the [Spamassassin Wiki](https://wiki.apache.org/spamassassin/BayesNotWorking). +With the default settings, SpamAssassin will require 200 mails trained for spam (for example with the method explained above) and 200 mails trained for ham (using the same command as above but using `--ham` and providing it with some ham mails). Until you provided these 200+200 mails, SpamAssassin will not take the learned mails into account. For further reference, see the [SpamAssassin Wiki](https://wiki.apache.org/spamassassin/BayesNotWorking). ### How can I configure a catch-all? @@ -248,7 +248,7 @@ SA_TAG2=3.75 SA_KILL=100000.0 ``` -- The very negative vaue in `SA_TAG` makes sure, that all emails have the Spamassasin headers included. +- The very negative vaue in `SA_TAG` makes sure, that all emails have the SpamAssassin headers included. - `SA_TAG2` is the actual threshold to set the YES/NO flag for spam detection. - `SA_KILL` needs to be very high, to make sure nothing is bounced at all (`SA_KILL` superseeds `SPAMASSASSIN_SPAM_TO_INBOX`) diff --git a/mailserver.env b/mailserver.env index 2981451c..c8103663 100644 --- a/mailserver.env +++ b/mailserver.env @@ -195,7 +195,7 @@ REPORT_INTERVAL=daily POSTFIX_INET_PROTOCOLS=all # ––––––––––––––––––––––––––––––––––––––––––––––– -# ––– Spamassassin Section –––––––––––––––––––––– +# ––– SpamAssassin Section –––––––––––––––––––––– # ––––––––––––––––––––––––––––––––––––––––––––––– ENABLE_SPAMASSASSIN=0 diff --git a/target/scripts/startup/fixes-stack.sh b/target/scripts/startup/fixes-stack.sh index 8ecd66b7..078ce816 100644 --- a/target/scripts/startup/fixes-stack.sh +++ b/target/scripts/startup/fixes-stack.sh @@ -50,6 +50,6 @@ function _fix_cleanup_clamav function _fix_cleanup_spamassassin { - _notify 'task' 'Cleaning up disabled spamassassin' + _notify 'task' 'Cleaning up disabled SpamAssassin' rm -f /etc/cron.daily/spamassassin } diff --git a/target/scripts/startup/setup-stack.sh b/target/scripts/startup/setup-stack.sh index e404c542..4482fc4d 100644 --- a/target/scripts/startup/setup-stack.sh +++ b/target/scripts/startup/setup-stack.sh @@ -1379,7 +1379,7 @@ function _setup_security_stack echo "# WARNING: this file is auto-generated." >"${DMS_AMAVIS_FILE}" echo "use strict;" >>"${DMS_AMAVIS_FILE}" - # Spamassassin + # SpamAssassin if [[ ${ENABLE_SPAMASSASSIN} -eq 0 ]] then _notify 'warn' "Spamassassin is disabled. You can enable it with 'ENABLE_SPAMASSASSIN=1'"