Skip to content
/ pass-meta Public

A pass extension that provides a schema to organize the metadata in yaml format

License

Notifications You must be signed in to change notification settings

mtdb/pass-meta

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pass-meta

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.

Features

  • Add and copy metadata in yaml format
  • File attachment support
  • Basic TOTP support

Requerements

To install the requirements in Ubuntu or MacOS systems are:

apt install oathtool yq
brew install oath-toolkit yq

Ussage

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.

Example

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

Options

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)_

Installation

  • 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

Run tests

docker-compose -f test.yml up

About

A pass extension that provides a schema to organize the metadata in yaml format

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published