in reply to Re: Mail::Pop3Client messing up PGP email messages
in thread Mail::Pop3Client messing up PGP email messages

Thanks for the suggestion! That's retreving the e-mail the way it should be formatted. However...

Upon further investigation of my problems, in the encrypted text I'm retrieving, the last 3 = are replaced with =3D, thereby messing up the CRC of the encrypted text. GPG throws a CRC error when I try to decode it manually. However, like I said before, when I retrieve said e-mails in Thunderbird, the =3D is just =.

Any ideas on what's causing this mix up? It doesn't seem to be the encryption as that's coming through just fine.

Thanks!

Useless trivia: In the 2004 Las Vegas phone book there are approximately 28 pages of ads for massage, but almost 200 for lawyers.
  • Comment on Re^2: Mail::Pop3Client messing up PGP email messages

Replies are listed 'Best First'.
Re^3: Mail::Pop3Client messing up PGP email messages
by sgifford (Prior) on May 29, 2006 at 23:10 UTC
    That sounds like maybe the message is PGP-signed, then MIME-encoded. If that's the case, to check it you'll have to MIME-decode it (which will change the =3D to just =) then check the signature.
      I'm not sure what I'm doing wrong here. I'm about to pitch the e-mail attempt and use flock instead I'm getting so frustrated.

      Here's the code I'm trying:

      use strict; use MIME::Decoder; open FH, "audit1.gpg"; my $decoder = new MIME::Decoder "7Bit"; $decoder->decode(\*FH, \*STDOUT); close FH;

      Very basic, but I'm still getting the encoded 3D which shouldn't be there at the end of the message.

      I know that the encryption is correct, because when I physically remove the 3D towards the end of the file, it decodes properly.

      Can you please point me to what I might be missing?

      Useless trivia: In the 2004 Las Vegas phone book there are approximately 28 pages of ads for massage, but almost 200 for lawyers.
        The MIME encoding that would replace = with =3D is "quoted-printable". Try using:
        my $decoder = new MIME::Decoder "quoted-printable";

        You should be able to detect the right encoding from the MIME headers; it would surprise me if MIME::Decoder wouldn't do that automatically for you somehow.