Open roktomc opened 7 months ago
Fixes an issue of using a single static instance of SHA256 HashAlgorithm which is not thread safe (more on that can be found here https://stackoverflow.com/questions/73006466/is-hashalgorithm-computehash-thread-safe or here https://wanderingdeveloper.medium.com/c-cautionary-tail-the-dangers-of-sha256-reuse-2b5bb9c6fde9).
Creating multiple SszTree instances from concurrent threads randomly calculated wrong roots.
Fixes an issue of using a single static instance of SHA256 HashAlgorithm which is not thread safe (more on that can be found here https://stackoverflow.com/questions/73006466/is-hashalgorithm-computehash-thread-safe or here https://wanderingdeveloper.medium.com/c-cautionary-tail-the-dangers-of-sha256-reuse-2b5bb9c6fde9).
Creating multiple SszTree instances from concurrent threads randomly calculated wrong roots.