LandGrey / pydictor

A powerful and useful hacker dictionary builder for a brute-force attack
https://github.com/LandGrey/pydictor
GNU General Public License v3.0
3.22k stars 630 forks source link

Function --repeat fails with Python3 #26

Closed Mi-Al closed 3 years ago

Mi-Al commented 3 years ago

Hello! When I run the uniqifer tool with the --repeat function using Python3, like this:

python3 pydictor.py -tool uniqifer ~/rockyou_clean.txt --repeat "<=3" ">=3" "==0" -o ~/uniq.txt

Then an error occurs:

[-] Exception as following:

Traceback (most recent call last): File "/home/mial/bin/pydictor/lib/fun/decorator.py", line 22, in magic item = filterforfun(item) File "/home/mial/bin/pydictor/lib/fun/filter.py", line 243, in filterforfun item = repeat_filter(item, letter_repeat=pyoptions.letter_repeat, digital_repeat=pyoptions.digital_repeat, File "/home/mial/bin/pydictor/lib/fun/filter.py", line 151, in repeat_filter key = r.keys()[0] TypeError: 'dict_keys' object is not subscriptable None

But if I run the same command with Python2, then everything works fine:

python2 pydictor.py -tool uniqifer ~/rockyou_clean.txt --repeat "<=3" ">=3" "==0" -o ~/uniq.txt

LandGrey commented 3 years ago

Hello! When I run the uniqifer tool with the --repeat function using Python3, like this:

python3 pydictor.py -tool uniqifer ~/rockyou_clean.txt --repeat "<=3" ">=3" "==0" -o ~/uniq.txt

Then an error occurs:

[-] Exception as following: Traceback (most recent call last): File "/home/mial/bin/pydictor/lib/fun/decorator.py", line 22, in magic item = filterforfun(item) File "/home/mial/bin/pydictor/lib/fun/filter.py", line 243, in filterforfun item = repeat_filter(item, letter_repeat=pyoptions.letter_repeat, digital_repeat=pyoptions.digital_repeat, File "/home/mial/bin/pydictor/lib/fun/filter.py", line 151, in repeat_filter key = r.keys()[0] TypeError: 'dict_keys' object is not subscriptable None

But if I run the same command with Python2, then everything works fine:

python2 pydictor.py -tool uniqifer ~/rockyou_clean.txt --repeat "<=3" ">=3" "==0" -o ~/uniq.txt

The bug has been fixed at this commit on pydictor 2.1.5.3 version.

Mi-Al commented 3 years ago

Thank you!