25class TaintTesterChecker :
public Checker<check::PostStmt<Expr>> {
26 std::unique_ptr<BugType> BT =
27 std::make_unique<BugType>(
this,
"Tainted data",
"General");
34void TaintTesterChecker::checkPostStmt(
const Expr *E,
40 if (
isTainted(State, E,
C.getLocationContext())) {
42 auto report = std::make_unique<PathSensitiveBugReport>(*BT,
"tainted", N);
44 C.emitReport(std::move(report));
53bool ento::shouldRegisterTaintTesterChecker(
const CheckerManager &mgr) {
This represents one expression.
SourceRange getSourceRange() const LLVM_READONLY
SourceLocation tokens are not useful in isolation - they are low level value objects created/interpre...
CHECKER * registerChecker(AT &&... Args)
Used to register checkers.
bool isTainted(ProgramStateRef State, const Stmt *S, const LocationContext *LCtx, TaintTagType Kind=TaintTagGeneric)
Check if the statement has a tainted value in the given state.