The boundary generation system relies on a random generated boundary. E-mail boundaries can be nested in the same e-mail when e-mail contain subparts, and need to be strictliy different when inside the same message.
Although probablity of collision is low, we still rely on a non deterministic approach when it is realitively easy to make sure that boundaries are strictly different when generated inside the same message.
I am proposing this patch because I was indeed getting collisions every once in a while.
The proposed solution is to track a manually generated string that is to be appended to boundaries used during the generation of a single message + using SHA1 instead of MD5 to even further prevent collision of randomly generated boundaries.
Patch attached.
Comment | File | Size | Author |
---|---|---|---|
#1 | mimemail-2119613-1.patch | 721 bytes | sgabe |
mimemail.inc_.patch | 3.17 KB | david_garcia | |
Comments
Comment #1
sgabe CreditAttribution: sgabe commentedI would rather use just a static counter inside mimemail_multipart_body, see the attached patch.
Comment #2
sgabe CreditAttribution: sgabe commentedCommitted to both branches, thanks!
Comment #3
sgabe CreditAttribution: sgabe commentedChanging title to a more descriptive one.