FastbootCmds: oem device-info: check if user public key is set
It is possible to flash to a virtual partition `avb_custom_key` to
set a custom AVB key.
1) generate a custom avb private key
openssl genpkey -algorithm RSA \
-pkeyopt rsa_keygen_bits:4096 \
-outform PEM \
-out key_rsa4096.pem
2) Extract public key usingprivate key
- avbtool extract_public_key --key key_rsa4096.pem --output key_rsa4096.pub
The resulting `key_rsa4096.pub` can be flashed using fastboot:
- fastboot flash avb_custom_key key_ras4096.pub
Afterwards verify that the custom AVB key is set using:
- fastboot oem device-info
You can also use the official AVB repo as reference:
- https://android.googlesource.com/platform/external/avb/+/master/README.md#pixel-2-and-later
Change-Id: I6f65c58dd7f7cbdacfa02464d94815e5e3e6918f
Signed-off-by: Alexander Martinz <amartinz@shiftphones.com>
3 files changed