diff --git a/tools/releasetools/sign_target_files_apks.py b/tools/releasetools/sign_target_files_apks.py index b11225c18..3ab4a2c1d 100755 --- a/tools/releasetools/sign_target_files_apks.py +++ b/tools/releasetools/sign_target_files_apks.py @@ -255,6 +255,7 @@ def ProcessTargetFiles(input_tf_zip, output_tf_zip, misc_info, elif (OPTIONS.replace_ota_keys and info.filename in ( "BOOT/RAMDISK/res/keys", + "BOOT/RAMDISK/etc/update_engine/update-payload-key.pub.pem", "RECOVERY/RAMDISK/res/keys", "SYSTEM/etc/security/otacerts.zip", "SYSTEM/etc/update_engine/update-payload-key.pub.pem")): @@ -510,6 +511,10 @@ def ReplaceOtaKeys(input_tf_zip, output_tf_zip, misc_info): output_tf_zip, "SYSTEM/etc/update_engine/update-payload-key.pub.pem", pubkey) + common.ZipWriteStr( + output_tf_zip, + "BOOT/RAMDISK/etc/update_engine/update-payload-key.pub.pem", + pubkey) return new_recovery_keys