[ Merge of http://go/wvgerrit/101443 ] The WVDrmPlugin has a single CdmIdentifier. The CdmIdentifier contains a SPOID that is calculated from the device ID (keybox or OEM cert), an application reverse domain name and possibly an origin. The CdmIdentifier is set and SPOID calculated on certain calls into WVDrmPlugin. Once it is set, it will not be recalculated. We prevent certain operations such as modifying the origin once the CdmIdentifier has been set as this will require recalculating the SPOID. Recalculating the SPOID may affect open sessions or calls in progress. In a similar way, modifying the security level, will affect the Device ID value and in turn the SPOID. The security level cannot be modified if any sessions are open. This does leave open the possibility that the SPOID may be calculated at one security level, sessions are then closed, and the security level is then changed without an error being flagged. The provisioning certificate file name is based on the SPOID. When the SPOID does not match the security level, either the provisioning information may not be found even though that security level has been provisionined or the provisioning information may be stored in an incorrect location if provisioning occurs. The correct solution is to prevent modifications to the security level once the CdmIdentifier is set. This is a behavior change and might impact apps. We will reevaluate this for the next release. For now, we will work around this. When the CdmIdentifier is set for L3, we will calculate SPOIDs with both L1 and L3 device IDs and check if provisioning previously occurred with SPOIDs calculated for that level. If so, use that level, otherwise use L3. Bug: 147703382 Test: Android unit/integration tests, GtsMediaDrmTests Change-Id: Ia64adfc5848e431ee3876af03eebdb4b6eb83116
This is the source code for the Widevine Content Decryption Module (CDM) for the Android OS. It provides the libwvdrmengine plugin for DRM. Partners who are integrating a device should be familiar with the documents in the docs directory. This source code is NOT open source, and is not part of AOSP. However, it is released to partners external to Google after official Android releases. For this reason, partners should look for bug fixes and software updates on the widevine branches: +------------------------------+------------------------------+ |Android Version |Branch | +------------------------------+------------------------------+ |Android L |lmp-mr1-widevine-release | +------------------------------+------------------------------+ |Android M MR1 |mnc-mr1-widevine-release | +------------------------------+------------------------------+ |Android N MR2 |nyc-mr2-widevine-release | +------------------------------+------------------------------+ |Android OC |oc-widevine-release | +------------------------------+------------------------------+ |Android OC MR1 |oc-mr1-widevine-release | +------------------------------+------------------------------+ |Android Pi |pi-widevine-release | +------------------------------+------------------------------+