I did try it but not on iOS . It was on linux..

On Tue, Oct 9, 2012 at 11:37 PM, Taraniteja Vishwanatha <
[email protected]> wrote:

> Hey guys,
>
> I am trying to use AES256 cbc mode for encryption on iOS. I found some
> useful resources online http://saju.net.in/code/misc/openssl_aes.c.txt.
> I am generating key and IV using EVP_BytesToKey.Then I am initializing the
> EVP CIPHER context ( EVP_CIPHER_CTX_init(&e_ctx),
> EVP_EncryptInit_ex(&e_ctx, EVP_aes_256_cbc(), NULL, key, iv) etc. ).
> After this , I call EVP_EncryptInit_ex, update and final. I follow the
> same procedure for decrypt also.
> All the code is written in C and not Objective C.
> I can provide more code if needed.
>
> I am trying to do all this in iOS building in xcode as a static library.
> The encrypt / decrypt fails and ciphertext and plaintext are always
> \xaa\xaa\xaa..............\xaa.
>
> I am curious as to did anybody try aes256 cbc mode crypto uisng EVP APIs
> for iOS before?
>
> Thanks,
> Tarani
>

Reply via email to