Skip to content

Commit

Permalink
Release v3.2 (#21)
Browse files Browse the repository at this point in the history
* Added --hwmon-disable flag

* Added Polish wordlist

* Update VERSION

* Added OneRuleToRuleThemStill

* Replaced ORTRTA with ORTRTS

* Rename

* Added CeWL

* Fix CeWL check

* Typo

* Consistency

* Consistency

* Typo

* Fix issue

* Fix length + depth
  • Loading branch information
crypt0rr authored Feb 1, 2023
1 parent b20f138 commit e01044b
Show file tree
Hide file tree
Showing 16 changed files with 4,124,974 additions and 59 deletions.
10 changes: 7 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ Simple script to get some hash cracking done effectively.

Some sites where you can find wordlists:

* <https://weakpass.com/>
* <https://hashmob.net/>
- <https://weakpass.com/>
- <https://hashmob.net/>

Want to make the ***$HEX[1234]*** Hashcat output readable? Have a look at [hex-to-readable](https://github.com/crypt0rr/hex-to-readable).

Expand All @@ -19,7 +19,11 @@ There is a separate repo with support for Apple Silicon based systems. Find it o
git clone https://github.com/crypt0rr/hash-cracker
```

For the current implementation of PACK, python2 is required, also install `pip install pyenchant==3.0.0a1`. If you don't have python2 (ofc), you are not able to use option 12 and 13.
### Requirements for Full Functionality

- Python2
- `pip install pyenchant==3.0.0a1`
- [CeWL](https://github.com/digininja/CeWL/)

## Usage

Expand Down
8 changes: 8 additions & 0 deletions VERSION.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Version log

## v3.2 - Custom Word List Generator

* Added Polish [wordlist](https://raw.githubusercontent.com/sigo/polish-dictionary/master/dist/pl.txt)
* Added missing `--hwmon-disable` flag to `markov-generator.sh`
* Replaced OneRuleToRuleThemAll with [OneRuleToRuleThemStill](https://github.com/stealthsploit/OneRuleToRuleThemStill)
* Split `requirements.sh` into two files `mandatory` and `optional`
* Added Custom Word List Generator - [CeWL](https://github.com/digininja/CeWL/)

## v3.1 - To speed or not to speed #kernels

* Optimized kernels are used by default but can be disabled with the `-n` or `--no-limit` flag
Expand Down
13 changes: 9 additions & 4 deletions hash-cracker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@
# Copyright crypt0rr

function hash-cracker () {
echo -e "Checking if requirements are met:"
source scripts/requirements.sh
echo -e "Mandatory modules:"
source scripts/mandatory-checks.sh
echo -e "\nOptional modules:"
source scripts/optional-checks.sh
menu
}

Expand All @@ -25,7 +27,8 @@ function menu () {
echo "14. Fingerprint attack"
echo "15. Directory of word lists plain and then with OneRuleToRuleThemAll"
echo "16. Username iteration (only complete NTDS)"
echo -e "17. Markov-chain passwords generator\n"
echo "17. Markov-chain passwords generator"
echo -e "18. CeWL wordlist generator\n"

read -p "Please enter job number: " START
if [[ "$START" = "0" ]] || [[ "$START" = "exit" ]]; then
Expand Down Expand Up @@ -64,13 +67,15 @@ function menu () {
source scripts/processors/usernameaspassword.sh
elif [[ $START = '17' ]]; then
source scripts/processors/markov-generator.sh
elif [[ $START = '18' ]]; then
source scripts/processors/cewl.sh
else
echo -e "Not valid, try again\n"; menu
fi
hash-cracker
}

echo -e "hash-cracker v3.1 by crypt0rr (https://github.com/crypt0rr)\n"
echo -e "hash-cracker v3.2 by crypt0rr (https://github.com/crypt0rr)\n"

NOP=$1

Expand Down
22 changes: 22 additions & 0 deletions scripts/mandatory-checks.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/bash
# Copyright crypt0rr

# Requirements
HASHCAT=$(command -v hashcat)
POTFILE=(hash-cracker.pot)

# Logic
if ! [ -x "$(command -v $HASHCAT)" ]; then
echo '[-] Hashcat is not available/executable'; ((COUNTER=COUNTER + 1))
else
echo '[+] Hashcat is executable'
fi
if test -f "$POTFILE"; then
echo '[+] Potfile "hash-cracker.pot" present'
else
echo '[-] Potfile not present, will create "hash-cracker.pot"'
touch hash-cracker.pot
fi
if [ "$COUNTER" \> 0 ]; then
echo -e "\nNot all mandatory requirements are met. Please fix and try again."; exit 1
fi
34 changes: 34 additions & 0 deletions scripts/optional-checks.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
#!/bin/bash
# Copyright crypt0rr

# Logic
if [[ -x "scripts/extensions/common-substr" ]]; then
echo '[+] Common-substr is executable'
else
echo '[-] Common-substr is not available/executable (option 10 / 11)'
fi
if [[ -x "$(command -v python2)" ]]; then
echo '[+] Python2 is executable'
else
echo '[-] Python2 is not available/executable (option 12 / 13)'
fi
if [[ -x "scripts/extensions/hashcat-utils/bin/expander.bin" ]]; then
echo '[+] Expander is executable'
else
echo '[-] Expander is not available/executable (option 14)'
fi
if [[ -x "$(command -v cewl)" ]]; then
echo '[+] CeWL is executable'
CEWL=$(command -v cewl)
else
echo '[-] CeWL is not available/executable (option 18)'
fi

echo -e "\nKernel mode:"
if [ "$NOP" == '-n' ] || [ "$NOP" == '--no-limit' ]; then
echo "[-] Optimised kernels disabled"
KERNEL=''
else
echo "[+] Optimised kernels enabled"
KERNEL='-O'
fi
25 changes: 25 additions & 0 deletions scripts/processors/cewl.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#!/bin/bash
# Copyright crypt0rr

# Logic
read -p "Please enter the full URL to spider (e.g. https://kb.offsec.nl): " URL
read -p "Output name for the CeWL wordlist: " CEWLLIST

read -p "Depth to spider to (0-9): " DEPTH
until [[ $DEPTH = [0-9] || [0-9][0-9] ]]; do
echo "Please only use 0-99."
read -p "Depth to spider to (0-99): " DEPTH
done

read -p "Minimum word length (1-9): " LENGTH
until [[ $LENGTH = [1-9] || [1-9][0-9] ]]; do
echo "Please only use 1-99."
read -p "Minimum word length (1-99): " LENGTH
done

echo -e "\nCeWL is going to start, this will take some time..."
echo -e "\nNOTE: If it takes to long, use CTRL+C to stop where CeWL is currently at, this will result in an output file.\n"

$CEWL -d $DEPTH -m $LENGTH -w $CEWLLIST $URL -u "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.169 Safari/537.36"

echo -e "\nCeWL created a wordlist named:" $CEWLLIST "\n"
2 changes: 1 addition & 1 deletion scripts/processors/light.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ fi

# Rules
source scripts/rules/rules.config
RULELIST=($rule3 $rockyou30000 $ORTRTA $fbtop $OUTD $TOXICSP $passwordpro $d3ad0ne $d3adhob0 $generated2 $toprules2020 $digits1 $digits2 $hob064 $leetspeak $toggles1 $toggles2)
RULELIST=($rule3 $rockyou30000 $ORTRTS $fbtop $OUTD $TOXICSP $passwordpro $d3ad0ne $d3adhob0 $generated2 $toprules2020 $digits1 $digits2 $hob064 $leetspeak $toggles1 $toggles2)

# Logic
$HASHCAT $KERNEL --bitmap-max=24 --hwmon-disable --potfile-path=$POTFILE -m$HASHTYPE $HASHLIST $WORDLIST
Expand Down
6 changes: 3 additions & 3 deletions scripts/processors/markov-generator.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ source scripts/selectors/hashlist.sh

# Rules
source scripts/rules/rules.config
RULELIST=($rule3 $rockyou30000 $ORTRTA $fbfull $pantag $OUTD $techtrip2 $TOXICSP $passwordpro $d3ad0ne $d3adhob0 $generated2 $toprules2020 $hob064 $leetspeak)
RULELIST=($rule3 $rockyou30000 $ORTRTS $fbfull $pantag $OUTD $techtrip2 $TOXICSP $passwordpro $d3ad0ne $d3adhob0 $generated2 $toprules2020 $hob064 $leetspeak)

# Logic
read -p "Use potfile (p) or wordlist (w): " LIST
Expand All @@ -31,11 +31,11 @@ read -p "Use rules? (y/n): " USERULES

if [[ $USERULES =~ ^[Yy]$ ]]; then
for RULE in ${RULELIST[*]}; do
$HASHCAT $KERNEL --bitmap-max=24 --potfile-path=$POTFILE -m$HASHTYPE $HASHLIST tmp_pwcreated -r $RULE --loopback
$HASHCAT $KERNEL --bitmap-max=24 --hwmon-disable --potfile-path=$POTFILE -m$HASHTYPE $HASHLIST tmp_pwcreated -r $RULE --loopback
done
rm tmp_pwcreated
elif [[ $USERULES =~ ^[Nn]$ ]]; then
$HASHCAT $KERNEL --bitmap-max=24 --potfile-path=$POTFILE -m$HASHTYPE $HASHLIST tmp_pwcreated
$HASHCAT $KERNEL --bitmap-max=24 --hwmon-disable --potfile-path=$POTFILE -m$HASHTYPE $HASHLIST tmp_pwcreated
rm tmp_pwcreated
else
echo -e "Try again...\n"
Expand Down
2 changes: 1 addition & 1 deletion scripts/processors/multiple-wordlists.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ source scripts/selectors/multiple-wordlist.sh

# Rules
source scripts/rules/rules.config
RULELIST=($ORTRTA)
RULELIST=($ORTRTS)

# Logic
$HASHCAT $KERNEL --bitmap-max=24 --hwmon-disable --potfile-path=$POTFILE -m$HASHTYPE $HASHLIST $WORDLIST
Expand Down
2 changes: 1 addition & 1 deletion scripts/processors/toggle.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ fi

# Rules
source scripts/rules/rules.config
RULELIST=($rockyou30000 $ORTRTA $OUTD $passwordpro $d3ad0ne $d3adhob0 $generated2 $toprules2020 $digits1 $digits2 $hob064 $leetspeak $toggles1 $toggles2)
RULELIST=($rockyou30000 $ORTRTS $OUTD $passwordpro $d3ad0ne $d3adhob0 $generated2 $toprules2020 $digits1 $digits2 $hob064 $leetspeak $toggles1 $toggles2)

# Logic
for RULE in ${RULELIST[*]}; do
Expand Down
2 changes: 1 addition & 1 deletion scripts/processors/usernameaspassword.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ source scripts/selectors/hashlist.sh

# Rules
source scripts/rules/rules.config
RULELIST=($big $fbfull $d3ad0ne $d3adhob0 $digits1 $digits2 $digits3 $dive $fordyv1 $generated2 $generated3 $hob064 $huge $leetspeak $NSAKEYv2 $ORTRTA $OUTD $pantag $passwordpro $rockyou30000 $techtrip2 $tenKrules $toggles1 $toggles2 $toprules2020 $TOXIC10k $TOXICSP $williamsuper)
RULELIST=($big $fbfull $d3ad0ne $d3adhob0 $digits1 $digits2 $digits3 $dive $fordyv1 $generated2 $generated3 $hob064 $huge $leetspeak $NSAKEYv2 $ORTRTS $OUTD $pantag $passwordpro $rockyou30000 $techtrip2 $tenKrules $toggles1 $toggles2 $toprules2020 $TOXIC10k $TOXICSP $williamsuper)

# Logic
cat $HASHLIST | cut -d '\' -f2 | awk -F: '{print $1}' > tmp_usernames
Expand Down
44 changes: 0 additions & 44 deletions scripts/requirements.sh

This file was deleted.

Loading

0 comments on commit e01044b

Please sign in to comment.