From 29f250d8f2a60b88ebd7a0ddd01f50772ce91180 Mon Sep 17 00:00:00 2001 From: Jaromil Date: Sat, 20 Aug 2011 19:00:10 +0200 Subject: [PATCH] fix: on -k - , wipe temp file --- src/tomb | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/tomb b/src/tomb index 40af797..6a0cada 100755 --- a/src/tomb +++ b/src/tomb @@ -758,6 +758,7 @@ mount_tomb() { # set up variables to be used # the full path is made with $tombdir/$tombfile + local tombkey local tombfile local tombdir @@ -865,6 +866,12 @@ mount_tomb() { rmdir $tombkeydir fi + # if key was from stdin delete temp file and dir + if [ $tombkeydir ]; then + ${WIPE[@]} ${tombkey} + rmdir $tombkeydir + fi + if [ -r /dev/mapper/${mapper} ]; then break; # password was correct fi