http://issues.apache.org/SpamAssassin/show_bug.cgi?id=5179
[EMAIL PROTECTED] changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |[EMAIL PROTECTED]
------- Additional Comments From [EMAIL PROTECTED] 2007-02-14 16:48 -------
Sorry for coming late for lunch again.
> $line =~ s/$/\r\n/s;
Well, the Mail::DKIM documentation clearly states that
line endings must be \015 \012, and reinforces it by an example:
# use SMTP line terminators
$dkim->PRINT("$_\015\012");
The exact character codes are important because they enter
as data into crypto hashing.
People used to Perl on Unix platforms (including myself)
often forget the semantics that Perl gives to \r and \n.
It is explained in the perlport man page. Here is an
important excerpt:
A common misconception ... is that \n eq \012 everywhere.
When using protocols such as common Internet protocols,
\012 and \015 are called for specifically, and the values
of the logical \n and \r (carriage return) are not reliable.
[...]
| Unix | DOS | Mac |
---------------------------
\n | LF | LF | CR |
\r | CR | CR | LF |
\n * | LF | CRLF | CR |
\r * | CR | CR | LF |
---------------------------
* text-mode STDIO
That conversion section calling $dkim->PRINT should be modified
to always append \015\012 to lines (instead of \r\n), to insure
the code will also work on DOS and Mac.
Could the ticket be reopened, or should I enter the above as
a new entry?
Mark
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.