[PATCH 0/2] Fix issue when password with empty name exists
zx2c4.com at holgerdell.com
Sun May 24 16:29:55 CEST 2020
The Firefox extension passff makes it all too easy to accidentally
generate a password with an empty name. However, if the file
~/.password-store/.gpg exists, pass does not behave as expected. The
first patch provides a trivial fix for this, and contains test cases
that expose the bug.
More generally, one might wonder whether a password with empty name
should be allowed at all, or whether it should be hidden. Since the file
.gpg starts with a period, it is considered to be hidden, so the file
isn't even visible.
The second patch contains some test cases that check whether `pass ls`
correctly hides hidden files and files in hidden directories (it does),
assuming that the behavior of `ls` with respect to hidden files should
be emulated. Perhaps a command line option `pass ls -a` should list
hidden files, too?
Holger Dell (2):
show: Fix behavior when password with empty name exists.
tests: Added tests for the list command.
src/password-store.sh | 2 +-
tests/t0020-show-tests.sh | 10 +++++++++
tests/t0030-list-tests.sh | 42 +++++++++++++++++++++++++++++++++++++
tests/t0060-rm-tests.sh | 6 ++++++
tests/t0100-insert-tests.sh | 4 ++++
tests/t0200-edit-tests.sh | 7 +++++++
6 files changed, 70 insertions(+), 1 deletion(-)
create mode 100755 tests/t0030-list-tests.sh
More information about the Password-Store