The _verify_proof
function uses a loop to iterate over the Merkle proof and compute the hash, as seen below:
As the number of users and proof elements increases, this could lead to increased gas costs for verification, potentially making the contract inefficient and unaffordable for large-scale usage.
Consider optimizing the Merkle proof verification process, such as limiting the maximum number of proof elements that can be processed in a single transaction. Alternatively, the contract can use an off-chain service to handle Merkle proof verification and reduce on-chain computations.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.