views:

88

answers:

1

Hi All, I'm new to OpenSSL. I understand that encryption should be performed using the EVP API which acts as a common interface to all the ciphers. AES CTR mode seems to be present in the version of OpenSSL that I have, but the definition for EVP_aes_128_ctr is disabled in evp.h:

#if 0
const EVP_CIPHER *EVP_aes_128_ctr(void);
#endif

Any idea why this is? Can I just remove the #if 0? Any other pointers on getting 128 bit AES CTR mode encryption to work in OpenSSL would be appreciated!

Thanks! -M

+1  A: 

Btw, it looks like the answer to this is no, not yet. But maybe soon. I found this email thread indicating that a patch to address this issue may have been submitted in June 2010:

http://www.mail-archive.com/[email protected]/msg01972.html

But when I downloaded the latest development branch from SVN, AES CTR was still not enabled in EVP. I ended up just implementing it directly, for which I found this link helpful:

http://stackoverflow.com/questions/3141860/aes-ctr-256-encryption-mode-of-operation-on-openssl

mindthief