[Mailman-Developers] Monthly reminder Errors-To etc

Joris Trooster trooster@interstroom.nl
Mon, 1 Jan 2001 10:32:22 +0100

If mailman sends the monthly reminders, the Return-Path, Sender, Errors-To
and X-BeenThere header tags will be set to a 'random' mailinglist created on
your system. Even if you have set up mailman with different virtual-hosts,
another virtual host can be set in the mail header Sender.

Have a look some relevant code of /yourpath/mailman/cron/mailpasswds :

def mail_passwords(mlist, hosts):
   HandlerAPI.DeliverToUser(mlist, msg, {'_nolist': 1})

def main():
   a_public_list = None
   for listname in Utils.list_names():
        mlist = MailList.MailList(listname, lock=0)
        if not a_public_list and mlist.advertised:
            a_public_list = mlist
   if a_public_list:
            mail_passwords(a_public_list, hosts)

And the comments in the code:  "The list can be any random one - it is only
used for the message delivery mechanism."

You see that it is the first mailinglist created on your system that is used
for setting the Return-Path, Sender, Errors-To, X-BeenThere headers in the
monthly reminder messages.

A quick solution is to change the code (at the end) in cron/mailpasswds to:

    if a_public_list:
        # This line is added to set a custom Sender in het mailheader:
        a_public_list=MailList.MailList(mm_cfg.MONTHLY_SENDER, lock=0)
            mail_passwords(a_public_list, hosts)

And add to Mailman/mm_cfg.py :

# Use this list as the Return-Path, Sender, Errors-To and X-BeenThere
# for the monthly reminders. Be sure that this list exists!!
MONTHLY_SENDER      = 'defaultlist'

It's just a quick work around. It should be better to have a separate Sender
for the montly reminders (wish list for future versions!).

Joris Trooster

John Martin wrote:
- -------------- cut here ---->8 ---< head
Return-Path: <ababa-admin@venice.essential.org>
Delivered-To: jam@jamux.com
Subject: lists.essential.org mailing list memberships reminder
From: mailman-owner@venice.essential.org
To: jam@essential.org
Sender: ababa-admin@venice.essential.org
Errors-To: ababa-admin@venice.essential.org
X-BeenThere: ababa@lists.essential.org
- ---- 8<------- cut here ----------> tail

with the bogus envelope sender, "Errors-To" and header-sender
presumably causing <ababa-admin@venice.essential.org> to be inundated
with delivery error notices.

Is this an error that has crept into my Mailman configuration, or is
this what Mailman will do until the item on the To Do list is