From 68a9589925cca68e5368eea1754c1a5c789c355b Mon Sep 17 00:00:00 2001 From: Jaromil Date: Sat, 10 Feb 2018 20:21:18 +0100 Subject: [PATCH] set ownership after dig and forge --- tomb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tomb b/tomb index 864aa58..b2e86de 100755 --- a/tomb +++ b/tomb @@ -1600,7 +1600,8 @@ dig_tomb() { ${=DD} if=/dev/urandom bs=1048576 count=$tombsize of=$TOMBPATH [[ $? == 0 && -e $TOMBPATH ]] && { - ls -lh $TOMBPATH + _sudo chown ${_UID}:${_GID} "$TOMBPATH" + ls -lh "$TOMBPATH" } || { _warning "Error creating the tomb ::1 tomb path::" $TOMBPATH _failure "Operation aborted." @@ -1715,6 +1716,7 @@ forge_key() { _failure "Operation aborted." } + _sudo chown ${_UID}:${_GID} "$TOMBKEYFILE" _message "Done forging ::1 key file::" $TOMBKEYFILE _success "Your key is ready:" ls -lh $TOMBKEYFILE