error with bad email with % in addError in htmlformat.py

Bug #266174 reported by Mark Sapiro
2
Affects Status Importance Assigned to Milestone
GNU Mailman
Fix Released
Medium
Unassigned

Bug Description

If an e-mail address being added to any of several
properties via the list admin Gui is "bad" and also
happens to contain a '%' character an error similar to
the following occurs.

Traceback (most recent call last):
  File "/usr/local/mailman/scripts/driver", line 87, in
run_main
    main()
  File "/usr/local/mailman/Mailman/Cgi/admin.py", line
175, in main
    change_options(mlist, category, subcat, cgidata, doc)
  File "/usr/local/mailman/Mailman/Cgi/admin.py", line
1296, in change_options
    gui.handleForm(mlist, category, subcat, cgidata, doc)
  File "/usr/local/mailman/Mailman/Gui/Privacy.py",
line 510, in handleForm
    GUIBase.handleForm(self, mlist, category, subcat,
cgidata, doc)
  File "/usr/local/mailman/Mailman/Gui/GUIBase.py",
line 158, in handleForm
    doc.addError(
  File "/usr/local/mailman/Mailman/htmlformat.py", line
340, in addError
    self.AddItem(Header(3, Bold(FontAttr(
TypeError: not enough arguments for format string

The error actually occurs in evaluation of errmsg %
args where errmsg is 'Bad email address for option
%(property)s: %(val)s' and the value of 'val' in args
contains a '%'.

This occurs in many places in the admin Gui where the
entry is an e-mail address, e.g owner, moderator,
ban_list, accept_these_nonmembers, etc. but not for
example in a mass subscribe list.

email addresses which cause the problem include for
example abc%def.ghi and ab%c@def@ghi but not
ab%<email address hidden> since this latter address is not deemed
invalid.

[http://sourceforge.net/tracker/index.php?func=detail&aid=1099840&group_id=103&atid=100103]

Tags: web-cgi
Revision history for this message
Tokio Kikuchi (tkikuchi) wrote :

Fixed in CVS and appear in 2.1.6 soon.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.