Using the binder object we can directly get names of interfaces
rather than hardcoding the strings. This allows for lookup to be easier.
Test: atest keystore2_test and atest CtsKeystoreTestCases
Bug: 249096262
Change-Id: I74bc696b860e2c08286b1d5175378e8d44728858
Fix for regression in aosp/2453685, this gets the
version of keymint that is on the device.
Test: atest keystore2_test
Bug: 275589241 276396649
Change-Id: I2afe1472a0a4e3c4f81379c589833285bb228811
The RkpPoolStats atom has been moved from keystore2 into rkpd, so
we no longer need to query it from keystore2.
Bug: 268247931
Test: presubmit
Change-Id: I285011ed29183e3008310be248ddeb8b9668ac01
Support for listing key entries in batches, so that a large number of
key entries, or entries with long key aliases, could be listed.
The list of key descriptors (which contain the key alias) is returned
to JCA from Keystore2 service via the Binder interface.
The size of a single Binder transaction is limited. Thus, we have run
into http://b/222287335 , where an app can create too many Keystore2
keys than can be returned in a single Binder transaction. Effectively,
this prevents the app from listing the keys it generated at all.
This is solved by adding a method to the Keystore2 interface for
obtaining all the key descriptors whose alias is past a given value
(with the intention that this value is the last key alias from the
previous batch). Keystore2 already limits the number of entries
returned to a number estimated to fit under the Binder transaction size
limit. Together, this enables callers to receive the list of key
descriptors in batches.
Additionally, add a method to Keystore2 to return the total number of
key entries by querying the DB for the number of rows, rather than count
the number of entries returned (which may be truncated).
Bug: 222287335
Test: atest KeystoreTests
Test: atest CtsKeystoreTestCases:android.keystore.cts.AndroidKeyStoreTest
Test: atest keystore2_test
Change-Id: I4a8efef2303beadd2cf6db992833d87bf58d7aec
These interfaces are deprecated and replaced by
android.security.rkp_aidl ones.
Bug: 273325840
Change-Id: I6f561d7c332fc3cc5921453b5bd5938154b700d0
Test: m
These interfaces are deprecated and replaced by
android.security.rkp_aidl ones.
Bug: 273325840
Test: m
Change-Id: I888ded721341ab6e6e89fe236c8fb0f7e6122b74
The data format changed a bit, and the fingerprint needs to be included
at the end of the CSRv3 data. Make sure to include that, else the RKP
server rejects the payload.
Test: run tool + upload output
Test: rkp_factory_extraction_lib_test
Change-Id: I5a13b21e65c64f19b9417a7d1e169710867e7a8f
The code is mostly from credstore. The intention here is that we replace
that code with a common library.
Test: librkp_support_test
Change-Id: I28ebc5a253c037277dad6d39b761b4e8aa4347e8
Reads on `tokio::fs::File` are expected to block, and are performed
inside a `spawn_blocking` call so that they don't block the reactor.
Bug: 268075535
Test: read from /dev/socket/prng_seeder 256 times
Change-Id: I009d1fb11b540412e705cc2be0ebc7e2f09d2c0c
This CL replaces the usage of the core::slice::memchr function with
calls to std::iter::position.
Test: m keystore2_unsafe_fuzzer
Test: TH
Bug: 267698452
Change-Id: I33cab09176d0ff02ce092e240e887ece98728915
Aidl Instances can be gotten from the binder with
get_declared_instances.
Test: m keystore2 && m keystore2_unsafe_fuzzer
Change-Id: I36b4bdb8de6dd8abedf50d2026d1d841ce27c55d
This cl arranges the source code of sample_inputs and its integration
test diced_open_dice_cbor_test in one place.
Bug: 268322533
Test: m microdroid_manager
Test: atest libdiced_sample_inputs.integration_test
Change-Id: I33831b20d719ab43d96b3affb8f478db42ca2739