When signing an app with Apple's codesign
tool, it seems I might want to set the -o kill
option:
Code with the kill flag set will die when it becomes dynamically invalid.
This corresponds to the kSecCodeSignatureForceKill
constant to "Always set the kSecCodeStatusKill
status flag on launch" which:
Indicates that the code wants to be killed (terminated) if it ever loses its validity.
Sounds great, but what does it really mean?
Naturally, if "anything" were to break my code's integrity during execution I would want the process killed. But what would that "something" be? Will this flag guard against any and all code injection attacks?