in reply to decrypt problems with Crypt::Rijndael (datasize not multiple of blocksize)

Well, you give us 4 lines of code, and an error message for code at line 25. You say you are getting the error message when decrypting, but the message says it is for encrypt.

As you probably know, Rijndael is a block-cipher algorithm. Your data must be a multiple of 16 in size. It seems like you know this. Keep in mind also that this is a binary algorithm -- there are no invalid values, either on input or output. One thing to look out for is encrypted data manipulation. Your encrypted data can contain anything. If you inadvertently perform any string-like operation on it, the results are unpredictable.

Please provide the encrypt/decrypt sample code if you want more feedback
  • Comment on Re: decrypt problems with Crypt::Rijndael (datasize not multiple of blocksize)