diff --git a/libwvdrmengine/oemcrypto/odk/include/odk_structs.h b/libwvdrmengine/oemcrypto/odk/include/odk_structs.h index 6b814367..6efce32f 100644 --- a/libwvdrmengine/oemcrypto/odk/include/odk_structs.h +++ b/libwvdrmengine/oemcrypto/odk/include/odk_structs.h @@ -19,7 +19,7 @@ extern "C" { #define ODK_MINOR_VERSION 2 /* ODK Version string. Date changed automatically on each release. */ -#define ODK_RELEASE_DATE "ODK v18.2 2023-07-05" +#define ODK_RELEASE_DATE "ODK v18.2 2023-07-06" /* The lowest version number for an ODK message. */ #define ODK_FIRST_VERSION 16 diff --git a/libwvdrmengine/oemcrypto/odk/src/odk.c b/libwvdrmengine/oemcrypto/odk/src/odk.c index 54e7e996..3e51a90c 100644 --- a/libwvdrmengine/oemcrypto/odk/src/odk.c +++ b/libwvdrmengine/oemcrypto/odk/src/odk.c @@ -473,6 +473,9 @@ OEMCryptoResult ODK_ParseRenewal(const uint8_t* message, size_t message_length, * a new one. We use the timestamp to make sure we have the latest request. * We only do this if playback has already started. This allows us to reload * an offline license and also reload a renewal before starting playback. + * TODO: b/290249855 - This is reversed. It should be "!=" instead of "<". + * We will not fix this in the current release, because it is already in + * production code. Instead, this will be fixed in v19. */ if (clock_values->timer_status != ODK_CLOCK_TIMER_STATUS_LICENSE_LOADED && clock_values->time_of_renewal_request < diff --git a/libwvdrmengine/oemcrypto/odk/test/odk_test.cpp b/libwvdrmengine/oemcrypto/odk/test/odk_test.cpp index 8759c222..4d6b9ef0 100644 --- a/libwvdrmengine/oemcrypto/odk/test/odk_test.cpp +++ b/libwvdrmengine/oemcrypto/odk/test/odk_test.cpp @@ -894,7 +894,10 @@ TEST(OdkTest, ParseRenewalErrorTimer) { uint32_t buf_size = 0; ODK_BuildMessageBuffer(&(params.core_message), params.extra_fields, &buf, &buf_size); - params.clock_values.time_of_renewal_request = 0; + // Set the time for the last renewal request, as seen in clock_values, to be + // after the time in the request. + // TODO: b/290249855 - This is reversed. It should be +5. + params.clock_values.time_of_renewal_request = params.playback_clock - 5; OEMCryptoResult err = ODK_ParseRenewal( buf, buf_size, buf_size, &(params.core_message.nonce_values), params.system_time, &(params.timer_limits), &(params.clock_values),