[GH-ISSUE #2651] Ethereum pre-sale issue. #1717

Closed
opened 2026-10-15 04:23:12 +07:00 by bsakaguchi · 10 comments
Owner

Originally created by @kost123 on GitHub (Aug 3, 2017).
Original GitHub issue: https://github.com/openwall/john/issues/2651

When trying to crack ethereum presale wallets with CPU or OpenCL (same problem) sometimes it finishes too early. Bruteforce/mask seems to work OK but when using wordlists it doesn't.

I started a wordlist of 20 GB yesterday on GPU and its ETA was 11 hours, but it finished in 2.5 hours, I tried a smaller list of about 10k passwords on CPU and it finished at about 33%.

Temps are fine.

Originally created by @kost123 on GitHub (Aug 3, 2017). Original GitHub issue: https://github.com/openwall/john/issues/2651 When trying to crack ethereum presale wallets with CPU or OpenCL (same problem) sometimes it finishes too early. Bruteforce/mask seems to work OK but when using wordlists it doesn't. I started a wordlist of 20 GB yesterday on GPU and its ETA was 11 hours, but it finished in 2.5 hours, I tried a smaller list of about 10k passwords on CPU and it finished at about 33%. Temps are fine.
bsakaguchi 2026-10-15 04:23:12 +07:00
Author
Owner

@kholia commented on GitHub (Aug 4, 2017):

How can I reproduce this problem locally? Describe all the steps involved in detail.

Which dictionary file were you using? Can you provide a sample hash which exhibits this problem?

Is the problem reproducible with the following (common) dictionary?

https://github.com/danielmiessler/SecLists/blob/master/Passwords/10k_most_common.txt

<!-- gh-comment-id:320146034 --> @kholia commented on GitHub (Aug 4, 2017): How can I reproduce this problem locally? Describe all the steps involved in detail. Which dictionary file were you using? Can you provide a sample hash which exhibits this problem? Is the problem reproducible with the following (common) dictionary? https://github.com/danielmiessler/SecLists/blob/master/Passwords/10k_most_common.txt
Author
Owner

@kost123 commented on GitHub (Aug 4, 2017):

I used HashesOrg list from weakpass.com with some simple rules appending 1-4 and do nothing.

I can't provide a sample hash. But I was able to produce it with a smaller wordlist:

roflcopy1
roflcopy2
roflcopy3
roflcopy4
roflcopy5
roflcopy6
roflcopy7
roflcopy8
roflcopy9
roflcopy10
roflcopy11
roflcopy12
roflcopy13
roflcopy14
roflcopy15
roflcopy16
roflcopy17
roflcopy18
roflcopy19
roflcopy20
roflcopy21
roflcopy22
roflcopy23
roflcopy24

Use this with --rules:jumbo

It exits at 30% or so

I am spamming S for status as hard as I can here:

0g 0:00:00:02 4.64% (ETA: 05:01:53) 0g/s 7306p/s 7306c/s 7306C/s Roflcopy288888..roflcopy17123456
0g 0:00:00:03 7.88% (ETA: 05:01:48) 0g/s 7244p/s 7244c/s 7244C/s RofLcOPY18..RofLCOpY9
0g 0:00:00:04 9.41% (ETA: 05:01:52) 0g/s 7265p/s 7265c/s 7265C/s roflcopy10386..roflcopy1389
0g 0:00:00:05 10.93% (ETA: 05:01:55) 0g/s 7270p/s 7270c/s 7270C/s roflcopy2725..roflcopy17727
0g 0:00:00:06 12.46% (ETA: 05:01:58) 0g/s 7277p/s 7277c/s 7277C/s roflcopy18063..roflcopy9066
0g 0:00:00:07 13.98% (ETA: 05:02:00) 0g/s 7280p/s 7280c/s 7280C/s Roflcopy10402..Roflcopy1405
0g 0:00:00:08 15.51% (ETA: 05:02:02) 0g/s 7284p/s 7284c/s 7284C/s Roflcopy2741..Roflcopy17743
0g 0:00:00:10 17.03% (ETA: 05:02:08) 0g/s 7299p/s 7299c/s 7299C/s Roflcopy18079..Roflcopy9082
0g 0:00:00:11 18.56% (ETA: 05:02:09) 0g/s 7303p/s 7303c/s 7303C/s roflcopy10mg..roflcopy1mj
0g 0:00:00:12 20.08% (ETA: 05:02:09) 0g/s 7301p/s 7301c/s 7301C/s roflcopy2zh..roflcopy17zj
0g 0:00:00:13 24.65% (ETA: 05:02:02) 0g/s 7308p/s 7308c/s 7308C/s mroflcopy18h..mroflcopy9k
0g 0:00:00:14 26.17% (ETA: 05:02:03) 0g/s 7308p/s 7308c/s 7308C/s zroflcopy10i..zroflcopy1l
0g 0:00:00:15 DONE (2017-08-04 05:01) 0g/s 7303p/s 7303c/s 7303C/s ROFLCOPY10..ROFLCOPY24
Session completed

I'm not able to reproduce it on the list you sent me using basic rules, and it will take too long to use jumbo rules on it, but again I didn't use jumbo rules on HashesOrg list. Very odd, I was thinking it could have been skipping passwords but to skip 66%+ of passwords doesn't seem right.

<!-- gh-comment-id:320148525 --> @kost123 commented on GitHub (Aug 4, 2017): I used HashesOrg list from weakpass.com with some simple rules appending 1-4 and do nothing. I can't provide a sample hash. But I was able to produce it with a smaller wordlist: roflcopy1 roflcopy2 roflcopy3 roflcopy4 roflcopy5 roflcopy6 roflcopy7 roflcopy8 roflcopy9 roflcopy10 roflcopy11 roflcopy12 roflcopy13 roflcopy14 roflcopy15 roflcopy16 roflcopy17 roflcopy18 roflcopy19 roflcopy20 roflcopy21 roflcopy22 roflcopy23 roflcopy24 Use this with --rules:jumbo It exits at 30% or so I am spamming S for status as hard as I can here: ``` 0g 0:00:00:02 4.64% (ETA: 05:01:53) 0g/s 7306p/s 7306c/s 7306C/s Roflcopy288888..roflcopy17123456 0g 0:00:00:03 7.88% (ETA: 05:01:48) 0g/s 7244p/s 7244c/s 7244C/s RofLcOPY18..RofLCOpY9 0g 0:00:00:04 9.41% (ETA: 05:01:52) 0g/s 7265p/s 7265c/s 7265C/s roflcopy10386..roflcopy1389 0g 0:00:00:05 10.93% (ETA: 05:01:55) 0g/s 7270p/s 7270c/s 7270C/s roflcopy2725..roflcopy17727 0g 0:00:00:06 12.46% (ETA: 05:01:58) 0g/s 7277p/s 7277c/s 7277C/s roflcopy18063..roflcopy9066 0g 0:00:00:07 13.98% (ETA: 05:02:00) 0g/s 7280p/s 7280c/s 7280C/s Roflcopy10402..Roflcopy1405 0g 0:00:00:08 15.51% (ETA: 05:02:02) 0g/s 7284p/s 7284c/s 7284C/s Roflcopy2741..Roflcopy17743 0g 0:00:00:10 17.03% (ETA: 05:02:08) 0g/s 7299p/s 7299c/s 7299C/s Roflcopy18079..Roflcopy9082 0g 0:00:00:11 18.56% (ETA: 05:02:09) 0g/s 7303p/s 7303c/s 7303C/s roflcopy10mg..roflcopy1mj 0g 0:00:00:12 20.08% (ETA: 05:02:09) 0g/s 7301p/s 7301c/s 7301C/s roflcopy2zh..roflcopy17zj 0g 0:00:00:13 24.65% (ETA: 05:02:02) 0g/s 7308p/s 7308c/s 7308C/s mroflcopy18h..mroflcopy9k 0g 0:00:00:14 26.17% (ETA: 05:02:03) 0g/s 7308p/s 7308c/s 7308C/s zroflcopy10i..zroflcopy1l 0g 0:00:00:15 DONE (2017-08-04 05:01) 0g/s 7303p/s 7303c/s 7303C/s ROFLCOPY10..ROFLCOPY24 Session completed ``` I'm not able to reproduce it on the list you sent me using basic rules, and it will take too long to use jumbo rules on it, but again I didn't use jumbo rules on HashesOrg list. Very odd, I was thinking it could have been skipping passwords but to skip 66%+ of passwords doesn't seem right.
Author
Owner

@kholia commented on GitHub (Aug 4, 2017):

I was able to observe similar behavior with following steps,

$ cat wordlist
roflcopy1
roflcopy2
roflcopy3
roflcopy4
roflcopy5
roflcopy6

Here is a sample hash for testing,

$ethereum$w*4ab35fcb5c3101af70d5b3bf22829af3dbd48813273b17566ee364285c7bcfb2d52611a58e54d3e6be27e458073304e71e356afc4c97da0143910308f30563fe*c4dfdaa5288b477d0ff25a260ef32a24282cc4e2*97b3d2c2c8106507b87744f0b12f73c2

$ ../run/john hash -w=wordlist --rules=jumbo
...
Press 'q' or Ctrl-C to abort, almost any other key for status
0g 0:00:00:01 2.97% (ETA: 09:33:31) 0g/s 1674p/s 1690c/s 1674C/s y5roflcop..Rolcopy5
0g 0:00:00:02 4.26% (ETA: 09:33:44) 0g/s 1694p/s 1694c/s 1694C/s Roflcopy662..Roflcopy144
0g 0:00:00:03 7.32% (ETA: 09:33:38) 0g/s 1698p/s 1698c/s 1698C/s ROfLcOpy4..rOflcoPy5
0g 0:00:00:05 9.82% (ETA: 09:33:48) 0g/s 1708p/s 1708c/s 1708C/s roflcopy2459..roflcopy3480
0g 0:00:00:06 11.17% (ETA: 09:33:51) 0g/s 1708p/s 1708c/s 1708C/s roflcopy6757..roflcopy1779
0g 0:00:00:09 15.01% (ETA: 09:33:57) 0g/s 1711p/s 1711c/s 1711C/s Roflcopy2611..Roflcopy3632
0g 0:00:00:10 16.26% (ETA: 09:33:59) 0g/s 1710p/s 1710c/s 1710C/s Roflcopy4888..Roflcopy5909
0g 0:00:00:11 17.50% (ETA: 09:34:00) 0g/s 1707p/s 1707c/s 1707C/s roflcopy6cn..roflcopy1dj
0g 0:00:00:12 18.85% (ETA: 09:34:01) 0g/s 1705p/s 1705c/s 1705C/s roflcopy4oa..roflcopy5ov
0g 0:00:00:13 20.10% (ETA: 09:34:02) 0g/s 1704p/s 1704c/s 1704C/s roflcopy6yr..roflcopy1zn
0g 0:00:00:14 24.39% (ETA: 09:33:55) 0g/s 1701p/s 1701c/s 1701C/s jroflcopy2j..kroflcopy3e
0g 0:00:00:15 25.64% (ETA: 09:33:56) 0g/s 1697p/s 1697c/s 1697C/s uroflcopy4a..uroflcopy5v
0g 0:00:00:16 26.89% (ETA: 09:33:57) 0g/s 1694p/s 1694c/s 1694C/s ROFlCoPy6..roFlcopY1
0g 0:00:00:16 DONE (2017-08-04 09:33) 0g/s 1691p/s 1691c/s 1691C/s ROFLcOpY6..ROFLCOPY6

@magnumripper Your advice is needed here. I have no idea about what is going wrong here!

<!-- gh-comment-id:320151564 --> @kholia commented on GitHub (Aug 4, 2017): I was able to observe similar behavior with following steps, ``` $ cat wordlist roflcopy1 roflcopy2 roflcopy3 roflcopy4 roflcopy5 roflcopy6 ``` Here is a sample hash for testing, `$ethereum$w*4ab35fcb5c3101af70d5b3bf22829af3dbd48813273b17566ee364285c7bcfb2d52611a58e54d3e6be27e458073304e71e356afc4c97da0143910308f30563fe*c4dfdaa5288b477d0ff25a260ef32a24282cc4e2*97b3d2c2c8106507b87744f0b12f73c2` ``` $ ../run/john hash -w=wordlist --rules=jumbo ... Press 'q' or Ctrl-C to abort, almost any other key for status 0g 0:00:00:01 2.97% (ETA: 09:33:31) 0g/s 1674p/s 1690c/s 1674C/s y5roflcop..Rolcopy5 0g 0:00:00:02 4.26% (ETA: 09:33:44) 0g/s 1694p/s 1694c/s 1694C/s Roflcopy662..Roflcopy144 0g 0:00:00:03 7.32% (ETA: 09:33:38) 0g/s 1698p/s 1698c/s 1698C/s ROfLcOpy4..rOflcoPy5 0g 0:00:00:05 9.82% (ETA: 09:33:48) 0g/s 1708p/s 1708c/s 1708C/s roflcopy2459..roflcopy3480 0g 0:00:00:06 11.17% (ETA: 09:33:51) 0g/s 1708p/s 1708c/s 1708C/s roflcopy6757..roflcopy1779 0g 0:00:00:09 15.01% (ETA: 09:33:57) 0g/s 1711p/s 1711c/s 1711C/s Roflcopy2611..Roflcopy3632 0g 0:00:00:10 16.26% (ETA: 09:33:59) 0g/s 1710p/s 1710c/s 1710C/s Roflcopy4888..Roflcopy5909 0g 0:00:00:11 17.50% (ETA: 09:34:00) 0g/s 1707p/s 1707c/s 1707C/s roflcopy6cn..roflcopy1dj 0g 0:00:00:12 18.85% (ETA: 09:34:01) 0g/s 1705p/s 1705c/s 1705C/s roflcopy4oa..roflcopy5ov 0g 0:00:00:13 20.10% (ETA: 09:34:02) 0g/s 1704p/s 1704c/s 1704C/s roflcopy6yr..roflcopy1zn 0g 0:00:00:14 24.39% (ETA: 09:33:55) 0g/s 1701p/s 1701c/s 1701C/s jroflcopy2j..kroflcopy3e 0g 0:00:00:15 25.64% (ETA: 09:33:56) 0g/s 1697p/s 1697c/s 1697C/s uroflcopy4a..uroflcopy5v 0g 0:00:00:16 26.89% (ETA: 09:33:57) 0g/s 1694p/s 1694c/s 1694C/s ROFlCoPy6..roFlcopY1 0g 0:00:00:16 DONE (2017-08-04 09:33) 0g/s 1691p/s 1691c/s 1691C/s ROFLcOpY6..ROFLCOPY6 ``` @magnumripper Your advice is needed here. I have no idea about what is going wrong here!
Author
Owner

@kost123 commented on GitHub (Aug 4, 2017):

Ok so..

I'll switch to password* just to make it easier:

When trying

password1
password2
password3
password4
password5
password6

It stops at 30% mark ish.

When I scramble the passwords to this:

passrgrword1
passwrgrord2
passworergrd3
passwordgreg4
passgrgrgword5
parggrgssword6

It makes it to 50%

some more..

passrgrword1
passwgregrgrord2
pasregrgsworergrd3
passrgregwordgreg4
pargrgssgrgrgword5
pgrgarggrgssword6

100%

It is removing duplicates but not updating the % done? Is it possible that 66%+ of hashesorg is duplicates when used with rules? It certainly seems possible with these small lists.

Edit: It seems it happens on all hashtypes so you can change the title name if possible.

Edit2: even stranger behaviour when using a larger password list (same format as before) with --rules:Wordlist, it just jumps 10% then 23% then finishes.

0g 0:00:00:02 1.03% (ETA: 06:09:39) 0g/s 7692p/s 7692c/s 7692C/s password1..password6
0g 0:00:00:03 1.55% (ETA: 06:09:39) 0g/s 7666p/s 7666c/s 7666C/s password1..password6
0g 0:00:00:04 3.82% (ETA: 06:08:10) 0g/s 7648p/s 7648c/s 7648C/s Password1..Password6
0g 0:00:00:05 4.34% (ETA: 06:08:22) 0g/s 7637p/s 7637c/s 7637C/s Password1..Password6
0g 0:00:00:07 4.86% (ETA: 06:08:50) 0g/s 7594p/s 7594c/s 7594C/s Password1..Password6
0g 0:00:00:08 15.90% (ETA: 06:07:16) 0g/s 7615p/s 7615c/s 7615C/s PASSWORD1..PASSWORD6
0g 0:00:00:09 16.42% (ETA: 06:07:20) 0g/s 7614p/s 7614c/s 7614C/s PASSWORD1..PASSWORD6
0g 0:00:00:10 16.94% (ETA: 06:07:25) 0g/s 7623p/s 7623c/s 7623C/s PASSWORD1..PASSWORD6
0g 0:00:00:11 17.45% (ETA: 06:07:30) 0g/s 7645p/s 7645c/s 7645C/s PASSWORD1..PASSWORD6
0g 0:00:00:13 40.78% (ETA: 06:06:57) 0g/s 7627p/s 7627c/s 7627C/s psswrd1..psswrd6
0g 0:00:00:14 41.30% (ETA: 06:06:59) 0g/s 7607p/s 7607c/s 7607C/s psswrd1..psswrd6
0g 0:00:00:15 41.81% (ETA: 06:07:01) 0g/s 7621p/s 7621c/s 7621C/s psswrd1..psswrd6
0g 0:00:00:16 DONE (2017-08-04 06:06) 0g/s 7602p/s 7602c/s 7602C/s psswrd1..psswrd6
Session completed

Your wordlist you provided does not have this problem so I'm thinking this must just be some duplicate problem, "Wordlist" rule set must not contain many duplicates but has them in different parts. However jumbo uses Wordlist, Single, NT and OldOffice which must have ALOT of duplicates from the Wordlist set to finish really fast appearing to just stop, but you would think single has a whole lot more variations than Wordlist and HashesOrg would not create 70% duplicates in 4 append rules.

<!-- gh-comment-id:320153017 --> @kost123 commented on GitHub (Aug 4, 2017): Ok so.. I'll switch to password* just to make it easier: When trying ``` password1 password2 password3 password4 password5 password6 ``` It stops at 30% mark ish. When I scramble the passwords to this: ``` passrgrword1 passwrgrord2 passworergrd3 passwordgreg4 passgrgrgword5 parggrgssword6 ``` It makes it to 50% some more.. ``` passrgrword1 passwgregrgrord2 pasregrgsworergrd3 passrgregwordgreg4 pargrgssgrgrgword5 pgrgarggrgssword6 ``` 100% It is removing duplicates but not updating the % done? Is it possible that 66%+ of hashesorg is duplicates when used with rules? It certainly seems possible with these small lists. Edit: It seems it happens on all hashtypes so you can change the title name if possible. Edit2: even stranger behaviour when using a larger password list (same format as before) with --rules:Wordlist, it just jumps 10% then 23% then finishes. ``` 0g 0:00:00:02 1.03% (ETA: 06:09:39) 0g/s 7692p/s 7692c/s 7692C/s password1..password6 0g 0:00:00:03 1.55% (ETA: 06:09:39) 0g/s 7666p/s 7666c/s 7666C/s password1..password6 0g 0:00:00:04 3.82% (ETA: 06:08:10) 0g/s 7648p/s 7648c/s 7648C/s Password1..Password6 0g 0:00:00:05 4.34% (ETA: 06:08:22) 0g/s 7637p/s 7637c/s 7637C/s Password1..Password6 0g 0:00:00:07 4.86% (ETA: 06:08:50) 0g/s 7594p/s 7594c/s 7594C/s Password1..Password6 0g 0:00:00:08 15.90% (ETA: 06:07:16) 0g/s 7615p/s 7615c/s 7615C/s PASSWORD1..PASSWORD6 0g 0:00:00:09 16.42% (ETA: 06:07:20) 0g/s 7614p/s 7614c/s 7614C/s PASSWORD1..PASSWORD6 0g 0:00:00:10 16.94% (ETA: 06:07:25) 0g/s 7623p/s 7623c/s 7623C/s PASSWORD1..PASSWORD6 0g 0:00:00:11 17.45% (ETA: 06:07:30) 0g/s 7645p/s 7645c/s 7645C/s PASSWORD1..PASSWORD6 0g 0:00:00:13 40.78% (ETA: 06:06:57) 0g/s 7627p/s 7627c/s 7627C/s psswrd1..psswrd6 0g 0:00:00:14 41.30% (ETA: 06:06:59) 0g/s 7607p/s 7607c/s 7607C/s psswrd1..psswrd6 0g 0:00:00:15 41.81% (ETA: 06:07:01) 0g/s 7621p/s 7621c/s 7621C/s psswrd1..psswrd6 0g 0:00:00:16 DONE (2017-08-04 06:06) 0g/s 7602p/s 7602c/s 7602C/s psswrd1..psswrd6 Session completed ``` Your wordlist you provided does not have this problem so I'm thinking this must just be some duplicate problem, "Wordlist" rule set must not contain many duplicates but has them in different parts. However jumbo uses Wordlist, Single, NT and OldOffice which must have ALOT of duplicates from the Wordlist set to finish really fast appearing to just stop, but you would think single has a whole lot more variations than Wordlist and HashesOrg would not create 70% duplicates in 4 append rules.
Author
Owner

@ghost commented on GitHub (Aug 5, 2017):

Using:

../run/john  -w=wordlist --rules=jumbo --stdout > full
sort full | uniq > cleaned
wc -l cleaned

I compared:

passrgrword1
passwgregrgrord2
pasregrgsworergrd3
passrgregwordgreg4
pargrgssgrgrgword5
pgrgarggrgssword6

versus

roflcopy1
roflcopy2
roflcopy3
roflcopy4
roflcopy5
roflcopy6

Then, I checked that, e.g. 16 seconds * 7602 p/s, is the expected number of candidates.
0g 0:00:00:16 DONE (2017-08-04 06:06) 0g/s 7602p/s 7602c/s 7602C/s psswrd1..psswrd6

So, ETA was not updated fast enough. Other than this, reasonable results.


I tried a 386M wordlist and was able see ETA changing a lot. Have your checked how your 20GB wordlist behaves?

<!-- gh-comment-id:320390215 --> @ghost commented on GitHub (Aug 5, 2017): Using: ``` ../run/john -w=wordlist --rules=jumbo --stdout > full sort full | uniq > cleaned wc -l cleaned ``` I compared: ``` passrgrword1 passwgregrgrord2 pasregrgsworergrd3 passrgregwordgreg4 pargrgssgrgrgword5 pgrgarggrgssword6 ``` versus ``` roflcopy1 roflcopy2 roflcopy3 roflcopy4 roflcopy5 roflcopy6 ``` Then, I checked that, e.g. `16 seconds * 7602 p/s`, is the expected number of candidates. `0g 0:00:00:16 DONE (2017-08-04 06:06) 0g/s 7602p/s 7602c/s 7602C/s psswrd1..psswrd6` So, ETA was not updated fast enough. Other than this, reasonable results. *** I tried a 386M wordlist and was able see ETA changing a lot. Have your checked how your 20GB wordlist behaves?
Author
Owner

@kost123 commented on GitHub (Aug 5, 2017):

When you say not updated fast enough.. the output I posted above I tried on a list of about 10,000 passwords all of password1, password2.. etc format and it wasn't really a case of not being updated fast enough it was random jumps throughout, also why would the ETA not update fast enough for similar passwords but update fine on jumbled up ones?

My 20GB list which is really just a 4gb with some rules. I started and checked the status a few times, all of which was ok for the 10minutes I was checking, then I went to sleep and woke up and checked and it finished in 2.5hours instead of the 11-12hours it said when I started it.

<!-- gh-comment-id:320390999 --> @kost123 commented on GitHub (Aug 5, 2017): When you say not updated fast enough.. the output I posted above I tried on a list of about 10,000 passwords all of password1, password2.. etc format and it wasn't really a case of not being updated fast enough it was random jumps throughout, also why would the ETA not update fast enough for similar passwords but update fine on jumbled up ones? My 20GB list which is really just a 4gb with some rules. I started and checked the status a few times, all of which was ok for the 10minutes I was checking, then I went to sleep and woke up and checked and it finished in 2.5hours instead of the 11-12hours it said when I started it.
Author
Owner

@ghost commented on GitHub (Aug 5, 2017):

also why would the ETA not update fast enough for similar passwords but update fine on jumbled up ones?

Ok, you are right to disbelieve me. What I thought was:

  • we are running 22k rules (approx) in the example;
  • --rules=jumbo has a rule that deletes the last character; similarity becomes equality;
  • then the [1] rule Q start rejecting all/every rule after # 7k (or 25%);
  • all rules were tried; but a lot were rejected and it seemed correct on a first thought;
  • at the end, I used stdoutand wc to confirm that things make sense;
  • when running on a dissimilar wordlist, a lot of rules/words are rejected (above rule # 7k), but not all of them.

That said, I was confident things were ok, but I failed to make a prove that JtR is working properly and the issue remains open.


[1] Q query the memory and reject the word unless it has changed

PS:
Based on JtR internals: rule_number, rules_pass, rule_count, ...

<!-- gh-comment-id:320451249 --> @ghost commented on GitHub (Aug 5, 2017): > also why would the ETA not update fast enough for similar passwords but update fine on jumbled up ones? Ok, you are right to disbelieve me. What I thought was: - we are running 22k rules (approx) in the example; - `--rules=jumbo` has a rule that deletes the last character; similarity becomes equality; - then the [1] rule `Q` start rejecting all/every rule after # 7k (or 25%); - all rules were tried; but a lot were rejected and it seemed correct on a first thought; - at the end, I used `stdout`and `wc` to confirm that things make sense; - when running on a dissimilar wordlist, a lot of rules/words are rejected (above rule # 7k), but not all of them. That said, I was confident things were ok, but I failed to make a prove that JtR is working properly and the issue remains open. **** [1] Q query the memory and reject the word unless it has changed PS: Based on JtR internals: rule_number, rules_pass, rule_count, ...
Author
Owner

@ghost commented on GitHub (Aug 5, 2017):

  • As another evidence, I patched JtR to do nothing on Q rule:
diff --git a/src/rules.c b/src/rules.c
index 94ca9eb..0531fd7 100644
--- a/src/rules.c
+++ b/src/rules.c
@@ -1867,8 +1867,8 @@ char *rules_apply(char *word_in, char *rule, int split, char *last)
                        break;
 
                case 'Q':
-                       if (!strncmp(memory, in, rules_max_length))
-                               REJECT
+                       //if (!strncmp(memory, in, rules_max_length))
+                       //      REJECT
                        break;
 
                case 'X': /* append/insert/prepend substring from memory */
  • Patched, it run up to 100% (producing dupes is my guess).
0g 0:00:03:06 95,52% (ETA: 19:39:27) 0g/s 640.3p/s 640.3c/s 640.3C/s ROFlcopy2..ROFlcopy5
0g 0:00:03:07 95,95% (ETA: 19:39:27) 0g/s 640.2p/s 640.2c/s 640.2C/s ROFlcoPY2..ROFlcoPY5
0g 0:00:03:08 96,48% (ETA: 19:39:27) 0g/s 640.3p/s 640.3c/s 640.3C/s ROFlcOPY4..ROFlcOPY1
0g 0:00:03:09 96,96% (ETA: 19:39:27) 0g/s 640.3p/s 640.3c/s 640.3C/s ROFlCoPy2..ROFlCoPy5
0g 0:00:03:10 97,44% (ETA: 19:39:27) 0g/s 640.5p/s 640.5c/s 640.5C/s ROFlCOpY6..ROFlCOPy3
0g 0:00:03:11 97,97% (ETA: 19:39:27) 0g/s 640.6p/s 640.6c/s 640.6C/s ROFLcopY2..ROFLcopY5
0g 0:00:03:12 98,45% (ETA: 19:39:28) 0g/s 640.7p/s 640.7c/s 640.7C/s ROFLcOpy6..ROFLcOpY3
0g 0:00:03:13 98,93% (ETA: 19:39:28) 0g/s 640.8p/s 640.8c/s 640.8C/s ROFLCopy4..ROFLCopy1
0g 0:00:03:14 99,46% (ETA: 19:39:28) 0g/s 641.0p/s 641.0c/s 641.0C/s ROFLCoPY6..ROFLCOpy3
0g 0:00:03:15 99,94% (ETA: 19:39:28) 0g/s 641.1p/s 641.1c/s 641.1C/s ROFLCOPY4..ROFLCOPY1
0g 0:00:03:15 DONE (2017-08-05 19:39) 0g/s 641.0p/s 641.0c/s 641.0C/s ROFLCOPY6..ROFLCOPY6
  • Then, I compared the two wordlists+rules produced. At last, diff told me both files are equal.
$ ../run/john  -w=wordlist --rules=jumbo --stdout > regular
Press 'q' or Ctrl-C to abort, almost any other key for status
28063p 0:00:00:00 100,00% (2017-08-05 19:50) 400900p/s ROFLCOPY6

$ sort regular | uniq > reg_uniq
$ wc -l reg_uniq
26311 reg_uniq

$ ../run/johnQ  -w=wordlist --rules=jumbo --stdout > Qless
Press 'q' or Ctrl-C to abort, almost any other key for status
125197p 0:00:00:00 100,00% (2017-08-05 19:51) 1788Kp/s ROFLCOPY6

$ sort Qless | uniq > q_uniq
[claudio@super src]$ wc -l q_uniq
26311 q_uniq

Don't be upset with me, but, I am convinced things are ok.

<!-- gh-comment-id:320455616 --> @ghost commented on GitHub (Aug 5, 2017): * As another evidence, I patched JtR to do nothing on `Q` rule: ``` diff --git a/src/rules.c b/src/rules.c index 94ca9eb..0531fd7 100644 --- a/src/rules.c +++ b/src/rules.c @@ -1867,8 +1867,8 @@ char *rules_apply(char *word_in, char *rule, int split, char *last) break; case 'Q': - if (!strncmp(memory, in, rules_max_length)) - REJECT + //if (!strncmp(memory, in, rules_max_length)) + // REJECT break; case 'X': /* append/insert/prepend substring from memory */ ``` * Patched, it run up to 100% (producing dupes is my guess). ``` 0g 0:00:03:06 95,52% (ETA: 19:39:27) 0g/s 640.3p/s 640.3c/s 640.3C/s ROFlcopy2..ROFlcopy5 0g 0:00:03:07 95,95% (ETA: 19:39:27) 0g/s 640.2p/s 640.2c/s 640.2C/s ROFlcoPY2..ROFlcoPY5 0g 0:00:03:08 96,48% (ETA: 19:39:27) 0g/s 640.3p/s 640.3c/s 640.3C/s ROFlcOPY4..ROFlcOPY1 0g 0:00:03:09 96,96% (ETA: 19:39:27) 0g/s 640.3p/s 640.3c/s 640.3C/s ROFlCoPy2..ROFlCoPy5 0g 0:00:03:10 97,44% (ETA: 19:39:27) 0g/s 640.5p/s 640.5c/s 640.5C/s ROFlCOpY6..ROFlCOPy3 0g 0:00:03:11 97,97% (ETA: 19:39:27) 0g/s 640.6p/s 640.6c/s 640.6C/s ROFLcopY2..ROFLcopY5 0g 0:00:03:12 98,45% (ETA: 19:39:28) 0g/s 640.7p/s 640.7c/s 640.7C/s ROFLcOpy6..ROFLcOpY3 0g 0:00:03:13 98,93% (ETA: 19:39:28) 0g/s 640.8p/s 640.8c/s 640.8C/s ROFLCopy4..ROFLCopy1 0g 0:00:03:14 99,46% (ETA: 19:39:28) 0g/s 641.0p/s 641.0c/s 641.0C/s ROFLCoPY6..ROFLCOpy3 0g 0:00:03:15 99,94% (ETA: 19:39:28) 0g/s 641.1p/s 641.1c/s 641.1C/s ROFLCOPY4..ROFLCOPY1 0g 0:00:03:15 DONE (2017-08-05 19:39) 0g/s 641.0p/s 641.0c/s 641.0C/s ROFLCOPY6..ROFLCOPY6 ``` * Then, I compared the two wordlists+rules produced. At last, `diff` told me both files are equal. ``` $ ../run/john -w=wordlist --rules=jumbo --stdout > regular Press 'q' or Ctrl-C to abort, almost any other key for status 28063p 0:00:00:00 100,00% (2017-08-05 19:50) 400900p/s ROFLCOPY6 $ sort regular | uniq > reg_uniq $ wc -l reg_uniq 26311 reg_uniq $ ../run/johnQ -w=wordlist --rules=jumbo --stdout > Qless Press 'q' or Ctrl-C to abort, almost any other key for status 125197p 0:00:00:00 100,00% (2017-08-05 19:51) 1788Kp/s ROFLCOPY6 $ sort Qless | uniq > q_uniq [claudio@super src]$ wc -l q_uniq 26311 q_uniq ``` Don't be upset with me, but, I am convinced things are ok.
Author
Owner

@kost123 commented on GitHub (Aug 6, 2017):

Ofcourse I am not upset! I am only trying to find the end result of this :) It does appear by your work that everything is fine, so any patch to this would be purely cosmetic. I'm not sure exactly how it would be possible to predict rejects and update the % status properly. At least it puts my mind at ease that I am not wasting time :)

<!-- gh-comment-id:320478302 --> @kost123 commented on GitHub (Aug 6, 2017): Ofcourse I am not upset! I am only trying to find the end result of this :) It does appear by your work that everything is fine, so any patch to this would be purely cosmetic. I'm not sure exactly how it would be possible to predict rejects and update the % status properly. At least it puts my mind at ease that I am not wasting time :)
Author
Owner

@kholia commented on GitHub (Aug 6, 2017):

Thanks for helping me out here @claudioandre 👍

<!-- gh-comment-id:320507354 --> @kholia commented on GitHub (Aug 6, 2017): Thanks for helping me out here @claudioandre 👍
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
openwall/john#1717
No description provided.