GaloisInc / hacrypto

Experiments in high-assurance crypto.
BSD 3-Clause "New" or "Revised" License
46 stars 14 forks source link

Look in to oddity in HMAC vectors from NIST website #91

Closed jldodds closed 9 years ago

jldodds commented 9 years ago

Why are there so many odd Tlens used?

dmzimmerman commented 9 years ago

I believe I figured this out, and accounted for it in my horrible hack to the HMAC tests... basically, the Tlen is independent of other considerations, and - in combination with the L setting for the group of tests, determines which of the various SHAs gets used for a given test (for example, SHA-224 can be used for Tlen 14, 16, 20, 24, 28, but SHA-256 can also be used for 16 and 24.