Mask attack functionality - Printable Version +- hashcat Forum (https://hashcat.net/forum) +-- Forum: Developer (https://hashcat.net/forum/forum-39.html) +--- Forum: hashcat (https://hashcat.net/forum/forum-40.html) +--- Thread: Mask attack functionality (/thread-12090.html) |
Mask attack functionality - Scanel-sys - 07-26-2024 Im a developer and im interested in studying the mechanism of generating passwords for mask attack. I've already found functionality of rule mode attack but seems to be another attack mode. So i would like to know which src files contain functionality of mask attack and how does it work on cpu/gpu RE: Mask attack functionality - penguinkeeper - 07-26-2024 This is kind of hard to answer, as there is a lot involved in masks but put simply, Hashcat distributes the first 4 bytes to as many threads on the GPU as it can (called the base loop), then each of those threads has an inner loop (called the mod loop), where the rest of the candidate is generated by the GPU itself, so if you had ?l?l?l?l?d?d?d?d, the outer loop would be ?l?l?l?l and the inner loop would be ?d?d?d?d. This is the reason why if you use a mask like "ABCD?a?a?a?a?a?a", it'll be extraordinarily slow, because there'll only be a single candidate, "ABCD" to distribute to the CPU/GPU threads, while if you do it the other way around, as "?a?a?a?a?a?aABCD", it'll be near full speed as it can be parallelised fully RE: Mask attack functionality - Scanel-sys - 07-26-2024 I found outer_loop and inner_loops only in hashcat.c Also found topic on hashcat wiki about amplifier loop and base loop but theres no information about how do these call in src files also found files mpsp.c/h which produces passwords with cpu but didnt find the thing about gpu RE: Mask attack functionality - Scanel-sys - 07-30-2024 Seems like CPU password generating doesnt work. If i use --stdout with -S (--slow-candidates) flag it doesnt print anything but without -S does well (cpu + gpu generating). RE: Mask attack functionality - buka - 07-30-2024 Well, it prints something. Empty lines. $ ./hashcat.bin -a 3 ?d -S --stdout | wc -l 10 RE: Mask attack functionality - Scanel-sys - 07-30-2024 I checked binary and there re just nulls Dont think its should be like that Found functionality - hashcat creates threads with thread_calc or thread_calc_stdin from dispatch.c In case of CPU it uses mpsp functions but in case of cpu-gpu chain dont know RE: Mask attack functionality - Scanel-sys - 07-30-2024 I found Passwords being generated in markov_le(be).cl Does it has any connection with markov chains? |