From 6722b160cb8ea3d0591adb15fa3795ae7c9bbed7 Mon Sep 17 00:00:00 2001 From: Suikan <26223147+suikan4github@users.noreply.github.com> Date: Sun, 8 May 2022 12:25:24 +0900 Subject: [PATCH] Clear passphrase information before exit. --- script/lib/common.sh | 3 +++ script/ubuntu-kaiten-yaki.sh | 6 ++++++ script/void-kaiten-yaki.sh | 6 ++++++ 3 files changed, 15 insertions(+) diff --git a/script/lib/common.sh b/script/lib/common.sh index c37b0f9..2a34de0 100644 --- a/script/lib/common.sh +++ b/script/lib/common.sh @@ -139,6 +139,9 @@ function confirmation(){ ...Installation process terminated.. HEREDOC return 1 # with error status + else + # Clear the PASSPHRASE for checking because we don't use it anymore. + PASSPHRASE_C="" fi # passphrase validation diff --git a/script/ubuntu-kaiten-yaki.sh b/script/ubuntu-kaiten-yaki.sh index 7b932e3..e3b4b5d 100644 --- a/script/ubuntu-kaiten-yaki.sh +++ b/script/ubuntu-kaiten-yaki.sh @@ -67,8 +67,14 @@ function main() { post_install # Free LUKS volume as swap volume. + echo "...Disabling swap to release the LUKS volume." swapoff -a + # Deleting the passphrase information. + echo "...Deleting passphrase information." + PASSPHRASE="" + export PASSPHRASE + # Normal end return 0 diff --git a/script/void-kaiten-yaki.sh b/script/void-kaiten-yaki.sh index d31adcc..a49a378 100644 --- a/script/void-kaiten-yaki.sh +++ b/script/void-kaiten-yaki.sh @@ -82,8 +82,14 @@ function main() { post_install # Free LUKS volume as swap volume. + echo "...Disabling swap to release the LUKS volume." swapoff -a + # Deleting the passphrase information. + echo "...Deleting passphrase information." + PASSPHRASE="" + export PASSPHRASE + # Normal end return 0