Comment 1 for bug 405733

Revision history for this message
Anik (clay) wrote :

You are correct about the assumption that the "AUTH PLAIN" string is not generated correctly. After some observation (I have very little Perl knowledge) it looks like sendEmail adds 0x0d0d0a, that's one 0x0d too much. It looks like the function base64_encode works incorrectly. It adds 0x0d0a after each 76 characters and then finally chomps the string once, and it looks like this does not delete the 0x0d.

My fix was to replace the chomp by a doubled chop:

833,834c833
< chop $data;
< chop $data;
---
> chomp $data;

This seems to fix it for me.