return FALSE;
}
this->prf_alg = alg;
+ DESTROY_IF(this->prf);
this->prf = lib->crypto->create_prf(lib->crypto, alg);
if (this->prf == NULL)
{
/* SK_d is used for generating CHILD_SA key mat => store for later use */
key_size = this->prf->get_key_size(this->prf);
+ chunk_clear(&this->skd);
if (!prf_plus->allocate_bytes(prf_plus, key_size, &this->skd))
{
goto failure;
goto failure;
}
+ DESTROY_IF(this->aead_in);
+ DESTROY_IF(this->aead_out);
+
if (encryption_algorithm_is_aead(alg))
{
if (!derive_ike_aead(this, alg, key_size, prf_plus))
}
}
+ chunk_clear(&this->skp_build);
+ chunk_clear(&this->skp_verify);
+
/* SK_pi/SK_pr used for authentication => stored for later */
key_size = this->prf->get_key_size(this->prf);
if (!prf_plus->allocate_bytes(prf_plus, key_size, &key))