A pass extension that provides a schema to organize the metadata in yaml format, the idea is to have a valid yaml document within ⊥
and ⊤
delimiters, it is not relevant the content out of them, then you can edit the document following the yaml rules inside the delimiters or write without rules outside them.
- Add and copy metadata in yaml format
- File attachment support
- Basic TOTP support
- pass 1.7.0 or later for extension support
- oathtool for TOTP support
- yq from https://pypi.org/project/yq/
To install the requirements in Ubuntu or MacOS systems are:
apt install oathtool yq
brew install oath-toolkit yq
Usage:
pass append pass-name key-name [value|file-path]
Add a new key/value pair in the document metadata
pass meta pass-name key-name [--clip,-c]
Show existing key and optionally put it on the clipboard.
If the key value is a file, it will open using the xdg-open command.
pass Super/Secret
S3cr3tP4ssw0rd
this is a secret note
pass append Super/Secret username mtdb
pass Super/Secret
S3cr3tP4ssw0rd
this is a secret note
⊥
username: mtdb
⊤
pass meta Super/Secret username
(use -c to copy instead show)
mtdb
pass append Super/Secret secretimage /secret/image.png
(the command detects if the file exists before executing)
pass Super/Secret
S3cr3tP4ssw0rd
this is a secret note
⊥
username: mtdb
secretimage: //sFDuY8jez8H2rful.gpg
⊤
pass meta Super/Secret secretimage
(show the image)
The command shows the file following the mailcap rules.
pass append Super/Secret otp BASE32SECRET3232
pass Super/Secret
S3cr3tP4ssw0rd
this is a secret note
⊥
username: mtdb
secretimage: //sFDuY8jez8H2rful.gpg
otp: BASE32SECRET3232
⊤
pass meta Super/Secret otp
(assume base32 standard totp secret)
456123
Set these enviroment variables to configure the command behavior
- PASSWORD*STORE_META_START_DELIMITER *(default: ⊥)_
- PASSWORD*STORE_META_END_DELIMITER *(default: ⊤)_
- PASSWORD*STORE_ATTACHMENTS_DIR *(default: $PREFIX/.attachments)_
- PASSWORD*STORE_TOTP_KEY_IDENTIFIER *(default: otp)_
- Enable password-store extensions by setting
PASSWORD_STORE_ENABLE_EXTENSIONS=true
- Copy append.bash and meta.bash into
~/password-store/.extensions
Note: make sure the yq
and oathtool
commands are available in your console
docker-compose -f test.yml up