Hi,

        It's been more than 3 days now since I started configure courier-pop-ssl. 
Just for the record, I will tell you what OS I am running and what I am 
trying to accomplish.

        The OS is Debian Woody bf2.4. The install for courier-pop-ssl was as easy as 
possible using the apt-get utility in Debian. Then, I wanted to add mysql 
support, so I did:
> apt-get install courier-authmysql
So, everything in the install went just fine.

        Now, what I want to accomplish. I will need to deliver mail to at least 4 
different domains. All the MX records for those domains point to the server 
(which function as a web, ftp and mail server). The SMTP daemon is EXIM. I 
also do not want to create system users on my machine; so I am using 
courier-pop with mysql to create the needed users in the database. The only 
thing I do for the users in the database are the home directories (shown 
later in this message). Also, I would like to be able to have separate 
accounts, meaning that [EMAIL PROTECTED] does not have the same login 
info with [EMAIL PROTECTED]

        I guess that is all that I need for right now. I will not get into mail 
aliases and how to set them up from mysql. After 3 days of trying even if I 
get an e-mail via POP-SSL would be a good reason for celebration ;-)

        Below are the config files and also the error logs that I get when a user 
tried to retrieve its e-mail from the POP server:

Mysql Connection Log (at least we know that we're getting connected):
cat /var/log/mysql.log :
...
030610  7:42:29 12 Connect     [EMAIL PROTECTED] on
                                12 Init DB     mailserver
                                12 Query       SELECT id, crypt, clear, uid,
                                gid, home, maildir, quota, name FROM passwd
                                WHERE id = "andreim"

Mail log:
cat /var/log/mail.log (no authentication whatsoever, and we get a LOGIN 
FAILED):
...
Jun 10 08:03:31 server1m pop3d-ssl: Connection, ip=[::ffff:192.168.1.124]
Jun 10 08:03:36 server1m pop3d-ssl: LOGIN FAILED, ip=[::ffff:192.168.1.124]
Jun 10 08:03:36 server1m pop3d-ssl: Unexpected SSL connection shutdown.
Jun 10 08:03:36 server1m courierpop3login: Connection, 
ip=[::ffff:192.168.1.124]
Jun 10 08:03:41 server1m courierpop3login: LOGIN FAILED, 
ip=[::ffff:192.168.1.124]

File structure for:
/etc/courier/authmysqlrc :

MYSQL_SERVER            localhost
MYSQL_USERNAME          mailserver
MYSQL_PASSWORD          mypass***
MYSQL_SOCKET            /var/run/mysqld/mysqld.sock
MYSQL_PORT              3306
MYSQL_OPT               0
MYSQL_DATABASE          mailserver
MYSQL_USER_TABLE        passwd
MYSQL_LOGIN_FIELD       id
MYSQL_CRYPT_PWFIELD     crypt
MYSQL_CLEAR_PWFIELD     clear
MYSQL_UID_FIELD         uid
MYSQL_GID_FIELD         gid
MYSQL_HOME_FIELD        home
MYSQL_NAME_FIELD        name
MYSQL_MAILDIR_FIELD     maildir
MYSQL_QUOTA_FIELD       quota

Database Dump:

CREATE TABLE passwd (
  sid int(19) NOT NULL auto_increment,
  user varchar(128) NOT NULL default '',
  domain varchar(255) NOT NULL default '',
  id varchar(128) NOT NULL default '',
  crypt varchar(128) NOT NULL default '',
  clear varchar(128) NOT NULL default '',
  name varchar(128) NOT NULL default '',
  uid int(10) unsigned NOT NULL default '1100',
  gid int(10) unsigned NOT NULL default '1100',
  home varchar(255) NOT NULL default '/home/vmail',
  maildir varchar(255) default 'Maildir',
  quota varchar(255) NOT NULL default '',
  PRIMARY KEY  (sid),
  KEY id (id)
) TYPE=MyISAM;

INSERT INTO passwd VALUES (1, 'userone', 'domain.org', '
                                                        [EMAIL PROTECTED]', 
'c1BgdMkWkRUuA',
                                                        'mypassword', 'User Full 
Name', 1100,
                                                        1100, 
'/home/vmail/userone-domain-org',
                                                        'Maildir', '10');

Home Directory structure for userone:

drwxr-sr-x    3 nobody   staff        4096 2003-06-09 21:44 .
drwxr-sr-x    4 root     staff        4096 2003-06-09 21:44 ..
drwx--S---    5 nobody   staff        4096 2003-06-09 21:44 Maildir

Maildir Directory structure for userone:

drwx--S---    5 nobody   staff        4096 2003-06-09 21:44 .
drwxr-sr-x    3 nobody   staff        4096 2003-06-09 21:44 ..
drwx------    2 nobody   staff        4096 2003-06-09 21:44 cur
drwx------    2 nobody   staff        4096 2003-06-09 21:44 new
drwx------    2 nobody   staff        4096 2003-06-09 21:44 tmp


Module configuration:

/etc/courier/pop3d:             AUTHMODULES="authdaemon"
                                                AUTHMODULES_ORIG="authdaemon"

/etc/courier/authmodulelist:    authdaemon

/etc/courier/authdaemonrc:              authmodulelist="authmysql"


Directory structure for /etc/courier:

drwxr-xr-x    3 root     root         4096 2003-06-10 00:04 .
drwxr-xr-x  100 root     root         8192 2003-06-10 07:27 ..
-rw-r--r--    1 root     root         2694 2003-06-09 23:32 authdaemonrc
-rw-r--r--    1 root     root           11 2003-06-09 23:32 authmodulelist
-rw-------    1 daemon   daemon        410 2003-06-10 00:06 authmysqlrc
-rw-r--r--    1 root     root         3430 2003-06-10 00:17 pop3d
-rw-r--r--    1 root     root          333 2003-06-09 23:21 pop3d.cnf
-rw-------    1 root     root         2129 2003-06-09 23:21 pop3d.pem
-rw-r--r--    1 root     root         5604 2003-05-15 17:11 pop3d-ssl


Directory structure for /usr/lib/courier:

drwxr-xr-x    5 root     root         4096 2003-06-09 23:21 .
drwxr-xr-x  119 root     root        36864 2003-06-09 23:16 ..
drwxr-xr-x    2 root     root         4096 2003-06-09 23:17 authlib
drwxr-xr-x    3 root     root         4096 2003-06-09 23:18 courier
-rwxr-xr-x    1 root     root         2182 2003-05-15 17:11 makedat
-rwxr-xr-x    1 root     root         3156 2003-05-15 17:11 makeuserdb
-rwxr-xr-x    1 root     root         1173 2003-05-15 17:11 mkpop3dcert
-rwxr-xr-x    1 root     root         1542 2003-05-15 17:11 pop3d
lrwxrwxrwx    1 daemon   root           22 2003-06-09 23:16 pop3d.pem -> 
/etc/courier/pop3d.pem
-rwxr-xr-x    1 root     root         1679 2003-05-15 17:11 pw2userdb
drwxr-xr-x    2 root     root         8192 2003-06-09 23:16 rootcerts
-rwxr-xr-x    1 root     root         4828 2003-05-15 17:11 userdb
-rwxr-xr-x    1 root     root         1731 2003-05-15 17:11 vchkpw2userdb


PLEASE HELP!!! Any suggestion is highly appreciated!

Anticipated thanks for your support.
-- 
Andrei Magureanu
====================
Web Application Developer
[EMAIL PROTECTED]



-------------------------------------------------------
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
_______________________________________________
courier-users mailing list
[EMAIL PROTECTED]
Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users

Reply via email to