Giter Club home page Giter Club logo

password-generator's Introduction

password-generator

Yet another xkcd-style password generator.

Word list is taken from hermitdave/FrequencyWords.

Usage

Note: At the moment all sample commands below assume you are executing from the base directory of a clone of this repository.

generate.sh

This is just a wrapper around shuf. Given input on stdin, it outputs 5 lines at random. Repeats are allowed.

$ cat word_list.txt | ./generate.sh
touch
farmers
costs
armies
caused

It optionally takes a count as an argument, to specify the number of lines to output

$ cat word_list.txt | ./generate.sh 10
execution
flour
extended
forbidden
foundation
muscles
benefits
cake
worst
fuel

generate.sh requires shuf or gshuf on your system. On OS X, you can get gshuf as part of the coreutils package, through Homebrew.

brew install coreutils

make

Alternately, I provide a set of convenience targets for make:

$ make password   # or just `make`. The default target invokes `password`.
pot
wax
steam
hurt
cape

Again, the default length is 5, but can be adjusted

$ PICK=3 make password
flowing
magazine
grandson

Here you can also adjust the size of the word list we generate from by specifying POOL. This defaults to 8192, which I've chosen because it seems a nice balance between memorability and password length. Being a power of 2, it also simplifies back of the envelope estimates of password entropy.

$ POOL=20 PICK=10 make password
we
and
have
of
it
that
the
what
to
to

There are additional targets for longer outputs or space-separated outputs.

$ make long_password
greece
mia
purchase
normal
interest
cab
rig
relationships
ross
corridor
$ make flat_password
injury aim assigned naive deserved

The Makefile also contains targets for rebuilding the word list.

$ make clean word_list

will wipe out the existing copy, and rebuild it from a fresh copy of the English word list in hermitdave/FrequencyWords.

password-generator's People

Contributors

nar8789 avatar

Stargazers

 avatar

Watchers

 avatar  avatar

password-generator's Issues

switch to frequency-based dictionary

The current dictionary, generated by truncating the letterpress dictionary based on word length, tends to come up with a lot of obscure words. As a user, I want to generate passwords from a list of high-frequency words, so passwords are more memorable

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.