Exploit databaseDownload repository ZIP
GH-e6e5922ef9ac5cc7d4897803cb452516
zero2005x/rokid-rv101-research
Sources for CVE-2026-43499
168 sourcesPreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source
Repository files15
zero2005x/rokid-rv101-researchRevision c74832d113c5
- ↑..Parent directory
- btf_parse.py
- btf_var.py
- dump_axml.py
- dump_jumptable.py
- dump_waiter_btf.py
- fingerprint.py
- ikconfig.py
- parse_arsc.py
- parse_boot.py
- parse_erofs.py
- parse_symtab.py
- pe_parse.py
- read_imgheader.py
- read_miscdev.py
- read_vars.py
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
research/ghostlock_refs/extracted/honor/cve-2026-43499-honor-main/scripts/parse/read_imgheader.py
Python · 1,534 bytes#!/usr/bin/env python3
# -*- coding: utf-8 -*-
import struct
k = open(r"D:\新建文件夹 (4)\root\545\unpacked\kernel.bin", "rb").read()
# ARM64 Linux Image header (boot protocol)
code0 = struct.unpack("<I", k[0x00:0x04])[0]
text_off= struct.unpack("<Q", k[0x08:0x10])[0]
img_size= struct.unpack("<Q", k[0x10:0x18])[0]
flags = struct.unpack("<Q", k[0x18:0x20])[0]
res2 = struct.unpack("<Q", k[0x20:0x28])[0]
res3 = struct.unpack("<Q", k[0x28:0x30])[0]
res4 = struct.unpack("<Q", k[0x30:0x38])[0]
magic = k[0x38:0x3c].decode('latin1')
res5 = struct.unpack("<I", k[0x3c:0x40])[0]
print(f"code0 = {code0:#010x}")
print(f"text_offset = {text_off:#018x} ({text_off} = {'TEXT_OFFSET (text 相对物理加载基址偏移)'})")
print(f"image_size = {img_size:#018x} ({img_size})")
print(f"flags = {flags:#018x} (LE=bit0 {'SET' if flags&1 else 'clear'}, BE=bit1 {'SET' if flags&2 else 'clear'})")
print(f"magic = {magic!r} (应为 'ARM\\x64')")
# PE 头 ImageBase(虚拟基址)
pe_off = struct.unpack("<I", k[0x3c:0x40])[0]
print(f"\nPE header offset = {pe_off:#x}")
if k[pe_off:pe_off+4] == b'PE\x00\x00':
# COFF header 后是 Optional header (PE32+ 因为 64-bit)
opt = pe_off + 4 + 20
magic_opt = struct.unpack("<H", k[opt:opt+2])[0]
print(f"Optional header magic = {magic_opt:#x} ({'PE32+' if magic_opt==0x20b else 'PE32'})")
if magic_opt == 0x20b:
image_base = struct.unpack("<Q", k[opt+24:opt+32])[0]
print(f"ImageBase (虚拟) = {image_base:#018x}")