Group license support
This commit is contained in:
@@ -54,8 +54,15 @@ class WidevineCas : public wvutil::TimerHandler {
|
||||
std::string& license_id);
|
||||
|
||||
// Processes the entitlement |response| to a entitlement license request.
|
||||
virtual CasStatus handleEntitlementResponse(const std::string& response,
|
||||
std::string& license_id);
|
||||
// |license_id| is the id of the license installed. Can be used to select
|
||||
// which license to install.
|
||||
// |multi_content_license_info| contains the message that can be sent to the
|
||||
// app if the installed license is a multi content license.
|
||||
// |group_license_info| contains the message that can be sent to the app if
|
||||
// the installed license is a group license.
|
||||
virtual CasStatus handleEntitlementResponse(
|
||||
const std::string& response, std::string& license_id,
|
||||
std::string& multi_content_license_info, std::string& group_license_info);
|
||||
|
||||
// Generates an entitlement license request in |entitlement_request| for the
|
||||
// media described in |init_data|.
|
||||
@@ -87,8 +94,11 @@ class WidevineCas : public wvutil::TimerHandler {
|
||||
// Set the minimum age required to process ECM.
|
||||
virtual CasStatus HandleSetParentalControlAge(const CasData& data);
|
||||
|
||||
// Remove the in used license. If successful content id is returned.
|
||||
virtual CasStatus RemoveLicense(const std::string file_name);
|
||||
// Remove the license file given the filename user provides.
|
||||
virtual CasStatus RemoveLicense(const std::string& file_name);
|
||||
|
||||
// Record the license id that user provides.
|
||||
virtual CasStatus RecordLicenseId(const std::string& license_id);
|
||||
|
||||
void OnTimerEvent() override;
|
||||
|
||||
@@ -127,6 +137,15 @@ class WidevineCas : public wvutil::TimerHandler {
|
||||
// The age_restriction field in ECM must be greater or equal to
|
||||
// |parental_control_min_age|. Otherwise, ECM will stop being processed.
|
||||
uint parental_control_age_ = 0;
|
||||
// The assigned_license_id helps to indicate which license file current
|
||||
// content will use if multiple licenses exist.
|
||||
std::string assigned_license_id_;
|
||||
// The current in use license_id.
|
||||
std::string license_id_;
|
||||
// The group id of a Group license. Empty if the license is not a Group
|
||||
// license (multi content license is not a group license). Used in processECM
|
||||
// to select group keys that can be decrypted by the license.
|
||||
std::string license_group_id_;
|
||||
}; // namespace wvcas
|
||||
|
||||
} // namespace wvcas
|
||||
|
||||
Reference in New Issue
Block a user