fix pw_add logic
j3s j3s@c3f.net
Thu, 28 Jan 2021 15:07:49 -0600
1 files changed,
2 insertions(+),
2 deletions(-)
jump to
M
bin/pa
→
bin/pa
@@ -44,7 +44,7 @@ # Heredocs are sometimes implemented via temporary files,
# however this is typically done using 'mkstemp()' which # is more secure than a leak in '/proc'. age -r "$pubkey" -o "$name.age" <<-EOF && - $pass + $pass EOF printf '%s\n' "Saved '$name' to the store." }@@ -71,7 +71,7 @@
age -i ~/.age/key.txt --decrypt "$1.age" > "$tmpfile" "${EDITOR:-vi}" "$tmpfile" - if [ ! -f $tmpfile ]; then + if [ ! -f "$tmpfile" ]; then die "New password not saved" fi