Open
Description
As we are building manta (https://github.com/Manta-Network), we figured out that we need an incremental merkle tree that has Log N
internal nodes, which is not supported in the current MerkleTree implementaion. The properties that we need for this merkle tree:
- Able to generate ZK membership proofs
- The merkle tree can be fixed sized and append only (i.e. mark the unused leaf node as a filler, etc)
- The number of internal nodes is
Log N
. (since we need to store the internal nodes on chain,O(N)
storage would be too expensive).
I think 3 is only possible if this merkle tree only supportappend
. Happy to submit a PR on this. Would also like to hear is there any design considerations that need to take care of during the implementation.