Static Value-Flow Analysis
|
Base class for all detectors. More...
#include <AEDetector.h>
Public Types | |
enum | DetectorKind { BUF_OVERFLOW , NULL_DEREF , UNKNOWN } |
Enumerates the types of detectors available. More... | |
Public Member Functions | |
AEDetector () | |
Constructor initializes the detector kind to UNKNOWN. | |
virtual | ~AEDetector ()=default |
Virtual destructor for safe polymorphic use. | |
virtual void | detect (AbstractState &as, const ICFGNode *node)=0 |
Pure virtual function for detecting issues within a node. | |
virtual void | handleStubFunctions (const CallICFGNode *call)=0 |
Pure virtual function for handling stub external API calls. (e.g. UNSAFE_BUFACCESS) | |
virtual void | reportBug ()=0 |
Pure virtual function to report detected bugs. | |
DetectorKind | getKind () const |
Get the kind of the detector. | |
Static Public Member Functions | |
static bool | classof (const AEDetector *detector) |
Check if the detector is of the UNKNOWN kind. | |
Protected Attributes | |
DetectorKind | kind |
The kind of the detector. | |
Base class for all detectors.
Definition at line 38 of file AEDetector.h.
Enumerates the types of detectors available.
Enumerator | |
---|---|
BUF_OVERFLOW | Detector for buffer overflow issues. |
NULL_DEREF | Detector for nullptr dereference issues. |
UNKNOWN | Default type if the kind is not specified. |
Definition at line 45 of file AEDetector.h.
|
inline |
|
virtualdefault |
Virtual destructor for safe polymorphic use.
|
inlinestatic |
Check if the detector is of the UNKNOWN kind.
detector | Pointer to the detector. |
Definition at line 67 of file AEDetector.h.
|
pure virtual |
Pure virtual function for detecting issues within a node.
as | Reference to the abstract state. |
node | Pointer to the ICFG node. |
Implemented in SVF::BufOverflowDetector, and SVF::NullptrDerefDetector.
|
inline |
Get the kind of the detector.
Definition at line 94 of file AEDetector.h.
|
pure virtual |
Pure virtual function for handling stub external API calls. (e.g. UNSAFE_BUFACCESS)
call | Pointer to the ext call ICFG node. |
Implemented in SVF::BufOverflowDetector, and SVF::NullptrDerefDetector.
|
pure virtual |
Pure virtual function to report detected bugs.
Implemented in SVF::BufOverflowDetector, and SVF::NullptrDerefDetector.
|
protected |
The kind of the detector.
Definition at line 100 of file AEDetector.h.