Merges to android Pi release (part 5)

These are a set of CLs merged from the wv cdm repo to the android repo.

* Change build options for make protobuf host tools

  Author: Gene Morgan <gmorgan@google.com>

  [ Merge of http://go/wvgerrit/30381 ]

  Also revert local change to protobuf/extension_set.cc
  This builds after adding -Wno-return-type and -Wno-unused flags.

* OEMCrypto v13 stub

  Author: Rintaro Kuroiwa <rkuroiwa@google.com>

  [ Merge of http://go/wvgerrit/30004 ]

* Remove merge conflict tags

  Author: Edwin Wong <edwinwong@google.com>

  [ Merge of http://go/wvgerrit/30120 ]

  Remove merge conflict tags for http://go/wvgerrit/29880

* Added Android Things ARM provisioning key to L3

  Author: Srujan Gaddam <srujzs@google.com>

  [ Merge of http://go/wvgerrit/29701 ]

  BUG: 63443584

BUG: 71650075
Test: Not currently passing. Will be addressed in a subsequent
      commit in the chain.

Change-Id: Ifd867b491dfda5d67d2e225695535b5af9e18260
This commit is contained in:
Rahul Frias
2018-01-09 18:03:56 -08:00
parent 169d0b6cb6
commit b7c9ad57c9
24 changed files with 1852 additions and 1129 deletions

View File

@@ -7,6 +7,7 @@
#include <vector>
#include "clock.h"
#include "cdm_session.h"
#include "crypto_key.h"
#include "crypto_session.h"
#include "device_files.h"
@@ -274,7 +275,8 @@ CdmResponseType CdmLicense::PrepareKeyRequest(
CdmResponseType CdmLicense::PrepareKeyUpdateRequest(
bool is_renewal, const CdmAppParameterMap& app_parameters,
CdmKeyMessage* signed_request, std::string* server_url) {
CdmSession* cdm_session, CdmKeyMessage* signed_request,
std::string* server_url) {
if (!initialized_) {
LOGE("CdmLicense::PrepareKeyUpdateRequest: not initialized");
return LICENSE_PARSER_NOT_INITIALIZED_1;
@@ -330,6 +332,12 @@ CdmResponseType CdmLicense::PrepareKeyUpdateRequest(
if (NO_ERROR != status) return status;
}
// TODO(rfrias): Refactor to avoid needing to call CdmSession
if (cdm_session) {
CdmResponseType status = cdm_session->UpdateUsageEntryInformation();
if (NO_ERROR != status) return status;
}
std::string usage_report;
CdmResponseType status = crypto_session_->GenerateUsageReport(
provider_session_token_, &usage_report, &usage_duration_status,