1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-22 14:28:07 +00:00
Commit Graph

4 Commits

Author SHA1 Message Date
Jochen Hoenicke
32bda8d1d9
Faster PBKDF2 by reusing intermediate results.
The old implementation needed 6 sha transformations per iterations:

- 2 for computing sha512 of seed,
- 2 for computing digests of ipads/opads,
- 2 for computing digests of intermediate hashes.

The first 4 transformations are the same in every iteration so we cache
them.  A new function hmac_sha512_prepare computes these digests.
We made sha512_Transform visible in pbkdf2 and prevent unneccessary
big/little endian conversions back and forth.
2016-07-13 22:17:23 +02:00
Pavol Rusnak
445e859450
split hmac into init/update/final 2016-04-26 17:19:00 +02:00
Pavol Rusnak
612f5ab050 fix copyright headers 2014-05-22 20:54:58 +02:00
Pavol Rusnak
047b30cf2f add hmac-sha256/512 2013-09-10 21:47:06 +02:00