Enjoy Slackware 15.0!
Welcome to the Slackware Documentation Project
Trace:
<!-- Add your text below. We strongly advise to start with a Headline (see button bar above). --> ====== Adding Sieve and ManageSieve support to dovecot ====== ===== Installing the Software ===== Assuming you have set up Dovecot and Postfix as per [[howtos:network_services:postfix_dovecot_mysql|Creating a Virtual Mail Server with Postfix, Dovecot and MySQL]] you may want some server-side filtering, and vacation response capabilities. This can be done using the sieve filter language, and edited by your virtual mail users using managesieve. There is a slackbuild for dovecot that provides the sieve and managesieve functionality called [[http://slackbuilds.org/repository/14.1/network/dovecot-pigeonhole/?search=pigeonhole|pigeonhole]]. <note important>You must use the version of pigeonhole designed for the version of dovecot you are using as the abi changes from version to version.</note> Once you have installed pigeonhole using the slackbuild, for example, using [[https://github.com/sbopkg/sbopkg/releases/download/0.37.0/sbopkg-0.37.0-noarch-1_cng.tgz|sbopkg]] you can then configure it. ===== Configuring Pigeonhole ===== We will use a basic configuration, which can be expanded later if needed. copy the following 3 files from /usr/doc/dovecot-2.your.version/example-config/conf.d/ to /etc/dovecot/conf.d 20-managesieve.conf 90-sieve.conf 20-lmtp.conf Edit /etc/dovecot/conf.d/20-managesieve.conf and uncomment the protocols line, service managesieve-login line, the inet_listener and port lines, and the two close braces lines. this will leave you with the following uncommented lines in the file <code>protocols = $protocols sieve service managesieve-login { inet_listener sieve { port = 4190 } } protocol sieve { }</code> that is managesieve enabled. now to configure sieve itself. Edit /etc/dovecot/conf.d/90-sieve.conf in the plugin section make the sieve line read <code>sieve=file:/var/vmail/vhosts/%d/%n/sieve/scripts;active=/var/vmail/vhosts/%d/%n/sieve/.dovecot.sieve</code> this specifies where the user sieve scripts will be stored. (We do not use the default location of the virtual users email folder, as it is not recommended [[http://wiki2.dovecot.org/Pigeonhole/ManageSieve/Configuration|see]], as it shows up as a directory in email clients.) we also might as well configure an error log file for each user's scripts, so after that line, add a new line <code>sieve_user_log = file:/var/vmail/vhosts/%d/%n/sieve/sieve_error.log</code> Now edit /etc/dovecot/conf.d/20-lmtp.conf and uncomment the mail_plugins line in the protocol lmtp section and modify it to read <code>mail_plugins = $mail_plugins sieve</code> ===== Open the firewall for ManageSieve ===== that is it for basic installation, although if you were following [[howtos:network_services:postfix_dovecot_mysql|Creating a Virtual Mail Server with Postfix, Dovecot and MySQL]] you will also need to add port 4190 to the firewall with something like <code>iptables -A INPUT -p tcp --dport 4190 -m state --state NEW -j ACCEPT</code> You may also want to restart dovecot to make sure it sees your newly added plugins <code>/etc/rc.d/rc.dovecot restart</code> ===== Configuring Thunderbird for Sieve ===== ManageSieve as a tool to allow (virtual) users to create their own filters is not much use without a client. Fortunately there is one available for mozilla thunderbird. Unfortunately, the one available on the mozilla addons/extentions site does not work with any current version of thunderbird. Fortunately, to cut a long story short, the author has a more recent version which does work. It can be downloaded [[https://github.com/thsmi/sieve/blob/master/nightly/0.2.3/sieve-0.2.3h.xpi?raw=true|here]] and should newer versions come out, they should be available from the [[https://github.com/thsmi/sieve/blob/master/nightly/|nightly]] folder on the project's github site. Download this file to your computer, and manually install it into thunderbird. Once this is installed, select the sieve-enabled mail account in thunderbird, then select tools - sieve message filters. Allow autodetect, and approve the certificate warning message (assuming you chose self-certified certificate in the howto). Now you can create sieve filters, which will act on your mail at the server. The plugin has some help for syntax and keywords, and there are plenty of examples on the internet for different tasks. ====== Sources ====== <!-- If you are copying information from another source, then specify that source --> <!-- * Original source: [[http://some.website.org/some/page.html]] --> <!-- Authors are allowed to give credit to themselves! --> * Originally written by [[wiki:user:tim | User tim]] <!-- * Contributions by [[wiki:user:yyy | User Y]] --> <!-- Please do not modify anything below, except adding new tags.--> <!-- You must remove the tag-word "template" below before saving your new page --> {{tag>howtos email postfix dovecot mysql ssl sieve}}
Article
Discussion
Show pagesource
Old revisions
PDF export
Log In
Navigation
Main Page
Project Charter
Site News
Staff
Table of Contents
Search
Toolbox
What links here
Recent Changes
Media Manager
Site index
Printable version
Permanent link
Cite this article
In Other Languages
SlackDocs
Request an account
Dokuwiki Manual
Dokuwiki Syntax
SlackDocs Style Guide
Authoring Guidelines
Translation Guide
Slackware Links
Slackware.com
Slackware-Current Change Log
Package Browser
Slackware Mirrors
@LinuxQuestions.org
QR Code