Crash when moderating messages with empty sender address

Bug #897103 reported by Bernd Wurst on 2011-11-28
This bug affects 1 person
Affects Status Importance Assigned to Milestone
GNU Mailman
Mark Sapiro

Bug Description

A message in the moderation queue has had an empty sender address ("From: foobar <>").

This leads to the folowing traceback:
admin(9230): [----- Mailman Version: 2.1.14 -----]
admin(9230): [----- Traceback ------]
admin(9230): Traceback (most recent call last):
admin(9230): File "/home/.internal/mailman/scripts/driver", line 112, in run_main
admin(9230): main()
admin(9230): File "/home/.internal/mailman/Mailman/Cgi/", line 167, in main
admin(9230): process_form(mlist, doc, cgidata)
admin(9230): File "/home/.internal/mailman/Mailman/Cgi/", line 718, in process_form
admin(9230): if id not in senderactions[sender]['message_ids']:
admin(9230): KeyError: 'message_ids'

Mark Sapiro (msapiro) wrote :

I have fixed this by preventing the underlying cause from happening. If a message is held for which Mailman's Message.get_sender() method returns an empty string, the sender in the request.pck file will be recorded as '<missing>'. This will prevent the problem in the future, but it won't fix the crash if there is an existing held message entry in request.pck with a null sender. The crash can be avoided by going to the message detail page for the held message by following the number link next to the Subject: in the overview page and discarding the message from the detail page.

Interestingly, for this issue to have occurred in the first place, in addition to the From: header having a null address, the same must have been true of a Sender: header if any and the envelope sender.

Changed in mailman:
assignee: nobody → Mark Sapiro (msapiro)
importance: Undecided → Low
milestone: none → 2.1.15
status: New → Fix Committed
Mark Sapiro (msapiro) on 2012-06-15
Changed in mailman:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers