1

As a general rule, GPUs are more effective than CPUs when it comes to performing acutely repetitive tasks, like iterating over lists and generating permutations of a set (i.e. exhausting dictionaries & keysets), in order to crack a hash.

Obviously, not all CPUs & GPUs are the same. Maybe a particular CPU could outperform a particular GPU for such a purpose, but that's generally not the case.

So what about Field Programmable Gate Arrays (FPGAs)? Generally speaking, are they even better suited to cracking hashes, than GPUs?


See also: Why are GPUs so good at cracking passwords?

  • There are multiple types of FPGAs. Some are basically FGPA-ASIC hybrids and perform very well but are expensive unless purchased in bulk, whereas others are just regular programmable FPGAs which often do not perform as well as a powerful GPU of similar price (some are actually quite slow). So you really should specify exactly what kind of FPGA you are talking about. – forest Oct 19 '18 at 6:48
  • The differences are explained in one of the links I provided in my answer. – forest Oct 19 '18 at 8:35
2

What exactly is an FPGA?

An FPGA is not like a GPU. A GPU is a pre-designed processor with all the circuitry already there. All you have to do is hook it up and let software interface with it. FPGAs, on the other hand, are completely different beasts. They are a "blank slate" processor. You have to design an FPGA, not just buy one. You determine what transistors do what, how they hook up, etc. They are efficient because every part has a job, but they require you have a deep understanding of electronics and integrated circuit design.

In the question you linked explaining what makes a GPU so good at password cracking, it says that a GPU has a large number of identical cores that can run the same algorithm in parallel. How the core works internally is something that you don't need to know in order to make use of it (and likely can't legally know). For an FPGA, however, there is no such unit. You create each core and design it. You set up the individual logic gates. Basically, you design the chip, using the FPGA as nothing more than the actual, physical hardware that contains the transistors. Developing on them can be difficult.

Which is faster for hash cracking?

For the same price, a high-end GPU is likely to be faster than an FPGA at processing hashes, but an FPGA is likely to use less power for processing the same number of hashes. It's important to note that there are several different kinds of FPGA. An FPGA "conversion" involves creating an ASIC from FPGA HDL. This is often quite expensive and is only done when purchasing in quantity, but tends to be a bit faster than a regular FPGA (apparently around 30% faster), and much easier, and cheaper, than designing an ASIC. A true ASIC is, of course, much more efficient than either. Designing an ASIC is even more difficult than programming an FPGA, and requires far more knowledge of low-level integrated circuit design. Overall, ASICs are efficient and fast, but costly and hard to design.

Which should you get?

If you want the highest possible MHash/s for a given price, or if you need the flexibility of supporting multiple algorithms, get a GPU. If you want the highest possible MHash/J (joule, an energy unit), get an FPGA. If you want both speed and efficiency and do not care about price, design an ASIC.

If you are new to password cracking and just want to build an efficient cracking rig, get a few fast GPUs. FPGAs and ASICs are typically used if you are a company with a team of developers with a large (but strict) budget to work with, when custom solutions are needed. For most password cracking needs, a GPU would do just fine, not only because of their competitive speed, but because popular hash-cracking software like Hashcat is designed to make use of GPUs for acceleration. Nothing of that sort exists for FPGAs or ASICs, meaning you'd have to design it all yourself.

An excellent post on the Electronics Stack Exchange explains the difference between FPGAs, ASICs, and general-purpose microcontrollers (which a GPU is most similar to) in more detail, from an electronics design perspective, rather than a hash-cracking perspective.

  • You've used some terminology that I've no prior knowledge of. MHash, HDL, ASIC, etc. I have a lot more knowledge about this kind of thing than the average person, but it's probably nothing compared to someone such as yourself. FPGAs are a relatively new concept for me. However, if I knew more, I'd ask better questions. So, by all means, please feel free to elaborate on ASICs, and anything else you feel is relevant. – tjt263 Oct 19 '18 at 8:23
  • @tjt263 MHash means million hashes, so 500 MHash/s means 500,000,000 hashes per second. HDL is the language that you "program" an FPGA or ASIC in, and ASIC is basically a super customized circuit that you design yourself, even more customized than an FPGA. If it's a new concept to you, I suggest using a GPU instead. Only use an FPGA if you know you need one. – forest Oct 19 '18 at 8:35
  • Actually, I'm more interested in buying 25-50 or so, of one or the other. That ought to put a dent in it. I heard about someone doing this effectively with a bunch of FPGAs, which piqued my interest. And actually, from what I understand, hashcat plays well with FPGAs, thanks to OPENCL. – tjt263 Oct 19 '18 at 20:58
  • @tjt263 There are some IP cores which give FPGAs OpenCL support. Is power usage a big concern? – forest Oct 20 '18 at 2:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.