Add a feature to give min and max length

Also more informative warnings when choosing potentially insecure
options and move some more logic into the password generator.