Is there a way to prove a program doesn't leave keys in memory after it exists?
Some programs are designed to zeroize sensitive fields after they are used. If you knew the values of these fields you could scan for them in memory after the program exists if you could avoid causing a segmentation fault.
One approach I've imagined is hacking the OS so you controlled same memory the program used. Then just search the memory for the field values. Assuming the fields were long enough false positives would be like hitting the lottery.
If this is reinventing the wheel please tell me what this wheel is named or if I'm making this to complicated.
Sure you can't prove it will never leave keys but you could prove it didn't during a particular run. Just looking for a reasonable test developers can use to check.