Make change and version bump to AV1A.240515.001
Snap for 11830041 from d926fb31ec to vic-widevine-partner-release
Change-Id: Id850f9b967fd599eca001b3c4339198f0330bdec
This commit is contained in:
@@ -98,7 +98,11 @@ fi
|
||||
# If that fails, an error message will be printed.
|
||||
try_adb_push() {
|
||||
# android-tests.zip requires /data/nativetest, we should use the same
|
||||
if [ -f $OUT/data/nativetest/$1 ]; then
|
||||
if [ -f $OUT/data/nativetest64/$1 ]; then
|
||||
test_file=$OUT/data/nativetest64/$1
|
||||
elif [ -f $OUT/data/nativetest64/vendor/$1/$1 ]; then
|
||||
test_file=$OUT/data/nativetest64/vendor/$1/$1
|
||||
elif [ -f $OUT/data/nativetest/$1 ]; then
|
||||
test_file=$OUT/data/nativetest/$1
|
||||
elif [ -f $OUT/data/nativetest/vendor/$1/$1 ]; then
|
||||
test_file=$OUT/data/nativetest/vendor/$1/$1
|
||||
|
||||
@@ -83,7 +83,7 @@ void LicenseHolder::FailReloadLicense() {
|
||||
}
|
||||
|
||||
void LicenseHolder::GenerateAndPostRenewalRequest(
|
||||
const std::string& policy_id) {
|
||||
const std::string& renewal_policy_id) {
|
||||
event_listener_.set_renewal_needed(false);
|
||||
CdmKeyRequest request;
|
||||
const CdmResponseType result =
|
||||
@@ -92,7 +92,7 @@ void LicenseHolder::GenerateAndPostRenewalRequest(
|
||||
if (config_.dump_golden_data()) {
|
||||
MessageDumper::DumpRenewalRequest(request);
|
||||
}
|
||||
const std::string url = MakeUrl(config_.renewal_server(), policy_id);
|
||||
const std::string url = MakeUrl(config_.renewal_server(), renewal_policy_id);
|
||||
request_in_flight_.reset(new UrlRequest(url));
|
||||
ASSERT_TRUE(request_in_flight_->is_connected())
|
||||
<< "Failed for " << content_id();
|
||||
@@ -117,7 +117,7 @@ void LicenseHolder::LoadRenewal() {
|
||||
}
|
||||
|
||||
void LicenseHolder::GenerateAndPostReleaseRequest(
|
||||
const std::string& policy_id) {
|
||||
const std::string& release_policy_id) {
|
||||
event_listener_.set_renewal_needed(false);
|
||||
CdmKeyRequest request;
|
||||
CdmAppParameterMap empty_app_parameters;
|
||||
@@ -134,7 +134,7 @@ void LicenseHolder::GenerateAndPostReleaseRequest(
|
||||
// TODO (b/295956275) vickymin: write DumpReleaseRequest function
|
||||
// MessageDumper::DumpReleaseRequest(request);
|
||||
}
|
||||
const std::string url = MakeUrl(config_.renewal_server(), policy_id);
|
||||
const std::string url = MakeUrl(config_.renewal_server(), release_policy_id);
|
||||
request_in_flight_.reset(new UrlRequest(url));
|
||||
ASSERT_TRUE(request_in_flight_->is_connected())
|
||||
<< "Failed for " << content_id();
|
||||
@@ -262,22 +262,16 @@ void LicenseHolder::GenerateKeyRequest(const InitializationData& init_data,
|
||||
}
|
||||
|
||||
std::string LicenseHolder::MakeUrl(const std::string& server_url,
|
||||
const std::string& policy_id) {
|
||||
const std::string& renewal_policy_id) {
|
||||
// For tests, we want to specify the policy, but the UAT server only allows us
|
||||
// to set the content id as the video_id. So each policy is matched to a
|
||||
// single license with the same name. The local license server, on the other
|
||||
// hand, wants to see the policy id in the url. So we have to guess which
|
||||
// format to use based on the name of the server.
|
||||
const std::string path = server_url + config_.client_auth();
|
||||
std::string video_query;
|
||||
if (!policy_id.empty()) {
|
||||
if (path.find("proxy.uat") != std::string::npos) {
|
||||
// This is uat or uat-nightly. Set the video_id.
|
||||
video_query = "video_id=" + policy_id;
|
||||
} else {
|
||||
// This is probably a local license server. Set the policy.
|
||||
video_query = "policy=" + policy_id;
|
||||
}
|
||||
if (!renewal_policy_id.empty()) {
|
||||
const std::string video_query =
|
||||
"video_id=" + content_id() + "&renewal_policy=" + renewal_policy_id;
|
||||
// If there is already a parameter, then we don't need to add another
|
||||
// question mark.
|
||||
return path + ((path.find('?') == std::string::npos) ? '?' : '&') +
|
||||
|
||||
@@ -69,13 +69,13 @@ class LicenseHolder {
|
||||
// Attempt to reload a license, but expect a failure.
|
||||
void FailReloadLicense();
|
||||
// Generate the renewal request, and send it to the server.
|
||||
void GenerateAndPostRenewalRequest(const std::string& policy_id);
|
||||
void GenerateAndPostRenewalRequest(const std::string& renewal_policy_id);
|
||||
// Fetch the renewal response. This can add a few seconds of latency.
|
||||
void FetchRenewal();
|
||||
// Load the renewal response that was fetched in FetchRenewal().
|
||||
void LoadRenewal();
|
||||
// Generate the release request, and send it to the server.
|
||||
void GenerateAndPostReleaseRequest(const std::string& policy_id);
|
||||
void GenerateAndPostReleaseRequest(const std::string& release_policy_id);
|
||||
// Fetch the release response. This can add a few seconds of latency.
|
||||
void FetchRelease();
|
||||
// Load the release response that was fetched in FetchRelease().
|
||||
@@ -137,7 +137,7 @@ class LicenseHolder {
|
||||
// Generate a URL for the specified policy. The license request should be sent
|
||||
// to this url.
|
||||
std::string MakeUrl(const std::string& server_url,
|
||||
const std::string& policy_id);
|
||||
const std::string& renewal_policy_id);
|
||||
// Fetch the key response from the server.
|
||||
void GetKeyResponse(const CdmKeyRequest& key_request);
|
||||
};
|
||||
|
||||
@@ -25,11 +25,15 @@ LOCAL_STATIC_LIBRARIES := \
|
||||
libcdm_protos \
|
||||
libcdm_utils \
|
||||
libjsmn \
|
||||
libjsoncpp \
|
||||
libgmock \
|
||||
libgmock_main \
|
||||
libgtest \
|
||||
libwvaidl \
|
||||
libwvdrmcryptoplugin_aidl \
|
||||
libwvlevel3 \
|
||||
libwv_odk \
|
||||
libPlatformProperties \
|
||||
|
||||
LOCAL_SHARED_LIBRARIES := \
|
||||
android.hardware.drm-V1-ndk \
|
||||
@@ -41,7 +45,6 @@ LOCAL_SHARED_LIBRARIES := \
|
||||
liblog \
|
||||
libprotobuf-cpp-lite \
|
||||
libutils \
|
||||
libwvaidl \
|
||||
wv_media_drm_flags_c_lib \
|
||||
|
||||
LOCAL_HEADER_LIBRARIES := \
|
||||
|
||||
@@ -22,14 +22,20 @@ LOCAL_C_INCLUDES := \
|
||||
|
||||
LOCAL_STATIC_LIBRARIES := \
|
||||
libcdm \
|
||||
libcdm_utils \
|
||||
libcutils \
|
||||
libcdm_protos \
|
||||
libcdm_utils \
|
||||
libjsmn \
|
||||
libjsoncpp \
|
||||
libgmock \
|
||||
libgmock_main \
|
||||
libgtest \
|
||||
libwvaidl \
|
||||
libwvdrmdrmplugin_aidl \
|
||||
libwvlevel3 \
|
||||
libwv_odk \
|
||||
libPlatformProperties \
|
||||
|
||||
LOCAL_SHARED_LIBRARIES := \
|
||||
android.hardware.drm-V1-ndk \
|
||||
@@ -40,7 +46,6 @@ LOCAL_SHARED_LIBRARIES := \
|
||||
liblog \
|
||||
libprotobuf-cpp-lite \
|
||||
libutils \
|
||||
libwvaidl \
|
||||
wv_media_drm_flags_c_lib \
|
||||
|
||||
LOCAL_HEADER_LIBRARIES := \
|
||||
@@ -92,6 +97,8 @@ LOCAL_STATIC_LIBRARIES := \
|
||||
libgtest \
|
||||
libgtest_main \
|
||||
libjsmn \
|
||||
libwvaidl \
|
||||
libwvdrmdrmplugin_aidl \
|
||||
libwvlevel3 \
|
||||
libwv_odk \
|
||||
|
||||
@@ -101,7 +108,6 @@ LOCAL_SHARED_LIBRARIES := \
|
||||
liblog \
|
||||
libprotobuf-cpp-lite \
|
||||
libutils \
|
||||
libwvaidl \
|
||||
|
||||
LOCAL_C_INCLUDES += \
|
||||
external/protobuf/src \
|
||||
|
||||
@@ -26,9 +26,9 @@ struct CoreMessageFeatures {
|
||||
|
||||
// This is the published version of the ODK Core Message library. The default
|
||||
// behavior is for the server to restrict messages to at most this version
|
||||
// number. The default is 19.0.
|
||||
// number. The default is 19.1.
|
||||
uint32_t maximum_major_version = 19;
|
||||
uint32_t maximum_minor_version = 0;
|
||||
uint32_t maximum_minor_version = 1;
|
||||
|
||||
bool operator==(const CoreMessageFeatures &other) const;
|
||||
bool operator!=(const CoreMessageFeatures &other) const {
|
||||
|
||||
@@ -16,10 +16,10 @@ extern "C" {
|
||||
|
||||
/* The version of this library. */
|
||||
#define ODK_MAJOR_VERSION 19
|
||||
#define ODK_MINOR_VERSION 0
|
||||
#define ODK_MINOR_VERSION 1
|
||||
|
||||
/* ODK Version string. Date changed automatically on each release. */
|
||||
#define ODK_RELEASE_DATE "ODK v19.0 2024-03-22"
|
||||
#define ODK_RELEASE_DATE "ODK v19.1 2024-03-25"
|
||||
|
||||
/* The lowest version number for an ODK message. */
|
||||
#define ODK_FIRST_VERSION 16
|
||||
|
||||
@@ -33,7 +33,7 @@ CoreMessageFeatures CoreMessageFeatures::DefaultFeatures(
|
||||
features.maximum_minor_version = 4; // 18.4
|
||||
break;
|
||||
case 19:
|
||||
features.maximum_minor_version = 0; // 19.0
|
||||
features.maximum_minor_version = 1; // 19.1
|
||||
break;
|
||||
default:
|
||||
features.maximum_minor_version = 0;
|
||||
|
||||
@@ -276,6 +276,9 @@ OEMCryptoResult ODK_InitializeSessionValues(ODK_TimerLimits* timer_limits,
|
||||
case 18:
|
||||
nonce_values->api_minor_version = 4;
|
||||
break;
|
||||
case 19:
|
||||
nonce_values->api_minor_version = 1;
|
||||
break;
|
||||
default:
|
||||
nonce_values->api_minor_version = 0;
|
||||
break;
|
||||
|
||||
@@ -1275,7 +1275,7 @@ std::vector<VersionParameters> TestCases() {
|
||||
{16, ODK_MAJOR_VERSION, ODK_MINOR_VERSION, 16, 5},
|
||||
{17, ODK_MAJOR_VERSION, ODK_MINOR_VERSION, 17, 2},
|
||||
{18, ODK_MAJOR_VERSION, ODK_MINOR_VERSION, 18, 4},
|
||||
{19, ODK_MAJOR_VERSION, ODK_MINOR_VERSION, 19, 0},
|
||||
{19, ODK_MAJOR_VERSION, ODK_MINOR_VERSION, 19, 1},
|
||||
// Here are some known good versions. Make extra sure they work.
|
||||
{ODK_MAJOR_VERSION, 16, 3, 16, 3},
|
||||
{ODK_MAJOR_VERSION, 16, 4, 16, 4},
|
||||
@@ -1287,13 +1287,16 @@ std::vector<VersionParameters> TestCases() {
|
||||
{ODK_MAJOR_VERSION, 18, 3, 18, 3},
|
||||
{ODK_MAJOR_VERSION, 18, 4, 18, 4},
|
||||
{ODK_MAJOR_VERSION, 19, 0, 19, 0},
|
||||
{ODK_MAJOR_VERSION, 19, 1, 19, 1},
|
||||
{0, 16, 3, 16, 3},
|
||||
{0, 16, 4, 16, 4},
|
||||
{0, 16, 5, 16, 5},
|
||||
{0, 17, 1, 17, 1},
|
||||
{0, 17, 2, 17, 2},
|
||||
{0, 18, 3, 18, 3}, // Change to 19 when the default version is updated.
|
||||
{0, 18, 3, 18, 3},
|
||||
{0, 18, 4, 18, 4},
|
||||
{0, 19, 0, 19, 0},
|
||||
{0, 19, 1, 19, 1},
|
||||
};
|
||||
return test_cases;
|
||||
}
|
||||
|
||||
@@ -49,6 +49,7 @@ LOCAL_C_INCLUDES += \
|
||||
|
||||
LOCAL_STATIC_LIBRARIES := \
|
||||
libcdm \
|
||||
libcppbor \
|
||||
libjsmn \
|
||||
libgmock \
|
||||
libgtest \
|
||||
@@ -62,7 +63,6 @@ LOCAL_STATIC_LIBRARIES := \
|
||||
|
||||
LOCAL_SHARED_LIBRARIES := \
|
||||
libbase \
|
||||
libcppbor \
|
||||
libcrypto \
|
||||
libdl \
|
||||
libbinder_ndk \
|
||||
|
||||
@@ -544,7 +544,7 @@ TEST_P(OEMCryptoSessionTestsDecryptTests, DecryptZeroSizeSubSample) {
|
||||
ASSERT_NO_FATAL_FAILURE(LoadLicense());
|
||||
ASSERT_NO_FATAL_FAILURE(MakeBuffers());
|
||||
ASSERT_NO_FATAL_FAILURE(EncryptData());
|
||||
ASSERT_NO_FATAL_FAILURE(TestDecryptCENC());
|
||||
ASSERT_NO_FATAL_FAILURE(DecryptCENC());
|
||||
}
|
||||
|
||||
// There are probably no frames this small, but we should handle them anyway.
|
||||
|
||||
@@ -635,6 +635,9 @@ TEST_P(OEMCryptoLicenseTest, EntitledKeySessionsAPI17) {
|
||||
if (wvoec::global_features.api_version < 17) {
|
||||
GTEST_SKIP() << "Test for versions 17 and up only.";
|
||||
}
|
||||
if (!global_features.supports_cas) {
|
||||
GTEST_SKIP() << "OEMCrypto does not support CAS";
|
||||
}
|
||||
license_messages_.set_license_type(OEMCrypto_EntitlementLicense);
|
||||
ASSERT_NO_FATAL_FAILURE(license_messages_.SignAndVerifyRequest());
|
||||
ASSERT_NO_FATAL_FAILURE(license_messages_.CreateDefaultResponse());
|
||||
|
||||
@@ -27,7 +27,8 @@ elif [ 0 -eq `expr index "$GTEST_FILTER" "-"` ]; then
|
||||
fi
|
||||
|
||||
# The Android supplement allows for installation in these paths:
|
||||
OEC_PATHS=/system/lib64:/system/lib/:/vendor/lib64:/vendor/lib:/system/lib64/vndk-R:/system/lib/vndk-R
|
||||
OEC_PATHS=/apex/com.google.android.widevine/lib64:/apex/com.google.android.widevine/lib:
|
||||
OEC_PATHS+=/system/lib64:/system/lib/:/vendor/lib64:/vendor/lib:/system/lib64/vndk-R:/system/lib/vndk-R
|
||||
|
||||
# Execute a command in "adb shell" and capture the result.
|
||||
adb_shell_run() {
|
||||
@@ -49,7 +50,8 @@ adb_shell_run() {
|
||||
# to load. We must reverse the library path in this case so we don't attempt
|
||||
# to load 64-bit libraries with the 32-bit liboemcrypto.so.
|
||||
if ! adb $SERIAL_NUM shell ls /vendor/lib64/liboemcrypto.so &> /dev/null; then
|
||||
OEC_PATHS=/system/lib:/system/lib64/:/vendor/lib:/vendor/lib64:/system/lib/vndk-R:/system/lib64/vndk-R
|
||||
OEC_PATHS=/apex/com.google.android.widevine/lib:/apex/com.google.android.widevine/lib64:
|
||||
OEC_PATHS+=/system/lib:/system/lib64/:/vendor/lib:/vendor/lib64:/system/lib/vndk-R:/system/lib64/vndk-R
|
||||
fi
|
||||
adb $SERIAL_NUM shell "LD_LIBRARY_PATH=$OEC_PATHS GTEST_FILTER=$GTEST_FILTER $@ $test_file" \|\| echo "$adb_error" | tee "$tmp_log"
|
||||
! grep -Fq "$adb_error" "$tmp_log"
|
||||
|
||||
@@ -19,18 +19,32 @@ LOCAL_C_INCLUDES := \
|
||||
vendor/widevine/libwvdrmengine/oemcrypto/include \
|
||||
|
||||
LOCAL_STATIC_LIBRARIES := \
|
||||
libaidlcommonsupport \
|
||||
libgtest \
|
||||
libgtest_main \
|
||||
libjsmn \
|
||||
libjsoncpp \
|
||||
libcdm \
|
||||
libcdm_protos \
|
||||
libcdm_utils \
|
||||
libwvdrmcryptoplugin_aidl \
|
||||
libwvdrmdrmplugin_aidl \
|
||||
libwvlevel3 \
|
||||
libwv_odk \
|
||||
libwvaidl \
|
||||
libPlatformProperties \
|
||||
|
||||
LOCAL_SHARED_LIBRARIES := \
|
||||
android.hardware.drm-V1-ndk \
|
||||
libbase \
|
||||
libbinder_ndk \
|
||||
libcrypto \
|
||||
libcutils \
|
||||
libdl \
|
||||
liblog \
|
||||
libprotobuf-cpp-lite \
|
||||
libutils \
|
||||
libwvaidl \
|
||||
wv_media_drm_flags_c_lib \
|
||||
|
||||
LOCAL_HEADER_LIBRARIES := \
|
||||
libstagefright_foundation_headers \
|
||||
|
||||
@@ -1 +1 @@
|
||||
AV1A.240428.001
|
||||
AV1A.240515.001
|
||||
|
||||
Reference in New Issue
Block a user