in reply to Re: Crypt OpenPGP Brain twister
in thread Crypt OpenPGP Brain twister

Um, its the decrypt call that is failing

Replies are listed 'Best First'.
Re^3: Crypt OpenPGP Brain twister
by Anonymous Monk on Aug 14, 2012 at 20:34 UTC
    jeteve or others: Did this ever get a resolution? I'm repeating the same error on the decode. What to do?

      I had a similar problem, and I have solved it downgrading from Crypt-OpenPGP-1.06 to Crypt-OpenPGP-1.04

      The reason for this is that version 1.06 uses Math::BigInt where 1.04 uses Math::Pari for big numbers

      When a private RSA key is extracted from the ring, the components are stored in Math::BigInt objects, and at some point it are used with a Crypt::RSA::Key::Private objects, that internally uses Math::Pari objects for the components

      When the Crypt::RSA::Key::Private::AUTOLOAD method is called for component creation with a Math::BigInt object reference as a parameter, it fails. The component is't updated, but no error is reported

      Later, when the private key is going to be used for decrypt, it fails because it doesn't have the private components

      Hope this help

      Sorry, I meant on the decrypt.