Dissable or speedup autotune
#1
Autotune is not a problem in 95% of the usage.

But, when I try it with Mask Attack and get the mask from Extreme Breach Masks (a big list of mask for every size) and yet order the mask from faster to slower, I have a problem.

Like, for 9 digits, there is about 229k lines of mask. From every line it NEED to run the autotune. In this way, for the firsts nk lines, the time running the autotune is BIGGER than the time cracking it. When every line takes about 10 minutes, this will  not be problem.

So, why not hashcat just run the autotune once?  Why do it need to do for every entry in the mask attack? How can I dissable it or use the values it gets?
Reply
#2
I feel your pain. I wish there was an "--autotune-classic" or similar that would revert to the old method.

Today, the only way to disable autotuning is to manually add your own tuning. On the command line, this is done with -n/--kernel-accel and -u/--kernel-loops. If you do a run, and watch for the accel/loop values that are calculated by autotuning, you can just steal those values and use them and they won't suck.

Side note: if each mask only takes a few seconds to run and you're doing 229k of them, you can probably combine quite a few of them into larger masks.
~
Reply
#3
(05-20-2023, 03:27 AM)royce Wrote: Today, the only way to disable autotuning is to manually add your own tuning. On the command line, this is done with -n/--kernel-accel and -u/--kernel-loops. If you do a run, and watch for the accel/loop values that are calculated by autotuning, you can just steal those values and use them and they won't suck.
The autotune just set this two values?  This is the same for every hash type and GPU? In other words, for the same hash and GPU, for every type of attack I try, the value will be the same? So, can I safety use it "hardcoded"?

(05-20-2023, 03:27 AM)royce Wrote: Side note: if each mask only takes a few seconds to run and you're doing 229k of them, you can probably combine quite a few of them into larger masks.
Lol, this was just my first test. And yes, even without autotune, there is the time to start-stop every line. I will need to code a logic to make this more fast Smile
Reply
#4
(05-20-2023, 03:27 AM)royce Wrote: revert to the old method.

When did that change happen?
Reply
#5
(05-20-2023, 05:06 PM)rodrigo.Brasil Wrote: The autotune just set this two values?  This is the same for every hash type and GPU? In other words, for the same hash and GPU, for every type of attack I try, the value will be the same? So, can I safety use it "hardcoded"?
Well, the tuning might be pretty different for different kinds of attacks. So you might want to run it and get the autotuned values for attacks of non-trivial run time.
~
Reply
#6
(05-27-2023, 06:14 AM)buka Wrote:
(05-20-2023, 03:27 AM)royce Wrote: revert to the old method.

When did that change happen?

Some time between 6.2.3 and 6.2.4 IIRC?
~
Reply
#7
(05-20-2023, 03:27 AM)royce Wrote: I feel your pain. I wish there was an "--autotune-classic" or similar that would revert to the old method.

Today, the only way to disable autotuning is to manually add your own tuning. On the command line, this is done with -n/--kernel-accel and -u/--kernel-loops. If you do a run, and watch for the accel/loop values that are calculated by autotuning, you can just steal those values and use them and they won't suck.

This worked very well. But I am a little insecure. What do those values impact my scenario? I am doing --a 3 -m 1000 (NTLM)? What effect will it have in the fastest case ?d?d?d...  and the slowest (?a?a?a..)? Like you say, I run and see what it calculates. But in the fastest cases, it changed the values. How I have to think about it?

Anyway, these are the values it calculates after autotune (more than the two you informed):
Code:
-n, --kernel-accel            | Num  | Manual workload tuning, set outerloop step size to X 
-u, --kernel-loops            | Num  | Manual workload tuning, set innerloop step size to X 
-T, --kernel-threads          | Num  | Manual workload tuning, set thread count to X        
    --backend-vector-width    | Num  | Manually override backend vector-width to X         

(05-20-2023, 03:27 AM)royce Wrote: Side note: if each mask only takes a few seconds to run and you're doing 229k of them, you can probably combine quite a few of them into larger masks.

This is interesting. Let's say I know the password needs to have one special character, but only one. How can I do this? I don't see another way than writing all the lines like:
Code:
?s?l?l?l?l?l
?l?s?l?l?l?l
?l?l?s?l?l?l
....
How can I combine this mask? Hashcat doesn't have this option to say: it needs to have one special character only. Maybe this could be a new feature!  Smile
Reply
#8
Just to point out my example, I know I can do things like:

Code:
--custom-charset1 ?u?l?d   

?s?1?1?!?1
?1?s?1?!?1
?1?1?s?!?1
....

The point here is the permutation. If I try to make something more complex: Let's say I know my password have:
  • One, and only one special character (in any place)
  • One, and only one upper
  • One, and only one lower
  • and the rest are digits

How can I write this rule without having to write all the permutations possible?
Reply
#9
(06-25-2023, 02:58 AM)rodrigo.Brasil Wrote: Just to point out my example, I know I can do things like:

Code:
--custom-charset1 ?u?l?d   

?s?1?1?!?1
?1?s?1?!?1
?1?1?s?!?1
....

The point here is the permutation. If I try to make something more complex: Let's say I know my password have:
  • One, and only one special character (in any place)
  • One, and only one upper
  • One, and only one lower
  • and the rest are digits

How can I write this rule without having to write all the permutations possible?

Let me give it a go for your requirement.
Using mask:
?l?u?s?d?d?d?d?d
?u?s?l?d?d?d?d?d
?s?l?u?d?d?d?d?d
?l?s?u?d?d?d?d?d
?s?u?l?d?d?d?d?d
?u?l?s?d?d?d?d?d


?d?l?u?s?d?d?d?d
?d?u?s?l?d?d?d?d
?d?s?l?u?d?d?d?d
?D?l?s?u?d?d?d?d
?D?s?u?l?d?d?d?d
?D?u?l?s?d?d?d?d

?d?d?l?u?s?d?d?d
?d?d?u?s?l?d?d?d
?d?d?s?l?u?d?d?d
?d?d?l?s?u?d?d?d
?d?d?s?u?l?d?d?d
?d?d?u?l?s?d?d?d

.....
.....
?l?u?s  just keep shift to right for every block.
Reply
#10
(06-25-2023, 03:56 AM)Gyfer Wrote: Let me give it a go for your requirement.
Using mask:

?l?u?s  just keep shift to right for every block.

You didn't understand what I try to say. I know I can write all the nk lines of every permutation. What I was saying was how to do it without having to write all this lines? How to combine it?
Reply