diff --git a/avbtool.py b/avbtool.py index a56c680..f7111ce 100755 --- a/avbtool.py +++ b/avbtool.py @@ -2424,6 +2424,12 @@ def info_image(self, args): header.public_key_offset) key_blob = vbmeta_blob[key_offset:key_offset + header.public_key_size] + if args.rollback_index_location: + o.write('{}\n'.format(header.rollback_index_location)) + return + if args.rollback_index: + o.write('{}\n'.format(header.rollback_index)) + return if footer: o.write('Footer version: {}.{}\n'.format(footer.version_major, footer.version_minor)) @@ -4530,6 +4536,12 @@ def run(self, argv): help=('Show information about Android Things ' 'eXtension (ATX).'), action='store_true') + sub_parser.add_argument('--rollback_index', + help=('Only rollback_index'), + action='store_true') + sub_parser.add_argument('--rollback_index_location', + help=('Only rollback_index_location'), + action='store_true') sub_parser.set_defaults(func=self.info_image) sub_parser = subparsers.add_parser(