Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 38849

Summary: Request: add bounce encapsulation patch to qmail
Product: Gentoo Linux Reporter: Ryan Finnie <ryan>
Component: New packagesAssignee: Net-Mail Packages <net-mail+disabled>
Severity: enhancement    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 29485    

Description Ryan Finnie 2004-01-20 14:50:56 UTC
Please add the bounce encapsulation patch for qmail, located at

The latest patch is backwards compatible with "normal" qmail; you must enable it via /var/qmail/control/usebounceencap in order to alter qmail's functionality, so there should be no adverse affects to including this patch.


Short intro: Several MTAs encapsulate the original message in a MIME
message/rfc822 part when sending a bounce.  qmail, however, does not.  
This makes it difficult to extract the original message on graphical MUAs
(Evolution and Outlook for example let you drag and drop encapsulated
messages into other folders as if they were regular messages (because they
are!)).  This patch adds a message/rfc822 encapsulation to the bounce
messages that qmail sends out.

Reproducible: Always
Steps to Reproduce:
Comment 1 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-01-20 14:59:16 UTC
reading your ChangeLog there for the message unique identifier, look at using time + process id (just like maildir filenames). you should be able to borrow the code from the delievry code.
Comment 2 Ryan Finnie 2004-01-20 15:08:05 UTC
qmail-send does not fork itself out for each message processed, so the pid is going to always remain the same.  And since the time is not hires, it's possible that both the bounce and the bounced bounce can be processed in the same second, which really screws up the MIME encapsulation.  (Unlikely, but before I added the stdlib.h/rand() functionality, I would see it occur every couple weeks.)
Comment 3 Ryan Finnie 2004-05-24 01:19:17 UTC
In response to the previous comments, RFC1918 tagging functionality was change, and has been running beautifully for the last few months.

New version at
Comment 4 Ryan Finnie 2004-12-09 13:17:50 UTC
Heh, I don't think anybody noticed, but that previous comment should say "RFC822", not "RFC1918" :)
Comment 5 Michael Hanselmann (hansmi) (RETIRED) gentoo-dev 2005-01-03 12:55:35 UTC
Added to qmail-1.03-r16. Could you test it, please?
Comment 6 Ryan Finnie 2005-01-16 23:25:32 UTC
Sorry for the delay, seems to work fine.  Thanks!
Comment 7 Michael Hanselmann (hansmi) (RETIRED) gentoo-dev 2005-01-17 01:09:54 UTC
Closing the bug. Thanks for testing!