bitcoinjs / merkle-lib

A performance conscious library for merkle root and tree calculations.
MIT License
29 stars 17 forks source link

Fix issue proofing a data block (leaf) contained in another Buffer #10

Closed claudiosdc closed 3 years ago

claudiosdc commented 4 years ago

This is a fix for issue #8 where the data block (leaf) to be proofed is in a Buffer different from the one used when building the tree. The changes also allow for internal nodes and leaves to be either a Buffer or a Uint8Array instance (though Uint8Array only works for Node.js version 8 and above).