The John the Ripper reference I keep open while working a file. Set your hash file, wordlist, and format once, and every command rewrites itself with your values, ready to copy. Below that is the full flag reference, the *2john extractor list, and the common formats. New to John? Start with the John the Ripper guide. Everything here was verified on John the Ripper 1.9.0-jumbo-1 (the jumbo build).
Set your values once
Set these once. Every command picks up your values. John usually auto-detects the format, so you only need to set it when forcing a specific type.
Step 1: extract the hash from a file
If you are cracking an encrypted file, turn it into a hash first with the matching *2john tool, then point John at the output:
zip2john secret.zip > :hashfile # then crack :hashfile belowSwap zip2john for the tool that matches your file: rar2john, pdf2john.pl, office2john.py, keepass2john, ssh2john. The full list is in the extractor table further down. Raw database hashes (MD5, NTLM, bcrypt) skip this step, they go straight into the hash file.
Ready-to-run cracking commands
Auto-detect and crack (John guesses the format from the hash):
john --wordlist=:wordlist :hashfileForce the format + wordlist (when auto-detect is ambiguous):
john --format=:format --wordlist=:wordlist :hashfileWordlist + rules (mangle each word, the highest-yield attack):
john --format=:format --wordlist=:wordlist --rules :hashfileSingle crack mode (build guesses from the username, run this first):
john --single --format=:format :hashfileIncremental (John's statistics-driven brute force, bound the length):
john --incremental --max-length=8 :hashfileMask attack (targeted brute force when you know the shape):
john --format=:format --mask=:mask :hashfileUse all your CPU cores (split the job with fork):
john --fork=:fork --format=:format --wordlist=:wordlist :hashfileShow what you have cracked (read results from the pot file):
john --show --format=:format :hashfileThe full flag reference
John the Ripper Flag Reference
Every flag organised by task. Jumbo build, tested on 1.9.0-jumbo-1.
The *2john extractors
The jumbo build ships around a hundred of these. The ones you will actually reach for:
| Tool | Cracks the password on a... | hashcat equivalent mode |
|---|---|---|
zip2john | ZIP archive (PKZIP / WinZip-AES) | 17200 / 13600 |
rar2john | RAR3 / RAR5 archive | 12500 / 13000 |
7z2john.pl | 7-Zip archive | 11600 |
pdf2john.pl | PDF document | 10500 / 10600 / 10700 |
office2john.py | Word / Excel / PowerPoint | 9400 / 9500 / 9600 |
keepass2john | KeePass database | 13400 |
ssh2john | encrypted SSH private key | 22911 |
gpg2john | GnuPG key / message | 17010 / 17020 |
The file-cracking walkthrough is in crack ZIP, RAR, and PDF passwords.
Common formats (--format=)
John usually auto-detects, but when it asks, these are the names:
| Hash | --format= |
|---|---|
| Raw MD5 / SHA-1 / SHA-256 | raw-md5 / raw-sha1 / raw-sha256 |
| NTLM | NT |
| bcrypt | bcrypt |
sha512crypt $6$ / sha256crypt $5$ | sha512crypt / sha256crypt |
| Argon2 | argon2 |
| WPA handshake | wpapsk |
| NetNTLMv2 | netntlmv2 |
| Kerberos TGS-REP / AS-REP | krb5tgs / krb5asrep |
| ZIP / RAR5 / PDF / Office / KeePass | ZIP / RAR5 / PDF / Office / KeePass |
Where to go next
- The GPU half of the toolkit: hashcat cheat sheet.
- John's best use case: cracking ZIP, RAR, and PDF passwords.
- Which tool when: hashcat vs John the Ripper.
- The full picture: how password cracking works.
john --wordlist=rockyou.txt hash.txt; John auto-detects most formats. Then read the result with john --show hash.txt. For an encrypted file, extract the hash first with the matching *2john tool.--format= when the guess is ambiguous (several formats share a shape) or wrong. Run john --list=formats to see the exact name to use.--fork=N where N is the number of cores, e.g. --fork=8. John splits the keyspace across the processes. This is CPU-only; for GPU speed on common hashes use hashcat.~/.john/john.pot. Results persist between runs, so John never re-cracks the same hash, and john --show hash.txt reads from it. Use --pot= to point at a different file.Sources
Authoritative references this article was fact-checked against.
- John the Ripper documentation (official)openwall.com
- John the Ripper, cracking modes (official)openwall.com
- John the Ripper jumbo, source (official)github.com





