Example #1
0
int EVP_PKEY_set1_EC_KEY(EVP_PKEY *pkey, EC_KEY *key) {
    if (EVP_PKEY_assign_EC_KEY(pkey, key)) {
        EC_KEY_up_ref(key);
        return 1;
    }
    return 0;
}
Example #2
0
int EVP_PKEY_set1_EC_KEY(EVP_PKEY *pkey, EC_KEY *key)
{
	int ret = EVP_PKEY_assign_EC_KEY(pkey,key);
	if (ret)
		EC_KEY_up_ref(key);
	return ret;
}
Example #3
0
EC_KEY *EVP_PKEY_get1_EC_KEY(EVP_PKEY *pkey)
{
    EC_KEY *ret = EVP_PKEY_get0_EC_KEY(pkey);
    if (ret != NULL)
        EC_KEY_up_ref(ret);
    return ret;
}
Example #4
0
EC_KEY *EVP_PKEY_get1_EC_KEY(EVP_PKEY *pkey) {
  EC_KEY *ec_key = EVP_PKEY_get0_EC_KEY(pkey);
  if (ec_key != NULL) {
    EC_KEY_up_ref(ec_key);
  }
  return ec_key;
}
Example #5
0
EC_KEY *EVP_PKEY_get1_EC_KEY(EVP_PKEY *pkey) {
    if (pkey->type != EVP_PKEY_EC) {
        OPENSSL_PUT_ERROR(EVP, EVP_R_EXPECTING_AN_EC_KEY_KEY);
        return NULL;
    }
    EC_KEY_up_ref(pkey->pkey.ec);
    return pkey->pkey.ec;
}
Example #6
0
EC_KEY *EVP_PKEY_get1_EC_KEY(EVP_PKEY *pkey)
{
    if (pkey->type != EVP_PKEY_EC) {
        EVPerr(EVP_F_EVP_PKEY_GET1_EC_KEY, EVP_R_EXPECTING_A_EC_KEY);
        return NULL;
    }
    EC_KEY_up_ref(pkey->pkey.ec);
    return pkey->pkey.ec;
}
Example #7
0
extern "C" int32_t CryptoNative_EcKeyUpRef(EC_KEY* r)
{
    return EC_KEY_up_ref(r);
}