Distributing workload in oclhashcat

Description

This article explains how to split large brute-force projects using oclHashcat.

Why do it this way?

Rather than just leaving a project running for days on end, you can split the project into chunks making it more manageable. Another benefit is you could also give other users / computers parts of the projects to run decreasing the overall run-time.

Example

In this example, I'll setup a project to run mixalpha-num length 8:

Charset: 62

Length: 8

  • (62 ^ 8) = 218,340,105,584,896, (218 trillion, 340 billion, 105 million, 584 thousand, 896) total combinations.

Lets say I get 2 billion/sec on my GPU. To calculate total crack-time, divide total_combinations by GPU speed/sec:

  • (218,340,105,584,896 / 2,000,000,000) = 109170 secs_total
  • (109170 / 60) = 1819.5 mins_total
  • (1819.5 / 60) = 30.325 hrs_total

Now, I want to break it up into 4 hr long projects each so, to work out how many parts of the charset are in each project:

  • ((charset / hrs_total) * 4 hrs)
  • ((62 / 30.325) * 4) = 8.18 chars each from the charset in each project.

Basically, round it down to a whole number and put however many chars from the charset in each project and use the custom charsets to define whats being used:

./oclHashcat.bin -1 ?d?l?u -2 01234567 -o [output-file] [hashes-file] ?1?1?1?1 ?1?1?1?2
./oclHashcat.bin -1 ?d?l?u -2 89abcdef -o [output-file] [hashes-file] ?1?1?1?1 ?1?1?1?2
./oclHashcat.bin -1 ?d?l?u -2 ghijklmn -o [output-file] [hashes-file] ?1?1?1?1 ?1?1?1?2
./oclHashcat.bin -1 ?d?l?u -2 opqrstuv -o [output-file] [hashes-file] ?1?1?1?1 ?1?1?1?2
./oclHashcat.bin -1 ?d?l?u -2 wxyzABCD -o [output-file] [hashes-file] ?1?1?1?1 ?1?1?1?2
./oclHashcat.bin -1 ?d?l?u -2 EFGHIJKL -o [output-file] [hashes-file] ?1?1?1?1 ?1?1?1?2
./oclHashcat.bin -1 ?d?l?u -2 MNOPQRST -o [output-file] [hashes-file] ?1?1?1?1 ?1?1?1?2
./oclHashcat.bin -1 ?d?l?u -2 UVWXYZ -o [output-file] [hashes-file] ?1?1?1?1 ?1?1?1?2

Notice how the first custom charset deals with the whole charset and the second one deals with just the 8 parts of the charset.

Except where otherwise noted, content on this wiki is licensed under the following license: Public Domain