Mail Server: Difference between revisions

From Objectif Client Inc
Jump to navigation Jump to search
Line 30: Line 30:
<syntaxhighlight lang="bash">apt-get install postfix</syntaxhighlight>
<syntaxhighlight lang="bash">apt-get install postfix</syntaxhighlight>
=== Configuration ===
=== Configuration ===
# main.cf
# /etc/postfix/main.cf
<syntaxhighlight lang="bash">mailbox_transport = cyrus</syntaxhighlight>
<syntaxhighlight lang="bash">mailbox_transport = cyrus</syntaxhighlight>


# master.cf
# /etc/postfix/master.cf
<syntaxhighlight lang="bash">
<syntaxhighlight lang="bash">
# The Cyrus deliver program has changed incompatibly, multiple times.
# The Cyrus deliver program has changed incompatibly, multiple times.

Revision as of 03:35, 1 June 2016

Cyrus

Installation

Install Cyrus Package

apt-get install cyrus-admin cyrus-clients cyrus-common cyrus-doc cyrus-imapd cyrus-nntpd cyrus-pop3d cyrus-sasl2-doc libcyrus-imap-perl

Install Sasl auth

apt-get install libauthen-sasl-perl libgsasl7 libsasl2-2 libsasl2-modules libsasl2-modules-db sasl2-bin

Validate / Adjust the configuration

/etc/default/saslauthd

START=yes
##Postfix Rooted
OPTIONS="-c -m /var/spool/postfix/var/run/saslauthd"

/etc/imapd.conf

admins: cyrus
sasl_mech_list: PLAIN LOGIN
defaultdomain: objclt.com
sasl_pwcheck_method: saslauthd
tls_cert_file: /etc/ssl/certs/ssl-cert-snakeoil.pem
tls_key_file: /etc/ssl/private/ssl-cert-snakeoil.key

Postfix

Web site PostFix

Installation

apt-get install postfix

Configuration

  1. /etc/postfix/main.cf
mailbox_transport = cyrus
  1. /etc/postfix/master.cf
# The Cyrus deliver program has changed incompatibly, multiple times.
cyrus     unix  -   n   n   -   -   pipe
  flags=R user=cyrus argv=/usr/sbin/cyrdeliver -e -m "${extension}" ${user}
mailbox_transport = lmtp:unix:/var/run/lmtp

lmtp      unix  -       -       n       -       -       lmtp
adduser postfix mail

saslpasswd2 -c cyrus

Spamassassin

Web site SpamAssassin

Installation

apt-get install spamassassin

Open DKIM

Web site Open DKIM

Installation

<syntaxhighlight lang="bash"apt-get install opendkim</syntaxhighlight>

Setup

For each domain:

  • Create folder
    mkdir /etc/opendkim/keys/domain_name 
  • Update configuration file /etc/opendkim/KeyTable
  • Generate Key
    opendkim-genkey -s mail -d domain_name
  • Change Owner
    chown opendkim: /etc/opendkim/KeyTable/domaine_name/mail.private
  • Copy the key (mail.txt) into the dns record.

Unbound

Web site Unbound

Not tested yet