This commit is contained in:
Jean-Marie Mineau 2024-11-05 16:27:03 +01:00
parent f5ecee8d78
commit faf3b80871

View file

@ -248,6 +248,12 @@ def check_smali():
type=Path,
required=True,
)
parser.add_argument(
"--out",
help="Path to the file where to store the results",
type=Path,
required=True,
)
key_parser = parser.add_mutually_exclusive_group(required=False)
key_parser.add_argument(
"--api-key-file",
@ -335,4 +341,12 @@ def check_smali():
elif smali != smali_new:
dist_dup_classes.add(cl)
data[sha256]["redef_classes"] = list(dist_dup_classes)
print(json.dumps(data))
if data[sha256]["redef_classes"]:
print(f"{sha256}:")
for c in data[sha256]["redef_classes"]:
print(f" {c}")
else:
print(f"{sha256}: No true redefinition")
with args.out.open("w") as f:
json.dump(data, f)