On Sun, Nov 13, 2005, [EMAIL PROTECTED] wrote: > I am trying to make a C++ class to make encrytion and decrytion simple > using the blowfish algorithm with openssl. Anyways, I have modelled my > program around > http://www.linuxgazette.com/issue87/misc/vinayak/sym_funcs.c.txt which is > a C program for reading and writing files, with encrytion using openssl. > Anyways, both programs seem to fail the same way on larger files (they > will pass on smaller files) and I can't seem to get EVP_DecryptFinal_ex to > work. > Here are my encrypt and decrypt functions with my defines as follows >
I suggest you rely on the documentation instead. The normal way to do things is to call EVP_EncryptInit_ex() initially, then call EVP_EncryptUpdate() one or more times on each chunk to be encrypted and finally call EVP_EncryptFinal_ex() when all data has been handled. That example seems to be calling EVP_EncryptFinal_ex() on each chunk. Steve. -- Dr Stephen N. Henson. Email, S/MIME and PGP keys: see homepage OpenSSL project core developer and freelance consultant. Funding needed! Details on homepage. Homepage: http://www.drh-consultancy.demon.co.uk ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List openssl-users@openssl.org Automated List Manager [EMAIL PROTECTED]