Re: How to do AES-256-CBC encryption with EVP_CIPHER_CTX now opaque?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 25/11/16 14:42, Dave Poirier wrote:
> *Question 1: Are there other functions I should have been using to
> implement AES-256-CBC than the EVP methods above?*

EVP is the correct thing to be using.

> 
> Question 2: If EVP is the way to go for implementing AES-256-CBC, which
> functions should I be looking at to not require EVP_CIPHER_CTX variable
> declaration?

You still use an EVP_CIPHER_CTX, you just don't allocate it on the stack
like you have in your code:

EVP_CIPHER_CTX *ctx = EVP_CIPHER_CTX_new();

if (ctx == NULL)
	/* Do some error handling */

...do your crypto stuff....

/* Free the allocated EVP_CIPHER_CTX */
EVP_CIPHER_CTX_free(ctx);



Matt
-- 
openssl-users mailing list
To unsubscribe: https://mta.openssl.org/mailman/listinfo/openssl-users



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux