Skip to content

TaintAnalysis::magic_tainted

Make certain variables always tainted.

Synopsis

Declared in <src/midend/programAnalysis/genericDataflow/simpleAnalyses/taintAnalysis.h>

bool
magic_tainted(
    SgNode* node,
    FiniteVarsExprsProductLattice* prodLat);

Description

Variables whose names begin with the string "TAINTED" are assumed to be tainted regardless of their situation. This is our currently kludgy way of introducing taint into a specimen ‐‐ the user modifies the specimen and introduces taint with these specially named variables. E.g.,

ORIGINAL                               MODIFIED
------------------------------------ ------------------------------------
int specimen() {                       int specimen() {
                                           extern int TAINTED;
    int a = 2 * foo();                     int a = 2 * foo() + TAINTED;
    return a;                              return a;
}                                      }

Parameters

Name

Description

node

This class represents the base class for all IR nodes within Sage III.

Created with MrDocs