GithubHelp home page GithubHelp logo

santakd / pwsafe Goto Github PK

View Code? Open in Web Editor NEW

This project forked from lucasepe/pwsafe

0.0 2.0 0.0 55 KB

Cross Platform simple and secure password management from commandline.

License: MIT License

Go 100.00%

pwsafe's Introduction

PWSafe

Go Report Card Github All Releases License

Cross Platform simple and secure password management from commandline.

  • Free open source software

  • Works on Linux, Mac OSX, Windows

  • Just a single portable binary file

Since the Password Safe file format is open-source and widely used, there are also compatible clients for many platforms.

You can choose to store all your passwords in a single encrypted master password database, or use multiple databases to further organize your passwords (work and home, for example).

Create a new password store (init)

| => pwsafe init -file test.dat
Secret phrase: *****
Secret phrase again: ***** 
๐Ÿ‘ password store 'test.dat' successfully created

Add a new account info (push)

| => pwsafe push -file test.dat -url http://www.mysecretsite.com -user [email protected] -pass abbraadabbra "My Cool Site"
Secret phrase: *****
๐Ÿ‘ record successfully pushed to store 'test.dat'

Show a summary of all records (list)

| => pwsafe list -file test.dat
Secret phrase: *****
                          /Users/lucasepe/Temp/test.dat 

  My Cool Site            [email protected]   http://www.mysecretsite.com

Edit / Update a record (push)

| => pwsafe push -file test.dat -category Bank "My Cool Site"
Secret phrase: *****
๐Ÿ‘ record successfully pushed to store 'test.dat'

Fetch a specific field content (pull)

| => pwsafe pull -file test.dat "my cool site"
Secret phrase: *****
abbraadabbra
  • by default `field=pass``

You can specify a field name

| => pwsafe pull -field url upwork
Secret phrase: 
https://www.upwork.com

Copy a specific field value to clipboard (clip)

Useful if you want to grab the password without showing the record content.

| => pwsafe clip -file test.dat "my cool site"
Secret phrase: *****
๐Ÿ‘ check your clipboard for the content of the field 'pass'
  • by default the password value is copied to clipboard (-pass)
    • you can also specify -url or -user.

Remove a record (remove)

| => pwsafe remove "my cool site"
Secret phrase: *****
๐Ÿ‘ record successfully removed from store '/Users/lucasepe/Temp/test.dat'

How to avoid typing the secret phrase each time

Caution: use this method only if you are sure the you are the only one accessing to your computer!

Given PWSAFE_HOME=$HOME/.pwsafe as the pwsafe home folder.

The default database will reside in this folder named as vault.dat.

If you are tired to type each time the secret phrase, follow those steps:

Goto the $PWSAFE_HOME folder

cd $PWSAFE_HOME

Generate a private RSA key

Save it in a file called vault-pri.pem:

$ openssl genrsa -out vault-pri.pem 1024 

Export the public key

Save it in a file called vault-pub.pem:

$ openssl rsa -in vault-pri.pem -pubout -out vault-pub.pem 

Encrypt your secret phrase (base64 encode it)

Save it in a file called vault.key:

$ echo 'abbracadabbra!' | openssl rsautl -encrypt -inkey vault-pub.pem -pubin | base64 > vault.key

That's all!

Now you can access to data in your default database (vault.dat) without typing the secret phrase.

If you wants to enable the secret phrase typing again, simply remove the following files:

  • vault.key, vault-pri.key, vault-pub.key

Credits

PWSafe database file encryption/decryption derived from the original work of https://github.com/tkuhlman/gopwsafe

pwsafe's People

Contributors

lucasepe avatar

Watchers

 avatar  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.