from pathlib import Path import struct,hashlib,json,argparse parser=argparse.ArgumentParser(description='Independent ELF64 little-endian native-command byte oracle');parser.add_argument('--input',type=Path,required=True);parser.add_argument('--output',type=Path,required=True);args=parser.parse_args();path=args.input;b=path.read_bytes();assert b[:6]==b'\x7fELF\x02\x01' shoff=struct.unpack_from('=name if names[name:end] not in [b'execute_command',b'execute_command_internal'] or info&15!=2:continue target=sections[section];file_offset=target[4]+value-target[3] assert target[4]<=file_offset and file_offset+size<=target[4]+target[5] rows.append({'symbol_table_section':si,'symbol_ordinal':ordinal,'name':names[name:end].decode('ascii'),'address':value,'bytes':size,'file_offset':file_offset,'first_16_bytes_hex':b[file_offset:file_offset+16].hex()}) assert rows result={'path':str(path),'artifact_sha256':hashlib.sha256(b).hexdigest(),'artifact_bytes':len(b),'elf_class':64,'byte_order':'little','elf_machine':struct.unpack_from('