- Create a new private GitHub repository for the password store
- Generate ssh key pair to use with GitHub if you haven't already
ssh-keygen -t ed25519
- Install homebrew (a prerequisite to be able to install the standard unix password manager. Homebrew can be installed via a curl command here: https://brew.sh. Installation takes a couple (5?) minutes
- Install pass with
brew install pass
(https://www.passwordstore.org)
- (Linux) If you for some reason dont have pass or gpg installed, install them first
- Generate GPG-key with command
gpg --gen-key
. Answer the questions asked by GPG. Email is enough (https://gist.github.com/flbuddymooreiv/a4f24da7e0c3552942ff). If passphrase is chosen here, this has to be entered every time you want to show a password in the store - Run
pass init <gpg-key-id>
Note: Skip this step if you are planning on using pass on multiple devices
To use multiple devices, each device must have all other devices public keys in the gpg key ring. This can be done by exporting the public key on each device and store them in the repo:
-
Exporting public key to file (from device 1):
gpg --output <keyfilename>.pgp --armor --export <key-id>
-
Either put this key in the repository or transfer it in some other way to other devices
-
Importing public key to gpg (from device 2)
gpg --import .keys/<keyfilename>.gpg
-
Trust the imported key
gpg --edit-key ubuntu
trust
Choose option 5 (trust ultimately) -
Clone the repository for the other devices. Run
pass init <gpg-key name 1> <gpg-key name 2> ....
(order is important. Need to be the same for all devices.
Repeat these steps for all devices
- Now pass is ready to be used :)
-
Download the (a) pass app for your iPhone:
https://mssun.github.io/passforios/ -
Generate a key-pair for the mobile device with gpg from a computer
gpg --generate-key
-
Copy all public keys to a file
gpg --armor --export <gpg-key-id #1> <gpg-key-id #2> <gpg-key-id #3> > pubkeys.txt
-
Copy the private key to be used for the mobile device to file
gpg --output <mobile private key file name>.pgp --armor --export-secret-key <mobile key id>
-
Copy the combined public key and private key to the mobile device (for instance by using icloud files)
-
Configure the mobile device by opening the pass ios app, go to settings -> php key -> load from file -> select the keys.
-
Remove the private key from the computer you generated the key-pair from (but keep the public key)
gpg --delete-secret-key mobile
-
Remove the physical files from icloud (and also delete them from the .Trash folder)
-
Remember to import the public key for the mobile device to other already configured devices
Tags: #pass #passwordstore #password #passwordmanager #gpg