Report OEMCrypto security patch level
am: e33895f5de
* commit 'e33895f5deccdbb15d3ba028190e07864f326ab2':
Report OEMCrypto security patch level
Change-Id: I377b697ebae8beee5679d71cf9233e15d95d65c3
This commit is contained in:
@@ -35,6 +35,7 @@ class CryptoSession {
|
||||
virtual bool GetApiVersion(uint32_t* version);
|
||||
virtual bool GetSystemId(uint32_t* system_id);
|
||||
virtual bool GetProvisioningId(std::string* provisioning_id);
|
||||
virtual uint8_t GetSecurityPatchLevel();
|
||||
|
||||
virtual CdmResponseType Open() { return Open(kLevelDefault); }
|
||||
virtual CdmResponseType Open(SecurityLevel requested_security_level);
|
||||
|
||||
@@ -234,6 +234,10 @@ bool CryptoSession::GetProvisioningId(std::string* provisioning_id) {
|
||||
return true;
|
||||
}
|
||||
|
||||
uint8_t CryptoSession::GetSecurityPatchLevel() {
|
||||
return OEMCrypto_Security_Patch_Level(requested_security_level_);
|
||||
}
|
||||
|
||||
CdmResponseType CryptoSession::Open(SecurityLevel requested_security_level) {
|
||||
LOGV("CryptoSession::Open: Lock");
|
||||
AutoLock auto_lock(crypto_lock_);
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#include "license.h"
|
||||
|
||||
#include <arpa/inet.h>
|
||||
#include <sstream>
|
||||
#include <vector>
|
||||
|
||||
#include "clock.h"
|
||||
@@ -25,6 +26,7 @@ std::string kProductNameKey = "product_name";
|
||||
std::string kBuildInfoKey = "build_info";
|
||||
std::string kDeviceIdKey = "device_id";
|
||||
std::string kWVCdmVersionKey = "widevine_cdm_version";
|
||||
std::string kOemCryptoSecurityPatchLevelKey = "oem_crypto_security_patch_level";
|
||||
const unsigned char kServiceCertificateCAPublicKey[] = {
|
||||
0x30, 0x82, 0x01, 0x8a, 0x02, 0x82, 0x01, 0x81, 0x00, 0xb4, 0xfe, 0x39,
|
||||
0xc3, 0x65, 0x90, 0x03, 0xdb, 0x3c, 0x11, 0x97, 0x09, 0xe8, 0x68, 0xcd,
|
||||
@@ -994,6 +996,11 @@ CdmResponseType CdmLicense::PrepareClientId(
|
||||
client_info->set_name(kWVCdmVersionKey);
|
||||
client_info->set_value(value);
|
||||
}
|
||||
client_info = client_id->add_client_info();
|
||||
client_info->set_name(kOemCryptoSecurityPatchLevelKey);
|
||||
std::stringstream ss;
|
||||
ss << (uint32_t)session_->GetSecurityPatchLevel();
|
||||
client_info->set_value(ss.str());
|
||||
|
||||
ClientIdentification_ClientCapabilities* client_capabilities =
|
||||
client_id->mutable_client_capabilities();
|
||||
|
||||
Reference in New Issue
Block a user