I only wanted this in one place, but thought we might as well do it
all in one go.
In a couple of places I added an explicit edition instead of using the
default (whatever that is).
See https://doc.rust-lang.org/edition-guide/rust-2021/index.html.
Test: find . -name "Android.bp" -type f|xargs grep edition | grep -v 2021
Test: atest ComposHostTestCases MicrodroidHostTestCases
Change-Id: I4de050078b303cc5614d230e0d36d5454d60a807
AVF presubmit test config currently runs all tests in the 'presubmit'
group. However, in presubmit the test configs are invoked with all
TEST_MAPPING paths from all affected CLs. Our test config can therefore
run tests from TEST_MAPPINGs outside of the Virtualization repo.
To work around this problem, move all Virtualization tests to
'avf-presubmit' group. Test config running in presubmit will still be
invoked with TEST_MAPPINGs from various repos but only our tests will
match the group.
Rename the postsubmit group to 'avf-postsubmit' for consistency.
Bug: 236755822
Test: atest --test-mapping packages/modules/Virtualization:avf-presubmit
Test: atest --test-mapping packages/modules/Virtualization:avf-postsubmit
Change-Id: I7be5781bef4b6e060a69724c7b4256423adc649c
APKs are brought from tools/apksig/src/test/resources/com/android/apksig
Covered test for all existing v3-only apks at there.
Bug: 233573377
Test: atest libapkverify.integration_test
Change-Id: Icdad3afa352fec2286d70a395f18a0973e6e2def
Get the best APK digest from the APK and include it in the generated
idsig.
Test: atest libidsig.test
Bug: 234564414
Change-Id: If55eab3bb62131bcdb9dfeb6000b9a5ba7ab9236
The v4 signing scheme includes an APK digest to match the strongest
digest available in the v3 or v2. Add a function to extract that digest
from an APK.
Test: libapkverify.test
Bug: 234564414
Change-Id: I69ce9c9c5ff6daf1f09e1bd4620ebf1ce015b5fa
The signing algorithms were already ranked following the order of
preference used by the v4 signing scheme, so there's no functional
change. Documentation is added to make this connection explicit and a
functions for selecting the best signed is factored out.
Test: libapkverify.test
Bug: 234564414
Change-Id: I28e25ce744cbc5854d1cb2b73fee9f966d2f8eb6
Don't mark the tests as host supported as they will otherwise fail when
the server tries to run them as the dependencies don't get bundled
properly.
Test: presbumit
Change-Id: I8ce5a21e5a27e15df1df84ea7d682c24cd8c4d67
Switch to using the certified implementation of cryptographic
algorithms, boringssl, that's available through the openssl crate.
Add an ECDSA signed APK to the test suite to give that algorithm some
coverage.
Bug: 232676161
Test: atest libapkverify.test
Test: atest libapkverify.integration_test
Change-Id: I5f86b40e110d8aaeb22109757253950bd7824833
The library exposes two functions that are just wrappers around the v3
implementation. Make that more clear by simply re-exporting the v3
functions. The TODO for adding v2 support remains.
The documentation is consolidated so the same information remains.
Test: atest libapkverify.test
Change-Id: Id497486dd054474516a664be1539b41732085b79