Hijacking is Buffer Overflow (2001)
paulgraham.com
paulgraham.com
Yeah! Hijacking is a failure of type systems due to command injection. Properly typed planes world fail to allow passenger actions to be interpreted as pilot actions.
To prevent these threats, the TSA should confiscate bad analogy guns or at least validate strict isomorphism.
(And as far as the article goes, it's not even correct. Your "data" includes closures/function pointers/whatever and if that data gets corrupted you could get the program to call into the wrong function.)
Of course something like Heartbleed is a bit different because it's around extract data that shouldn't have been there in the first place.
But still, some kind of "interpreter" is needed for any language and challenge is to make sure that user-input remains "data" as the interpreter understands it. This "sanitizing" is an ultimately hard problem even as each version of the problem (preventing buffer overruns, prevent sql-injection, etc) seems easy.
Security similarly is hard in that finding all weak points and strengthening them is hard even as strength weak-point-X may seem easy.
From http://en.wikipedia.org/wiki/Buffer_overflow_protection#Cana...
Canaries or canary words are known values that are placed between a buffer and control data on the stack to monitor buffer overflows. When the buffer overflows, the first data to be corrupted will usually be the canary, and a failed verification of the canary data is therefore an alert of an overflow, which can then be handled, for example, by invalidating the corrupted data.
This defense is only one that needs to be done if you use a language without memory safety in the first place.