Home
last modified time | relevance | path

Searched refs:rsa (Results 1 – 2 of 2) sorted by relevance

/hardware/qcom/keymaster/
Dkeymaster_qcom.cpp138 Unique_RSA rsa(RSA_new()); in qcom_km_get_keypair_public() local
139 if (rsa.get() == NULL) { in qcom_km_get_keypair_public()
144 rsa->n = BN_bin2bn(reinterpret_cast<const unsigned char*>(keyblob_ptr->modulus), in qcom_km_get_keypair_public()
146 if (rsa->n == NULL) { in qcom_km_get_keypair_public()
151 rsa->e = BN_bin2bn(reinterpret_cast<const unsigned char*>(&keyblob_ptr->public_exponent), in qcom_km_get_keypair_public()
153 if (rsa->e == NULL) { in qcom_km_get_keypair_public()
163 if (EVP_PKEY_assign_RSA(pkey.get(), rsa.get()) != 1) { in qcom_km_get_keypair_public()
167 OWNERSHIP_TRANSFERRED(rsa); in qcom_km_get_keypair_public()
/hardware/libhardware/tests/keymaster/
Dkeymaster_test.cpp427 Unique_RSA rsa(EVP_PKEY_get1_RSA(actual.get())); in TEST_P() local
428 ASSERT_FALSE(rsa.get() == NULL) in TEST_P()
431 ASSERT_EQ(static_cast<unsigned long>(RSA_F4), BN_get_word(rsa.get()->e)) in TEST_P()
434 ASSERT_EQ((GetParam() + 7) / 8, static_cast<uint32_t>(RSA_size(rsa.get()))) in TEST_P()