Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 78479274 authored by Brint E. Kriebel's avatar Brint E. Kriebel
Browse files

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
parent b77db58c
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -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.