[Exim] Re: Implementing ODMR

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Brian Candler
Date:  
À: jh
CC: exim-users
Sujet: [Exim] Re: Implementing ODMR
> I'm currently coding an ODMR-server (see rfc 2645: on-demand mail relay,
> smtp with dynamic ip addresses) to use (especially) with Exim. It works
> so far very nice (and was less work than I expected), but I want to make
> sure I use a proper concept and don't missed anything that made it
> better or easier.


I think this is very useful work. Rather than taking files from a bsmtp
spool directory, personally I would read them from a Maildir (using
'serialmail') - that means that a single mailbox can be used for
POP3/IMAP/ATRN access. However that does rely on using the Return-Path: and
Envelope-To: headers to reconstruct the SMTP envelope.

It seems to me that there are two sides to this coin:

(A) ODMR server

This has to:
1. accept an ESMTP connection
2. AUTHenticate the user
3. In response to ATRN, dump the maildrop to the user

1 and 2 are already parts of Exim, and it would be nice to re-use those,
especially to avoid duplicating all the AUTH functionality in a separate
daemon (especially if doing complex AUTHentication, e.g. against an LDAP
server). If Exim had the ability to accept an ATRN command and then simply
invoke an external program, passing the SMTP stream on stdin and stdout and
the authenticated id as a parameter, that would do the job nicely.

(B) ODMR client

This has to:
1. connect to a remote SMTP server
2. AUTHenticate itself to that server
3. Send an ATRN
4. Accept incoming SMTP messages until QUIT

Again, Exim already has most of this functionality, in particular the
ability to act as an AUTH client.

This one I expect would take more work. I guess ideally we'd need a variant
of 'exim -bd' which would connect to a specified host, send AUTH/ATRN, and
then accept incoming messages as usual. Perhaps it could just exec()
'exim -bs' at that point.

Regards,

Brian.