diff options
| author | Theofilos Augoustis <theofilos.augoustis@gmail.com> | 2025-10-30 08:52:26 +0000 |
|---|---|---|
| committer | Theofilos Augoustis <theofilos.augoustis@gmail.com> | 2025-10-31 14:27:33 +0000 |
| commit | 03bb1569161ab218827474b8d89c2df6eb306825 (patch) | |
| tree | 71c9bafa97f780b61236aa464dc0bdcac7566d30 | |
| parent | 28d5548aa9e9e99dbab79b97999cc451467705e0 (diff) | |
| download | focaccia-03bb1569161ab218827474b8d89c2df6eb306825.tar.gz focaccia-03bb1569161ab218827474b8d89c2df6eb306825.zip | |
Enable cross-validation with single-stepping in debug mode
| -rw-r--r-- | src/focaccia/symbolic.py | 2 | ||||
| -rwxr-xr-x | src/focaccia/tools/capture_transforms.py | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/focaccia/symbolic.py b/src/focaccia/symbolic.py index 2560c41..4989a48 100644 --- a/src/focaccia/symbolic.py +++ b/src/focaccia/symbolic.py @@ -587,7 +587,7 @@ def run_instruction(instr: miasm_instr, loc = lifter.add_instr_to_ircfg(instr, ircfg, None, False) assert(isinstance(loc, Expr) or isinstance(loc, LocKey)) except NotImplementedError as err: - raise Exception(f'Unable to lift instruction {instr}: {err}. Skipping.') from None + raise Exception(f'Unable to lift instruction {instr}: {err}. Skipping') # Execute instruction symbolically new_pc, modified = execute_location(loc) diff --git a/src/focaccia/tools/capture_transforms.py b/src/focaccia/tools/capture_transforms.py index d742994..23d150d 100755 --- a/src/focaccia/tools/capture_transforms.py +++ b/src/focaccia/tools/capture_transforms.py @@ -73,10 +73,12 @@ def main(): detlog = NullDeterministicLog() env = TraceEnvironment(args.binary, args.args, utils.get_envp(), nondeterminism_log=detlog) - tracer = SymbolicTracer(env, remote=args.remote, cross_validate=args.cross_validate, + tracer = SymbolicTracer(env, remote=args.remote, cross_validate=args.debug, force=args.force) - trace = tracer.trace(start_addr=args.start_address, stop_addr=args.stop_address) + trace = tracer.trace(start_addr=args.start_address, + stop_addr=args.stop_address) + with open(args.output, 'w') as file: parser.serialize_transformations(trace, file) |