There are plethora of GUI based password managers out there. A quick google search will lead you to pick one suitable for you. But the command line password managers are very few. The one today we are going to talk about is Titan. It is written using C programming language. It uses SQlite to save the passwords, and all passwords will be stored using AES encryption. Titan uses openSSL library to perform the encryption. Password database is also protected from tampering by using a keyed-hash message authentication code (HMAC). Titan is not just a password manager. Since version 1.2, Titan also supports encrypting files and directories.
In this brief tutorial, let us see how to install and use Titan command line password manager.
Table of Contents
Installation
The following instructions are tested under Ubuntu 16.04 LTS server edition.
First, Install SQlite, openSSL and Git if they are not installed already:
$ sudo apt-get install libsqlite3-dev libssl-dev git
Git clone Titan repository:
$ git clone https://github.com/nrosvall/titan.git
The above command will clone the Titan repository in a directory called titan in your current working directory.
$ cd titan
Then, compile and install Titan using commands:
$ make
$ sudo make install
Titan Usage
Titan usage is fairly and straight forward. The typical command to use Titan is:
$ titan [flags] [options]
First, initialize a new database using command:
$ titan -i mypasswords
Where mypasswords is the database name. This database will be created in the current directory.
To show the database path, just run:
$ titan -s
If you have more than one database, you can switch between them by running the following command:
$ titan -u <database_path>
Now you can start adding the entries.
To add a new entry in Titan, run:
$ titan -a
Fill up the values one by one.
Title: MySQL root password Username: root Url: ostechnix.com Notes: Database administrator password Password (empty to generate new):
You can view all entries at any time using command:
$ titan -A
You will see an output something like below.
===================================================================== ID: 1 Title: MySQL root password User: root Url: ostechnix.com Password: ********** Notes: Database administrator password Modified: 2017-03-20 15:45:10 =====================================================================
To list a particular entry use -l option with ID name like below.
$ titan -l 1
To search entries, use -f option. For example, the following command will search for the entries about MySQL.
$ titan -f mysql
To edit any entry, you need to use -c option with ID name like below.
$ titan -c 1
The above command will allow you to edit an entry that has ID number 1. It will list the current details of each ID before editing them.
Current title MySQL root password New title: MySQL password Current username root New username: sk Current url ostechnix.com New url: ostechnix.com Current notes Database administrator password New note: Database user password Current password ubuntu New password (empty to generate new):
To remove an entry, run:
$ titan -r <ID_NAME>
To encrypt the current database, run:
$ titan -e
Similarly, to decrypt a database use -d option.
$ titan -d <database_path>
To generate a password, use -g option with password length. Say for example, to generate a password with 10 letters, run:
$ titan -g 10
To view all passwords, run:
$ titan --show-passwords -A
To encrypt automatically after exit:
$ titan --auto-encrypt
To encrypt files in a directory:
$ titan --encrypt-directory /home/sk/Documents/
To open the help section, run:
$ titan --help
Also, refer the man pages.
$ man titan
Suggested read:
- 4 Easy Ways To Generate A Strong Password In Linux
- KeeWeb - An Open Source, Cross Platform Password Manager
- Buttercup – A Free, Secure And Cross-platform Password Manager
- How To Set Password Policies In Linux
And, that's all. Hope this helps. If you find this guide useful, share it on your social, professional networks and support us.
Cheers!
Resource:
Thanks for stopping by!
Help us to help you:
- Subscribe to our Email Newsletter : Sign Up Now
- Support OSTechNix : Donate Via PayPal
- Download free E-Books and Videos : OSTechNix on TradePub
- Connect with us: Facebook | Twitter | Google Plus | LinkedIn | RSS feeds
Have a Good day!!
2 comments
It’s better to use full path when using titan –init. That way Titan always knows the full path and user does not need to care in what directory he/she calls titan.
Nice. One suggestion? The text for the actual command line entries is way too light, maybe reverse things and mane the “instruction” text light and make the CLI text bold?….it just helps a lot when trying to read this on a small screen or from a monitor that’s not that “bright” anymore.