Tampering and Forgery

Seen in CS247 - Software Engineering Principles

Tampering

Changing a valid instance of ADT to become invalid in an unexpected way.

Node n{"bad ptr", (Node*)0x247} // completly random memory address

Forgery

Creating an invalid instance of this ADT.

Node n {"a", nullptr};
n.next = &n; // A cycle of 1 node.
 
Node n{"abc", nullptr};
Node p{"def", &n}; // This will try to delete stack memory when the dtor runs.