Package: pysswords
Pysswordslets you manage
your login credentials from the terminal. Password files are saved intoGnuGPGencrypted
files into the Database Path_. Only with the passphrase used to create
the pyssword database you can decrypt password files. If you want to
know more about how pysswords works internally, check the Under the
Hood_ section.Pysswords console interfaceMain Features☑Console interface☑Manage multiple databases☑Add, edit, remove credentials☑Copy passwords to clipboard☑List credentials as a table☑Colored output☑Search credentials by name, login or comments☑Search with regular expression☑Bulk update/remove credentials☑Select credentials by fullname syntax☑Grouping credentials☑Exporting Pysswords database☑Importing Pysswords database☑Importing credentials from1password☑Randomly generated credential passwords☐Undo/Redo updates to the database☑implemented feature,☐not implemented feature.InstallationStable versionMake sure you haveGPGandpipinstalled:pipinstallpysswordsDevelopment versionLinux/OSXWindowsThelatest development versioncan be installed directly from
GitHub:$pipinstall--upgradehttps://github.com/marcwebbie/pysswords/tarball/masterQuickstart# create a new credentials database. Option: `-I` or `--init`pysswords--init# add new credentials. Option: `-a` or `--add`pysswords-a# get credential "example". Option: `-g` or `--get`pysswords-gexample# edit credential "example". Option: `-u` or `--update`pysswords-uexample# remove credential "example". Option: `-r` or `--remove`pysswords-rexample# search credentials by "exam". Option: `-s` or `--search`pysswords-sexam# search credentials using regular expressions Option: `-s` or `--search`.pysswords-sexample\.com|org# copy password from credential "example" into system clipboard.
# Option: `-c` or `--clipboard`pysswords-cexample# print all credentials as a table with hidden passwordspysswords# print all credentials as a table with passwords in plain text.
# Option: `-P` or `--show-password`pysswords-P# specify other Pysswords database. Option `-D` or `--database`pysswords-D/path/to/other/database# delete database and remove all credentials
# Option: `--clean`pysswords--clean# shows help. Option `-h` or `--help`pysswords--help# shows version. Option `--version`pysswords--versionTutorials1) Syncing your databaseDropboxWith Pysswords database on default path~/.pysswordsand with a
Dropbox shared directory on path~/Dropbox# move your Pysswords database inside your Dropbox directorymv~/.pysswords~/Dropbox/.pysswords# create a symbolic link to your shared .pysswords directory on the default path.ln-s~/Dropbox/.pysswords~/.pysswordsGoogle DriveWith Pysswords database on default path~/.pysswordsand with a
GoogleDrive shared directory on path~/GoogleDrive# move your Pysswords database inside your Dropbox directorymv~/.pysswords~/GoogleDrive/.pysswords# create a symbolic link to your shared .pysswords directory on the default path.ln-s~/GoogleDrive/.pysswords~/.pysswords2) Exporting/Importing Pyssword databases# export database to a pysswords database file called pysswords.db
# Option: `--export`pysswords--exportpysswords.db# import database from pysswords database file called pysswords.db
# Option: `--import`pysswords--importpysswords.db# import 1password 1pif exported filepysswords--importpasswords.1pif/data1.1pif3) Grouping credentials by namePysswords credentials handles multiple logins for each name which groups
credentials by name:# create john credentialpysswords-aName:example.comLogin:johnPassword:**********Comment:Nocomment# create doe credentialpysswords-aName:example.comLogin:doePassword:**********Comment:# listing credentialspysswords|Name|Login|Password|Comment||-------------+---------+------------+------------||example.com|doe|***|||example.com|john|***|Nocomment|4) Selecting credentials by fullname syntaxYou can select grouped credentials by using fullname syntaxlogin@name:pysswords-gdoe@example.com|Name|Login|Password|Comment||-------------+---------+------------+-----------||example.com|doe|***||5) Using multiple databasesSometimes it is useful to have multiple databases with different
passphrases for higher security. This can be done using-DPysswords
option.Creating databases on a given directory (ex:~/databases)# create personal Pysswords databasepysswords--init-D~/databases/personal_passwords# create work Pysswords databasepysswords--init-D~/databases/work_passwords# create junk Pysswords databasepysswords--init-D~/databases/junk_passwordsAdding passwords to specific database# add password to personal Pysswords databasepysswords-D~/databases/personal_passwords-a# add password to junk Pysswords databasepysswords-D~/databases/junk_passwords-aAdding passwords to specific database# listing specific databasespysswords-D~/databases/junk_passwordsUnder The HoodEncryptionEncryption is done withGnuGPGusingAES256.
Take a look atpysswords.cryptmodule to know more.Database PathThe default database path is at~/.pysswords. If you want to change
the database path, add--databaseoption to pysswords together with--init.pysswords--init--database"/path/to/another/database/"Database structurePysswords database is structured in a directory hierachy. Every
credential is a.pysswordfile inside a directory named after a
credential group.An empty database would look like this:pysswords--database/tmp/pysswords--inittree/tmp/pysswords-la# /tmp/pysswords
# └── .keys
#     ├── pubring.gpg
#     ├── random_seed
#     ├── secring.gpg
#     └── trustdb.gpgAfter adding a new credential the database would look like this:pysswords--database/tmp/pysswords-a# Name: github.com
# Login: octocat
# Password: **********
# Comments:tree/tmp/pysswords-la# /tmp/pysswords
# ├── .keys
# │   ├── pubring.gpg
# │   ├── random_seed
# │   ├── secring.gpg
# │   └── trustdb.gpg
# └── github.com
#     └── octocat.pysswordIf we add more credentials to group github.com. Directory structure
would be:pysswords--database/tmp/pysswords-a# Name: github.com
# Login: octocat2
# Password: **********
# Comments:tree/tmp/pysswords-la# /tmp/pysswords
# ├── .keys
# │   ├── pubring.gpg
# │   ├── random_seed
# │   ├── secring.gpg
# │   └── trustdb.gpg
# └── github
#     └── octocat.pyssword
#     └── octocat2.pysswordContributingFork the repositoryhttps://github.com/marcwebbie/pysswords/forkRead theMakefileWrite your tests ontests/test.pyIf everything is OK. push your changes and make a pull request. ;)License (MIT License)The MIT License (MIT)Copyright (c) 2014-2015 Marc Webbie,http://github.com/marcwebbiePermission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
“Software”), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.