retdec
|
Finds interesting API calls in a module. More...
#include <api_call_pattern_finder.h>
Public Member Functions | |
virtual const std::string | getId () const override |
Returns the ID of the finder. More... | |
virtual Patterns | findPatterns (ShPtr< Module > module) override |
Finds patterns in the given module and returns them. More... | |
![]() | |
virtual | ~PatternFinder ()=default |
Static Public Member Functions | |
static ShPtr< PatternFinder > | create (ShPtr< ValueAnalysis > va, ShPtr< CallInfoObtainer > cio) |
Creates and returns a new instance of APICallPatternFinder. More... | |
Private Member Functions | |
APICallPatternFinder (ShPtr< ValueAnalysis > va, ShPtr< CallInfoObtainer > cio) | |
Constructs a pattern finder. More... | |
Additional Inherited Members | |
![]() | |
using | Patterns = std::vector< ShPtr< Pattern > > |
A list of patterns. More... | |
![]() | |
PatternFinder (ShPtr< ValueAnalysis > va, ShPtr< CallInfoObtainer > cio) | |
Constructs a pattern finder. More... | |
![]() | |
ShPtr< ValueAnalysis > | va |
Analysis of values. More... | |
ShPtr< CallInfoObtainer > | cio |
The used call info obtainer. More... | |
Finds interesting API calls in a module.
This finder finds calls in a module that are considered interesting. For a list of such calls, see the implementation of getAPICallFuncNames() in the .cpp file.
TODO Include only calls to declared functions, or also to defined ones? For example, if there is a ShellExecute() function defined in the module, should we also include calls to it even though it may have different behavior than ShellExecute() from WinAPI?
TODO Move the names of interesting functions into semantics?
Instances of this class have reference object semantics. Use create() to create instances.
|
private |
Constructs a pattern finder.
See PatternFinder::PatternFinder() for more information.
|
static |
Creates and returns a new instance of APICallPatternFinder.
See PatternFinder::PatternFinder() for more information on the parameters and preconditions.
|
overridevirtual |
Finds patterns in the given module and returns them.
The returned patterns are instances of StmtsPattern.
Implements retdec::llvmir2hll::PatternFinder.
|
overridevirtual |
Returns the ID of the finder.
Implements retdec::llvmir2hll::PatternFinder.