Hi, I'm playing around with ECC using v 5.4.0.0 of the library.
One of my test cases involves encrypting and decrypting a zero length string; encryption produces a non-zero length cipher text. When decrypting I call CryptoPP::ECIES<CryptoPP::ECP>::Decryptor::MaxPlaintextLength() which unsurprisingly returns 0. Unfortunately, I believe, 0 is also returned when the cipher text is invalid and as such I'm returning an error saying the cipher text has become corrupted and can't be decrypted. The only solution I can think of is to forbid encryption of 0 length cipher texts but I'd rather not (purely because I don't want to add limitations to the application, a zero length string is a valid string...). Are there any other ways to detect the difference between an invalid cipher text and one that decrypts to a 0 length plain text? Thanks, Patrick --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the "Crypto++ Users" Google Group. To unsubscribe, send an email to [EMAIL PROTECTED] More information about Crypto++ and this group is available at http://www.cryptopp.com. -~----------~----~----~----~------~----~------~--~---
