Internal BCC extraction tool to consume verified device info

BCC extraction tool calls OEMCrypto_GetDeviceInformation() to read
verified device info from TEE. If the verified device info is not
available, (e.g. not implemented), it falls back to using OS properties.

This CL changes the tool used by widevine internally. Another CL will
update the tool for factory use.

Test: Ran the tool on Pixel 7 w/wo verified device info being present
Bug: 263312447

Change-Id: I71a48cc210f6a6f26f339f512a1851237ba94172
This commit is contained in:
Cong Lin
2022-12-19 21:41:26 -08:00
parent ead412cc55
commit a880498f36
4 changed files with 142 additions and 30 deletions

View File

@@ -44,6 +44,8 @@ class WidevineProvisioner {
cppbor::Array BuildCertReqRecipients(const std::vector<uint8_t>& pubkey,
const std::vector<uint8_t>& kid) const;
void InitializeCryptoInterface();
bool GetDeviceInfoCommon(cppbor::Map& device_info_map);
bool TryAddVerifiedDeviceInfo(cppbor::Map& device_info_map);
std::unique_ptr<OEMCryptoInterface> crypto_interface_;
};