Home
last modified time | relevance | path

Searched refs:ec_key (Results 1 – 12 of 12) sorted by relevance

/system/keymaster/include/keymaster/km_openssl/
Dec_key.h33 EC_KEY_Ptr ec_key) in EcKey() argument
34 : AsymmetricKey(move(hw_enforced), move(sw_enforced), factory), ec_key_(move(ec_key)) {} in EcKey()
42 EcKey(EC_KEY* ec_key, AuthorizationSet hw_enforced, AuthorizationSet sw_enforced, in EcKey() argument
44 : AsymmetricKey(move(hw_enforced), move(sw_enforced), key_factory), ec_key_(ec_key) {} in EcKey()
Dopenssl_utils.h101 size_t ec_group_size_bits(EC_KEY* ec_key);
/system/keymaster/km_openssl/
Dec_key_factory.cpp101 UniquePtr<EC_KEY, EC_KEY_Delete> ec_key(EC_KEY_new()); in GenerateKey() local
103 if (ec_key.get() == nullptr || pkey.get() == nullptr) return KM_ERROR_MEMORY_ALLOCATION_FAILED; in GenerateKey()
116 if (EC_KEY_set_group(ec_key.get(), group.get()) != 1 || in GenerateKey()
117 EC_KEY_generate_key(ec_key.get()) != 1 || EC_KEY_check_key(ec_key.get()) < 0) { in GenerateKey()
121 if (EVP_PKEY_set1_EC_KEY(pkey.get(), ec_key.get()) != 1) return TranslateLastOpenSslError(); in GenerateKey()
134 EcKey key(*hw_enforced, *sw_enforced, this, move(ec_key)); in GenerateKey()
177 EC_KEY_Ptr ec_key(EVP_PKEY_get1_EC_KEY(pkey.get())); in ImportKey() local
178 if (!ec_key.get()) return KM_ERROR_INVALID_ARGUMENT; in ImportKey()
180 EcKey key(*hw_enforced, *sw_enforced, this, move(ec_key)); in ImportKey()
207 UniquePtr<EC_KEY, EC_KEY_Delete> ec_key(EVP_PKEY_get1_EC_KEY(pkey.get())); in UpdateImportKeyDescription() local
[all …]
Dopenssl_utils.cpp159 size_t ec_group_size_bits(EC_KEY* ec_key) { in ec_group_size_bits() argument
160 const EC_GROUP* group = EC_KEY_get0_group(ec_key); in ec_group_size_bits()
/system/keymaster/legacy_support/
Dkeymaster1_engine.cpp171 unique_ptr<EC_KEY, EC_KEY_Delete> ec_key(EC_KEY_new_method(engine_.get())); in BuildEcKey() local
172 if (!ec_key) { in BuildEcKey()
178 if (!EC_KEY_set_ex_data(ec_key.get(), ec_key_index_, key_data)) { in BuildEcKey()
195 if (!EC_KEY_set_group(ec_key.get(), EC_KEY_get0_group(public_ec_key.get())) || in BuildEcKey()
196 !EC_KEY_set_public_key(ec_key.get(), EC_KEY_get0_public_key(public_ec_key.get()))) { in BuildEcKey()
202 return ec_key.release(); in BuildEcKey()
213 unique_ptr<EC_KEY, EC_KEY_Delete> ec_key(EVP_PKEY_get1_EC_KEY(key)); in GetData() local
214 return GetData(ec_key.get()); in GetData()
227 Keymaster1Engine::KeyData* Keymaster1Engine::GetData(const EC_KEY* ec_key) const { in GetData()
228 if (!ec_key) return nullptr; in GetData()
[all …]
/system/keymaster/tests/
Dnist_curve_key_exchange_test.cpp190 UniquePtr<EC_KEY, EC_KEY_Delete> ec_key( in TEST() local
192 ASSERT_TRUE(ec_key.get() && EC_KEY_check_key(ec_key.get())); in TEST()
195 NistCurveKeyExchange* key_exchange = new NistCurveKeyExchange(ec_key.release(), &error); in TEST()
/system/update_engine/payload_consumer/
Dpayload_verifier.cc176 EC_KEY* ec_key = EVP_PKEY_get0_EC_KEY(public_key.get()); in VerifyRawSignature() local
177 TEST_AND_RETURN_FALSE(ec_key != nullptr); in VerifyRawSignature()
183 ec_key) == 1) { in VerifyRawSignature()
/system/security/keystore-engine/
Dkeystore2_engine.cpp85 unsigned int* sig_len, EC_KEY* ec_key);
298 unsigned int* sig_len, EC_KEY* ec_key) { in ecdsa_sign() argument
300 EC_KEY_get_ex_data(ec_key, Keystore2Engine::get().ec_key_ex_index())); in ecdsa_sign()
307 size_t ecdsa_size = ECDSA_size(ec_key); in ecdsa_sign()
/system/update_engine/payload_generator/
Dpayload_signer.cc330 EC_KEY* ec_key = EVP_PKEY_get0_EC_KEY(private_key.get()); in SignHash() local
331 TEST_AND_RETURN_FALSE(ec_key != nullptr); in SignHash()
333 signature.resize(ECDSA_size(ec_key)); in SignHash()
340 ec_key) != 1) { in SignHash()
/system/keymaster/key_blob_utils/
Dsoftware_keyblobs.cpp141 UniquePtr<EC_KEY, EC_KEY_Delete> ec_key(EVP_PKEY_get1_EC_KEY(pubkey)); in FakeKeyAuthorizations() local
142 if (!ec_key.get()) return TranslateLastOpenSslError(); in FakeKeyAuthorizations()
145 ec_get_group_size(EC_KEY_get0_group(ec_key.get()), &key_size_bits); in FakeKeyAuthorizations()
/system/keymaster/include/keymaster/legacy_support/
Dkeymaster1_engine.h108 unsigned int* sig_len, EC_KEY* ec_key);
/system/keymaster/
DAndroid.bp133 "km_openssl/ec_key.cpp",