X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=scripts%2Flive-helpers;h=79b158c95b5cc86c7a8ede2aaad108c82964d62f;hb=cd90bb08ee23ba400527b963a5cd2bec99c174c9;hp=59bdb4fd673c9dc4c4d631b159af394ee5448915;hpb=3cd34c818ca9695d0b5a8bab80c0ef08544acfbf;p=live-boot-grml.git diff --git a/scripts/live-helpers b/scripts/live-helpers index 59bdb4f..79b158c 100644 --- a/scripts/live-helpers +++ b/scripts/live-helpers @@ -327,10 +327,47 @@ find_cow_device () break fi + # Checking for a luks device + if [ -e /sbin/cryptsetup ] && /sbin/cryptsetup isLuks ${devname} + then + while true + do + load_keymap + + echo -n "Enter passphrase for ${pers_label} on ${devname}: " >&6 + read -s passphrase + echo "${passphrase}" > /tmp/passphrase + unset passphrase + exec 9&6 + read answer + + if [ "$(echo "${answer}" | cut -b1 | tr A-Z a-z)" = "n" ] + then + unset answer + break + fi + done + fi + if [ "$(/lib/udev/vol_id -l ${devname} 2>/dev/null)" = "${pers_label}" ] then echo "${devname}" - return + return 0 fi if [ "${PERSISTENT}" = "nofiles" ] @@ -361,6 +398,7 @@ find_cow_device () esac done done + return 1 } find_files ()