small pixel drawing of a pufferfish pa

jessify the README
Jes Olson j3s@c3f.net
Wed, 28 Dec 2022 02:01:39 -0800
commit

47453355dbf727a369bd8c1fc5f90237811a47ba

parent

b52acdd2d96ee9f58f6cbee4849c68f4232d8862

2 files changed, 88 insertions(+), 108 deletions(-)

jump to
A README

@@ -0,0 +1,88 @@

+ pa + a simple password manager + + features + - encryption implemented using age[1] + - automatic key generation + - multiple identity/recipient support + - written in portable posix shell + - simple to extend + - only ~120 lines of code + - pronounced "paw" + + + dependencies + - age + - age-keygen + + + usage + $ pa help + pa + a simple password manager based on age + + commands: + [a]dd [name] - Add a password entry. + [d]el [name] - Delete a password entry. + [e]dit [name] - Edit a password entry with nvim. + [l]ist - List all entries. + [s]how [name] - Show password for an entry. + + env vars: + Password length: export PA_LENGTH=50 + Password pattern: export PA_PATTERN=_A-Z-a-z-0-9 + Password/key dir: export PA_DIR=~/.local/share/pa + + + command examples + $ pa add test + Generate a password? [y/n]: y + Saved 'test' to the store. + + $ pa list + test + + $ pa show test + vJwKuEBtxBVvdR-xppTdfofIei0oLlkoSK4OCSP2bMEBsP6ahM + + $ pa edit test + <opens $EDITOR> + + $ pa del test + Delete pass file 'test'? [y/n]: y + + + faq + > how does this differ from pass, passage, etc? + + pa is pa-inless. smaller, simpler, cleaner, does it harder, better, + faster, stronger + + > why u make this? + + if you're curious, i wrote a whole blog post about my reasons[2] + + > where are my keys? + + secret: ~/.local/share/pa/identities + public: ~/.local/share/pa/recipients + + > where are my passwords? + + probably ~/.local/share/pa/passwords + + > how can i rename a password? + + cd ~/.local/share/pa/passwords + mv foo.age bar.age + + + credits + - pa was originally forked from pash[3] by dylanaraps[4] + - age is a project by Filippo Valsorda[5] + +[1]: https://github.com/FiloSottile/age +[2]: https://j3s.sh/thought/storing-passwords-with-age.html +[3]: https://github.com/dylanaraps/pash +[4]: https://github.com/dylanaraps +[5]: https://filippo.io
D README.md

@@ -1,108 +0,0 @@

-# password ass (pa) - -A simple password manager using [age](https://github.com/FiloSottile/age) written in POSIX `sh`. Based on [pash](https://github.com/dylanaraps/pash) by [dylanaraps](https://github.com/dylanaraps). - -- Automatically generates an `age` key if one is not detected. -- Written in safe and [shellcheck](https://www.shellcheck.net/) compliant POSIX `sh`. -- Only `120~` LOC (*minus blank lines and comments*). -- Configurable password generation using `/dev/urandom`. -- Guards against `set -x`, `ps` and `/proc` leakage. -- Easily extendible through the shell. -- Ability to edit passwords using `$EDITOR` - -## Table of Contents - -<!-- vim-markdown-toc GFM --> - -* [Dependencies](#dependencies) -* [Usage](#usage) -* [FAQ](#faq) - * [Where are passwords stored?](#where-are-passwords-stored) - * [How do I rename an entry?](#how-do-i-rename-an-entry) - * [How can I extend pa?](#how-can-i-extend-pa) - -<!-- vim-markdown-toc --> - -## Dependencies - -- `age` - -## Usage - -``` - pa - a simple password manager based on age - - commands: - [a]dd [name] - Add a password entry. - [d]el [name] - Delete a password entry. - [e]dit [name] - Edit a password entry with nvim. - [l]ist - List all entries. - [s]how [name] - Show password for an entry. - - env vars: - Password length: export PA_LENGTH=50 - Password pattern: export PA_PATTERN=_A-Z-a-z-0-9 - Password/key dir: export PA_DIR=~/.local/share/pa -``` - -Examples: - -``` -pa add web/gmail -pa list | grep chan -pa del facebook -pa show github -pa edit sourcehut -``` - -## FAQ - -### How does this differ from `pass`, etc? - -I was looking for a shell-based password manager that used age. Actually, see my blog post if you're really that curious: - -https://j3s.sh/thought/storing-passwords-with-age.html - -### Where are passwords stored? - -The passwords are stored in `age` encrypted files located at `${XDG_DATA_HOME:=$HOME/.local/share}/pa}`. - -### How do I change the password store location? - -Set the environment variable `PA_DIR` to a directory. - -```sh -# Default: '~/.local/share/pa'. -export PA_DIR=~/.local/share/pa - -# This can also be used as a one-off. -PA_DIR=/mnt/drive/pa pa list -``` - -### How do I rename an entry? - -It's a file! Standard UNIX utilities can be used here. - - - -### How can I extend `pa`? - -A shell function can be used to add new commands and functionality to `pa`. The following example adds `pa git` to execute `git` commands on the password store. - -```sh -pa() { - case $1 in - g*) - cd "${PA_DIR:=${XDG_DATA_HOME:=$HOME/.local/share}/pa/passwords}" - shift - git "$@" - ;; - - *) - command pa "$@" - ;; - esac -} -``` -