Skip to content
Commit 4ba1eeaa authored by Victor Hsieh's avatar Victor Hsieh
Browse files

Verify the content length in the verity digest

When generating digest for verity, for the last incomplete 4k chunk, the
data is padded with 0s.  This implies that we can not tell from the
digest whether the file contains 0 or not, or how many 0s.

Since the verity hash is used by the kernel, the definition cannot be
change.  Instead, the actual hashed content length is appended to the
original digest and is verified before used.

Also uprev algorithm IDs.

Test: use new apksigner to sign an apk, apk can be installed on device
Bug: 30972906
Change-Id: I382af6e4090c7dc3f92d5acb5ac5d02d1f496992
parent 8c55e8c3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment