Add configure options --with-{zxcvbn-c,zxcvbn-cpp,pwquality} to
explicitly enable or disable estimator backends. Default behavior
is to automatically enable the backend if it is found available.
Man page, help message and getopt_long argument all say the
short option to disable the internal dictionary is '-D', but
the switch code was looking for '-i'. Doh.
Make sure the generated file src/dictint.h is not listed as a
source file to be distributed (this prevent building a release
tarball when conigure was called without --with-dict).
If the only available backend is libpwquality, then do not bother
displaying and accepting the -d, --dict option as that backend
does not support using a user-supplied dictionary.
Describe all backends in an array and loop through that array
when necessary. Also, replace all backend-specific options
(-z, -Z, -p) with a single -e option.
This drastically reduces the number of #if blocks and makes
the code easier to read.
Do not mix the printing code in the functions that perform the
password strength estimation. Store results into a ad-hoc structure
and use a single dedicated function to print them.
If scorepw is called without non-option argument, read the
password to evaluate from standard input.
Reading is truncated to 200 characters max (which should be
enough for any password).
Add Autoconf code to automatically detect the three password
strength estimation libraries that we plan to support (zxcvbn,
zxcvbn-cpp, and pwquality).