Code Monkey home page Code Monkey logo

pass-meta's Introduction

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 then it opens following the mailcap rules
        http://linux.die.net/man/4/mailcap

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)
  • PASSWORD_STORE_META_FALLBACK (default: none) valid values: pass, tail or none

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

pass-meta's People

Contributors

mtdb avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.