page
Password manager with age encryption.
This is a fork of passage by strchris since it is no longer maintained and I enjoyed using it. It was also a good excuse for me to start digging into rust. Note that I've renamed the tool page, given that the author of age has released a popular alternative to the password-store, which is also called passage.
Note that page is compatible with the password database file created by the original passage, so you can safely migrate to this tool.
Installation
Binaries and packages (preferred)
The release page includes binaries for Linux, mac OS and Windows.
Build from source (for development)
With a rust toolchain present, you could do this (which makes sense if you want to contribute):
$ git clone https://github.com/deeuu/page
# Dependencies for Debian / Ubuntu
$ apt install libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libdbus-1-dev
$ cargo install --path .Walkthrough
page creates an age-encrypted storage file (the password database), whose current default location depends on the OS family, for a given username user:
Linux: `/home/user/.local/share/page/entries.toml.age`
mac OS: `/Users/user/Library/Application Support/page/entries.toml.age`
Windows: `C:\Users\user\AppData\Roaming\page\data\entries.toml.age`
You can create this file by running page init once. Check the path to the storage folder at any time with page info:
$ page info
Storage file: /home/deeuu/.local/share/page/entries.toml.ageNow let's create a new entry called email, with $ page new email:
Enter passphrase:
Password for 'email':So here we are prompted for two things:
Enter passphraseis the secret we want to encrypt the password database with (this is used to enrypt the entries file, so applies to all passwords).Password for 'email'is the password for the entry namedemailthat we want to store.
Now page list should show one entry (email), which we can decrypt with either:
$ page show <entry> # the password gets copied to the clipboardor
$ page show --on-screen <entry> # the password is printed to the consolepage supports additional (but optional) attributes such as the username and url associated with the entry. For example:
$ page new <entry> --username <user> --url <url> # include username and url
$ page show <entry> --attribute username # copy the username to the clipboardHooks
page is able to call into git-style hooks before or after certain events which affect the password database. A typical use case for hooks is if your password file is stored in version control and you want to automatically push/pull the changes when interacting with page.
To use hooks, place executable scripts, named after the hook you want to react on, inside the hooks folder (its path can be seen by running page info). These scripts are called and passed the event which triggered the hook as the first argument.
Existing hooks:
pre_load(called before the password database gets loaded)post_save(called after the password database is updated)
These commands trigger hooks:
page new(pre_load,post_savewith event namenew_entry)page list(pre_loadwith event namelist_entries)page show(pre_loadwith event nameshow_entry)page edit(pre_load,post_savewith event nameedit_entry)page remove(pre_load,post_savewith event nameremove_entry)
Example hook scripts can be found here.
Keyring integration
If possible, page will try to store the passphrase of your database into the OS keyring. You can run page keyring check to see if this works. If you no longer want the password to be stored in the keyring run page keyring forget.
To skip the keyring integration, page takes a global flag --no-keyring.
Shell completion
Shell completion is available via page completion <SHELL> where SHELL is one of bash, zsh, fish, elvish, powershell, or nushell. Completion scripts are written to standard output.
Usage
$ page
A password manager with age encryption
Usage: page [OPTIONS] <COMMAND>
Commands:
init Initialize the password store
new Add a new entry
list List all known entries
show Decrypt and show an entry
edit Edit an entry
remove Remove an entry
info Display status information
keyring Keyring related commands
completion Generate shell completion
help Print this message or the help of the given subcommand(s)
Options:
-n, --no-keyring Disable the keyring integration
-h, --help Print help
-V, --version Print version