[][src]Crate lib_wordpass

Functions

generate_password

Generate a password using words selected at random from the list of words. The resulting string will have at least min_letter_count letters (excluding spaces) and at least min_word_count words. If initial_capital is true, the first word will begin with a capital letter If use_caps is true, all words will begin with a capital letter. If use_spaces is true, words will be separated by spaces.

get_default_filename

Try to get a reasonable default word list. This will sometimes be effective on modern linux systems We look first in the user's config folder ($XDG_CONFIG_HOME) to see if there is a folder for wordpass. If so, and it contains a file words.txt, we use that. If not, we look for a system dictionary in /usr/share/dict/words Returns the filename for a dictionary if found, else None.

get_word_list

Get a Vec of words from a file. If filter is true, words which are not lowercase ascii are filtered. This is helpful to filter out words with apostrophes, proper nouns or names beginning with capital letters.