DEV Community

Cover image for A Command line memorable password generator. Now in Python.
Mike Sanders
Mike Sanders

Posted on

A Command line memorable password generator. Now in Python.

I have been using this utility for a couple of years and thought I would share it, code and all. A few years back, I saw an article about best practices for passwords using a combination of a couple of words, numbers, and symbols. At the time, I had a Mac machine that had a nice generator, but I thought...

How can I make this usable across all operating systems?

Python to the rescue

Python is one of those languages that is easy to install on all Operating Systems. It basically is already installed on many, and for developers, it is a nice language to have around.

The script is pretty straightforward. It uses a word dictionary from Linux operating systems and randomly picks a couple of words, numbers, and symbols and creates a list of passwords for you to choose from.

Show Me the Passwords

Okay, so the script is going to ask what password length you want. It can generate passwords 8 to 36 characters long and yes, you can remember these!

Here is example output for 16 character passwords.

aerial3543?regal baling58+Creator hones34464%avert rebind54%Sukkoth halting8!gannets inroads68^wattle toehold5%salving zenith91+curbing crime859~Antaeus bingo5375$rapist brogan791-texted dolled16*kindled kismet86#leering wrack87728*probe prose521+prevail bubble761~onward pinups69=gristle inkiest4$uniting deftly131+Kansas Orbison6?Nicobar 
Enter fullscreen mode Exit fullscreen mode

Here is some craziness with 36 character long passwords.

uncharacteristic162-characterization segregationists9881,departmentalized anthropocentric29567%deconstructions agriculturalists7195-procrastinators instantaneously88827^counterexamples incompatibility1227+aristocratically telecommunication8.anesthesiologists indeterminately7818^circumscriptions exemplification44961!authoritatively counterclaiming52167*inaccessibility industrialization96%nationalizations septuagenarians78367%familiarization obstructionists18361*inconsequential instrumentation67833$uncommunicative interchangeably23734#representatives environmentalists134-radiotelephones parliamentarians4914,particularities disillusionment5514&acknowledgements maintainability18449*exemplification trustworthiness86634.consciousnesses 
Enter fullscreen mode Exit fullscreen mode

Show me the code

Sure, it's up on Git Hub at https://github.com/devdog66/memorable-password

Top comments (0)