aboutsummaryrefslogtreecommitdiff
path: root/elk.hook
diff options
context:
space:
mode:
Diffstat (limited to 'elk.hook')
-rw-r--r--elk.hook27
1 files changed, 27 insertions, 0 deletions
diff --git a/elk.hook b/elk.hook
new file mode 100644
index 0000000..d5cbabf
--- /dev/null
+++ b/elk.hook
@@ -0,0 +1,27 @@
+#!/bin/sh
+
+run_hook() {
+ echo '▄▄▄▄▄▄▄▄ ▄▄▄▄ ▄▄'
+ echo '██▀▀▀▀▀▀ ▀▀██ ██'
+ echo '██ ██ ██ ▄██▀'
+ echo '███████ ██ ██▄██'
+ echo '██ ██ ██▀██▄'
+ echo '██▄▄▄▄▄▄ ██▄▄▄ ██ ▀█▄'
+ echo '▀▀▀▀▀▀▀▀ ▀▀▀▀ ▀▀ ▀▀▀'
+ echo
+ modprobe -a -q dm-crypt >/dev/null 2>&1
+
+ if [ ! -e "/dev/disk/by-uuid/${authusbuuid}" ]; then
+ printf "AuthUSB not found, please plug it in...\r"
+
+ while [ ! -e "/dev/disk/by-uuid/${authusbuuid}" ]; do
+ sleep 0.1
+ done
+ fi
+
+ stty -echo
+ printf "Enter Decryption Password: "
+ read password
+ stty echo
+ printf "$password" | cryptsetup open "/dev/disk/by-uuid/${authusbuuid}" authkeys
+}