[Vmail-discuss] Courier
Jose de Paula Eufrasio Junior
jjunior at pib.com.br
16 Apr 2003 13:12:20 -0300
--=-wMZBV/1ohtl5MMiWuhMS
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
On Wed, 2003-04-16 at 04:24, Chris Lightfoot wrote:
> On Tue, Apr 15, 2003 at 09:40:02PM -0400, Lane Vance wrote:
> > Unfortunately, the archive stops on March 5. Does anyone have the rest=
of
> > the posts archived anywhere? Can the archive be brought up to date?
>=20
> well, it is now -- your post was the first after 5th
> March.
I did courier working with vmail... A little modified vmail database
table structure, but it worked.
Here's the struct:
__________________BEGIN STRUCT_______________________
# Host: localhost
# Generation Time: Apr 16, 2003 at 01:04 PM
# Server version: 3.23.48
# Database : `virtualemail`
# --------------------------------------------------------
#
# Table structure for table `domain`
#
CREATE TABLE domain (
domain_name varchar(255) NOT NULL default '',
unix_user varchar(255) default NULL,
password_hash varchar(255) default NULL,
path varchar(255) default NULL,
max_popbox int(11) default NULL,
uid int(10) unsigned NOT NULL default '65534',
gid int(10) unsigned NOT NULL default '65534',
PRIMARY KEY (domain_name)
) TYPE=3DMyISAM;
# --------------------------------------------------------
#
# Table structure for table `domain_alias`
#
CREATE TABLE domain_alias (
domain_name varchar(255) NOT NULL default '',
alias varchar(255) NOT NULL default '',
PRIMARY KEY (alias)
) TYPE=3DMyISAM;
# --------------------------------------------------------
#
# Table structure for table `forwarder`
#
CREATE TABLE forwarder (
domain_name varchar(255) NOT NULL default '',
local_part varchar(255) NOT NULL default '',
remote_name varchar(255) NOT NULL default '',
PRIMARY KEY (domain_name(16),local_part(32))
) TYPE=3DMyISAM;
# --------------------------------------------------------
#
# Table structure for table `popbox`
#
CREATE TABLE popbox (
domain_name varchar(255) NOT NULL default '',
local_part varchar(255) NOT NULL default '',
password_hash varchar(255) default NULL,
mbox_name varchar(255) default NULL,
spamassassin tinyint(1) NOT NULL default '0',
imap_quota varchar(255) NOT NULL default '',
clearpw varchar(128) NOT NULL default '',
PRIMARY KEY (domain_name(16),local_part(32))
) TYPE=3DMyISAM;
# --------------------------------------------------------
#
# Table structure for table `relayhosts`
#
CREATE TABLE relayhosts (
hostname varchar(255) NOT NULL default ''
) TYPE=3DMyISAM;
# --------------------------------------------------------
#
# Table structure for table `web_session`
#
CREATE TABLE web_session (
domain_name varchar(255) NOT NULL default '',
session_id varchar(32) default NULL,
expires int(11) default NULL,
PRIMARY KEY (domain_name)
) TYPE=3DMyISAM;
_________END STRUC__________
And you need to compile courier with the authdaemon with authmysql
authenticator support, and edit the authmysqlrc in the (prefix)/etc to
use a custom SQL query using the option "MYSQL_SELECT_CLAUSE". Here's
mine:
_________BEGIN CONFIG SNIP_________________
MYSQL_SELECT_CLAUSE SELECT popbox.local_part, \
TRIM('{crypt}' FROM popbox.password_hash), \
domain.gid, \
domain.uid, \
popbox.clearpw, \
TRIM(TRAILING 'Maildir' FROM CONCAT(domain.path,
'/', popbox.mbox_name)), \
CONCAT(domain.path, '/', popbox.mbox_name), \
popbox.imap_quota, \
'' \
FROM popbox, domain \
WHERE popbox.local_part =3D '$(local_part)' \
AND popbox.domain_name =3D '$(domain)' \
AND popbox.domain_name =3D domain.domain_name
__________END CONFIG SNIP____________
This is necessary because the SQL query that comes as an example in the
courier authmysqlrc config doesn't work with vmail as advertised. The
only thing that you need to configure in this file is the connection
settings (user/pass/host) and the name of the database (virtualemail, in
this case).
[]s
Junior
>=20
> --=20
> The cost of living hasn't affected its popularity (anonymous)
>=20
> _______________________________________________
> vmail-discuss mailing list
> vmail-discuss@lists.beasts.org
> http://lists.beasts.org/mailman/listinfo/vmail-discuss
--=20
Jos=E9 de Paula Eufr=E1sio J=FAnior
Analista de Sistema | CPD
ProInternet do Brasil
--=-wMZBV/1ohtl5MMiWuhMS
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: This is a digitally signed message part
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org
iD8DBQA+nYDkuux+hAffZfsRAl4ZAJ4/jnCWcbcgIUre0ViCQ2DGOH/neACaAmgA
Ij9KoOyU8DRV4sIKOE9G6QE=
=v30X
-----END PGP SIGNATURE-----
--=-wMZBV/1ohtl5MMiWuhMS--