leaking_addresses: add timeout on file read

Currently script can stall if we read certain files (like
/proc/kmsg). While we have a mechanism to skip these files once they are
discovered it would be nice to not stall on as yet undiscovered files of
this kind.

Set a timer before each file is parsed, warn user if timer expires.

Suggested-by: Kees Cook <[email protected]>
Signed-off-by: Tobin C. Harding <[email protected]>
1 file changed