2023-03-29 12:43:14 +05:30
|
|
|
{
|
2023-03-30 18:29:06 +05:30
|
|
|
"address": "0x9C09146844C1326c2dBC41c451766C7138F88155",
|
2023-03-29 12:43:14 +05:30
|
|
|
"abi": [
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "membershipDeposit",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "depth",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "_poseidonHasher",
|
|
|
|
"type": "address"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "nonpayable",
|
|
|
|
"type": "constructor"
|
|
|
|
},
|
2023-03-30 18:29:06 +05:30
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "DuplicateIdCommitment",
|
|
|
|
"type": "error"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "EmptyBatch",
|
|
|
|
"type": "error"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "FullBatch",
|
|
|
|
"type": "error"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "required",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "provided",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "InsufficientDeposit",
|
|
|
|
"type": "error"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "to",
|
|
|
|
"type": "address"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "InvalidWithdrawalAddress",
|
|
|
|
"type": "error"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "idCommitment",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "MemberHasNoStake",
|
|
|
|
"type": "error"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "idCommitment",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "MemberNotRegistered",
|
|
|
|
"type": "error"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "givenSecretsLen",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "givenReceiversLen",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "MismatchedBatchSize",
|
|
|
|
"type": "error"
|
|
|
|
},
|
2023-03-29 12:43:14 +05:30
|
|
|
{
|
|
|
|
"anonymous": false,
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"indexed": false,
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "idCommitment",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"indexed": false,
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "index",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "MemberRegistered",
|
|
|
|
"type": "event"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"anonymous": false,
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"indexed": false,
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "idCommitment",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "MemberWithdrawn",
|
|
|
|
"type": "event"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "DEPTH",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "MEMBERSHIP_DEPOSIT",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "SET_SIZE",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "idCommitmentIndex",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "members",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "bool",
|
|
|
|
"name": "",
|
|
|
|
"type": "bool"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "poseidonHasher",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "contract IPoseidonHasher",
|
|
|
|
"name": "",
|
|
|
|
"type": "address"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "idCommitment",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "register",
|
|
|
|
"outputs": [],
|
|
|
|
"stateMutability": "payable",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256[]",
|
|
|
|
"name": "idCommitments",
|
|
|
|
"type": "uint256[]"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "registerBatch",
|
|
|
|
"outputs": [],
|
|
|
|
"stateMutability": "payable",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "stakedAmounts",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "secret",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "address payable",
|
|
|
|
"name": "receiver",
|
|
|
|
"type": "address"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "withdraw",
|
|
|
|
"outputs": [],
|
|
|
|
"stateMutability": "nonpayable",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256[]",
|
|
|
|
"name": "secrets",
|
|
|
|
"type": "uint256[]"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "address payable[]",
|
|
|
|
"name": "receivers",
|
|
|
|
"type": "address[]"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "withdrawBatch",
|
|
|
|
"outputs": [],
|
|
|
|
"stateMutability": "nonpayable",
|
|
|
|
"type": "function"
|
|
|
|
}
|
|
|
|
],
|
2023-03-30 18:29:06 +05:30
|
|
|
"transactionHash": "0x22932746438754cd22feebe99500d9eb17d30dff98e1a6f69087029bdd0ec0da",
|
2023-03-29 12:43:14 +05:30
|
|
|
"receipt": {
|
|
|
|
"to": null,
|
|
|
|
"from": "0xc2eB015aCb170177F726626707C82f994736ef15",
|
2023-03-30 18:29:06 +05:30
|
|
|
"contractAddress": "0x9C09146844C1326c2dBC41c451766C7138F88155",
|
|
|
|
"transactionIndex": 21,
|
|
|
|
"gasUsed": "1005129",
|
2023-03-29 12:43:14 +05:30
|
|
|
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
|
2023-03-30 18:29:06 +05:30
|
|
|
"blockHash": "0x72ab3b6fe8bd65d68924b621959f5d584810701d39de96fa9b1478a67d0dbee5",
|
|
|
|
"transactionHash": "0x22932746438754cd22feebe99500d9eb17d30dff98e1a6f69087029bdd0ec0da",
|
2023-03-29 12:43:14 +05:30
|
|
|
"logs": [],
|
2023-03-30 18:29:06 +05:30
|
|
|
"blockNumber": 3193048,
|
|
|
|
"cumulativeGasUsed": "5908021",
|
2023-03-29 12:43:14 +05:30
|
|
|
"status": 1,
|
|
|
|
"byzantium": true
|
|
|
|
},
|
2023-03-30 18:29:06 +05:30
|
|
|
"args": [1000000000000000, 20, "0xa1554EAF0DF18C05956249aac375e212edeD2CcF"],
|
|
|
|
"numDeployments": 2,
|
|
|
|
"solcInputHash": "b1509b5db56df56b3944fa20992a2034",
|
|
|
|
"metadata": "{\"compiler\":{\"version\":\"0.8.15+commit.e14f2714\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"membershipDeposit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"depth\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_poseidonHasher\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"DuplicateIdCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyBatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FullBatch\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"required\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"provided\",\"type\":\"uint256\"}],\"name\":\"InsufficientDeposit\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"InvalidWithdrawalAddress\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"idCommitment\",\"type\":\"uint256\"}],\"name\":\"MemberHasNoStake\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"idCommitment\",\"type\":\"uint256\"}],\"name\":\"MemberNotRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"givenSecretsLen\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"givenReceiversLen\",\"type\":\"uint256\"}],\"name\":\"MismatchedBatchSize\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"idCommitment\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"}],\"name\":\"MemberRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"idCommitment\",\"type\":\"uint256\"}],\"name\":\"MemberWithdrawn\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"DEPTH\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MEMBERSHIP_DEPOSIT\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"SET_SIZE\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"idCommitmentIndex\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"members\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"poseidonHasher\",\"outputs\":[{\"internalType\":\"contract IPoseidonHasher\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"idCommitment\",\"type\":\"uint256\"}],\"name\":\"register\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"idCommitments\",\"type\":\"uint256[]\"}],\"name\":\"registerBatch\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"stakedAmounts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"secret\",\"type\":\"uint256\"},{\"internalType\":\"address payable\",\"name\":\"receiver\",\"type\":\"address\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"secrets\",\"type\":\"uint256[]\"},{\"internalType\":\"address payable[]\",\"name\":\"receivers\",\"type\":\"addre
|
|
|
|
"bytecode": "0x60e06040523480156200001157600080fd5b50604051620012c0380380620012c0833981810160405281019062000037919062000142565b82608081815250508160a08181525050816001901b60c0818152505080600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050506200019e565b600080fd5b6000819050919050565b620000b781620000a2565b8114620000c357600080fd5b50565b600081519050620000d781620000ac565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006200010a82620000dd565b9050919050565b6200011c81620000fd565b81146200012857600080fd5b50565b6000815190506200013c8162000111565b92915050565b6000806000606084860312156200015e576200015d6200009d565b5b60006200016e86828701620000c6565b93505060206200018186828701620000c6565b925050604062000194868287016200012b565b9150509250925092565b60805160a05160c0516110cf620001f1600039600081816104140152818161058501526109070152600061054301526000818161047d015281816105a9015281816105d0015261063c01526110cf6000f3fe60806040526004361061009b5760003560e01c806398366e351161006457806398366e3514610176578063ae74552a146101a1578063bc499128146101cc578063d0383d6814610209578063f207564e14610234578063f220b9ec146102505761009b565b8062f714ce146100a0578063331b6ab3146100c957806340070712146100f45780635daf08ca1461011d57806369e4863f1461015a575b600080fd5b3480156100ac57600080fd5b506100c760048036038101906100c29190610b3f565b61027b565b005b3480156100d557600080fd5b506100de610289565b6040516100eb9190610bde565b60405180910390f35b34801561010057600080fd5b5061011b60048036038101906101169190610cb4565b6102af565b005b34801561012957600080fd5b50610144600480360381019061013f9190610d35565b6103b0565b6040516101519190610d7d565b60405180910390f35b610174600480360381019061016f9190610d98565b6103d0565b005b34801561018257600080fd5b5061018b610541565b6040516101989190610df4565b60405180910390f35b3480156101ad57600080fd5b506101b6610565565b6040516101c39190610df4565b60405180910390f35b3480156101d857600080fd5b506101f360048036038101906101ee9190610d35565b61056b565b6040516102009190610df4565b60405180910390f35b34801561021557600080fd5b5061021e610583565b60405161022b9190610df4565b60405180910390f35b61024e60048036038101906102499190610d35565b6105a7565b005b34801561025c57600080fd5b5061026561063a565b6040516102729190610df4565b60405180910390f35b610285828261065e565b5050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000848490509050600081036102f1576040517fc2e5347d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8282905081146103405784849050838390506040517f727c6a75000000000000000000000000000000000000000000000000000000008152600401610337929190610e0f565b60405180910390fd5b60005b818110156103a85761039586868381811061036157610360610e38565b5b9050602002013585858481811061037b5761037a610e38565b5b90506020020160208101906103909190610e67565b61065e565b80806103a090610ec3565b915050610343565b505050505050565b60026020528060005260406000206000915054906101000a900460ff1681565b600082829050905060008103610412576040517fc2e5347d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f0000000000000000000000000000000000000000000000000000000000000000816000546104419190610f0b565b10610478576040517f75eb4dbe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000817f00000000000000000000000000000000000000000000000000000000000000006104a69190610f61565b90508034146104ee5780346040517f25c3f46e0000000000000000000000000000000000000000000000000000000081526004016104e5929190610e0f565b60405180910390fd5b60005b8281101561053a5761052785858381811061050f5761050e610e38565b5b9050602002013584346105229190610fea565b6108ae565b808061053290610ec3565b9150506104f1565b5050505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b60005481565b60016020528060005260406000206000915090505481565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f0000000000000000000000000000000000000000000000000000000000000000341461062d577f0000000000000000000000000000000000000000000000000000000000000000346040517f25c3f46e00000000000000000000000000
|
|
|
|
"deployedBytecode": "0x60806040526004361061009b5760003560e01c806398366e351161006457806398366e3514610176578063ae74552a146101a1578063bc499128146101cc578063d0383d6814610209578063f207564e14610234578063f220b9ec146102505761009b565b8062f714ce146100a0578063331b6ab3146100c957806340070712146100f45780635daf08ca1461011d57806369e4863f1461015a575b600080fd5b3480156100ac57600080fd5b506100c760048036038101906100c29190610b3f565b61027b565b005b3480156100d557600080fd5b506100de610289565b6040516100eb9190610bde565b60405180910390f35b34801561010057600080fd5b5061011b60048036038101906101169190610cb4565b6102af565b005b34801561012957600080fd5b50610144600480360381019061013f9190610d35565b6103b0565b6040516101519190610d7d565b60405180910390f35b610174600480360381019061016f9190610d98565b6103d0565b005b34801561018257600080fd5b5061018b610541565b6040516101989190610df4565b60405180910390f35b3480156101ad57600080fd5b506101b6610565565b6040516101c39190610df4565b60405180910390f35b3480156101d857600080fd5b506101f360048036038101906101ee9190610d35565b61056b565b6040516102009190610df4565b60405180910390f35b34801561021557600080fd5b5061021e610583565b60405161022b9190610df4565b60405180910390f35b61024e60048036038101906102499190610d35565b6105a7565b005b34801561025c57600080fd5b5061026561063a565b6040516102729190610df4565b60405180910390f35b610285828261065e565b5050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000848490509050600081036102f1576040517fc2e5347d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8282905081146103405784849050838390506040517f727c6a75000000000000000000000000000000000000000000000000000000008152600401610337929190610e0f565b60405180910390fd5b60005b818110156103a85761039586868381811061036157610360610e38565b5b9050602002013585858481811061037b5761037a610e38565b5b90506020020160208101906103909190610e67565b61065e565b80806103a090610ec3565b915050610343565b505050505050565b60026020528060005260406000206000915054906101000a900460ff1681565b600082829050905060008103610412576040517fc2e5347d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f0000000000000000000000000000000000000000000000000000000000000000816000546104419190610f0b565b10610478576040517f75eb4dbe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000817f00000000000000000000000000000000000000000000000000000000000000006104a69190610f61565b90508034146104ee5780346040517f25c3f46e0000000000000000000000000000000000000000000000000000000081526004016104e5929190610e0f565b60405180910390fd5b60005b8281101561053a5761052785858381811061050f5761050e610e38565b5b9050602002013584346105229190610fea565b6108ae565b808061053290610ec3565b9150506104f1565b5050505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b60005481565b60016020528060005260406000206000915090505481565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f0000000000000000000000000000000000000000000000000000000000000000341461062d577f0000000000000000000000000000000000000000000000000000000000000000346040517f25c3f46e000000000000000000000000000000000000000000000000000000008152600401610624929190610e0f565b60405180910390fd5b61063781346108ae565b50565b7f000000000000000000000000000000000000000000000000000000000000000081565b3073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614806106c45750600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16145b1561070657806040517f21680a040000000000000000000000000000000000000000000000000000000081526004016106fd919061103c565b60405180910390fd5b6000610711836109fc565b90506002600082815260200190815260200160002060009054906101000a900460ff1661077557806040517f5a971ebb00000000000000000000000000000000000000000000000000000000815260040161076c9190610df4565b60405180910390fd5b60006001600083815260200190815260200160002054036107cd57806040517faabeeba50000000000000000000000000000000000000000000000000000000081526004016107c49190610df4565b60405180910390fd5b60006001600083815260200190815260200160002054905060006002600084815260200190
|
2023-03-29 12:43:14 +05:30
|
|
|
"devdoc": {
|
2023-03-30 18:29:06 +05:30
|
|
|
"errors": {
|
|
|
|
"InsufficientDeposit(uint256,uint256)": [
|
|
|
|
{
|
|
|
|
"params": {
|
|
|
|
"provided": "The provided deposit amount",
|
|
|
|
"required": "The required deposit amount"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"MismatchedBatchSize(uint256,uint256)": [
|
|
|
|
{
|
|
|
|
"params": {
|
|
|
|
"givenReceiversLen": "The length of the receivers array",
|
|
|
|
"givenSecretsLen": "The length of the secrets array"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"events": {
|
|
|
|
"MemberRegistered(uint256,uint256)": {
|
|
|
|
"params": {
|
|
|
|
"idCommitment": "The idCommitment of the member",
|
|
|
|
"index": "The index of the member in the set"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"MemberWithdrawn(uint256)": {
|
|
|
|
"params": {
|
|
|
|
"idCommitment": "The idCommitment of the member"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2023-03-29 12:43:14 +05:30
|
|
|
"kind": "dev",
|
2023-03-30 18:29:06 +05:30
|
|
|
"methods": {
|
|
|
|
"register(uint256)": {
|
|
|
|
"params": {
|
|
|
|
"idCommitment": "The idCommitment of the member"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"registerBatch(uint256[])": {
|
|
|
|
"params": {
|
|
|
|
"idCommitments": "array of idCommitments"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"withdraw(uint256,address)": {
|
|
|
|
"params": {
|
|
|
|
"secret": "The idSecretHash of the member"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"withdrawBatch(uint256[],address[])": {
|
|
|
|
"params": {
|
|
|
|
"receivers": "array of addresses to receive the funds",
|
|
|
|
"secrets": "array of idSecretHashes"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2023-03-29 12:43:14 +05:30
|
|
|
"version": 1
|
|
|
|
},
|
|
|
|
"userdoc": {
|
2023-03-30 18:29:06 +05:30
|
|
|
"errors": {
|
|
|
|
"DuplicateIdCommitment()": [
|
|
|
|
{
|
|
|
|
"notice": "Member is already registered"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"EmptyBatch()": [
|
|
|
|
{
|
|
|
|
"notice": "Provided Batch is empty"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"FullBatch()": [
|
|
|
|
{
|
|
|
|
"notice": "Batch is full, during batch operations"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"InsufficientDeposit(uint256,uint256)": [
|
|
|
|
{
|
|
|
|
"notice": "Invalid deposit amount"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"InvalidWithdrawalAddress(address)": [
|
|
|
|
{
|
|
|
|
"notice": "Invalid withdrawal address, when the receiver is the contract itself or 0x0"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"MemberHasNoStake(uint256)": [
|
|
|
|
{
|
|
|
|
"notice": "Member has no stake"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"MemberNotRegistered(uint256)": [
|
|
|
|
{
|
|
|
|
"notice": "Member is not registered"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"MismatchedBatchSize(uint256,uint256)": [
|
|
|
|
{
|
|
|
|
"notice": "Batch size mismatch, when the length of secrets and receivers are not equal"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"events": {
|
|
|
|
"MemberRegistered(uint256,uint256)": {
|
|
|
|
"notice": "Emitted when a new member is added to the set"
|
|
|
|
},
|
|
|
|
"MemberWithdrawn(uint256)": {
|
|
|
|
"notice": "Emitted when a member is removed from the set"
|
|
|
|
}
|
|
|
|
},
|
2023-03-29 12:43:14 +05:30
|
|
|
"kind": "user",
|
2023-03-30 18:29:06 +05:30
|
|
|
"methods": {
|
|
|
|
"DEPTH()": {
|
|
|
|
"notice": "The depth of the merkle tree"
|
|
|
|
},
|
|
|
|
"MEMBERSHIP_DEPOSIT()": {
|
|
|
|
"notice": "The deposit amount required to register as a member"
|
|
|
|
},
|
|
|
|
"SET_SIZE()": {
|
|
|
|
"notice": "The size of the merkle tree, i.e 2^depth"
|
|
|
|
},
|
|
|
|
"idCommitmentIndex()": {
|
|
|
|
"notice": "The index of the next member to be registered"
|
|
|
|
},
|
|
|
|
"members(uint256)": {
|
|
|
|
"notice": "The membership status of each member"
|
|
|
|
},
|
|
|
|
"poseidonHasher()": {
|
|
|
|
"notice": "The Poseidon hasher contract"
|
|
|
|
},
|
|
|
|
"register(uint256)": {
|
|
|
|
"notice": "Allows a user to register as a member"
|
|
|
|
},
|
|
|
|
"registerBatch(uint256[])": {
|
|
|
|
"notice": "Allows batch registration of members"
|
|
|
|
},
|
|
|
|
"stakedAmounts(uint256)": {
|
|
|
|
"notice": "The amount of eth staked by each member"
|
|
|
|
},
|
|
|
|
"withdraw(uint256,address)": {
|
|
|
|
"notice": "Allows a user to slash a member"
|
|
|
|
},
|
|
|
|
"withdrawBatch(uint256[],address[])": {
|
|
|
|
"notice": "Allows a user to slash a batch of members"
|
|
|
|
}
|
|
|
|
},
|
2023-03-29 12:43:14 +05:30
|
|
|
"version": 1
|
|
|
|
},
|
|
|
|
"storageLayout": {
|
|
|
|
"storage": [
|
|
|
|
{
|
2023-03-30 18:29:06 +05:30
|
|
|
"astId": 488,
|
2023-03-29 12:43:14 +05:30
|
|
|
"contract": "contracts/Rln.sol:RLN",
|
|
|
|
"label": "idCommitmentIndex",
|
|
|
|
"offset": 0,
|
|
|
|
"slot": "0",
|
|
|
|
"type": "t_uint256"
|
|
|
|
},
|
|
|
|
{
|
2023-03-30 18:29:06 +05:30
|
|
|
"astId": 493,
|
2023-03-29 12:43:14 +05:30
|
|
|
"contract": "contracts/Rln.sol:RLN",
|
|
|
|
"label": "stakedAmounts",
|
|
|
|
"offset": 0,
|
|
|
|
"slot": "1",
|
|
|
|
"type": "t_mapping(t_uint256,t_uint256)"
|
|
|
|
},
|
|
|
|
{
|
2023-03-30 18:29:06 +05:30
|
|
|
"astId": 498,
|
2023-03-29 12:43:14 +05:30
|
|
|
"contract": "contracts/Rln.sol:RLN",
|
|
|
|
"label": "members",
|
|
|
|
"offset": 0,
|
|
|
|
"slot": "2",
|
|
|
|
"type": "t_mapping(t_uint256,t_bool)"
|
|
|
|
},
|
|
|
|
{
|
2023-03-30 18:29:06 +05:30
|
|
|
"astId": 502,
|
2023-03-29 12:43:14 +05:30
|
|
|
"contract": "contracts/Rln.sol:RLN",
|
|
|
|
"label": "poseidonHasher",
|
|
|
|
"offset": 0,
|
|
|
|
"slot": "3",
|
2023-03-30 18:29:06 +05:30
|
|
|
"type": "t_contract(IPoseidonHasher)10"
|
2023-03-29 12:43:14 +05:30
|
|
|
}
|
|
|
|
],
|
|
|
|
"types": {
|
|
|
|
"t_bool": {
|
|
|
|
"encoding": "inplace",
|
|
|
|
"label": "bool",
|
|
|
|
"numberOfBytes": "1"
|
|
|
|
},
|
2023-03-30 18:29:06 +05:30
|
|
|
"t_contract(IPoseidonHasher)10": {
|
2023-03-29 12:43:14 +05:30
|
|
|
"encoding": "inplace",
|
|
|
|
"label": "contract IPoseidonHasher",
|
|
|
|
"numberOfBytes": "20"
|
|
|
|
},
|
|
|
|
"t_mapping(t_uint256,t_bool)": {
|
|
|
|
"encoding": "mapping",
|
|
|
|
"key": "t_uint256",
|
|
|
|
"label": "mapping(uint256 => bool)",
|
|
|
|
"numberOfBytes": "32",
|
|
|
|
"value": "t_bool"
|
|
|
|
},
|
|
|
|
"t_mapping(t_uint256,t_uint256)": {
|
|
|
|
"encoding": "mapping",
|
|
|
|
"key": "t_uint256",
|
|
|
|
"label": "mapping(uint256 => uint256)",
|
|
|
|
"numberOfBytes": "32",
|
|
|
|
"value": "t_uint256"
|
|
|
|
},
|
|
|
|
"t_uint256": {
|
|
|
|
"encoding": "inplace",
|
|
|
|
"label": "uint256",
|
|
|
|
"numberOfBytes": "32"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|