openssl: Move shared secret calculation to get_shared_secret()

This is a change from the multi-KE branch.
This commit is contained in:
Tobias Brunner
2022-04-14 19:05:44 +02:00
parent 94a3563c68
commit 1c1213f4b6
4 changed files with 51 additions and 73 deletions
@@ -62,6 +62,7 @@ bool openssl_compute_shared_key(EVP_PKEY *priv, EVP_PKEY *pub, chunk_t *shared)
if (EVP_PKEY_derive(ctx, shared->ptr, &shared->len) <= 0)
{
chunk_clear(shared);
goto error;
}