diff options
author | Brint E. Kriebel <bekit@cyngn.com> | 2016-02-16 17:47:46 -0800 |
---|---|---|
committer | Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de> | 2016-02-20 12:06:10 +0100 |
commit | 700d8f580e79ddc2f853cec8acc848706cbcbff5 (patch) | |
tree | 9637ff0c7500c186ffbbb3da4b2906d3670b41cb /tools | |
parent | 6d288053d3aa058c4f818109b872ac9984694efb (diff) | |
download | build-700d8f580e79ddc2f853cec8acc848706cbcbff5.zip build-700d8f580e79ddc2f853cec8acc848706cbcbff5.tar.gz build-700d8f580e79ddc2f853cec8acc848706cbcbff5.tar.bz2 |
releasetools: Store the proper base64 release key in the target files
This code was dropped when the original change
(I7528a8e7c484ea9209cd665b9263328ae834586a) was cherry-picked into 13.0.
Add it back in to the sign_target_files_apks.py file.
Change-Id: I0177a7d2a39ae03b21d0b2b4ad48a621ca5afd7b
Ticket: CYNGNOS-2067
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/releasetools/sign_target_files_apks.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tools/releasetools/sign_target_files_apks.py b/tools/releasetools/sign_target_files_apks.py index ed7a4b7..abdb845 100755 --- a/tools/releasetools/sign_target_files_apks.py +++ b/tools/releasetools/sign_target_files_apks.py @@ -398,6 +398,14 @@ def ReplaceOtaKeys(input_tf_zip, output_tf_zip, misc_info): common.ZipWriteStr(output_tf_zip, "RECOVERY/RAMDISK/res/keys", new_recovery_keys) + # Save the base64 key representation in the update for key-change + # validations + p = common.Run(["python", "build/tools/getb64key.py", mapped_keys[0]], + stdout=subprocess.PIPE) + data, _ = p.communicate() + if p.returncode == 0: + common.ZipWriteStr(output_tf_zip, "META/releasekey.txt", data) + # SystemUpdateActivity uses the x509.pem version of the keys, but # put into a zipfile system/etc/security/otacerts.zip. # We DO NOT include the extra_recovery_keys (if any) here. |