translate
– Python translator¶
-
pwnypack.shellcode.translate.
translate
(env, func, *args, **kwargs)[source]¶ Given a shellcode environment, a function and its parameters, translate the function to a list of shellcode operations ready to be compiled or assembled using
compile()
orassemble()
.Parameters: - env (Base) – An instance of a shellcode environment.
- func (callable) – The function to translate to shellcode.
- args – The positional arguments for the function.
- kwargs – The keyword arguments for the function.
Returns: The high-level shellcode operations.
Return type: list
-
pwnypack.shellcode.translate.
fragment
(f)[source]¶ Decorator to turn a function into a shellcode fragment that can be called as a function from within a translated function.
Parameters: f (callable) – The function to mark as a shellcode fragment. Returns: The decorated shellcode fragment. Return type: callable