[dovecot] PostgreSQL support

Alex Howansky alex at wankwood.com
Thu Mar 6 13:31:55 EET 2003


Timo,

I've written passdb and userdb modules for PostgreSQL. My C skills aren't that
great, so I borrowed heavily from the LDAP modules, and I've never developed
with automake/autoconf before, so I don't know how acceptable my patch to
configure.in is. Anyway, it seems to work ok but I haven't done really heavy
testing. If you can get past my poor C skills, I hope you will at least find my
work useful as a base to expand from.

The patch supports arbitrary queries which can use the %h/%n/%d macros, so
there's no need to have specific table or field names. For example, in the
configuration file, you'd specify something like:

password_query = select password from users where userid = '%u'

Like the LDAP module, it supports PLAIN, PLAIN-MD5, DIGEST-MD5, and CRYPT. It
also tries to be secure by immediately rejecting any auth attempts that don't
fit a very strict format. If the user-provided data contains any non-standard
characters, the query returns more than one row, etc., auth will immediately
fail.

Are you interested in my patch, and if so, how should I send it? Does the list
accept attachments? (The patch is against current CVS, by the way.)

Regards,

-- 
Alex Howansky
Wankwood Associates
http://www.wankwood.com/




More information about the dovecot mailing list