- by x32x01 ||
In penetration testing and cybersecurity assessments, generating custom wordlists is often necessary for password auditing, directory enumeration, and controlled lab testing.
Crunch is a powerful wordlist generator written in C that allows you to create highly customizable dictionaries based on specific patterns and character sets.
โ ๏ธ Important: Use Crunch only in authorized environments such as lab setups, bug bounty programs with permission, or professional security assessments.
It is commonly used in:
After installation, you can generate a basic wordlist.
This creates lowercase combinations automatically and saves them in dict.txt.
This generates combinations using only:
Great for targeted password pattern simulations in authorized labs.
Useful for testing password formats that allow spaces.
You can reference built-in combinations for lowercase, uppercase, numbers, and symbols.
This creates 4-character words using lowercase, uppercase, numbers, and symbols.
Useful when resuming interrupted generation.
This generates:
lowercase + number + symbol combinations.
These patterns are extremely useful in controlled password auditing environments.
Example:
Allows combining defined and undefined sets flexibly.
This prevents pattern interpretation.
To invert:
This changes combination order.
Prevents more than 2 identical characters together.
Useful when you only need partial combinations.
Great for creating test word combinations.
Generates all permutations from file contents.
Useful for managing large datasets.
Keeps files manageable.
To extract:
Compression reduces storage significantly.
Its pattern system, permutation options, and file management features make it extremely powerful for controlled testing scenarios.
Mastering Crunch improves your understanding of password complexity and attack simulation techniques - responsibly and ethically.
Stay ethical. Stay authorized. Stay secure ๐ก๏ธ๐ป
Crunch is a powerful wordlist generator written in C that allows you to create highly customizable dictionaries based on specific patterns and character sets.
โ ๏ธ Important: Use Crunch only in authorized environments such as lab setups, bug bounty programs with permission, or professional security assessments.
What Is Crunch? ๐ง
Crunch is a wordlist generator that creates all possible combinations of characters between a minimum and maximum length.It is commonly used in:
- Password testing labs ๐
- Capture The Flag (CTF) challenges ๐ดโโ ๏ธ
- Directory brute-force simulations ๐
- Security research environments ๐ฌ
Installing Crunch ๐ ๏ธ
On Kali Linux, Crunch is usually pre-installed. If not, install it using: Code:
apt install crunch Basic Wordlist Generation ๐
Generate words from 1 to 3 characters: Code:
crunch 1 3 -o dict.txt Using Custom Character Sets ๐ฏ
You can define specific characters: Code:
crunch 5 7 pass123 -o dict.txt Code:
Including Space as a Character ๐งฉ
You can include space in the character set: Code:
crunch 1 3 "raj " -o space.txt Viewing Available Character Sets ๐
Crunch includes predefined character sets: Code:
cat /usr/share/crunch/charset.lst Using Charset Codenames ๐ข
Example of using predefined mixed sets: Code:
crunch 4 4 -f charset.lst mixalpha-numeric-all -o wordlist.txt Using Start Block (-s Option) ๐
Start generating from a specific combination: Code:
crunch 4 4 -f charset.lst mixalpha-numeric-all -o wordlist.txt -s abc1 Creating Pattern-Based Wordlists ๐
Crunch supports pattern placeholders:@โ lowercase letters,โ uppercase letters%โ numbers^โ symbols
Code:
crunch -t @%^ -o dict.txt lowercase + number + symbol combinations.
Fixed Word + Pattern Examples ๐ง
Fixed word + 3 numbers
Code:
crunch 6 6 -t raj%%% -o num.txt Fixed word + 3 uppercase letters
Code:
crunch 6 6 -t raj,,, -o upper.txt Fixed word + 3 lowercase letters
Code:
crunch 6 6 -t raj@@@ -o lower.txt Fixed word + 3 symbols
Code:
crunch 6 6 -t raj^^^ -o symbol.txt Using Placeholder (+ Operator) โ
The + symbol acts as a placeholder when no specific charset is defined.Example:
Code:
crunch 3 3 + + 123 + -t %%@^ -o pattern.txt Treating Symbols as Literals (-l Option) ๐ค
If you want special characters treated literally instead of pattern placeholders: Code:
crunch 7 7 -t p@ss,%^ -l a@aaaaa > dict.txt Inverting Wordlist Order (-i) ๐
Default behavior fixes the first character first.To invert:
Code:
crunch 5 5 abc12 -t @@@%% -i -o invert.txt Limiting Duplicate Characters (-d) ๐ซ
To limit repeated characters: Code:
crunch 5 5 abc + 123 -t @@@%^ -d 2@ Early Stop Option (-e) โน๏ธ
Stop generation at a specific word: Code:
crunch 3 3 abc -e acc -o 2.txt Word Permutations (-p Option) ๐
Generate permutations without repetition: Code:
crunch 3 6 -p raj chandel tabcode Permuting Wordlists (-q Option) ๐
If you already have a list file: Code:
crunch -q list.txt Splitting Wordlists by Word Count (-c) ๐
Split into smaller files: Code:
crunch 1 1 -f charset.lst mixalpha-numeric-all-space -o START -c 60 Splitting by File Size (-b) ๐พ
Split files by size: Code:
crunch 4 7 Pass123 -b 1mb -o START Compressing Wordlists (-z gzip) ๐ฆ
To compress: Code:
crunch 4 7 Pass123 -z gzip -o START Code:
gunzip filename.txt.gz When Should You Use Crunch? ๐ฏ
Crunch is ideal for:- Security lab simulations
- Password strength testing
- Red team training
- CTF practice
- Controlled brute-force research
Final Thoughts ๐
Crunch is a fast and flexible wordlist generator widely used in cybersecurity training and professional penetration testing environments.Its pattern system, permutation options, and file management features make it extremely powerful for controlled testing scenarios.
Mastering Crunch improves your understanding of password complexity and attack simulation techniques - responsibly and ethically.
Stay ethical. Stay authorized. Stay secure ๐ก๏ธ๐ป
Last edited: