Files
android/libwvdrmengine
Alex Dale a2cdce4296 Changed Prov4.0 handler to accept only recent requests.
[ Cherry-pick of v19 http://go/wvgerrit/219291 ]
[ Merge of http://go/wvgerrit/219432 ]

If the same app/origin generates multiple provisioning 4.0
requests it is possible that a mismatch between the OEM/DRM
certificate and the wrapped OEM/DRM private key occurs.  The CDM
would use the OEM/DRM certificate of the first response one
received, and the wrapped private key of the last request generated.

To avoid this issue, the public key from the most recent request
is cached and checked against the responses received.  If the
keys match, that response is accepted; if the keys don't match
than the response is assumed "stale" and the response is dropped.

In an attempt to maintain existing behavior of the CDM, "stale"
responses will return NO_ERROR to the app.

Note: This was tested using both RSA and ECC cert key types.

VIC-specific: Needed to add implementation of StringContains() and
StringEndsWith().

Bug: 391469176
Test: run_prov40_tests
Change-Id: Id45d40d9af355c46a61c3cc2c19c252cf17c7489
2025-04-21 17:09:13 -07:00
..
2025-04-18 19:21:52 -07:00
2022-01-27 20:07:15 -08:00
2018-11-22 00:33:30 +00:00
2024-03-18 21:32:04 -07:00

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           |
+------------------------------+------------------------------+