|
__init__(self,
imm,
dictionaryfiles=None)
This class try to recognize a function using different methods
(address/signature/heuristic).
|
STRING
|
resolvFunctionByAddress(self,
address,
heuristic=90)
Look up into our dictionaries to find a function match.
|
INTEGER
|
checkHeuristic(self,
address,
reference,
refFirstCall=[])
Check a given address with a precomputed hash of a function.
|
|
compareHeuristic(self,
cfg,
refcfg)
|
|
makeFunctionHashHeuristic(self,
address,
compressed=False,
followCalls=True)
Consider:
- Control Flow Graph
- generalized instructions that:
access memory/write memory/use registers/use constant/call/jmp/jmc
and all his combinations.
|
UNSIGNED LONG
|
hash_a_list(self,
data)
Take a list and return a binary representation of his CRC32.
|
LIST
|
searchFunctionByHeuristic(self,
csvline,
heuristic=90,
module=None)
Search memory to find a function that fullfit the options.
|
LIST
|
_searchFunctionByHeuristic(self,
search,
functionhash=None,
firstcallhash=None,
exact=None,
heuristic=90,
module=None,
firstbb=None)
Search memory to find a function that fullfit the options.
|
LIST
|
searchFunctionByName(self,
name,
heuristic=90,
module=None,
version=None)
Look up into our dictionaries to find a function match.
|
STRING
|
makeFunctionHashExact(self,
address)
Return a SHA-1 hash of the function, taking the raw bytes as
data.
|
LIST
|
makeFunctionHash(self,
address,
compressed=False)
Return a list with the best BB to use for a search and the
heuristic hash of the function.
|
|
selectBasicBlock(self,
address)
|
LIST
|
generalizeFunction(self,
address)
Take an address an return a generalized version of the function,
dismissing address and register dependant information.
|
STRING
|
generalizeInstruction(self,
inp)
Generalize an instruction given an address or an opCode
instance
|
DWORD|None
|
findBasicBlockHeuristically(self,
address,
firstbb,
maxsteps=20)
Try to match a generalized BB with an address range (moving
backward).
|
DWORD|None
|
findFirstBB(self,
address,
recursive=False)
The main idea is traverse a function backward following Xrefs
until we reach a point where there's no more Xrefs other than
CALLs
|