Questions tagged [merkle]
The merkle tag has no usage guidance.
19 questions
3
votes
1
answer
807
views
Merkle tree airdrop how to build
I am writing an ERC20 token contract (contract token) with a mint of 2 million tokens.
I am also writing a Merkle tree airdrop contract and sending it to this contract (contract Merkle tree). So, let'...
2
votes
1
answer
33
views
What is the most efficient way of whitelisting at this moment in solidity?
Normal whitelisting setter functions are the most basic ones, I came across two more ways, Merkle Tree and signature-based whitelisting.
The question I had is:
Are the gas usage differences among ...
2
votes
0
answers
69
views
How does the Merkle proof mechanism exactly work in Ethereum? This is straightforward in bitcoin but
I've searched this site and elsewhere but can't find anywhere this is explained.
In bitcoin, it's straightforward. If you're a light client (SPV) in bitcoin, I understand how with the regular Merkle ...
1
vote
1
answer
63
views
How can a bytes32[] variable have a custom method (i.e., verifyCalldata)?
Code: https://www.contractreader.io/contract/mainnet/0x0C7D4bdA40CF78F9F1BAf6e3D5774f1E22c9CC4B
My question is about this verifyCalldata() call:
function verifyAddress(
uint256 _projectId,
...
1
vote
1
answer
113
views
Smart Contract: false Transaction mined but execution failed (Merkle trees)
I'm trying to implement a smart contract whitelist using Merkle trees. I have been following along This tutorial. However, instead of using the generate part, I used the online tool here: https://lab....
1
vote
1
answer
343
views
Question about verification in Merkle Trees
I have a general understanding of Merkle trees but I'm still not sure how the root or merkle hash can be used to proof the integrity of the transactions below it.
For example in this picture (https://...
1
vote
1
answer
207
views
Implementing Merkle Tree off chain
I have basic understanding of Merkle Tree and how it works, now I am implementing it to my smart contract as whitelist verification.
I stored the root in smart contract, implemented the verify ...
1
vote
1
answer
2k
views
use javascript merkle tree to generate hex proof for solidity merkletree validation
Here is my js code of generating hex proof for solidity verification
const express = require('express')
const { MerkleTree } = require('merkletreejs');
const { bufferToHex } = require('ethereumjs-util'...
1
vote
0
answers
148
views
BLUR airdrop claim explained - embedding a proof into a transaction
Recently, I saw that Blur had a twitter dependent airdrop. So basically you had to tweet and then you would get the option to claim tokens. I went to analyze the code, but it is overwhelming for me.
...
1
vote
0
answers
30
views
Uncertain MerkleTree Algorithm
I'm building my own MerkleTree algorithm however I found out that the root value generated from my MK algorithm is not the same that I generated from the online generator https://prathamudeshmukh....
1
vote
0
answers
125
views
Reversing the input of a merkle tree
I'm trying to reverse the input of a Merkle tree by comparing a proof from the original tree and the proof I am generating myself.
Original proof:
[
"...
1
vote
1
answer
546
views
Python Merkle Tree Libraries Don't Produce The Same Merkle Root As Node.js's "merkletreejs"
I have been trying to create merkle tree proofs in python.
In a whitelisted NFT project, I've used npm's merkletreejs which is a JavaScript library and it worked beautifully. Here is the Github page ...
0
votes
1
answer
29
views
Merkletree proof
in js i want array like this let arr = ["a","b","c"]
but i am getting arr = ['a','b','c']
is there any way to do this?
Notes : it's for merkletree to send proof through ...
0
votes
1
answer
52
views
Merkle tree Airdrop contract test failing
Can anyone help me figure out where I'm going wrong? Using ECDSA, I'm checking whether the address claiming the airdrop is a valid address or not. Using 4 of my addresses in hardhat localhost, I ...
0
votes
1
answer
384
views
How to compute witness for Merkle tree proof using Zokrates?
I am trying to learn how Zero Knowledge proof for Merkle tree verification work. Therefore I am using this example from Zokrates:
import "hashes/pedersen/512bit" as hash;
import "hashes/...
0
votes
1
answer
34
views
Is there a way to prove that a previous transaction was mined in solidity?
Context
We are working on a charity NFT, and we want to gate minting to those who have ALREADY donated to the charity by sending ETH to the charity wallet.
This makes things cleaner for tax write off ...
0
votes
1
answer
203
views
Error when using Merkle Proof with a lot of leaves
I have merkle proof integrated into our smart contract to implement a whitelist. It works nicely, but when I use a list of a lot of addresses (around 200), I run into issues. The proof for any address ...
0
votes
0
answers
175
views
Feedback on Implementing Merkle Airdrop for Rug Pull Victims
Summary: Developed a smart contract that enables the GovernorDAO Community to un-rug the CBDAO Rug Pull victims by providing them with a Merkle Distribution Airdrop. Over 1/3 of an already-minted ...
0
votes
0
answers
111
views
Does it possible to perform Merkle root proof with filters?
I have a centralized e-commerce system with orders table inside. There are few order categories inside this system such as:
Pending payment
Pending shipping
Pending delivery
Completed
Cancelled
I ...