Package winappdbg :: Module disasm :: Class Disassembler
[hide private]
[frames] | no frames]

Class Disassembler

source code


Generic disassembler. Uses a set of adapters to decide which library to load for which supported platform.

Instance Methods [hide private]

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __init__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Static Methods [hide private]
a new object with type S, a subtype of T
__new__(cls, arch=None, engine=None)
Factory class.
source code
Class Variables [hide private]
tuple( Engine ) engines = (<class 'winappdbg.disasm.DistormEngine'>, <class 'w...
Set of supported engines.
  __decoder = {}
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__new__(cls, arch=None, engine=None)
Static Method

source code 

Factory class. You can't really instance a Disassembler object, instead one of the adapter Engine subclasses is returned.

Parameters:
  • arch (str) - (Optional) Name of the processor architecture. If not provided the current processor architecture is assumed. For more details see win32.version._get_arch.
  • engine (str) - (Optional) Name of the disassembler engine. If not provided a compatible one is loaded automatically. See: Engine.name
Returns: a new object with type S, a subtype of T
Raises:
  • NotImplementedError - No compatible disassembler was found that could decode machine code for the requested architecture. This may be due to missing dependencies.
  • ValueError - An unknown engine name was supplied.
Overrides: object.__new__

Class Variable Details [hide private]

engines

Set of supported engines. If you implement your own adapter you can add its class here to make it available to Disassembler. Supported disassemblers are:
Type:
tuple( Engine )
Value:
(<class 'winappdbg.disasm.DistormEngine'>,
 <class 'winappdbg.disasm.BeaEngine'>,
 <class 'winappdbg.disasm.CapstoneEngine'>,
 <class 'winappdbg.disasm.LibdisassembleEngine'>,
 <class 'winappdbg.disasm.PyDasmEngine'>)