EYBlockchain / timber

Construct a Merkle Tree database from Ethereum logs.
Other
67 stars 19 forks source link

commitment hash > field prime results in failed root check in the circuit #80

Open ChaitanyaKonda opened 2 years ago

ChaitanyaKonda commented 2 years ago

When commitment hash is greater than the prime of the field, the root calculated is different from the one provided by the sibling path. At application level, this can be handled by ensuring the commitment hash is never greater than prime of the field, by picking a salt that will ensure this. This should not be considered as a permanent solution. This should be rectified in timber which is the source.