Skip to content
This repository has been archived by the owner on Apr 3, 2019. It is now read-only.

Wrong length check in HMAC function #219

Open
alexdupre opened this issue Mar 20, 2018 · 0 comments
Open

Wrong length check in HMAC function #219

alexdupre opened this issue Mar 20, 2018 · 0 comments

Comments

@alexdupre
Copy link

} else if (key < blocksize) {

The above check always returns false, since it's missing .length, so the buffer copy/padding is never performed. Luckily/Accidentally accessing an out-of-index array in Javascript returns an undefined type that has the same property of a 0, in regard of the XOR operation.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
@alexdupre and others