D. J. Bernstein wrote:
In a world that makes any use of RFC 2047, displaying text correctly
means identifying the locations where RFC 2047 encoding is used.
Display (as opposed to generation) does not require information about
header field syntax; RFC 2047 explicitly provides for considering
unrecognized fields as unstructured *for the purpose of display*.
Even worse, the definition is unstable. Consider a mail client that does
a perfect job of decoding RFC 2047 in mail messages today. As soon as
some nitwit defines and deploys a new header field using the RFC 2047
encoding, that mail client will start displaying messages incorrectly.
Not necessarily. Even if that were correct, "incorrect display" is
not nearly as serious as a protocol violation.
This is the design flaw under discussion.
No, the design flaw is an attempt to use RFC 2047 in gateways to modify
header field content *for transmission* (which is not a *display* issue),
based on untagged raw 8-bit content. RFC 2047 encoding must be used
during header field generation, where field syntax, charset, and language
(if relevant) are known or can be unambiguously determined.