GaloisInc / mime

A Haskell MIME library
Other
12 stars 11 forks source link

QuotedPrintable decoding broken #9

Open habbler opened 9 years ago

habbler commented 9 years ago

Consider "Wohnfl=C3=A4che". Here "=C3=A4" is one unicode charachter. However the decode function in module Codec-MIME-QuotedPrintable puts them in two different characters of String (unicode String). Then in processBody in module Codec-MIME-Parse we have T.pack $ decodeBody (T.unpack v) $ T.unpack body which makes the corruption complete.

This is a nasty error which hits normal Mime emails contains html (which are naturally encoded in UTF8).