Giter Club home page Giter Club logo

password-phrase-generator's Introduction

Password Phrase Generator

Password phrase generator written with Go inspired by https://randompassphrasegenerator.com/

Uses the included dictionary from Apple /usr/share/dict/words to source words

Demo

$ ./password-phrase-generator 
Frown-count-let3

First Attempt

Loads all words from dictionary file into a slice. Then generates a random index until 3 words are found to generate the phrase.

Optimized

Using go test -bench ., it doesn't seem to be actually any faster. Rather than loading the entire dictionary into a slice, it counts the total number of lines in the file and then continues to generate a random index. It then scans line by line to generate a slice of only the words up to the index generated.

password-phrase-generator's People

Contributors

zburk avatar yeboahnanaosei avatar

Watchers

James Cloos 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.