[Mailman-Users] Dynamic subscriber lists

Simon White simon at caperet.com
Mon Feb 2 19:47:21 CET 2004

02-Feb-04 at 12:09, Chris Barnes (chris-barnes at tamu.edu) wrote :
> This is a repost of a question I asked last week.  NOBODY replied - even
> just to say "can't be done".

Maybe nobody has a setup like that already, so they have nothing to say.
"Can't be done" is usually a phrase in the open source world that would
never be said. Nothing is impossible with source open for you, you could
even interface Mailman to your toaster. Not out of the box though :-)

> I need a MLM that can make an LDAP query and get all of the "faculty",
> then send the message out.  It needs to do this for EVERY message for
> that list.

AFAIK, the Mailman subscribers are stored in an internal database. In
order to get something working you'd probably have to hack your own
Python code. I might be wrong about that, but it can't be too hard to
get LDAP and Python working together.

I don't know where the dev is going where using an LDAP or SQL DB to
keep data is concerned. Apparently Sympa has an SQL backend which may or
may not be easier to hack.

Otherwise you can use the tools add_members and sync_members to keep a
sync between an external LDAP query tool in any language and the Mailman
DB. Getting query output to look like a plain text list of email
addresses to STDOUT shouldn't be too hard.

Without making some provision yourself for some kind of hacking, it
can't directly be done with Mailman, or with any other tools that I can
think of 'off the shelf'. You might get away with just an MTA with LDAP
and some kind of group aliasing hack (à la Postfix+LDAP aliases) too,
that depends on your list management requirements.

The difficulty with Mailman or any other mailing list tool is that
subscribes and unsubscribes have to be intelligently handled, so you'd
have to add flags (unsubscribe) to your LDAP queries, etc. If you don't
need to worry so much about subscriptions, because you're sending bulk
announcements in an education or corporate environment, then you don't
need all the complexity of Mailman, (digests, unsubscribes and
moderation + bounce processing to name the main ones off the top of my
head). You just need aliases to groups determined, most probably, by a
single LDAP query, see my comment about LDAP and Postfix for example.


Simon White. Internet Consultant, Linux/Windows Server Administration.
email, dns and web servers; php javascript perl asp; MySQL MSSQL Access
     Bridging the gap between management, HR and the tech team.

More information about the Mailman-Users mailing list