text
stringlengths
0
1.99k
instruction count measures the symbolic-emulation workload per sample and
serves as a proxy for the slice's complexity. The more instructions
executed under symbolic semantics, the broader the data-flow fan-out
across registers and memory. By normalizing mutation priorities against
this metric, E0 favors inputs that exercise larger slices of
data-dependent code, increasing the chance of uncovering vulnerabilities
requiring complex arithmetic or multi-step memory manipulations.
---------------------------------------------------------------------------
4 | Hash of Unique Emulated Instruction Addresses per Run
---------------------------------------------------------------------------
To detect overlapping symbolic-emulation regions across samples, E0
maintains a running, order-insensitive hash over the set of all unique
instruction (RVA) relative virtual addresses emulated under symbolic mode
across all sessions, modules, and threads. Each time Triton symbolically
processes an instruction, E0 inserts its address into a global hash
accumulator. At the end of the run, this accumulator represents the
"symbolic footprint" of that sample. Comparing hash values between runs
reveals whether two samples touched the same set of data-dependent
instructions (regardless of execution order or frequency). Distinct hashes
indicate that a new sample has uncovered previously unexplored symbolic
paths; identical hashes suggest redundant coverage. This high-resolution
fingerprint far surpasses basic-block bitmaps by accounting for
instruction-level context, multi-module interactions, and multi-threaded
execution.
---------------------------------------------------------------------------
5 | Unique SymDef ID Count per Run
---------------------------------------------------------------------------
Each time E0 captures a symbolic definition (SymDef), it checks whether
that SymDef ID has been seen in previous runs. If not, the SymDef is
marked as unique for this sample. The total number of unique SymDef IDs
captured in a run reflects the number of new function-boundary propagation
points discovered during execution. A higher count indicates that symbolic
input has reached new regions of code and crossed additional def-use
boundaries, expanding the observed symbolic data-flow graph. This simple
metric helps identify samples that extend input influence into unexplored
functions or modules.
---------------------------------------------------------------------------
Because these metrics span from broad-level (session count) to fine-
grained (instruction-address hash), E0 combines them into a unified
data-flow coverage score that prioritizes samples driving novel or deeper
symbolic activity; those that spawn new emulation sessions, introduce
additional symbolic definitions, exercise previously unseen emulated
instructions, or previously unseen symdefs. By focusing on inputs that
uncover fresh data-flow frontiers rather than merely toggling basic-block
bits, E0 rapidly directs exploration toward code regions where untrusted
input meaningfully influences computation.
This data-flow orientation yields key benefits: precise tracking of how
untrusted bytes propagate; reduced redundancy through instruction-level
hashing and definition counts; and comprehensive cross-module, cross-
thread coverage via a unified instruction-address footprint. In short,
Data-Flow Coverage Guidance transforms low-level symbolic events into
high-resolution signals, enabling E0 to probe untrusted data paths with
surgical accuracy and accelerate the discovery of deep, semantically
relevant vulnerabilities.
--[ 9 - Fine-Grained Memory Instrumentation via Hardware Watchpoints
Page-level guarding introduced severe performance penalties and didn't
scale. To address this, E0 falls back on the CPU's built-in hardware
watchpoints, which can monitor much smaller, power-of-two-aligned (address
and size) regions within a page. Because each core only provides four
debug registers, we employ a hierarchical bitmap and recursive splitting
algorithm to efficiently carve a 16 KB page into at most four minimally
sized watchpoint blocks, often using even fewer when possible.
.------------------------------------------------------------------.
| Hardware Watchpoint Constraints |
| |
| - Only four watchpoints per core |
| - Each WP must cover a 2^N-byte region, aligned to its size |
| - Any untracked byte in that region still fires an exception |
| - Scattered inputs force oversized regions -> spurious traps. |
'------------------------------------------------------------------'
Tracking an arbitrary set of bytes inside a 16KB page requires carving
that page into smaller power-of-two blocks. To do this efficiently, and
within the constraint of only four hardware watchpoint slots, we use a
three-level bitmap hierarchy and a recursive splitting strategy:
rootBitmap -> pageSegments -> pageQwords
[ Page (16KB) ]
|
.---v---. Level 1: 32 segments (512B each)
| seg | rootBitmap -> 1...0...1...0... (1 bit per 512B segment)
'-------'
|
.---v---. Level 2: 64 qwords per segment (8B each)
| qword | pageSegments[n] -> 0x... (1 bit per 8B qword)
'-------'
|
.---v---. Level 3: byte mask per qword
| byte | pageQwords[i] -> 0b10110010 (1 bit per byte in the qword)
'-------'
1. Level 1 (root): A 32-bit root bitmap marks which 512B segments contain
any tracked byte.
2. Level 2 (segments): For each set bit, a 64-bit segment mask identifies