How to create custom wordlist on Kali Linux with crunch

Kali Linux has countless tools to support security testing. Wordlist plays an important role in various cybersecurity tests and password-related tasks.

With the Crunch command on Linux, you can create different types of wordlists to use in your security tests, and mastering the Crunch command will be a valuable addition to your skill set. Below is how to install and use Crunch effectively to create wordlists on Kali Linux.

How to install Crunch on Kali Linux

The Crunch command is usually pre-installed on Kali Linux. But if you don't have it yet, you can easily install it from the official repository. But first, update your system inventory with:

sudo apt update

Install the Crunch package with:

sudo apt install crunch

How to use Crunch command on Linux

To learn more about Crunch, run:

crunch -h

This section briefly introduces the Crunch command and its syntax.

How to create custom wordlist on Kali Linux with crunch Picture 1

For a more detailed and in-depth look at the Crunch command and its various options, see the man page or get command line help with:

man crunch

Basic Crunch syntax

The basic syntax of the Crunch command is:

crunch [options]

min refers to the least number of characters you want to generate, while max is the largest number of characters you want to generate.

If you want the same number of characters, set the min and max values ​​to the same number. There are many options provided by the crush command to create different types of wordlists.

To create a wordlist with all "abc" character combinations, each three characters long, run:

crunch 3 3 abc

Set the character range using the Crunch command

You can customize your wordlist by defining a specific character range, for example, all numbers, letters, or just symbols. For example, to create a list containing all lowercase letters that are between 4 and 6 characters long, run:

crunch 4 6 abcdefghijklmnopqrstuvwxyz

To create a wordlist with only numbers, run:

crunch 10 10 0123456789

Note : You can specify the length of the characters.

Export wordlist to file using Crunch

You can use the -o option to specify the output file for your created wordlist. To create a wordlist consisting of the character combinations "abc123", each consisting of 4 characters, and save it to a file named "wordlist.txt", run:

crunch 4 4 abc123 -o wordlist.txt

Use Bruteforce mode in the Crunch command

The -b option allows you to specify a character set for brute-force generation. The normal processing mode produces a wordlist with combinations of characters from a specified set for a given range of word lengths.

The -b mode is more extensive because it creates the wordlist by generating permutations of characters from the base set, allowing it to include all possible combinations.

crunch 6 6 -b 1234567890abcdef -o bruteforce.txt

This command creates a wordlist with all possible combinations of the characters '"1234567890abcdef" with a length of 6 characters and saves it to bruteforce.txt.

Use Combination mode with Crunch

The -c option is used to create a combination of characters from multiple sets.

crunch 8 8 -c 1@% -o combinations.txt

This command creates a wordlist that combines characters from set 1 and @% to generate all possible combinations of 8 characters, saving them in combinations.txt.

Create wordlists with custom templates using Crunch

The -t option allows you to create a wordlist based on a custom template.

crunch 8 8 -t MyPass@@@@ -o unique.txt

This command creates a wordlist where @@@@ represents mutable characters and MyPass is constant. wordlist is saved in Unique.txt.

The resulting Wordlist will contain words that follow the specified pattern. In this case it will consist of words with MyPass followed by 4 variable characters which can be any combination of characters from the specified character set (in this case the default character set is use, including all alphanumeric characters).

This can be especially useful in situations where you need the wordlist to be tailored to a specific format, or to test passwords that follow a predictable pattern. To prevent others from easily guessing or brute-force your password, you should always keep some common password mistakes in mind when creating a new password.

Create wordlist using Dictionary mode

The -d option allows you to use an external dictionary file as the source for your wordlist.

crunch 6 6 -f /usr/share/dict/words -o dictionary-list.txt

In this example, the command creates a wordlist of words that are 6 characters long using the dictionary file as the source and saves it to dictionary-list.txt.

Create words without repeating characters using Crunch

To create words without repeated characters (i.e. each character in the word is unique), you can use the -p option followed by a hyphen.

This option specifies that the generated words must be unique and does this by removing repetition of characters within each word.

For example, to create a wordlist of 6-letter words with no repeating characters, use:

crunch 6 6 -p ABCDEF -o non-repeating-words.txt

This command creates words consisting of the letters "A," "B," "C," "D," "E" and "F" without repeating characters and saves the wordlist in a non-repeating-words file . txt.

5 ★ | 1 Vote

May be interested

  • Kali Linux is available on the Windows Store but is flagged by Windows DefenderKali Linux is available on the Windows Store but is flagged by Windows Defender
    kali linux is available on windows 10 store for use with windows subsystem for linux, but it cannot bypass windows defender.
  • How to install Kali Linux on macOSHow to install Kali Linux on macOS
    since the release of kali linux 1.0.8, kali linux supports efi. this additional feature simplifies the process of installing and running potassium on various apple macbook air, pro and retina models.
  • How to Install Kali Linux NetHunter on AndroidHow to Install Kali Linux NetHunter on Android
    kali linux is the most popular security and penetration testing operating system in the world. thanks to the nethunter project, you can now install kali linux on your android phone.
  • How to install Kali Linux reduced versionHow to install Kali Linux reduced version
    kali mini iso or kali linux's shortened version is a convenient way to install a minimal potassium system and install it 'from scratch'.
  • Team Kali Linux teaches free online pentest on TwitchTeam Kali Linux teaches free online pentest on Twitch
    offensive security, the creators of kali linux, has just announced that they will host a free penetration testing (pentest) course with kali linux.
  • How to install Kali Linux dual boot on macOSHow to install Kali Linux dual boot on macOS
    since the release of kali linux 1.0.8, kali linux supports adding efi. this additional feature simplifies the process of installing and running potassium on various apple macbook air, pro and retina models. modeling the device will determine the level of success when users experience with newer devices. refind preinstallation can also increase the success rate on older devices. this tutorial will show you dual osx booting with kali linux using refind and encryption options
  • Learn about Ethical hacking using Kali Linux and Raspberry PiLearn about Ethical hacking using Kali Linux and Raspberry Pi
    a raspberry pi 3 runs kali linux for building amazing hacking skills. this small computer is cheap, powerful and very flexible.
  • How to install Kali Linux running Dual Boot with WindowsHow to install Kali Linux running Dual Boot with Windows
    instructions detail how to install kali linux running in parallel with windows operating system. tips to install kali linux dual boot with windows, simple and fastest
  • How to encrypt LVM partitions when installing Kali LinuxHow to encrypt LVM partitions when installing Kali Linux
    sometimes, we have sensitive data and want to encrypt using the entire drive encryption. with kali installer, you can start installing lvm partition encryption on both the hard drive or usb drive. the installation procedure is very similar to the normal kali linux installation, except to choose an encrypted lvm partition during installation.
  • How to conduct IoT pentest with Kali LinuxHow to conduct IoT pentest with Kali Linux
    kali linux can be used to perform many pentest tests on computers in combination with other related techniques. the following are the penetration testing platforms and methods for iot devices related to kali linux.