summaryrefslogtreecommitdiff
path: root/Mailman/Handlers/CookHeaders.py
Commit message (Collapse)AuthorAgeFilesLines
...
* process(): Simplify the calculation of the List-Archive: header.bwarsaw2001-12-191-4/+1
|
* process(): We're now setting Sender: and Errors-To: to thebwarsaw2001-11-201-3/+3
| | | | | | listname-bounces@dom.ain address instead of to the -admin address. This departure cleans up the return path for bounced deliveries, but does require a regeneration of the aliases file.
* process(): If the list attribute include_rfc2369_headers is false,bwarsaw2001-10-211-1/+1
| | | | then don't add the List-* headers.
* process(): Reworked Reply-To: munging so list owners can establishbwarsaw2001-10-201-12/+31
| | | | | | | | their own policies. Specifically, added first_strip_reply_to which will control whether any additional Reply-To: headers override or extend an existing such field. Also, we no longer save the old Reply-To: header on X-Reply-To:
* Mostly cosmetic.bwarsaw2001-10-011-9/+1
|
* process(): Do not munge the Reply-To: field if reply_goes_to_list isbwarsaw2001-08-141-10/+15
| | | | | | `explicit' but the reply_to_address is invalid. Also, include some notes about better RFC 2369 support...
* Conversion to mimelib.bwarsaw2001-02-151-19/+35
| | | | | | | | De-string-module-ify Other Python 2.0 constructs used where appropriate. Get rid of HandlerAPI references -- this module is obsolete.
* process(): Get rid of the string module in favor of string methods.bwarsaw2000-12-201-3/+4
| | | | | Also, don't set the X-BeenThere: header by appending to msg.headers; use the __setitem__() interface instead.
* First round integration of Juan Carlos's translatable string markings.bwarsaw2000-12-071-1/+1
|
* process(): "Fix" the Reply-To: header munging algorithm. If mungingbwarsaw2000-11-161-5/+10
| | | | | | | is enabled, we now unconditionally munge based on the reply_goes_to_list config variable setting. If the Reply-To: header is munged, the original Reply-To: header (if any) is put on X-Reply-To:
* process(): Patch by Fil to force listinfo urls to be absolute.bwarsaw2000-10-271-1/+1
|
* process(): Wrap, in the RFC 822 style, the List-*: headers if they'rebwarsaw2000-10-061-0/+6
| | | | longer than 78 characters.
* process(): Darrell Fuhriman notes that the List-Archive: header'sbwarsaw2000-09-251-2/+3
| | | | value needs to be wrapped in angle brackets.
* process(): Typo in Reply-To: munging section's logic crept into thebwarsaw2000-09-251-1/+1
| | | | | last patch. This caused confirmation requests to have a reply-to pointing back to the list. Closes bug #115253.
* process(): To finally break -admin autoreply loops, we need to add thebwarsaw2000-09-211-2/+3
| | | | "X-Ack: no" header if the `noack' flag is set on msgdata.
* process(): Implementation of RFC 2369, inspired by zedboy's (Darrellbwarsaw2000-09-201-26/+41
| | | | | | | | | Fuhriman) SF patch #101290. List-Id: is kept for historical reasons even though it is not part of the RFC. The following headers included on each email: List-Help, List-Unsubscribe, List-Subscribe, List-Post with appropriate http and/or mailto urls for the list. List-Archive is also added if the mailing list supports archives. These headers are not added for "_nolist" messages (e.g. password reminders).
* Do not set the List-Id: header if the msgdata contains the volatilebwarsaw2000-09-151-1/+1
| | | | | key "_nolist" (set by mailpasswords). Close SF bug #114127, Jitterbug PR#149.
* process(): Because this module modifies the message object, set thebwarsaw2000-07-271-0/+4
| | | | | _dirty flag so the text will be forced to disk in the event of an Enqueue().
* process(): Set Sender: and Errors-To: either the the value specifiedbwarsaw2000-07-221-2/+2
| | | | in the msgdata dictionary, falling back to the -admin address.
* Many changes to make message delivery more robust in the face ofbwarsaw2000-05-081-7/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | failures, bugs, and lock acquisition timeouts. Instead of storing information about the progress of the delivery on the Message object, we pass around a parallel data structure called `msgdata' (current just a dictionary). All calculated information is passed through this object, but this changes the API to handler modules. They now take three arguments: the mailing list, the message object, and the msgdata. WARNING: This may change before 2.0 final. Specific changes include: HandlerAPI DiscardMessage(), HandlerAPI.SomeRecipientsFailed(): New shared exceptions. pipeline_deliver(): removed LIST_PIPELINE: global containing the primary list delivery pipeline DelivertoList: Revamped main entry point into message delivery to list membership. Takes three arguments: the mailing list, the message object, and the msgdata dictionary. This digs the pipeline to use out of the msgdata (allowing resumption of prematurely interrupted pipeline deliveries). Then each module is called in turn, and the shared exceptions are caught. As each module is completed successfully, it is removed from the head of the pipeline. This function returns the number of pipeline modules remaining to be executed (i.e. a return of 0 means DeliverToList() is done with this message and it can be dequeued). A catch-all is included in case some unexpected exception occurs (say a bug or typo in one of the delivery modules). Such an error will queue the message, so at least it doesn't just get lost. We try to never just lose a message. RedeliverMessage(), DeliverToUser(): reimplemented in terms of DeliverToList(). Acknowledge, AfterDelivery, CalcRecips, Cleanse, CookHeaders, Decorate, Replybot, ToArchive, ToUsenet Fix the function signature to match the new API (three arguments), and changed the implementations to extract delivery information from msgdata instead of as attributes of the message object. Approved Same as above, but also removed NotApproved exception. LoopError is now multiply derived from HandlerAPI.DiscardMessage and Errors.MMLoopingPost. Hold Same as above, but also changed slightly the way an exception is raised when a message is held. hold_for_approval() now takes four arguments (the msgdata parameter has been added), and the exc object can be a class or instance. If it's a class, it is simply zero-arg'd instantiated. We also use the str() of the exception to get us the reason for the hold. This allows us to override HandlerAPI.MessageHeld.__str__() for MessageToBig so that we can include the size of the message being held. SMTPDirect Same as above, but instead of explicitly enqueuing the messages when some or all of the recipient deliveries failed, just raise a HandlerAPI.SomeRecipientsFailed exception and let DeliverToList() manage the enqueuing. Thus queue_message() is removed. Sendmail Same as above, but if any chunks fail delivery, those recipients are queued by raising SomeRecipientsFailed. SpamDetect Same as above, except that if a regexp matches, a SpamDetect exception is raised directly. The DeliverToList() framework discards these spam messages instead of holding them for approval. ToDigest Same as above, except that if a digest is prepared for delivery, it is not sent directly via mlist.Post(). Instead, the message is queued for delivery, thereby relinquishing the lock soon. This means that digests will only be sent the next time qrunner runs.
* Update the copyright lines to include the years 1999 & 2000.bwarsaw2000-03-211-1/+1
|
* process(): 'fastrack' => 'fasttrack'. Elaborate the Reply-To: mungingbwarsaw2000-03-031-5/+10
| | | | | to handle the case where the header is set to an explicit address, as specified in mlist.reply_to_address.
* process(): When setting the 'Reply-To' header (note thebwarsaw2000-02-081-1/+1
| | | | | capitalization) using the setitem interface, you should not include the header key or the trailing newline.
* * X-BeenThere: headers were being overwritten every time they reachedhmeland2000-02-081-1/+6
| | | | | | | a new mailing list -- changed to append a new header per list (so that multi-list loops can be detected). * Set Reply-To: header to point back to list, if mlist.reply_goes_to_list is true and msg.fastrack is false/unset.
* First, because this module is going to modify the Sender: field forbwarsaw1999-11-241-6/+12
| | | | | | | | | | | | outgoing mail, we stash the original value of msg.GetSender() in a message object attribute msg.original_sender. This is used by the Acknowledge module. Second, only perform subject prefix prepending if not msg.isdigest an dnot msg.fastrack. I.e. the message isn't a pre-crafted digest message, and it's not being fast tracked via HandlerAPI.DeliverToUser. Fast tracking means it's being delivered to a single address and not to the general list subscribership.
* process(): Only add the mailing list subject prefix if the message isbwarsaw1999-11-111-6/+10
| | | | not a digest.
* New pipeline delivery modulebwarsaw1999-11-101-0/+84
"""Cook a message's Subject header. Use Cleanse.py module to actually remove various headers. """