I would like to get a pattern of CR and LF that will consistently break when
going through Anomy. Unfortunately, I can't seem to get this to happen. My
understanding of the problem is that Anomy is changing the way that CR and
LF are interpreted in the MIME itself when decoding/encoding. I have tried
three variations of files containing:
1. CR
2. LF
3. CRLF
All go through Anomy without any problems! They get properly decoded by
another MIME client, which in thise case is MIME::Parser.
Following is the output of the three tests. Notice that CR have been
replaced by --CR-- and LF with --LF--. When is Anomy breaking the CR or LF
in PDF files?
My goal is to try and fix this in Anomy instead of using an outside tool,
which will only slow down already busy mail servers.
...
]]]]]]] --- original ----
LINE: --CR----LF--
LINE: --CR--xx--CR----LF--
LINE: xx--CR--xx--LF--
LINE: xx--CR----LF--
LINE: --CR--
]]]]]]] --mime-----
LINE: Content-Type: multipart/mixed;
boundary="----------=_1068766722-2867-0"--LF--
LINE: Content-Transfer-Encoding: binary--LF--
LINE: MIME-Version: 1.0--LF--
LINE: X-Mailer: MIME-tools 5.411 (Entity 5.404)--LF--
LINE: From: 101816@xyz.molar.is--LF--
LINE: To: 101850@xyz.molar.is--LF--
LINE: Subject: Hello, nurse!--LF--
LINE: --LF--
LINE: This is a multi-part message in MIME format...--LF--
LINE: --LF--
LINE: ------------=_1068766722-2867-0--LF--
LINE: Content-Type: text/plain; name="example.txt"--LF--
LINE: Content-Disposition: inline; filename="example.txt"--LF--
LINE: Content-Transfer-Encoding: binary--LF--
LINE: --LF--
LINE: Input file is samples/cr.txt--LF--
LINE: --LF--
LINE: ------------=_1068766722-2867-0--LF--
LINE: Content-Type: application/pdf; name="example.pdf"--LF--
LINE: Content-Disposition: inline; filename="example.pdf"--LF--
LINE: Content-Transfer-Encoding: quoted-printable--LF--
LINE: --LF--
LINE: =0D--LF--
LINE: =0Dxx=0D--LF--
LINE: xx=0Dxx--LF--
LINE: xx=0D--LF--
LINE: =0D--LF--
LINE: ------------=_1068766722-2867-0----LF--
]]]]]]] --mime->anomy->decoded-------
LINE: --CR----LF--
LINE: --CR--xx--CR----LF--
LINE: xx--CR--xx--LF--
LINE: xx--CR----LF--
LINE: --CR--
...
]]]]]]] --- original ----
LINE: --CR----LF--
LINE: --LF--
LINE: --CR----LF--
LINE: xx--CR----LF--
LINE: --LF--
LINE: xx--CR----LF--
LINE: xx--LF--
LINE: xx--CR----LF--
LINE: --LF--
LINE: --CR----LF--
]]]]]]] --mime-----
LINE: Content-Type: multipart/mixed;
boundary="----------=_1068766734-2919-0"--LF--
LINE: Content-Transfer-Encoding: binary--LF--
LINE: MIME-Version: 1.0--LF--
LINE: X-Mailer: MIME-tools 5.411 (Entity 5.404)--LF--
LINE: From: 101816@xyz.molar.is--LF--
LINE: To: 101850@xyz.molar.is--LF--
LINE: Subject: Hello, nurse!--LF--
LINE: --LF--
LINE: This is a multi-part message in MIME format...--LF--
LINE: --LF--
LINE: ------------=_1068766734-2919-0--LF--
LINE: Content-Type: text/plain; name="example.txt"--LF--
LINE: Content-Disposition: inline; filename="example.txt"--LF--
LINE: Content-Transfer-Encoding: binary--LF--
LINE: --LF--
LINE: Input file is samples/crlf.txt--LF--
LINE: --LF--
LINE: ------------=_1068766734-2919-0--LF--
LINE: Content-Type: application/pdf; name="example.pdf"--LF--
LINE: Content-Disposition: inline; filename="example.pdf"--LF--
LINE: Content-Transfer-Encoding: quoted-printable--LF--
LINE: --LF--
LINE: =0D--LF--
LINE: --LF--
LINE: =0D--LF--
LINE: xx=0D--LF--
LINE: --LF--
LINE: xx=0D--LF--
LINE: xx--LF--
LINE: xx=0D--LF--
LINE: --LF--
LINE: =0D--LF--
LINE: --LF--
LINE: ------------=_1068766734-2919-0----LF--
]]]]]]] --mime->anomy->decoded-------
LINE: --CR----LF--
LINE: --LF--
LINE: --CR----LF--
LINE: xx--CR----LF--
LINE: --LF--
LINE: xx--CR----LF--
LINE: xx--LF--
LINE: xx--CR----LF--
LINE: --LF--
LINE: --CR----LF--
...
]]]]]]] --- original ----
LINE: --LF--
LINE: --LF--
LINE: --LF--
LINE: xx--LF--
LINE: --LF--
LINE: xx--LF--
LINE: xx--LF--
LINE: xx--LF--
LINE: --LF--
LINE: --LF--
]]]]]]] --mime-----
LINE: Content-Type: multipart/mixed;
boundary="----------=_1068766727-2893-0"--LF--
LINE: Content-Transfer-Encoding: binary--LF--
LINE: MIME-Version: 1.0--LF--
LINE: X-Mailer: MIME-tools 5.411 (Entity 5.404)--LF--
LINE: From: 101816@xyz.molar.is--LF--
LINE: To: 101850@xyz.molar.is--LF--
LINE: Subject: Hello, nurse!--LF--
LINE: --LF--
LINE: This is a multi-part message in MIME format...--LF--
LINE: --LF--
LINE: ------------=_1068766727-2893-0--LF--
LINE: Content-Type: text/plain; name="example.txt"--LF--
LINE: Content-Disposition: inline; filename="example.txt"--LF--
LINE: Content-Transfer-Encoding: binary--LF--
LINE: --LF--
LINE: Input file is samples/lf.txt--LF--
LINE: --LF--
LINE: ------------=_1068766727-2893-0--LF--
LINE: Content-Type: application/pdf; name="example.pdf"--LF--
LINE: Content-Disposition: inline; filename="example.pdf"--LF--
LINE: Content-Transfer-Encoding: quoted-printable--LF--
LINE: --LF--
LINE: --LF--
LINE: --LF--
LINE: --LF--
LINE: xx--LF--
LINE: --LF--
LINE: xx--LF--
LINE: xx--LF--
LINE: xx--LF--
LINE: --LF--
LINE: --LF--
LINE: --LF--
LINE: ------------=_1068766727-2893-0----LF--
]]]]]]] --mime->anomy->decoded-------
LINE: --LF--
LINE: --LF--
LINE: --LF--
LINE: xx--LF--
LINE: --LF--
LINE: xx--LF--
LINE: xx--LF--
LINE: xx--LF--
LINE: --LF--
LINE: --LF--