timportant fix for backward compatibility to 1.2 - tomb - the crypto undertaker HTML git clone git://parazyd.org/tomb.git DIR Log DIR Files DIR Refs DIR README DIR LICENSE --- DIR commit 551a7839f500a9ba4b26cd63774019d91615cb16 DIR parent 8d46ff46e15614caa7eedb180ad6ea246ce7e45b HTML Author: Jaromil <jaromil@dyne.org> Date: Thu, 20 Jun 2013 00:45:23 +0200 important fix for backward compatibility to 1.2 a grave bug has been affecting 1.3 and 1.3.1 releases, which makes keys created with those versions incompatible with other Tomb versions. This bug is now fixed and Tomb should be able again to open old tombs. A script to sanitize keys will be released soon. Diffstat: M tomb | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) --- DIR diff --git a/tomb b/tomb t@@ -605,7 +605,11 @@ change_passwd() { drop_key { - gen_key $lukskey > ${tmpnewkey} + + local algo + { option_is_set -o } && { algopt="`option_value -o`" } + + gen_key $lukskey $algopt > ${tmpnewkey} if ! is_valid_key $tmpnewkey; then die "Error: the newly generated keyfile does not seem valid" t@@ -718,7 +722,7 @@ get_lukskey() { -d "${keyfile}" 2> $res unset tombpass - grep 'DECRYPTION_OKAY' $res + grep 'DECRYPTION_OKAY' $res > /dev/null ret=$?; rm -f $res fi t@@ -733,7 +737,7 @@ gen_key() { # $1 the lukskey to encrypt # $2 is the --cipher-algo to use (string taken by GnuPG) local lukskey="$1" - local algo="$2" + local algo="${2:-AES256}" # here user is prompted for key password local tombpass="" local tombpasstmp=""