Spamassassin: Difference between revisions

From Open-Xchange
(Created page with "= Introduction = This OXpedia article describes, how to connect the [http://spamassassin.apache.org/ SpamAssassin] system with Open-Xchange. It allows accessing your SpamAssa...")
 
No edit summary
Line 87: Line 87:
$ changeuser -A oxadmin -P admin_password -c 1 -u username --gui_spam_filter_capabilities_enabled true  
$ changeuser -A oxadmin -P admin_password -c 1 -u username --gui_spam_filter_capabilities_enabled true  
</pre>
</pre>
[[Category: Administrator]]
[[Category: OX6]]
[[Category: AppSuite]]
[[Category: Spamhandling]]

Revision as of 13:42, 21 August 2014

Introduction

This OXpedia article describes, how to connect the SpamAssassin system with Open-Xchange. It allows accessing your SpamAssassin settings from within Open-Xchange and use the spam- and ham Learning mechanisms of SpamAssassin directly from within the Open-Xchange UI.

Prerequisites

Sieve

You will need to install and configure the SIEVE Mail filter program on your mail server. Since we will not cover the installation part of Sieve in this article, therefore we will only tell the important configuration settings needed for Sieve to get integrated with Open-Xchange.

SpamAssassin

You will also need to install and configure the SpamAssassin. Since we will not cover the installation part of SpamAssassin in this article, therefore we will only tell the important configuration settings needed for Sieve to get integrated with Open-Xchange.

Installation

We will need to install the following two packages on the Open-Xchange server.


Install on OX v6.22.x

Debian GNU/Linux 11.0

Add the following entry to /etc/apt/sources.list.d/open-xchange.list if not already present:

deb https://software.open-xchange.com/products/6.22/backend/DebianBullseye/ /
# if you have a valid maintenance subscription, please uncomment the 
# following and add the ldb account data to the url so that the most recent
# packages get installed
# deb https://[CUSTOMERID:PASSWORD]@software.open-xchange.com/products/6.22/backend/updates/DebianBullseye/ /

and run

$ apt-get update
$ apt-get install open-xchange-spamhandler-spamassassin open-xchange-mailfilter

Debian GNU/Linux 12.0

Add the following entry to /etc/apt/sources.list.d/open-xchange.list if not already present:

deb https://software.open-xchange.com/products/6.22/backend/DebianBookworm/ /
# if you have a valid maintenance subscription, please uncomment the 
# following and add the ldb account data to the url so that the most recent
# packages get installed
# deb https://[CUSTOMERID:PASSWORD]@software.open-xchange.com/products/6.22/backend/updates/DebianBookworm/ /

and run

$ apt-get update
$ apt-get install open-xchange-spamhandler-spamassassin open-xchange-mailfilter


Install on OX App Suite

Debian GNU/Linux 11.0

Add the following entry to /etc/apt/sources.list.d/open-xchange.list if not already present:

deb https://software.open-xchange.com/products/appsuite/stable/backend/DebianBullseye/ /
# if you have a valid maintenance subscription, please uncomment the 
# following and add the ldb account data to the url so that the most recent
# packages get installed
# deb https://[CUSTOMERID:PASSWORD]@software.open-xchange.com/products/appsuite/stable/backend/updates/DebianBullseye/ /

and run

$ apt-get update
$ apt-get install open-xchange-spamhandler-spamassassin open-xchange-mailfilter

Debian GNU/Linux 12.0

Add the following entry to /etc/apt/sources.list.d/open-xchange.list if not already present:

deb https://software.open-xchange.com/products/appsuite/stable/backend/DebianBookworm/ /
# if you have a valid maintenance subscription, please uncomment the 
# following and add the ldb account data to the url so that the most recent
# packages get installed
# deb https://[CUSTOMERID:PASSWORD]@software.open-xchange.com/products/appsuite/stable/backend/updates/DebianBookworm/ /

and run

$ apt-get update
$ apt-get install open-xchange-spamhandler-spamassassin open-xchange-mailfilter


Configuration

For Sieve

As we have now already installed the needed package open-xchange-mailfilter. Now we need to configure the setting the configuration file so that Open-Xchange can be integrated with Sieve.

Open the following file in your Linux editor.

$ /opt/open-xchange/etc/mailfilter.properties

Edit the following lines

SIEVE_SERVER=localhost //your sieve server name, localhost is default for single machine
 
SIEVE_PORT=4190 //this port should be same as the one you define during the installation of Sieve.

Save the changes and reboot Open-Xchange service.

$ /etc/init.d/open-xchange restart

Verify that the mailfilter bundle has started properly and should be ACTIVE.

$ listbundles | grep filter 

bundlename: com.openexchange.mail.filter status: ACTIVE

For SpamAssassin

Open the following file in Linux editor

$ /opt/open-xchange/etc/imap.properties

Edit the following parameter to:

com.openexchange.imap.spamHandler=SpamAssassin 

Once done then reboot the OX Service

$ /etc/init.d/open-xchange restart

Make sure that SpamAssassin port is also open Port 783 (by default). Also verify that spam bundles loaded successfully.

$ /opt/open-xchange/sbin/listbundles | grep spam 
bundlename: com.openexchange.spamhandler.spamassassin status: ACTIVE 


Finally, we will need to enable the GUI Capabilities for SPAM. To do this we have to run the following command for e.g.

$ changeuser -A oxadmin -P admin_password -c 1 -u username --gui_spam_filter_capabilities_enabled true