13 Commits
Author SHA1 Message Date
Willi Ballenthin 38b1baa98c Migrate API handlers to ctx.args
Handlers set the report display of an argument through ctx.args, by
parameter name where the signature is usable on x86 and x64 and by slot
index otherwise. argv holds the raw slots, and the transitional copy of
argv writes in handle_import_func is gone. Variadic handlers use
ctx.args.clear() and append(); delegating handlers pass ctx, so the
inner handler's displays apply to the outer call.

The display setter ignores values that are not strings, such as None
from a failed constant lookup or the raw pointer of a NULL string
argument.

API hooks get raw argv. WindowsEmulator.get_api_args() returns the
arguments of the hooked call as the report shows them, and the
emu_dll and dbgview examples use it.
2026-10-08 20:08:50 +01:00
Willi Ballenthin bf60d4111b ruff format: fix pre-existing formatting across project 2026-07-24 11:14:06 +01:00
Willi Ballenthin a1fb393f16 hooks: remove unused ctx kwarg 2026-03-25 09:39:01 +01:00
Willi Ballenthin f51c2f447e Add tests for example scripts 2026-03-06 17:46:06 +01:00
Willi Ballenthin 33c4433f0b Remove trivial accessors from PeFile and RuntimeModule
Remove get_emu_path/set_emu_path, get_sections, get_ptr_size,
get_base, and get_image_size from PeFile (common.py) and their
equivalents from RuntimeModule (loaders.py). Replace ~65 call
sites across 14 files with direct attribute access.
2026-03-06 14:12:54 +01:00
Willi Ballenthin d406763d96 Remove trivial accessors from MemMap, use direct attribute access
MemMap had 11 getter/setter methods that simply returned or assigned
a public attribute. Remove them all and replace ~60 call sites across
10 files with direct property access.
2026-03-06 13:56:30 +01:00
Willi Ballenthin a21b080910 gdb: add --gdb server stub via udbserver for interactive debugging
Integrate the udbserver library to expose a GDB Remote Serial Protocol
server on the emulated Unicorn instance. When --gdb is passed, the
emulator pauses before the first instruction and waits for a GDB client
to connect. Also removes the legacy get_logger()/logger= pattern that
was passing logger instances through constructors (Speakeasy.__init__
never accepted a logger parameter, so these were latent TypeErrors).
2026-02-27 09:52:31 +01:00
Willi Ballenthin 9b82c10bbb consolidate event timeline (and ruff format, sorry) 2026-02-27 09:51:28 +01:00
Willi Ballenthin d8d02b91b2 ruff: fix UP008 2026-02-27 09:51:04 +01:00
Willi Ballenthin 7059bbe80e ruff: fix I001 2026-02-27 09:51:04 +01:00
Willi Ballenthin e3d6e0c049 ruff: fix UP032 2026-02-27 09:51:04 +01:00
Willi Ballenthin e4520ae97b ruff: fix UP031 2026-02-27 09:51:04 +01:00
drewvis 228134b8a8 Initial commit 2020-08-21 17:05:28 -04:00