Salih Muhammed
All projects

Case study 02

Password strength analysis

Compared generated password samples across Bitwarden CLI, PasswordWolf and a custom Python generator, examining how length and character policy affect estimated strength.

450,000samples in saved results
3generators compared
15policy and length combinations

What the analysis did

Bitwarden CLIPasswordWolfCustom Pythonzxcvbn450k sampleslength8108 guesses121012 guesses201020 guessessame for every generator
Samples from three generators were scored with zxcvbn. Estimated guesses depended on length; the generator made no difference to the medians.

Median estimated guesses by length

Medians were the same for Bitwarden CLI, PasswordWolf and the custom generator, across all five character policies, with 10,000 samples in each cell. Offline times use the zxcvbn fast-hash scenario of 1010 guesses per second.
View data table
LengthMedian guessesMean zxcvbn scoreMedian offline time
81082.00.01 s
1210124.0100 s
2010204.0about 317 years

01

Approach

Python analysis of generated samples using zxcvbn estimates and descriptive character-frequency statistics, aggregated by generator, character policy and length.

02

What the results establish

The saved aggregate dataset contains 45 comparison groups totalling 450,000 samples. Length dominated: every generator and policy scored about 2 of 4 at 8 characters and 4 of 4 from 12 characters. One detail stood out. zxcvbn raised warnings on 10.4% of Bitwarden's 8-character symbols-and-digits samples, against under 0.5% for the other generators. The analysis explores estimated strength and recurring patterns, rather than measuring real-world password cracking.

03

Limitations and lessons

Reviewing my own work surfaced a discrepancy. The report names secrets.choice, while the saved custom generator uses Python's random module, which is not designed for cryptographic use. A correct build uses secrets. The comparison also does not establish that a custom generator is safer than a password manager.

All projects