Techzone/Crunch - Wordlist Generator

Crunch - Wordlist Generator

2 min readArticle

Crunch generates custom wordlists based on patterns, character sets, and length parameters. Unlike CeWL (web scraping) or WYD (personal info), Crunch is purely combinatorial — it generates every possible combination given your specifications. Can produce enormous files quickly.

Installation

bash
sudo apt install crunch

Basic Syntax

shell
crunch <min-length> <max-length> [charset] [options]

Examples

bash
# Generate all 4-character lowercase combos
crunch 4 4 abcdefghijklmnopqrstuvwxyz -o lowercase4.txt

# Generate 6-8 character alphanumeric combos
crunch 6 8 abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 -o alphanum.txt

# Numbers only, 4 digits (PINs)
crunch 4 4 0123456789 -o pins.txt

# All lowercase + numbers, length 8
crunch 8 8 abcdefghijklmnopqrstuvwxyz0123456789 -o lower_num8.txt

# Include special characters
crunch 8 10 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!@#$' -o complex.txt

Using Predefined Charsets

Crunch has built-in charset names in /usr/share/crunch/charset.lst:

bash
# Lowercase alpha
crunch 6 6 -f /usr/share/crunch/charset.lst lalpha -o out.txt

# Uppercase alpha
crunch 6 6 -f /usr/share/crunch/charset.lst ualpha -o out.txt

# Alpha + numeric
crunch 8 8 -f /usr/share/crunch/charset.lst lalpha-numeric -o out.txt

# All printable
crunch 6 8 -f /usr/share/crunch/charset.lst mixalpha-numeric-all-space -o out.txt

Pattern-Based Generation

Use -t for patterns. Special characters in patterns:

  • @ — lowercase letters
  • , — uppercase letters
  • % — numbers
  • ^ — special characters
bash
# Pattern: lowercase word + 4 digits
crunch 10 10 -t @@@@@%%%%  -o pattern.txt

# Format: 2 uppercase + 4 numbers + 2 uppercase
crunch 8 8 -t ,,%%%%,, -o format.txt

# Specific prefix: "Company" + 3 digits
crunch 10 10 -t Company%%% -o company.txt

# Keyword + year
crunch 10 10 -t Password%%%% -o password_year.txt
# Generates Password2024, Password2023, etc.

Pipe to Aircrack/Hashcat (No File)

bash
# Pipe directly to aircrack-ng (save disk space)
crunch 8 8 0123456789 | aircrack-ng -w - -b AA:BB:CC:DD:EE:FF capture.cap

# Pipe to hashcat
crunch 8 8 abcdefghijklmnopqrstuvwxyz | hashcat -m 2500 handshake.hccapx

Limit Output

bash
# Only output lines starting with specific string
crunch 8 8 abcde -s abcdeaaa  # Start at specific combo

# Output to compressed file
crunch 8 8 abc -o wordlist.7z

# Limit file size
crunch 8 8 abc -b 100mb -o START  # Split into 100MB files

Size Warning

Crunch can generate massive files. Calculate first:

shell
4-digit PINs: 10^4 = 10,000 combinations (~40KB)
8-char lowercase: 26^8 = 208 billion combos (~1.9TB!)

Always estimate before running. For large keyspaces, pipe directly to the cracking tool instead of saving to disk.

Common Use Cases

  • PIN cracking (4-6 digit numeric)
  • Known password patterns ("Company" + year)
  • Specific length + character class combinations
  • WPA/WPA2 handshake cracking (8-char numeric PSKs)

See Also

  • cewl-custom-wordlist-generator - Website-scraped wordlists
  • wyd - Personal info based wordlists
  • rsmangler-wordlist-mangler - Mangle existing wordlists
  • hashcat-password-cracking-guide - Use crunch output for offline cracking
techzonesite.comUnlock Your IT Potential