Repository navigation
DataStandardizer.File.InternetMessage 2.0.2
·
1 commit
to develop
since this release
Breaking changes:
MboxWriterno longer reports a message that can't be read back with its options asLongBodyLine; the reader's error is thrown with its own kind, position and entity path.ImfReader,ImfEntityReader,MboxReader,EmlxReaderandMhtmlReaderreject a line in a multipart entity that starts with its boundary and is not a delimiter, including the delimiters of a nested multipart entity whose boundary starts with the outer one, asImfWriteralready does (RFC 2046 §5.1.1).- A parameter given both as
nameand in an RFC 2231 form such asname*is now rejected as a duplicate (RFC 6838 §4.3), where the RFC 2231 value used to be kept. - Writers throw an ImfFileException for a multipart entity that was read with no close delimiter and hasn't changed, unless their options set AllowMissingBoundaryTerminator; ImfMessage.Validate reports it as InvalidBodyStructure.
ImfEntity.GetTextthrowsImfFileExceptionfor atext/html,text/xml,text/xml-external-parsed-entityortext/markdownentity with nocharsetparameter, instead of decoding it as US-ASCII. These types have no default character set (RFC 6657 §3), so readGetContentand find it as the format says.ImfEntity.GetTextthrowsImfFileExceptionfor atextentity with the+xmlsuffix, such astext/foo+xml, and nocharsetparameter, instead of decoding it as US-ASCII. These types have no default character set (RFC 7303 §4.2), so readGetContentand find it as XML says.
Fixed:
- The package now includes its XML documentation, so IntelliSense shows member descriptions.
- VCard FLOAT and EMLX real values are read as the same double on .NET Framework as on .NET 10, including negative zero.
EmlxWriter,MboxWriter, andImfWriterwriting a message from an mbox file no longer alter the bytes of a body they would have labelledbinaryunderAllowBinaryTransferEncoding; such a body is now encoded instead.ImfWriter,MboxWriterandEmlxWriterwriting a message that holds a message read from a file with other line breaks, such as one from an mbox or EMLX file being forwarded, now change its line breaks to those of the output, instead of refusing it or writing bare LF line breaks into a CRLF message.ImfWriter,MboxWriter,EmlxWriter,ImfEntityWriterandImfHeaderWriternow write a header field read from a file with other line breaks, such as one from an mbox file added to a message read from an.emlfile, with the line breaks of the message, instead of writing bare LF line breaks into a CRLF message.- RFC 6533 message/global-headers, -delivery-status and -disposition-notification entities may be quoted-printable or base64.
- A new UTF-8 header field no longer makes ImfMessage.Body, Validate or a Utf8 writer fail.
- MboxReader no longer adds a stray line feed to the start of a message read after skipping part of a CRLF message.
- ImfWriter adds MIME-Version to a message after a part of a multipart read without it changes.
- MboxReader applies the line-length limit to quoted From lines correctly after 8-bit and CRLF lines.
- MboxReader counts a carriage return that ends the file as part of a quoted From line.
- Header text decoding (
ImfHeaderText) decodes "Q"-encoded words with lower-case hexadecimal digits, such as=?UTF-8?Q?=c3=a9?=, by default, which RFC 2047 §4.2 allows; before, they were decoded only withImfOptions.AllowMalformedEncodedWords. - Quoted parameter values accept the US-ASCII control characters that RFC 822 allows, as text or as quoted-pairs, instead of rejecting them.
- Content-Type and Content-Disposition fields accept a quoted-pair whose backslash ends a folded line, such as
filename="a\<CRLF> b", and read it as the space after the fold (RFC 5322 §2.2.3); before, the field was rejected. - EmlxPlistValue.TryGetDouble gives the nearest double for a hexadecimal integer too large for a long.
EmlxWriter,MboxWriter,MhtmlWriter, andImfWriterwriting a message from an mbox file no longer alter the CR and LF octets of a body that isn't text and that they would have labelled7bitor8bit; such a body is now encoded instead, and one that asks for7bitor8bitis refused.- Writers refuse a moved part or separately read message whose kept bytes hold a delimiter of a boundary around it.
- A refusal of an entity inside a held message with other line breaks, such as one read from an mbox file, gives the
EntityPathof that entity within the message being written, not within the held message. - The refusal of a
binaryentity, or one with an extension mechanism, whose line breaks would change gives itsEntityPath.
Changed:
- A
text/*body from a forward-only stream, written as quoted-printable, has its bare LFs encoded as=0Ainstead of written as CRLF line breaks, so the content is kept as it is (RFC 2045 §6.7 rule 4).