depthcharge.executor
The depthcharge.executor module provides Operation
implementations responsible for executing code. Currently, this is limited to the use of the go
console command by way of the GoExecutor
implementation.
However, this module is intended of accommodate future additions, such as:
Support for automatically wrapping payloads with image headers and executing them with
boot*
family of console commands.Memory corruption exploitation and shellcode helper functions.
Similar to the above, integrating support for upstream and silicon-specific secure boot bypasses may also be reasonable additions.
Base Class
- class depthcharge.executor.Executor(ctx, **_kwargs)
Abstract base class for
Operation
implementations that facilitate arbitrary code execution on the target device.- execute_at(address: int, *args, **kwargs)
Instruct the target to execute instructions at the specified address.
Any additional positional and keyword arguments are passed to the underlying
Executor
implementation.Note: This method does not perform any pre-requisite validation before attempting to begin execution. Use the
Depthcharge.execute_payload()
method when executing built-in payloads.
Implementations
- class depthcharge.executor.GoExecutor(ctx, **_kwargs)
This class implements the
Executor
interface atop of U-Boot’s builtin functionality for executing U-Boot standalone programs via thego
console command.