Address offline playback with rollbacked time

Merge from http://go/wvgerrit/47640

Test: unit/integration tests

Bug: b/62058202

The usage table keeps track of license duration by using the current
system time. However, if a user were to rollback the time, they can
effectively continue offline playback indefinitely. This changes the way
we compute time by computing offsets by which the user rollbacked the
time and adding it to the current time. This change also includes a test
to verify protection against rollback for usage entries that is only run
when the user is root.

Change-Id: I97c430e1443747b0f9759ae5390b8f5d06bdebf1
This commit is contained in:
Srujan Gaddam
2018-04-05 11:29:53 -07:00
parent d873f40d80
commit 73c3007c24
10 changed files with 692522 additions and 707026 deletions

File diff suppressed because it is too large Load Diff