Skip to content
Book Open access

Lifting Hermes Bytecode to P-Code: A Ghidra Extension for Reverse Engineering React Native Apps

Nov 2026 · Proceedings of the 2026 2nd Workshop on Software Understanding and Reverse Engineering · 0 citations · 12 references

Abstract

React Native applications increasingly ship JavaScript logic as Hermes bytecode, a custom virtual-machine format that is not supported by mainstream reverse-engineering tools. We present HermesLoader, a Ghidra extension that loads Hermes bytecode, lifts it to Ghidra’s P-code intermediate representation, and exposes the resulting program through Ghidra’s standard disassembly, decompilation, navigation, and cross-reference workflows. The extension combines a SLEIGH specification for Hermes bytecode version 96 with a loader that reconstructs bytecode containers as typed program objects and a small set of Hermes-specific enrichment passes for strings, field-access chains, aggregate literals, and selected function references. We evaluate the implementation on source-generated Hermes bytecode samples compiled under multiple configurations. The lifter implements all 206 opcodes in version 96; our test corpus generates 199 of them and shows broad agreement with the reference hermesc disassembly. Remaining differences are mostly representational, with incomplete recovery of some table-driven control-flow targets as the main semantic limitation. These results show that Hermes bytecode can be integrated into Ghidra as a practical basis for interactive React Native reverse engineering.

Read PDF

We use cookies to run the site and, with your consent, for analytics and to show ads. See our Cookie Policy.