Report provider client token

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

A content provider may specify a provider client token in a license.
This is a client token generated by a provider. If present in a license,
they will now be included in a license renewal request.

Bug: 34386290
Test: WV unit/integration tests
Change-Id: I3db303ea4d8b4ff4495393be4015b49e13db2ffc
This commit is contained in:
Rahul Frias
2019-01-23 00:35:39 -08:00
parent 85e2c6a026
commit 7982f0848d
6 changed files with 137 additions and 5 deletions

View File

@@ -37,10 +37,14 @@ class ClientIdentification {
// |app_parameters| parameters provided by client/app to be included in
// provisioning/license request. optional, only used
// if |is_license_request| is true
// |provider_client_token| optional parameter specified by the content
// and included in the license. Only used if
// specified and if |is_license_request| is true
// |client_id| Portion of license/provisioning request that needs to be
// populated.
virtual CdmResponseType Prepare(
const CdmAppParameterMap& app_parameters,
const std::string& provider_client_token,
video_widevine::ClientIdentification* client_id);
private:

View File

@@ -84,6 +84,7 @@ class CdmLicense {
CdmResponseType PrepareClientId(
const CdmAppParameterMap& app_parameters,
const std::string& provider_client_token,
video_widevine::LicenseRequest* license_request);
CdmResponseType PrepareContentId(
@@ -148,6 +149,9 @@ class CdmLicense {
CdmLicenseKeyType license_key_type_;
RepeatedPtrField<License_KeyContainer> entitlement_keys_;
std::string provider_client_token_;
#if defined(UNIT_TEST)
friend class CdmLicenseTestPeer;
#endif