text stringlengths 0 1.99k |
|---|
- Opcode fingerprint (MEM) or edge RVA |
(RET: callee->caller, ARG: caller->callee) |
- 8-bit argument mask (ARG only) |
--------------------------------------------------------------------------- |
SymDef IDs are computed as follows: |
--------------------------------------------------------------------------- |
// MEM (load) definitions |
uint64_t symdef_mem = |
((uint64_t)pc_rva << 32) |
| *reinterpret_cast<const uint32_t*>(instruction.getOpcode()); |
// RET (return) definitions |
uint64_t symdef_ret = |
((uint64_t)return_target_rva << 32) |
| ret_instruction_rva; |
// ARG (call) definitions |
uint64_t base = ((uint64_t)called_function_rva << 32) |
| call_site_rva; |
uint64_t cleared = base & 0x00FFFFFFFFFFFFFFULL; // clear bits 56-63 |
uint64_t symdef_arg = ((uint64_t)sym_args_mask << 56) | cleared; |
--------------------------------------------------------------------------- |
Invocation IDs then build on the SymDef ID by adding AST complexity: |
--------------------------------------------------------------------------- |
uint64_t invocation = symdef /* _mem, _ret or _arg */ |
+ Ast->getLevel(); |
E0 stores both each SymDef ID and its corresponding invocation IDs |
(SymDef ID + AST level) in its local SQLite database for de-duplication |
and coverage tracking. In the future, we may incorporate a module-name |
hash into the RVA to guard against any potential collisions, but to date |
this simple 64-bit packing scheme has produced no ID conflicts. |
--[ 8 - Data-Flow Coverage Metrics |
Building on the selective symbolic instrumentation framework and the |
symbolic definitions described in previous sections, E0 replaces |
traditional, bitmap-based code-coverage metrics with a suite of high- |
resolution data-flow coverage signals. Conventional coverage relies on a |
bitmap, one bit per basic block or edge, to record whether a region has |
been exercised, but this low-resolution mechanism ignores semantic |
relevance. In practice, two inputs may mark the same basic blocks as |
covered, yet one may carry no untrusted input into a critical function |
argument while the other precisely steers untrusted bytes into a |
vulnerable buffer. Data-Flow Coverage Guidance, by contrast, captures |
exactly which instructions, and at which points in the def-use graph, are |
influenced by symbolic ("guarded") inputs. Whenever a guarded memory load |
produces a new symbolic operand, E0 invokes Triton to launch a targeted |
emulation slice and logs a set of "Symbolic Definitions" (ARG, MEM, RET) |
that record the precise ASTs showing how input bytes flow into registers |
or memory. |
Over the course of a single sample run, unlike code-coverage guidance |
which typically instruments only one or few modules, our data-flow |
approach fuses these definitions across all modules and threads to |
construct a coherent, per-instruction map of data-flow. By tracking |
symbolic dependencies at this level, E0 can distinguish execution paths |
that visit identical basic blocks but differ in how untrusted bytes |
influence computation. This finer granularity enables more efficient |
sample mutation, reduces blind fuzzing on semantically irrelevant code |
paths, and supplies downstream layers (SMT solver and LLM) with richer, |
contextually precise information. |
This fine-grained, instruction-level data-flow mapping supports multiple |
quantitative metrics, ranging from higher-level, less precise signals to |
lower-level, more precise signals, that E0 collects to guide data-flow |
coverage: |
--------------------------------------------------------------------------- |
1 | Symbolic Emulation Session Count per Run |
--------------------------------------------------------------------------- |
Each time a guarded memory load produces a new symbolic operand, E0 |
invokes Triton to launch a targeted emulation slice. The total number of |
such emulation slices/sessions per sample indicates how many distinct |
data-dependent "frontiers" the input has exercised. A higher session count |
implies deeper penetration into the def-use graph, reflecting multiple |
layers of data propagation. By tracking this count over time, the system |
deprioritizes further mutations of inputs that repeatedly trigger the same |
sessions and instead focuses on samples that spawn novel emulation slices. |
--------------------------------------------------------------------------- |
2 | Symbolic Definition Count per Run |
--------------------------------------------------------------------------- |
Within each emulation session, E0 logs every new symbolic definition, |
whether it arises from a guarded memory load (MEM), a function-call |
argument boundary (ARG), or a return value (RET). Recording the total |
number of definitions per sample run provides insight into (a) the depth |
of def-use propagation (for example, whether untrusted bytes reached |
multiple function boundaries) and (b) the exact points where input-derived |
data influenced control flow or memory. By comparing this count against |
previous runs, E0 identifies samples that expose new combinations of |
data-flow events, even if they traverse identical basic blocks. |
--------------------------------------------------------------------------- |
3 | Emulated Instructions Count per Run |
--------------------------------------------------------------------------- |
Not all instructions in a targeted emulation slice involve symbolic |
operands; nevertheless, E0 counts every instruction that Triton processes |
under ONLY_ON_SYMBOLIZED mode from the moment a guarded load triggers |
emulation until all live symbolic registers have been concretized. This |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.