fix(main/pass): improve conditional for /dev/shm warning
This commit is contained in:
parent
7f8821740f
commit
6fbab7ce0d
|
@ -3,7 +3,7 @@ TERMUX_PKG_DESCRIPTION="Lightweight directory-based password manager"
|
|||
TERMUX_PKG_LICENSE="GPL-2.0"
|
||||
TERMUX_PKG_MAINTAINER="@termux"
|
||||
TERMUX_PKG_VERSION=1.7.4
|
||||
TERMUX_PKG_REVISION=1
|
||||
TERMUX_PKG_REVISION=2
|
||||
TERMUX_PKG_SRCURL=https://git.zx2c4.com/password-store/snapshot/password-store-${TERMUX_PKG_VERSION}.tar.xz
|
||||
TERMUX_PKG_SHA256=cfa9faf659f2ed6b38e7a7c3fb43e177d00edbacc6265e6e32215ff40e3793c0
|
||||
TERMUX_PKG_DEPENDS="bash, coreutils, gnupg (>= 2.2.9-1), tree"
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
--- password-store-1.7.4/src/password-store.sh 2021-06-11 18:49:06.000000000 +0200
|
||||
+++ password-store-1.7.4.mod/src/password-store.sh 2021-07-26 10:10:09.076790995 +0200
|
||||
diff -uNr password-store-1.7.4/src/password-store.sh password-store-1.7.4.mod/src/password-store.sh
|
||||
--- password-store-1.7.4/src/password-store.sh 2021-06-11 19:49:06.000000000 +0300
|
||||
+++ password-store-1.7.4.mod/src/password-store.sh 2022-12-29 12:52:53.004171610 +0200
|
||||
@@ -155,7 +155,7 @@
|
||||
#
|
||||
|
||||
|
@ -26,20 +27,31 @@
|
|||
fi
|
||||
local sleep_argv0="password store sleep on display $display_name"
|
||||
|
||||
@@ -225,7 +227,7 @@
|
||||
@@ -225,15 +227,19 @@
|
||||
}
|
||||
trap remove_tmpfile EXIT
|
||||
else
|
||||
- [[ $warn -eq 1 ]] && yesno "$(cat <<-_EOF
|
||||
+ [[ $(uname -o) == "Android" ]] || [[ $warn -eq 1 ]] && yesno "$(cat <<-_EOF
|
||||
Your system does not have /dev/shm, which means that it may
|
||||
be difficult to entirely erase the temporary non-encrypted
|
||||
password file after editing.
|
||||
@@ -233,7 +235,7 @@
|
||||
Are you sure you would like to continue?
|
||||
_EOF
|
||||
)"
|
||||
- Your system does not have /dev/shm, which means that it may
|
||||
- be difficult to entirely erase the temporary non-encrypted
|
||||
- password file after editing.
|
||||
-
|
||||
- Are you sure you would like to continue?
|
||||
- _EOF
|
||||
- )"
|
||||
- SECURE_TMPDIR="$(mktemp -d "${TMPDIR:-/tmp}/$template")"
|
||||
+ if [ "$(uname -o)" != "Android" ] && [ -z "$TERMUX_VERSION" ]; then
|
||||
+ if [[ $warn -eq 1 ]]; then
|
||||
+ yesno "$(cat <<-_EOF
|
||||
+ Your system does not have /dev/shm, which means that it may
|
||||
+ be difficult to entirely erase the temporary non-encrypted
|
||||
+ password file after editing.
|
||||
+
|
||||
+ Are you sure you would like to continue?
|
||||
+ _EOF
|
||||
+ )"
|
||||
+ fi
|
||||
+ fi
|
||||
+ SECURE_TMPDIR="$(mktemp -d "${TMPDIR:-@TERMUX_PREFIX@/tmp}/$template")"
|
||||
shred_tmpfile() {
|
||||
find "$SECURE_TMPDIR" -type f -exec $SHRED {} +
|
||||
|
|
Loading…
Reference in New Issue