From 4d0d5bb918ef3365f82533507683329f8d1df629 Mon Sep 17 00:00:00 2001 From: minoplhy Date: Thu, 12 Dec 2024 12:34:20 +0700 Subject: [PATCH] cryptsetup-veracrypt.sh: set secure enough umask --- cryptsetup-veracrypt/cryptsetup-veracrypt.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cryptsetup-veracrypt/cryptsetup-veracrypt.sh b/cryptsetup-veracrypt/cryptsetup-veracrypt.sh index f1d468a..cf6d9a7 100644 --- a/cryptsetup-veracrypt/cryptsetup-veracrypt.sh +++ b/cryptsetup-veracrypt/cryptsetup-veracrypt.sh @@ -64,7 +64,8 @@ mount_parameters_prompt() { local group_uid=$(id -g "$user" 2>/dev/null) if [ $? -eq 0 ] && [ -n "$user_uid" ] && [ -n "$group_uid" ]; then - MOUNT_PARAMETERS+="gid=$user_uid,uid=$group_uid" + # mount with owner,group and umask is owner r/w/e only + MOUNT_PARAMETERS+="gid=$user_uid,uid=$group_uid,umask=077" else printf "User id for %s not found!\n" $user mount_parameters_prompt