Header menu logo B2R2

CFGAction Type

Our CFG reconstruction algorithm is performed by consuming actions (CFGAction). Each action has a priority, which is used to determine the order of the actions to run.

Union cases

Union case Description

EndTblRec(tbl, idx)

Full Usage: EndTblRec(tbl, idx)

Parameters:

Report the recovery result of a jump table entry. This will always be followed by a `StartTblRec` action to denote the end of the recovery.

tbl : JmpTableInfo
idx : int

ExpandCFG addrs

Full Usage: ExpandCFG addrs

Parameters:

Add more reachable edges to the initial CFG using the new program points.

addrs : Addr seq

InitiateCFG

Full Usage: InitiateCFG

Build an initial CFG that is reachable from the given function start address.

MakeCall(callSite, calleeAddr, CalleeInfo)

Full Usage: MakeCall(callSite, calleeAddr, CalleeInfo)

Parameters:

Create an abstract call node and connect it to the caller and fallthrough nodes when necessary.

callSite : Addr
calleeAddr : Addr
Item3 : CalleeInfo

MakeIndCall callSite

Full Usage: MakeIndCall callSite

Parameters:

Create an abstract call node for an indirect call and connect it to the caller and the fallthrough node.

callSite : Addr

MakeIndEdges(bbl, ins)

Full Usage: MakeIndEdges(bbl, ins)

Parameters:

Create edges for an indirect branch. We find the possible targets of the indirect branch and connect them with the given basic block.

bbl : Addr
ins : Addr

MakeSyscall(callSite, exit)

Full Usage: MakeSyscall(callSite, exit)

Parameters:
    callSite : Addr
    exit : bool

Create an abstract syscall node and connect it to the caller and fallthrough nodes when necessary.

callSite : Addr
exit : bool

MakeTlCall(callSite, calleeAddr, CalleeInfo)

Full Usage: MakeTlCall(callSite, calleeAddr, CalleeInfo)

Parameters:

Create an abstract tail-call node and connect it to the caller and fallthrough nodes when necessary.

callSite : Addr
calleeAddr : Addr
Item3 : CalleeInfo

StartTblRec(tbl, idx, src, dst)

Full Usage: StartTblRec(tbl, idx, src, dst)

Parameters:

Start recovering a jump table entry (only single entry at a time).

tbl : JmpTableInfo
idx : int
src : Addr
dst : Addr

UpdateCallEdges(calleeAddr, CalleeInfo)

Full Usage: UpdateCallEdges(calleeAddr, CalleeInfo)

Parameters:

Update the call edge(s) for the callee's abstract vertex. This action is used to inform that the callee's information (e.g., non-returning status) has been changed, and the call edges should be updated accordingly.

calleeAddr : Addr
Item2 : CalleeInfo

WaitForCallee calleeAddr

Full Usage: WaitForCallee calleeAddr

Parameters:

Wait for the callee to be resolved.

calleeAddr : Addr

Instance members

Instance member Description

this.IsEndTblRec

Full Usage: this.IsEndTblRec

Returns: bool
Returns: bool

this.IsExpandCFG

Full Usage: this.IsExpandCFG

Returns: bool
Returns: bool

this.IsInitiateCFG

Full Usage: this.IsInitiateCFG

Returns: bool
Returns: bool

this.IsMakeCall

Full Usage: this.IsMakeCall

Returns: bool
Returns: bool

this.IsMakeIndCall

Full Usage: this.IsMakeIndCall

Returns: bool
Returns: bool

this.IsMakeIndEdges

Full Usage: this.IsMakeIndEdges

Returns: bool
Returns: bool

this.IsMakeSyscall

Full Usage: this.IsMakeSyscall

Returns: bool
Returns: bool

this.IsMakeTlCall

Full Usage: this.IsMakeTlCall

Returns: bool
Returns: bool

this.IsStartTblRec

Full Usage: this.IsStartTblRec

Returns: bool
Returns: bool

this.IsUpdateCallEdges

Full Usage: this.IsUpdateCallEdges

Returns: bool
Returns: bool

this.IsWaitForCallee

Full Usage: this.IsWaitForCallee

Returns: bool
Returns: bool

this.Priority

Full Usage: this.Priority

Parameters:
Returns: int

The priority of the action. Higher values mean higher priority.

p : IPrioritizable
Returns: int

Type something to start searching.