You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One can also write similar test in go-ethereum repo (which I initially did), but this requires building go-ethereum.
It seems that all strings of length less or equal 4 are hashed correctly (thus all mentioned test vectors work), problem occurs whenever length of string is at least 5 (and it so happened all current test vectors are hashing string abc)
I was not able to figure out what's causing this issue, js implementation seems quite different from golang in go-ethereum
The text was updated successfully, but these errors were encountered:
@convexman hi there, thanks a lot for reporting and for this detailed write-up. We'll try to investigate soonish. 🙂
holgerd77
changed the title
Blake2 precompiled contract gives incorrect result on some inputs
VM: Blake2 precompiled contract gives incorrect result on some inputs
Sep 21, 2021
Version: release v4.1.3 (commit feef85f)
Node: v10.24.1
Steps to reproduce:
tests/api/istanbul/eip-152.js
and add following testcase toconst testCases = [...
npm run test:API
One can verify that expected value is correct by querying mainnet node
Hashing string
abcde
using some online hash calculator confirms this result (https://www.toolkitbay.com/tkb/tool/BLAKE2b_512)One can also write similar test in go-ethereum repo (which I initially did), but this requires building go-ethereum.
It seems that all strings of length less or equal 4 are hashed correctly (thus all mentioned test vectors work), problem occurs whenever length of string is at least 5 (and it so happened all current test vectors are hashing string
abc
)I was not able to figure out what's causing this issue, js implementation seems quite different from golang in go-ethereum
The text was updated successfully, but these errors were encountered: