Report OEMCrypto's ECC capabilities.
[ Merge of http://go/wvgerrit/110824 ]
When generating a provisioning request, the CDM includes the different
certificate key types that are supported.
This change will enable the reporting of ECC certificate types if
OEMCrypto supports them.
Test: Linux unit tests and Android integration test
Bug: 140813486
Change-Id: I713ff1c469dff5c8a41461727ce63486d962575e
(cherry picked from commit 547d2f8775)
Merged-In: I713ff1c469dff5c8a41461727ce63486d962575e
This commit is contained in:
@@ -1888,14 +1888,16 @@ bool CryptoSession::GetSupportedCertificateTypes(
|
||||
LOGV("Getting supported certificate types: id = %u", oec_session_id_);
|
||||
RETURN_IF_UNINITIALIZED(false);
|
||||
RETURN_IF_NULL(support, false);
|
||||
|
||||
uint32_t oec_support;
|
||||
WithOecReadLock("GetSupportedCertificateTypes", [&] {
|
||||
oec_support = OEMCrypto_SupportedCertificates(requested_security_level_);
|
||||
});
|
||||
const uint32_t oec_support =
|
||||
WithOecReadLock("GetSupportedCertificateTypes", [&] {
|
||||
return OEMCrypto_SupportedCertificates(requested_security_level_);
|
||||
});
|
||||
support->rsa_2048_bit = oec_support & OEMCrypto_Supports_RSA_2048bit;
|
||||
support->rsa_3072_bit = oec_support & OEMCrypto_Supports_RSA_3072bit;
|
||||
support->rsa_cast = oec_support & OEMCrypto_Supports_RSA_CAST;
|
||||
support->ecc_secp256r1 = oec_support & OEMCrypto_Supports_ECC_secp256r1;
|
||||
support->ecc_secp384r1 = oec_support & OEMCrypto_Supports_ECC_secp384r1;
|
||||
support->ecc_secp521r1 = oec_support & OEMCrypto_Supports_ECC_secp521r1;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user