Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>There are actually many ways of doing this. For simplicity, you should divide the majority of the work. In this case, it is rather obvious that most of the work is done in computing the hash. In cases where it is not obvious, you will want to profile your application and find out where the majority of the time is being spent. But also remember there is overhead incurred for many thread creations/joins, so it best to allocate a subset of work to each thread before beginning the work (perhaps check some protected shared variable if someone has found the solution).</p> <p>Notice, however, depending on the the kind of hashes you will be attempting to crack (I am assuming you will be brute-forcing), there is no guarantee that your program will finish. Most (by that, I mean any practical/effective one) hashing algorithms operate under the notion of computational infeasibility. If you will be generating random strings to crack, notice that all a cracker needs to do is find a collision. For instance, consider a situation where 'cat' and 'dog' map to the same hash value and the real password is 'dog.' If your cracker finds 'cat' as a solution, this solution is just as viable. This is still a very hard problem, however, and also not guaranteed to finish.</p> <p>The other alternative is a dictionary attack (since this is educational - this should be feasible). If you are doing a simple dictionary attack and the word is not in the dictionary, you will simply be out of luck. This is guaranteed to finish at the end of your dictionary, however. To implement this, it would be best to split your dictionary. If you have 4 threads and a dictionary of 1000 words, then each thread should get a different subset of the dictionary (each with 250 entries to work on). In practice, however, most protected passwords probably have some form of salt as well (just something to think about).</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload