Update the argument when signing aftl
The arguments transparency_log_servers and transparency_log_pub_keys
have been merged. Update the caller in the OTA script accordingly.
Also disable the test to contact aftl server until we have
a public server.
Bug: 153940575
Test: check the argument
Change-Id: If6a7e7d644884d395c75c2fcdfd6aa7c2380d851
diff --git a/tools/releasetools/common.py b/tools/releasetools/common.py
index ad69fef..47c46a8 100644
--- a/tools/releasetools/common.py
+++ b/tools/releasetools/common.py
@@ -932,8 +932,8 @@
return "{}:{}:{}".format(partition, rollback_index_location, pubkey_path)
-def AddAftlInclusionProof(output_image):
- """Appends the aftl inclusion proof to the vbmeta image."""
+def ConstructAftlMakeImageCommands(output_image):
+ """Constructs the command to append the aftl image to vbmeta."""
# Ensure the other AFTL parameters are set as well.
assert OPTIONS.aftl_tool_path is not None, 'No aftl tool provided.'
@@ -946,17 +946,24 @@
build_info = BuildInfo(OPTIONS.info_dict)
version_incremental = build_info.GetBuildProp("ro.build.version.incremental")
aftltool = OPTIONS.aftl_tool_path
+ server_argument_list = [OPTIONS.aftl_server, OPTIONS.aftl_key_path]
aftl_cmd = [aftltool, "make_icp_from_vbmeta",
"--vbmeta_image_path", vbmeta_image,
"--output", output_image,
"--version_incremental", version_incremental,
- "--transparency_log_servers", OPTIONS.aftl_server,
- "--transparency_log_pub_keys", OPTIONS.aftl_key_path,
+ "--transparency_log_servers", ','.join(server_argument_list),
"--manufacturer_key", OPTIONS.aftl_manufacturer_key_path,
"--algorithm", "SHA256_RSA4096",
"--padding", "4096"]
if OPTIONS.aftl_signer_helper:
aftl_cmd.extend(shlex.split(OPTIONS.aftl_signer_helper))
+ return aftl_cmd
+
+
+def AddAftlInclusionProof(output_image):
+ """Appends the aftl inclusion proof to the vbmeta image."""
+
+ aftl_cmd = ConstructAftlMakeImageCommands(output_image)
RunAndCheckOutput(aftl_cmd)
verify_cmd = ['aftltool', 'verify_image_icp', '--vbmeta_image_path',