/[gentoo]/xml/htdocs/doc/en/virt-mail-howto.xml
Gentoo

Diff of /xml/htdocs/doc/en/virt-mail-howto.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.35 Revision 1.36
1<?xml version='1.0' encoding='UTF-8'?> 1<?xml version='1.0' encoding='UTF-8'?>
2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/virt-mail-howto.xml,v 1.35 2004/11/02 10:50:22 swift Exp $ --> 2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/virt-mail-howto.xml,v 1.36 2004/11/08 10:12:54 swift Exp $ -->
3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> 3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
4 4
5<guide link=" /doc/en/virt-mail-howto.xml" > 5<guide link=" /doc/en/virt-mail-howto.xml" >
6<title>Virtual Mailhosting System with Postfix Guide</title> 6<title>Virtual Mailhosting System with Postfix Guide</title>
7<author title="Author" > 7<author title="Author" >
8<mail link="antifa@gentoo.org" >Ken Nowack</mail> 8<mail link="antifa@gentoo.org" >Ken Nowack</mail>
9</author> 9</author>
10<author title="Author" > 10<author title="Author" >
11<mail link="ezra@revoltltd.org" >Ezra Gorman</mail> 11<mail link="ezra@revoltltd.org" >Ezra Gorman</mail>
12</author> 12</author>
13<author title="Editor"> 13<author title="Editor">
14<mail link="klasikahl@gentoo.org" >Zack Gilburd</mail> 14<mail link="klasikahl@gentoo.org" >Zack Gilburd</mail>
15</author> 15</author>
16<abstract>This document details how to create a virtual mailhosting system based upon postfix, mysql, courier-imap, and cyrus-sasl. </abstract> 16<abstract>This document details how to create a virtual mailhosting system based upon postfix, mysql, courier-imap, and cyrus-sasl. </abstract>
17<version>1.0.13</version> 17<version>1.0.14</version>
18<date>November 02, 2004</date> 18<date>November 08, 2004</date>
19<!-- 19<!--
20 20
21Contents 21Contents
22 22
23I. Introduction 23I. Introduction
24II. Postfix Basics 24II. Postfix Basics
25III. Courier-imap 25III. Courier-imap
26IV. Cyrus-sasl 26IV. Cyrus-sasl
27V. SSL Certificates for Postfix and Apache 27V. SSL Certificates for Postfix and Apache
28VI. Adding SSL and SASL support to Postfix 28VI. Adding SSL and SASL support to Postfix
29VII. MySQL 29VII. MySQL
30VIII. Apache and phpMyAdmin 30VIII. Apache and phpMyAdmin
31IX. The vmail user 31IX. The vmail user
32X. Configuring MySQL Authentication and vhosts 32X. Configuring MySQL Authentication and vhosts
33XI. Squirrelmail 33XI. Squirrelmail
121# <i>/etc/init.d/courier-imapd-ssl start</i> 121# <i>/etc/init.d/courier-imapd-ssl start</i>
122# <i>/etc/init.d/courier-pop3d start</i> 122# <i>/etc/init.d/courier-pop3d start</i>
123# <i>/etc/init.d/courier-pop3d-ssl start</i> 123# <i>/etc/init.d/courier-pop3d-ssl start</i>
124</pre> 124</pre>
125<p>Start up your favorite mail client and verify that all connections you've started work for receiving and sending mail. Now that the basics work, we're going to do a whole bunch of stuff at once to get the rest of the system running. Again, please verify that what we've installed already works before progressing.</p> 125<p>Start up your favorite mail client and verify that all connections you've started work for receiving and sending mail. Now that the basics work, we're going to do a whole bunch of stuff at once to get the rest of the system running. Again, please verify that what we've installed already works before progressing.</p>
126</body> 126</body>
127</section> 127</section>
128</chapter> 128</chapter>
129<chapter> 129<chapter>
130<title>Cyrus-sasl</title> 130<title>Cyrus-sasl</title>
131<section> 131<section>
132<body> 132<body>
133<p>Next we're going to install cyrus-sasl. Sasl is going to play the role of actually passing your auth variables to pam, which will in turn pass that information to mysql for authentication of smtp users. For this howto, we'll not even try to verify that sasl is working until mysql is set up and contains a test user. Which is fine since we'll be authenticating against mysql in the end anyway.</p> 133<p>Next we're going to install cyrus-sasl. Sasl is going to play the role of actually passing your auth variables to pam, which will in turn pass that information to mysql for authentication of smtp users. For this howto, we'll not even try to verify that sasl is working until mysql is set up and contains a test user. Which is fine since we'll be authenticating against mysql in the end anyway.</p>
134<note>Now for some reason, sasl will not play nicely with pam against the shadow file. I banged my head against this problem for, well, a long time. If anyone knows why sasl will not auth against the shadow file in its current gentoo incarnation, please <mail link="ken@kickasskungfu.com" >email me</mail> as I'd love to hear a solution to this.</note> 134<note>Now for some reason, sasl will not play nicely with pam against the shadow file. I banged my head against this problem for, well, a long time. If anyone knows why sasl will not auth against the shadow file in its current gentoo incarnation, please <mail link="ken@kickasskungfu.com" >email me</mail> as I'd love to hear a solution to this.</note>
135<pre caption="Configuring and installing the cyrus-sasl ebuild" > 135<pre caption="Configuring and installing the cyrus-sasl ebuild" >
136# <i>USE='-ldap -mysql' emerge cyrus-sasl</i>
137<codenote>We don't have ldap and we're not using sasl's mysql capabilities </codenote> 136<comment>(We don't have ldap and we're using sasl's mysql capabilities
138<codenote>so we need to turn them off for this build.</codenote> 137 so we need to set the appropriate USE flags, but only if your USE flags
138 doesn't already contain the mysql USE flag and not the ldap one)</comment>
139# <i>mkdir /etc/portage</i>
140# <i>echo "dev-libs/cyrus-sasl -ldap mysql" &gt;&gt; /etc/portage/package.use</i>
141# <i>emerge cyrus-sasl</i>
139</pre> 142</pre>
140<p>Next, edit <path>/etc/sasl2/smtpd.conf</path>.</p> 143<p>Next, edit <path>/etc/sasl2/smtpd.conf</path>.</p>
141<pre caption="Starting sasl" > 144<pre caption="Starting sasl" >
142# <i>nano -w /etc/sasl2/smtpd.conf</i> 145# <i>nano -w /etc/sasl2/smtpd.conf</i>
143pwcheck_method: auxprop 146pwcheck_method: auxprop
144auxprop_plugin: sql 147auxprop_plugin: sql
145sql_engine: mysql 148sql_engine: mysql
146sql_hostnames: localhost 149sql_hostnames: localhost
147sql_user: mailsql 150sql_user: mailsql
148sql_passwd: <comment>&lt;password&gt;</comment> 151sql_passwd: <comment>&lt;password&gt;</comment>
149sql_database: mailsql 152sql_database: mailsql
150sql_select: select clear from users where email = '%u@%r' 153sql_select: select clear from users where email = '%u@%r'
151mech_list: plain login 154mech_list: plain login
152pwcheck_method: saslauthd 155pwcheck_method: saslauthd
153mech_list: LOGIN PLAIN 156mech_list: LOGIN PLAIN

Legend:
Removed from v.1.35  
changed lines
  Added in v.1.36

  ViewVC Help
Powered by ViewVC 1.1.20