A recurrent neural network for password cracking.
Separate dataset into train/valid/test:
$ python preprocess.pyNote that preprocess.py does not shuffle its input. You should shuffle your dataset before feeding it to preprocess.py
Train your own model:
$ python train.pySample all passwords with possibility above threshold:
$ python sample.py [--threshold <threshold>]Evaluate how well your model performed:
$ python eval.py <results_file> <test_data_file>Sampling a large number of passwords may take a very long time. Therefore, we use Monte Carlo methods to estimate the guess number of each password in the test set.
Guess number: number of guesses needed to crack a particular password.
The code for Monte Carlo requires two input files: one that contains k possibilities randomly sampled from the entire distribution (e.g. k = 10000) and another that contains the possibility of each password in the test set.
Randomly sample k possibilities from the distribution:
$ python sample-for-monte-carlo.py [--sample_size <sample_size>]Assign possibilities to each password in the test set:
$ python assign-probs.pyEvaluate how well your model performed:
$ python eval-monte-carlo.pyNote that due to copyright reasons, the code for Monte Carlo is not included in this repository.