Cristina Nita-Rotaru wrote: > > Hello. > > There might be a problem with EVP_DecryptUpdate. > > My understanding was that EVP_EncryptUpdate can be called > multiple times and then conclude the encryption by calling > EVP_EncryptFinal. A similar mechanism applies for > EVP_DecryptUpdate and EVP_DecryptFinal. > > In a test that I am running where two blocks of 16 bytes > are encrypted by calling EVP_EncryptUpdate twice (each on 16 bytes) > and then EVP_EncryptFinal, when I want to perform the > decryption in a similar manner, the first call of EVP_DecryptUpdate > on the first 16 bytes reports that only 8 bytes where decrypted. > Shouldn't this be 16? >
I've recently answered this in more detail in openssl-users. No its not a bug because the decrypt routines have to store up to one block of decrypted data internally due to the padding checking. Steve. -- Dr Stephen N. Henson. http://www.drh-consultancy.demon.co.uk/ Personal Email: [EMAIL PROTECTED] Senior crypto engineer, Gemplus: http://www.gemplus.com/ Core developer of the OpenSSL project: http://www.openssl.org/ Business Email: [EMAIL PROTECTED] PGP key: via homepage. ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [EMAIL PROTECTED] Automated List Manager [EMAIL PROTECTED]
