4 ms·
Exactly those. If you know (or have a hunch) that the backend is using go's totp library, you're going to ask hashcat first to try to guess secrets that are 20
by philsnow 8y ago
Exactly those. If you know (or have a hunch) that the backend is using go's totp library, you're going to ask hashcat first to try to guess secrets that are 20 random bytes (?b?b?b?b...?b). True, 256^20 is a bit larger than 26^10.
- elithrar 8y agoAnd short of PRNG issues / bias in those keys, telling hashcat to “guess” 20-byte keys is not really an attack given how infeasible it is. This just isn’t practical.
- tptacek 8y agoYou can't brute-force a 160-bit secret.
- vorpalhex 8y agoGiven the rise of asics and other specialized high performance hardware, that seems a hard statement to make. I doubt anyone is doing it currently, but given enough time it will certainly be possible.
- tptacek 8y agoASICs have nothing to do with it. With conventional computing, basic physical limits put the completion of a 128 bit brute force eons into the future.
- mcpherrinm 8y agoI have included a quote and link from Applied Cryptography below. The amount of energy needed to even count up to 2^160 is ridiculously huge, even if we ignore real computers and look at theoretical lower bounds of power. The planet earth does not have enough power to do that. We would have to capture a large fraction of the power output of our sun to brute force an entire 160 bit key space. Bitcoin is actually really useful for measuring what practical hash rates look like when somebody is very motivated. Using those numbers, the time to brute force a 160 bit value is much greater than the age of the universe. https://crypto.stackexchange.com/questions/48667/how-long-would-it-take-to-brute-force-an-aes-128-key https://crypto.stackexchange.com/questions/48667/how-long-wo... Quote: One of the consequences of the second law of thermodynamics is that a certain amount of energy is necessary to represent information. To record a single bit by changing the state of a system requires an amount of energy no less than kT, where T is the absolute temperature of the system and k is the Boltzman constant. (Stick with me; the physics lesson is almost over.) Given that k = 1.38×10-16 erg/°Kelvin, and that the ambient temperature of the universe is 3.2°Kelvin, an ideal computer running at 3.2°K would consume 4.4×10-16 ergs every time it set or cleared a bit. To run a computer any colder than the cosmic background radiation would require extra energy to run a heat pump. Now, the annual energy output of our sun is about 1.21×1041 ergs. This is enough to power about 2.7×1056 single bit changes on our ideal computer; enough state changes to put a 187-bit counter through all its values. If we built a Dyson sphere around the sun and captured all its energy for 32 years, without any loss, we could power a computer to count up to 2^192. Of course, it wouldn't have the energy left over to perform any useful calculations with this counter. ... And they strongly imply that brute-force attacks against 256-bit keys will be infeasible until computers are built from something other than matter and occupy something other than space. -- https://www.schneier.com/blog/archives/2009/09/the_doghouse_cr.html https://www.schneier.com/blog/archives/2009/09/the_doghouse_...
- vorpalhex 8y agoWell done. Point proven.