Skip to content
  • Contact us: +34 944 58 06 58
  • Plesk Partner Program
  • Plesk Lifecycle Policy
  • Blog
  • Contact us
  • Plesk 360
  • Contact us: +34 944 58 06 58
  • Plesk Partner Program
  • Plesk Lifecycle Policy
  • Blog
  • Contact us
  • Plesk 360
  • Solutions
    By Role
    • Developers
    • Content Managers
    • Digital Agencies
    • IT Admins
    • Web Hosters
    • Hyperscalers
    • Developers
    • Content Managers
    • Digital Agencies
    • IT Admins
    • Web Hosters
    • Hyperscalers
    By Edition
    • Web Admin Edition
    • Web Pro Edition
    • Web Host Edition
    • Business & Collaboration
    • Plesk WP Edition
    • Web Admin Edition
    • Web Pro Edition
    • Web Host Edition
    • Business & Collaboration
    • Plesk WP Edition
    By Cloud
    • Amazon Web Services
    • Microsoft Azure
    • Alibaba Cloud
    • GCP Marketplace
    • Vultr
    • DigitalOcean
    • Linode
    • UpCloud
    • Amazon Web Services
    • Microsoft Azure
    • Alibaba Cloud
    • GCP Marketplace
    • Vultr
    • DigitalOcean
    • Linode
    • UpCloud
    Partner Program
    Exclusive discounts, benefits and exposure to take your business to the next level
    Become a partner
    • By Role
      • Developers
      • Content Managers
      • Digital Agencies
      • IT Admins
      • Web Hosters
      • Hyperscalers
    • By Edition
      • Web Admin Edition
      • Web Pro Edition
      • Web Host Edition
      • Business & Collaboration
      • WP Edition
    • By Cloud
      • Amazon Web Services
      • Microsoft Azure
      • Alibaba Cloud
      • GCP Marketplace
      • Vultr
      • DigitalOcean
      • Linode
      • UpCloud
    • Partner Program
      • Partner Program
  • Product
    Explore Features
    • Everyone
    • Admins & Web Hosters
    • Developers
    • Designers & Agencies
    • Plesk Features
    • Everyone
    • Admins & Web Hosters
    • Developers
    • Designers & Agencies
    • Plesk Features
    Key Topics
    • SocialBee
    • WP Toolkit
    • Sitejet Builder
    • SEO Toolkit
    • Joomla! Toolkit
    • Plesk Premium Email
    • Plesk Email Security
    • SocialBee
    • WP Toolkit
    • Sitejet Builder
    • SEO Toolkit
    • Joomla! Toolkit
    • Plesk Premium Email
    • Plesk Email Security
    Feature Packs
    • Business & Collaboration
    • WP Pack
    • Hosting Pack
    • Power Pack
    • Language Pack
    • Business & Collaboration
    • WP Pack
    • Hosting Pack
    • Power Pack
    • Language Pack
    Featured Extension
    SocialBee
    • Explore Features
      • Everyone
      • Admins & Web Hosters
      • Developers
      • Designers & Agencies
      • Plesk Features
    • Key Topics
      • SocialBee
      • WP Toolkit
      • Sitejet Builder for Plesk
      • SEO Toolkit
      • Plesk Premium Email
      • Plesk Email Security
    • Feature Packs
      • Business & Collaboration
      • WP Pack
      • Hosting Pack
      • Power Pack
      • Language Pack
    • Featured Extension
      • Extension
  • Pricing
  • Extensions
  • Help Center
  • More
    • Careers
    • Events
    • Plesk University
  • FREE TRIAL
  • Solutions
    • By Role
      • Developers
      • Content Managers
      • Digital Agencies
      • IT Admins
      • Web Hosters
      • Hyperscalers
    • By Edition
      • Web Admin Edition
      • Web Pro Edition
      • Web Host Edition
      • Business & Collaboration
      • WP Edition
    • By Cloud
      • Amazon Web Services
      • Microsoft Azure
      • Alibaba Cloud
      • GCP Marketplace
      • Vultr
      • DigitalOcean
      • Linode
      • UpCloud
    • Partner Program
      • Partner Program
  • Product
    • Explore Features
      • Everyone
      • Admins & Web Hosters
      • Developers
      • Designers & Agencies
      • Plesk Features
    • Key Topics
      • SocialBee
      • WP Toolkit
      • Sitejet Builder
      • SEO Toolkit
      • Joomla! Toolkit
      • Plesk Premium Email
      • Plesk Email Security
    • Feature Packs
      • Business & Collaboration
      • WP Pack
      • Hosting Pack
      • Power Pack
      • Language Pack
    • Featured Extension
      • SocialBee
  • Pricing
  • Extensions
  • Help center
  • More
    • Careers
    • Events
    • Plesk University
    • Blog
    • Plesk Partner Program
    • Contact Us
  • FREE TRIAL
  • Solutions
    • By Role
      • Developers
      • Content Managers
      • Digital Agencies
      • IT Admins
      • Web Hosters
      • Hyperscalers
    • By Edition
      • Web Admin Edition
      • Web Pro Edition
      • Web Host Edition
      • Business & Collaboration
      • WP Edition
    • By Cloud
      • Amazon Web Services
      • Microsoft Azure
      • Alibaba Cloud
      • GCP Marketplace
      • Vultr
      • DigitalOcean
      • Linode
      • UpCloud
    • Partner Program
      • Partner Program
  • Product
    • Explore Features
      • Everyone
      • Admins & Web Hosters
      • Developers
      • Designers & Agencies
      • Plesk Features
    • Key Topics
      • SocialBee
      • WP Toolkit
      • Sitejet Builder
      • SEO Toolkit
      • Joomla! Toolkit
      • Plesk Premium Email
      • Plesk Email Security
    • Feature Packs
      • Business & Collaboration
      • WP Pack
      • Hosting Pack
      • Power Pack
      • Language Pack
    • Featured Extension
      • SocialBee
  • Pricing
  • Extensions
  • Help center
  • More
    • Careers
    • Events
    • Plesk University
    • Blog
    • Plesk Partner Program
    • Contact Us
  • FREE TRIAL

New Kolab Release 2: Plesk Premium Email Anti-spam Integration

  • By Elvis Plesky
  • March 13, 2019
  • Partners, Plesk news and announcements, Product and technology
2
Minutes

Using the Plesk Premium Email extension, your users’ ability to make the system learn about spam and ham greatly improves. This article outlines the functionality of the anti-spam integration of Plesk Premium Email using Dovecot, SpamAssassin and its Bayes algorithms.

A Plesk installation normally uses Dovecot, Postfix, SpamAssassin and Roundcube to provide your users with a complete mail stack. There are regular tests shipped with SpamAssassin. And of course, they detect spam and mark it as such – or even move the spam out of the user’s inbox.

But what happens when it can’t detect the spam? What if we incorrectly identify the mail as spam? How do your users let the system know what’s what?

How Plesk Premium Email anti-spam integration works

Users usually recognize a message as spam, press “Mark as Junk” or “Trash” buttons, and remove it from their inbox. Naturally, we want to prevent similar messages from cluttering inboxes again and again. Therefore, we could learn from the messages marked as spam or ham.

Can we learn from users’ interactions?

Yes! Because Plesk Premium Email creates the necessary feedback loop. Dovecot works in such a way that when a mail is moved in to or out of the Spam folder, the system learns whether the message is spam or ham. If you want to learn more about this, check the low-level technology documentation here.

Here’s the main outline of anti-spam integration

When a user recognizes a message as Spam, they press the “Mark as Junk” button. This can happen in Thunderbird, Roundcube, or anywhere else for that matter. Effectively, the message is moved from whichever folder it was, into the Spam folder.

When this change happens, Dovecot gets a trigger to respond by executing a system-wide Sieve script. This Sieve script in turn pipes the message through the SpamAssassin sa-learn utility. The same applies in the opposite scenario – if a user recognizes a message in the Spam folder as not actually spam. Because moving the message out of the spam folder will also ultimately trigger sa-learn.

Anti-spam integration: Installation instructions

We implemented this functionality in the Plesk Premium Email extension for v. 16.6 and up. But the extension itself can’t install the SpamAssassin component. You need manual intervention from a Plesk system administrator.

See Anti-Spam in Plesk Premium Email

Either ensure you install the SpamAssassin component before updating the extension. Or else, update the extension, then install the SpamAssassin component. Next, execute the following command-line. Because it will reconfigure domains and mailboxes with the Plesk Premium Email permission:

# /usr/local/psa/admin/bin/php \
-dauto_prepend_file=sdk.php \
'/usr/local/psa/admin/plib/modules/kolab/scripts/spamassassin.php'

Installing or removing SpamAssassin Component using Command Line

# /usr/local/psa/admin/sbin/autoinstaller add --components spamassassin

To remove SpamAssassin, albeit not recommended;

# /usr/local/psa/admin/sbin/autoinstaller remove --components spamassassin

Follow it up with disabling integration in the Plesk Premium Email extension;

# /usr/local/psa/admin/bin/php \
-dauto_prepend_file=sdk.php \
'/usr/local/psa/admin/plib/modules/kolab/scripts/spamassassin.php'

For more information about this integration, read our full documentation here.

What do you think of Kolab’s Anti-Spam integration using SpamAssassin and Dovecot? Let us know below.

arrow icon - Plesk
Tweet
Share
Share
Email
0 Shares
Picture of Elvis Plesky

Elvis Plesky

Our fun and curious team mascot's always plugged into the latest trends. He's here to share his knowledge and help you solve your tech problems.

One comment

  1. Peter
    Peter
    Apr 29, 2019 / 2:10 pm # Link Reply

    Spamassassin itself moves spam, that was already recognized as such, to the Spam folder. That is for the user to be able to check, whether there was a false positive. Does Kolab learn these messages, already tagged as Spam, again? That would confuse and fragment every bayes db out there.

Add a CommentCancel Reply

Your email address will not be published. Required fields are marked *

More results...

Generic filters
Exact matches only
Search in title
Search in content
Search in excerpt

GET LATEST NEWS AND TIPS

  • Yes, please, I agree to receiving my personal Plesk Newsletter! WebPros International GmbH and other WebPros group companies may store and process the data I provide for the purpose of delivering the newsletter according to the WebPros Privacy Policy. In order to tailor its offerings to me, Plesk may further use additional information like usage and behavior data (Profiling). I can unsubscribe from the newsletter at any time by sending an email to [email protected] or use the unsubscribe link in any of the newsletters.

  • This field is hidden when viewing the form
  • This field is hidden when viewing the form
  • This field is hidden when viewing the form
  • This field is hidden when viewing the form
  • This field is hidden when viewing the form
  • This field is hidden when viewing the form

Related Posts

Get Your Hands on Plesk Extensions and Toolkits This ‘HoliDeals’ Season (Part 1)

Read More »

How Modern Secure and Self-Hosted Messaging has Become a Cornerstone for Teams Worldwide

Read More »

Key Reasons Why You Should Upgrade Your Email Security Today

Read More »

Knowledge Base

SpamAssassin Spam Filter – (Plesk for Linux) Defining the Maximum Mail Size for SpamAssassin

Read More »

SpamAssassin Spam Filter – Configuring Black and White Lists

Read More »

Available Licensing Models

Read More »

Watchdog (System Monitoring) Component

Read More »

Restoring Mail Configuration

Read More »

Industry
Partners

industry-partner_ALIBABA
industry-partner_GOOGLEPARTNER
industry-partner_MICROSOFT
industry-partner_REDHAT-r2
industry-partner_ALIBABA
industry-partner_AUTOMATTIC
industry-partner_AWS
industry-partner_DIGITALOCEAN
industry-partner_SCALEWAY
Follow us:
Facebook Twitter Linkedin Youtube Github

COMPANY

About Plesk
Our Brand
Legal
Careers
Impressum

PRODUCT

Pricing 
Extensions
What’s new

KNOWLEDGE BASE

Documentation
Help Center
Migrate to Plesk
Contact Us
Hosting Wiki
Preview releases

PROGRAMS

Contributor Program NEW
Partner Program
Affiliate ProgramNEW

COMMUNITY

Blog
Forums 
Plesk University

First defaul

Company

About Plesk
Our Brand
Legal
Careers
Impressum

PRODUCT

Pricing 
Extensions
What’s new

KNOWLEDGE BASE​

Documentation
Help Center
Migrate to Plesk
Contact Us
Hosting Wiki
Preview releases

PROGRAMS​

Contributor Program NEW
Partner Program
Affiliate ProgramNEW

COMMUNITY​

Blog
Forums
Plesk University

Follow us:
Facebook Twitter Linkedin Youtube Github

© 2025 WebPros International GmbH. All rights reserved. Plesk and the Plesk logo are trademarks of WebPros International GmbH.

Managed with love with Plesk WP Toolkit