nmh-workers
[Top] [All Lists]

[Nmh-workers] multiple MIME-Version fields

2015-03-04 12:13:42
i've recently started getting messages with multiple MIME-Version
headers.  they all say "1.0", of course.

mhparse() verifies the first such header.  it will warn if the value's
not 1.0 ("unknown value"), but will proceed in any case.  any
subsequent such header generates a "has multiple fields" warning, but
is then ignored _without_ verification:

    mhshow:  message 4 has multiple MIME-Version: fields

i see nothing (just a quick read) in RFC 2045 regarding multiple
MIME-Version headers.  certainly if they all match, it's benign, but
i'd think we should be verifying all of them.

my real desire is for mhparse() to be silent if the multiple headers
all say "1.0" -- i can think of no reason for me to care if
"MIME-Version: 1.0" appears multiple times in a message.

the following patch accomplishes this:  all MIME-Version headers are
checked, and all those that are acceptable ("1.0") are ignored
silently.  the patch makes it possible for other programs (mhfixmsg? 
a future "mhverifymsg"?) to easily request the multiple header warning
in the future.

any objections?

paul
=----------------------
 paul fox, pgf(_at_)foxharp(_dot_)boston(_dot_)ma(_dot_)us (arlington, ma, 
where it's 35.6 degrees)

Attachment: txtWZSSodlpJM.txt
Description: 0001-mhparse.c-verify-all-MIME-Version-headers-encountere.patch

_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers
<Prev in Thread] Current Thread [Next in Thread>