2

I'm trying to generate all possible variation of a password.

The base word is like "PleaseSub!" and I need all possible version of it with uppercase, lowercase, etc.. I know there is something like 2^10 options but I can't figure out how to generate it with crunch or any other tool.

Any idea?

4

You can use hashcat to do so. You can write rules that will operate on your given wordlist (in this case, the single word "PleaseSub!", however it can be as many as you please) and generate a bunch of similar passwords according to your rules. e.g

sXY - s will replace X with Y

$X - will append the character X to your wordlist

^X - will prepend the character X to your wordlist

and so on, that link I provided will give you a bunch of different commands and how to utilise them effectively.

Example:

base_word.txt

PleaseSub!

please_sub.rule

se3       # Replace e with 3
sl1       # Replace l with 1
$1        # Append 1 to the generated password
$2        # Append 2 to the generated password
$3        # Append 3 to the generated password

Which can then be called like so hashcat --stdout -r please_sub.rule base_word.txt

Output

Pl3as3Sub!
P1easeSub!
PleaseSub!1
PleaseSub!2
PleaseSub!3

You can add multiple rules to a single line to have them all executed at the same time. E.g.

replace se3 with se3 sS5 $7

and the output becomes:

Pl3as35ub!7
P1easeSub!
PleaseSub!1
PleaseSub!2
PleaseSub!3

You can skip generating the wordlist and just call it directly like so hashcat -m <mode> hash.file base_word.txt -r please_sub.rule

Writing your own rules can be quite difficult, so a helpful hint if you're trying this on Kali there are a bunch of pre-built rules in /usr/share/hashcat/rules/

E.g.

hashcat -m <mode> hash.file base_word.txt -r /usr/share/hashcat/rules/best64.rule

This is not an exhaustive list and I encourage you read through the page I sent you for a much more in depth look at generating rules.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.