Implement Method to Release Licenses Without a Server Roundtrip
Merge from Widevine repo of http://go/wvgerrit/52480 Partners have asked for a way to release offline licenses without using a release message. This is typically used by cable partners who are caching licenses ahead of time and do not care about usage statistics. As part of implementing this request, CdmSession::DeleteLicense() was renamed to reflect that it only deletes the *files* associated with a license, and a new CdmSession::DeleteLicense() has been written that also cleans up other related data. Bug: 77955334 Test: CE CDM Unit Tests Test: tested as part of http://go/ag/4674759 Change-Id: I00d6e20935c5fecb3ac9be6757c0f191d85c6bd6
This commit is contained in:
@@ -113,8 +113,18 @@ class CdmEngine {
|
||||
virtual CdmResponseType RestoreKey(const CdmSessionId& session_id,
|
||||
const CdmKeySetId& key_set_id);
|
||||
|
||||
// This method releases the crypto resources and policy resources associated
|
||||
// with the given session. This renders the session largely useless. It is
|
||||
// preferable to close the session outright. This method does not delete any
|
||||
// stored offline data associated with the session.
|
||||
virtual CdmResponseType RemoveKeys(const CdmSessionId& session_id);
|
||||
|
||||
// This method removes all offline data associated with the session, such as
|
||||
// offline keys and usage info. It should be used with care, as it deletes the
|
||||
// info immediately and without using a release message, so the server is not
|
||||
// able to receive usage info or track releases for offline licenses.
|
||||
virtual CdmResponseType RemoveLicense(const CdmSessionId& session_id);
|
||||
|
||||
// Construct valid renewal request for the current session keys.
|
||||
virtual CdmResponseType GenerateRenewalRequest(
|
||||
const CdmSessionId& session_id, CdmKeyRequest* key_request);
|
||||
|
||||
Reference in New Issue
Block a user