KDF_DATA *expected = t->data;
unsigned char *got = NULL;
size_t got_len = expected->output_len;
+ EVP_KDF_CTX *ctx;
if (!EVP_KDF_CTX_set_params(expected->ctx, expected->params)) {
t->err = "KDF_CTRL_ERROR";
t->err = "INTERNAL_ERROR";
goto err;
}
+ if ((ctx = EVP_KDF_CTX_dup(expected->ctx)) != NULL) {
+ EVP_KDF_CTX_free(expected->ctx);
+ expected->ctx = ctx;
+ }
if (EVP_KDF_derive(expected->ctx, got, got_len, NULL) <= 0) {
t->err = "KDF_DERIVE_ERROR";
goto err;