Re: [Exim] Locked mail spool file

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Nigel Metheringham
Date:  
À: Trevor Sky Garside
CC: Phil Pennock, exim-users, pop-imap
Sujet: Re: [Exim] Locked mail spool file
trevor@??? said:
> Considering all of this, I decided to toss the idea of trying to
> access a Unix style single-file mailbox, and instead use the
> directory-per-user format of mailspool. A bit of creative file
> checking, and no flock'ing needed. Since this box is 100% virtual (no
> user logins except for the administrators), I will just make sure that
> the few programs/daeomons who would ever be deleting a particular mail
> message all employ a common 'locking' procedure. It's working out
> great for me so far, and the performance is amazingly better than with
> the old-style mailboxes.


This is getting *really* silly.
If you are basically using maildir spool format, then use, or at least
take as a base, the qmail pop3* programs. Whats more you then find
there are 3 programs in the set - pop3up, checkpassword and pop3d (from
memory, I may have got the names wrong).

The first program, pop3up, does the username/password part of the pop3
protocol. checkpassword is a small program that does *only* the
authentication and setup (ie changing UID, setting appropriate
directory), and then execs the pop3d which does the main part of the
pop protocol.

This means the authentication is as flexible as you want - just rewrite
checkpassword - I have written RADIUS authentication modules and some
db auth with no problems at all - and they are easy to prototype in
perl since the whole thing tends to be a few 10s of lines of code (in C
- about the same in perl too).

    Nigel.
-- 
[ - Opinions expressed are personal and may not be shared by VData - ]
[ Nigel Metheringham                  Nigel.Metheringham@??? ]
[ Phone: +44 1423 850000                         Fax +44 1423 858866 ]