java.lang.Object
me.gosimple.nbvcxz.Nbvcxz
This class allows you to do estimates on passwords. It can be instantiated and configured once, and the same
instance should be used for subsequent password estimates.
- Author:
- Adam Brusselback
-
Constructor Summary
ConstructorsConstructorDescriptionNbvcxz()Creates new instance with a default configuration.Nbvcxz(Configuration configuration) Creates a new instance with a custom configuration. -
Method Summary
Modifier and TypeMethodDescriptionGuess the entropy of a password with the configuration provided.Gets the current configuration.static DoublegetEntropyFromGuesses(BigDecimal guesses) Gets the entropy from the number of guesses passed in.static BigDecimalgetGuessesFromEntropy(Double entropy) Gets the number of guesses from the entropy passed in.static voidConsole application which will run with default configurations.voidsetConfiguration(Configuration configuration) Sets the configuration.
-
Constructor Details
-
Nbvcxz
public Nbvcxz()Creates new instance with a default configuration. -
Nbvcxz
Creates a new instance with a custom configuration.- Parameters:
configuration- aConfigurationto be used in all estimates.
-
-
Method Details
-
getEntropyFromGuesses
Gets the entropy from the number of guesses passed in.- Parameters:
guesses- aBigDecimalrepresenting the number of guesses.- Returns:
- entropy
Doublethat is calculated based on the guesses.
-
getGuessesFromEntropy
Gets the number of guesses from the entropy passed in.- Parameters:
entropy- aDoublerepresenting the number of guesses.- Returns:
- guesses
BigDecimalthat is calculated based on the entropy.
-
main
Console application which will run with default configurations.- Parameters:
args- arguments which are ignored!
-
getConfiguration
Gets the current configuration.- Returns:
- returns
Configuration
-
setConfiguration
Sets the configuration.- Parameters:
configuration- aConfigurationto be used in all estimates.
-
estimate
Guess the entropy of a password with the configuration provided.- Parameters:
password- The password you would like to attempt to estimate on.- Returns:
- Result object that contains info about the password.
-