From ab3f21f209e2a7a9e3d7801e9cd17901e9835a96 Mon Sep 17 00:00:00 2001 From: Richard Ramos Date: Wed, 30 Aug 2023 18:00:14 -0400 Subject: [PATCH] chore: compile smart contracts and generate types --- .gitmodules | 6 +- waku/v2/protocol/rln/contracts/README.md | 1 + waku/v2/protocol/rln/contracts/RLN.go | 773 ----------- .../rln/contracts/compile_contracts.sh | 24 + waku/v2/protocol/rln/contracts/generate.go | 4 +- waku/v2/protocol/rln/contracts/import.json | 31 + .../{PoseidonHasher.go => poseidon.go} | 35 +- waku/v2/protocol/rln/contracts/registry.go | 814 ++++++++++++ waku/v2/protocol/rln/contracts/rln-contract | 1 - waku/v2/protocol/rln/contracts/rln.go | 1171 +++++++++++++++++ .../protocol/rln/contracts/waku-rln-contract | 1 + 11 files changed, 2079 insertions(+), 782 deletions(-) delete mode 100644 waku/v2/protocol/rln/contracts/RLN.go create mode 100755 waku/v2/protocol/rln/contracts/compile_contracts.sh create mode 100644 waku/v2/protocol/rln/contracts/import.json rename waku/v2/protocol/rln/contracts/{PoseidonHasher.go => poseidon.go} (57%) create mode 100644 waku/v2/protocol/rln/contracts/registry.go delete mode 160000 waku/v2/protocol/rln/contracts/rln-contract create mode 100644 waku/v2/protocol/rln/contracts/rln.go create mode 160000 waku/v2/protocol/rln/contracts/waku-rln-contract diff --git a/.gitmodules b/.gitmodules index 6014d262..45cc4f78 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,3 @@ -[submodule "waku/v2/protocol/rln/contracts/rln-contract"] - path = waku/v2/protocol/rln/contracts/rln-contract - url = git@github.com:vacp2p/rln-contract.git +[submodule "waku/v2/protocol/rln/contracts/waku-rln-contract"] + path = waku/v2/protocol/rln/contracts/waku-rln-contract + url = git@github.com:waku-org/waku-rln-contract.git diff --git a/waku/v2/protocol/rln/contracts/README.md b/waku/v2/protocol/rln/contracts/README.md index 6717c75b..d4e0959e 100644 --- a/waku/v2/protocol/rln/contracts/README.md +++ b/waku/v2/protocol/rln/contracts/README.md @@ -3,6 +3,7 @@ ### Requirements: - Node.js - Go +- jq - [solcjs 0.8.15](https://github.com/ethereum/solc-js) - [abigen](https://github.com/ethereum/go-ethereum/tree/master/cmd/abigen) diff --git a/waku/v2/protocol/rln/contracts/RLN.go b/waku/v2/protocol/rln/contracts/RLN.go deleted file mode 100644 index a8bc8387..00000000 --- a/waku/v2/protocol/rln/contracts/RLN.go +++ /dev/null @@ -1,773 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package contracts - -import ( - "errors" - "math/big" - "strings" - - ethereum "github.com/ethereum/go-ethereum" - "github.com/ethereum/go-ethereum/accounts/abi" - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/event" -) - -// Reference imports to suppress errors if they are not otherwise used. -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -// RLNMetaData contains all meta data concerning the RLN contract. -var RLNMetaData = &bind.MetaData{ - 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\":\"contractIPoseidonHasher\",\"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\":\"addresspayable\",\"name\":\"receiver\",\"type\":\"address\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"secrets\",\"type\":\"uint256[]\"},{\"internalType\":\"addresspayable[]\",\"name\":\"receivers\",\"type\":\"address[]\"}],\"name\":\"withdrawBatch\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60e06040523480156200001157600080fd5b50604051620012c0380380620012c0833981810160405281019062000037919062000142565b82608081815250508160a08181525050816001901b60c0818152505080600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050506200019e565b600080fd5b6000819050919050565b620000b781620000a2565b8114620000c357600080fd5b50565b600081519050620000d781620000ac565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006200010a82620000dd565b9050919050565b6200011c81620000fd565b81146200012857600080fd5b50565b6000815190506200013c8162000111565b92915050565b6000806000606084860312156200015e576200015d6200009d565b5b60006200016e86828701620000c6565b93505060206200018186828701620000c6565b925050604062000194868287016200012b565b9150509250925092565b60805160a05160c0516110cf620001f1600039600081816104140152818161058501526109070152600061054301526000818161047d015281816105a9015281816105d0015261063c01526110cf6000f3fe60806040526004361061009b5760003560e01c806398366e351161006457806398366e3514610176578063ae74552a146101a1578063bc499128146101cc578063d0383d6814610209578063f207564e14610234578063f220b9ec146102505761009b565b8062f714ce146100a0578063331b6ab3146100c957806340070712146100f45780635daf08ca1461011d57806369e4863f1461015a575b600080fd5b3480156100ac57600080fd5b506100c760048036038101906100c29190610b3f565b61027b565b005b3480156100d557600080fd5b506100de610289565b6040516100eb9190610bde565b60405180910390f35b34801561010057600080fd5b5061011b60048036038101906101169190610cb4565b6102af565b005b34801561012957600080fd5b50610144600480360381019061013f9190610d35565b6103b0565b6040516101519190610d7d565b60405180910390f35b610174600480360381019061016f9190610d98565b6103d0565b005b34801561018257600080fd5b5061018b610541565b6040516101989190610df4565b60405180910390f35b3480156101ad57600080fd5b506101b6610565565b6040516101c39190610df4565b60405180910390f35b3480156101d857600080fd5b506101f360048036038101906101ee9190610d35565b61056b565b6040516102009190610df4565b60405180910390f35b34801561021557600080fd5b5061021e610583565b60405161022b9190610df4565b60405180910390f35b61024e60048036038101906102499190610d35565b6105a7565b005b34801561025c57600080fd5b5061026561063a565b6040516102729190610df4565b60405180910390f35b610285828261065e565b5050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000848490509050600081036102f1576040517fc2e5347d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8282905081146103405784849050838390506040517f727c6a75000000000000000000000000000000000000000000000000000000008152600401610337929190610e0f565b60405180910390fd5b60005b818110156103a85761039586868381811061036157610360610e38565b5b9050602002013585858481811061037b5761037a610e38565b5b90506020020160208101906103909190610e67565b61065e565b80806103a090610ec3565b915050610343565b505050505050565b60026020528060005260406000206000915054906101000a900460ff1681565b600082829050905060008103610412576040517fc2e5347d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f0000000000000000000000000000000000000000000000000000000000000000816000546104419190610f0b565b10610478576040517f75eb4dbe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000817f00000000000000000000000000000000000000000000000000000000000000006104a69190610f61565b90508034146104ee5780346040517f25c3f46e0000000000000000000000000000000000000000000000000000000081526004016104e5929190610e0f565b60405180910390fd5b60005b8281101561053a5761052785858381811061050f5761050e610e38565b5b9050602002013584346105229190610fea565b6108ae565b808061053290610ec3565b9150506104f1565b5050505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b60005481565b60016020528060005260406000206000915090505481565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f0000000000000000000000000000000000000000000000000000000000000000341461062d577f0000000000000000000000000000000000000000000000000000000000000000346040517f25c3f46e000000000000000000000000000000000000000000000000000000008152600401610624929190610e0f565b60405180910390fd5b61063781346108ae565b50565b7f000000000000000000000000000000000000000000000000000000000000000081565b3073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614806106c45750600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16145b1561070657806040517f21680a040000000000000000000000000000000000000000000000000000000081526004016106fd919061103c565b60405180910390fd5b6000610711836109fc565b90506002600082815260200190815260200160002060009054906101000a900460ff1661077557806040517f5a971ebb00000000000000000000000000000000000000000000000000000000815260040161076c9190610df4565b60405180910390fd5b60006001600083815260200190815260200160002054036107cd57806040517faabeeba50000000000000000000000000000000000000000000000000000000081526004016107c49190610df4565b60405180910390fd5b60006001600083815260200190815260200160002054905060006002600084815260200190815260200160002060006101000a81548160ff021916908315150217905550600060016000848152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f19350505050158015610870573d6000803e3d6000fd5b507fad2d771c5ad1c1e6f50cc769e53ec1e194002c29f28c3dd2af5639b60d8072a6826040516108a09190610df4565b60405180910390a150505050565b6002600083815260200190815260200160002060009054906101000a900460ff1615610905576040517e0a60f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000060005410610960576040517f75eb4dbe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016002600084815260200190815260200160002060006101000a81548160ff0219169083151502179055508060016000848152602001908152602001600020819055507f5a92c2530f207992057b9c3e544108ffce3beda4a63719f316967c49bf6159d2826000546040516109d7929190610e0f565b60405180910390a160016000808282546109f19190610f0b565b925050819055505050565b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b189fd4c836040518263ffffffff1660e01b8152600401610a599190610df4565b602060405180830381865afa158015610a76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a9a919061106c565b9050919050565b600080fd5b600080fd5b6000819050919050565b610abe81610aab565b8114610ac957600080fd5b50565b600081359050610adb81610ab5565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000610b0c82610ae1565b9050919050565b610b1c81610b01565b8114610b2757600080fd5b50565b600081359050610b3981610b13565b92915050565b60008060408385031215610b5657610b55610aa1565b5b6000610b6485828601610acc565b9250506020610b7585828601610b2a565b9150509250929050565b6000819050919050565b6000610ba4610b9f610b9a84610ae1565b610b7f565b610ae1565b9050919050565b6000610bb682610b89565b9050919050565b6000610bc882610bab565b9050919050565b610bd881610bbd565b82525050565b6000602082019050610bf36000830184610bcf565b92915050565b600080fd5b600080fd5b600080fd5b60008083601f840112610c1e57610c1d610bf9565b5b8235905067ffffffffffffffff811115610c3b57610c3a610bfe565b5b602083019150836020820283011115610c5757610c56610c03565b5b9250929050565b60008083601f840112610c7457610c73610bf9565b5b8235905067ffffffffffffffff811115610c9157610c90610bfe565b5b602083019150836020820283011115610cad57610cac610c03565b5b9250929050565b60008060008060408587031215610cce57610ccd610aa1565b5b600085013567ffffffffffffffff811115610cec57610ceb610aa6565b5b610cf887828801610c08565b9450945050602085013567ffffffffffffffff811115610d1b57610d1a610aa6565b5b610d2787828801610c5e565b925092505092959194509250565b600060208284031215610d4b57610d4a610aa1565b5b6000610d5984828501610acc565b91505092915050565b60008115159050919050565b610d7781610d62565b82525050565b6000602082019050610d926000830184610d6e565b92915050565b60008060208385031215610daf57610dae610aa1565b5b600083013567ffffffffffffffff811115610dcd57610dcc610aa6565b5b610dd985828601610c08565b92509250509250929050565b610dee81610aab565b82525050565b6000602082019050610e096000830184610de5565b92915050565b6000604082019050610e246000830185610de5565b610e316020830184610de5565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060208284031215610e7d57610e7c610aa1565b5b6000610e8b84828501610b2a565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000610ece82610aab565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610f0057610eff610e94565b5b600182019050919050565b6000610f1682610aab565b9150610f2183610aab565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115610f5657610f55610e94565b5b828201905092915050565b6000610f6c82610aab565b9150610f7783610aab565b9250817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615610fb057610faf610e94565b5b828202905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000610ff582610aab565b915061100083610aab565b9250826110105761100f610fbb565b5b828204905092915050565b600061102682610bab565b9050919050565b6110368161101b565b82525050565b6000602082019050611051600083018461102d565b92915050565b60008151905061106681610ab5565b92915050565b60006020828403121561108257611081610aa1565b5b600061109084828501611057565b9150509291505056fea26469706673582212201eba48f9e121352ff146b50c2c2a98d3cbb52bcd90bf3d5e555aa60d7c6778f064736f6c634300080f0033", -} - -// RLNABI is the input ABI used to generate the binding from. -// Deprecated: Use RLNMetaData.ABI instead. -var RLNABI = RLNMetaData.ABI - -// RLNBin is the compiled bytecode used for deploying new contracts. -// Deprecated: Use RLNMetaData.Bin instead. -var RLNBin = RLNMetaData.Bin - -// DeployRLN deploys a new Ethereum contract, binding an instance of RLN to it. -func DeployRLN(auth *bind.TransactOpts, backend bind.ContractBackend, membershipDeposit *big.Int, depth *big.Int, _poseidonHasher common.Address) (common.Address, *types.Transaction, *RLN, error) { - parsed, err := RLNMetaData.GetAbi() - if err != nil { - return common.Address{}, nil, nil, err - } - if parsed == nil { - return common.Address{}, nil, nil, errors.New("GetABI returned nil") - } - - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(RLNBin), backend, membershipDeposit, depth, _poseidonHasher) - if err != nil { - return common.Address{}, nil, nil, err - } - return address, tx, &RLN{RLNCaller: RLNCaller{contract: contract}, RLNTransactor: RLNTransactor{contract: contract}, RLNFilterer: RLNFilterer{contract: contract}}, nil -} - -// RLN is an auto generated Go binding around an Ethereum contract. -type RLN struct { - RLNCaller // Read-only binding to the contract - RLNTransactor // Write-only binding to the contract - RLNFilterer // Log filterer for contract events -} - -// RLNCaller is an auto generated read-only Go binding around an Ethereum contract. -type RLNCaller struct { - contract *bind.BoundContract // Generic contract wrapper for the low level calls -} - -// RLNTransactor is an auto generated write-only Go binding around an Ethereum contract. -type RLNTransactor struct { - contract *bind.BoundContract // Generic contract wrapper for the low level calls -} - -// RLNFilterer is an auto generated log filtering Go binding around an Ethereum contract events. -type RLNFilterer struct { - contract *bind.BoundContract // Generic contract wrapper for the low level calls -} - -// RLNSession is an auto generated Go binding around an Ethereum contract, -// with pre-set call and transact options. -type RLNSession struct { - Contract *RLN // Generic contract binding to set the session for - CallOpts bind.CallOpts // Call options to use throughout this session - TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session -} - -// RLNCallerSession is an auto generated read-only Go binding around an Ethereum contract, -// with pre-set call options. -type RLNCallerSession struct { - Contract *RLNCaller // Generic contract caller binding to set the session for - CallOpts bind.CallOpts // Call options to use throughout this session -} - -// RLNTransactorSession is an auto generated write-only Go binding around an Ethereum contract, -// with pre-set transact options. -type RLNTransactorSession struct { - Contract *RLNTransactor // Generic contract transactor binding to set the session for - TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session -} - -// RLNRaw is an auto generated low-level Go binding around an Ethereum contract. -type RLNRaw struct { - Contract *RLN // Generic contract binding to access the raw methods on -} - -// RLNCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. -type RLNCallerRaw struct { - Contract *RLNCaller // Generic read-only contract binding to access the raw methods on -} - -// RLNTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. -type RLNTransactorRaw struct { - Contract *RLNTransactor // Generic write-only contract binding to access the raw methods on -} - -// NewRLN creates a new instance of RLN, bound to a specific deployed contract. -func NewRLN(address common.Address, backend bind.ContractBackend) (*RLN, error) { - contract, err := bindRLN(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &RLN{RLNCaller: RLNCaller{contract: contract}, RLNTransactor: RLNTransactor{contract: contract}, RLNFilterer: RLNFilterer{contract: contract}}, nil -} - -// NewRLNCaller creates a new read-only instance of RLN, bound to a specific deployed contract. -func NewRLNCaller(address common.Address, caller bind.ContractCaller) (*RLNCaller, error) { - contract, err := bindRLN(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &RLNCaller{contract: contract}, nil -} - -// NewRLNTransactor creates a new write-only instance of RLN, bound to a specific deployed contract. -func NewRLNTransactor(address common.Address, transactor bind.ContractTransactor) (*RLNTransactor, error) { - contract, err := bindRLN(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &RLNTransactor{contract: contract}, nil -} - -// NewRLNFilterer creates a new log filterer instance of RLN, bound to a specific deployed contract. -func NewRLNFilterer(address common.Address, filterer bind.ContractFilterer) (*RLNFilterer, error) { - contract, err := bindRLN(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &RLNFilterer{contract: contract}, nil -} - -// bindRLN binds a generic wrapper to an already deployed contract. -func bindRLN(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := RLNMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -// Call invokes the (constant) contract method with params as input values and -// sets the output to result. The result type might be a single field for simple -// returns, a slice of interfaces for anonymous returns and a struct for named -// returns. -func (_RLN *RLNRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _RLN.Contract.RLNCaller.contract.Call(opts, result, method, params...) -} - -// Transfer initiates a plain transaction to move funds to the contract, calling -// its default method if one is available. -func (_RLN *RLNRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _RLN.Contract.RLNTransactor.contract.Transfer(opts) -} - -// Transact invokes the (paid) contract method with params as input values. -func (_RLN *RLNRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _RLN.Contract.RLNTransactor.contract.Transact(opts, method, params...) -} - -// Call invokes the (constant) contract method with params as input values and -// sets the output to result. The result type might be a single field for simple -// returns, a slice of interfaces for anonymous returns and a struct for named -// returns. -func (_RLN *RLNCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _RLN.Contract.contract.Call(opts, result, method, params...) -} - -// Transfer initiates a plain transaction to move funds to the contract, calling -// its default method if one is available. -func (_RLN *RLNTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _RLN.Contract.contract.Transfer(opts) -} - -// Transact invokes the (paid) contract method with params as input values. -func (_RLN *RLNTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _RLN.Contract.contract.Transact(opts, method, params...) -} - -// DEPTH is a free data retrieval call binding the contract method 0x98366e35. -// -// Solidity: function DEPTH() view returns(uint256) -func (_RLN *RLNCaller) DEPTH(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _RLN.contract.Call(opts, &out, "DEPTH") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -// DEPTH is a free data retrieval call binding the contract method 0x98366e35. -// -// Solidity: function DEPTH() view returns(uint256) -func (_RLN *RLNSession) DEPTH() (*big.Int, error) { - return _RLN.Contract.DEPTH(&_RLN.CallOpts) -} - -// DEPTH is a free data retrieval call binding the contract method 0x98366e35. -// -// Solidity: function DEPTH() view returns(uint256) -func (_RLN *RLNCallerSession) DEPTH() (*big.Int, error) { - return _RLN.Contract.DEPTH(&_RLN.CallOpts) -} - -// MEMBERSHIPDEPOSIT is a free data retrieval call binding the contract method 0xf220b9ec. -// -// Solidity: function MEMBERSHIP_DEPOSIT() view returns(uint256) -func (_RLN *RLNCaller) MEMBERSHIPDEPOSIT(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _RLN.contract.Call(opts, &out, "MEMBERSHIP_DEPOSIT") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -// MEMBERSHIPDEPOSIT is a free data retrieval call binding the contract method 0xf220b9ec. -// -// Solidity: function MEMBERSHIP_DEPOSIT() view returns(uint256) -func (_RLN *RLNSession) MEMBERSHIPDEPOSIT() (*big.Int, error) { - return _RLN.Contract.MEMBERSHIPDEPOSIT(&_RLN.CallOpts) -} - -// MEMBERSHIPDEPOSIT is a free data retrieval call binding the contract method 0xf220b9ec. -// -// Solidity: function MEMBERSHIP_DEPOSIT() view returns(uint256) -func (_RLN *RLNCallerSession) MEMBERSHIPDEPOSIT() (*big.Int, error) { - return _RLN.Contract.MEMBERSHIPDEPOSIT(&_RLN.CallOpts) -} - -// SETSIZE is a free data retrieval call binding the contract method 0xd0383d68. -// -// Solidity: function SET_SIZE() view returns(uint256) -func (_RLN *RLNCaller) SETSIZE(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _RLN.contract.Call(opts, &out, "SET_SIZE") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -// SETSIZE is a free data retrieval call binding the contract method 0xd0383d68. -// -// Solidity: function SET_SIZE() view returns(uint256) -func (_RLN *RLNSession) SETSIZE() (*big.Int, error) { - return _RLN.Contract.SETSIZE(&_RLN.CallOpts) -} - -// SETSIZE is a free data retrieval call binding the contract method 0xd0383d68. -// -// Solidity: function SET_SIZE() view returns(uint256) -func (_RLN *RLNCallerSession) SETSIZE() (*big.Int, error) { - return _RLN.Contract.SETSIZE(&_RLN.CallOpts) -} - -// IdCommitmentIndex is a free data retrieval call binding the contract method 0xae74552a. -// -// Solidity: function idCommitmentIndex() view returns(uint256) -func (_RLN *RLNCaller) IdCommitmentIndex(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _RLN.contract.Call(opts, &out, "idCommitmentIndex") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -// IdCommitmentIndex is a free data retrieval call binding the contract method 0xae74552a. -// -// Solidity: function idCommitmentIndex() view returns(uint256) -func (_RLN *RLNSession) IdCommitmentIndex() (*big.Int, error) { - return _RLN.Contract.IdCommitmentIndex(&_RLN.CallOpts) -} - -// IdCommitmentIndex is a free data retrieval call binding the contract method 0xae74552a. -// -// Solidity: function idCommitmentIndex() view returns(uint256) -func (_RLN *RLNCallerSession) IdCommitmentIndex() (*big.Int, error) { - return _RLN.Contract.IdCommitmentIndex(&_RLN.CallOpts) -} - -// Members is a free data retrieval call binding the contract method 0x5daf08ca. -// -// Solidity: function members(uint256 ) view returns(bool) -func (_RLN *RLNCaller) Members(opts *bind.CallOpts, arg0 *big.Int) (bool, error) { - var out []interface{} - err := _RLN.contract.Call(opts, &out, "members", arg0) - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -// Members is a free data retrieval call binding the contract method 0x5daf08ca. -// -// Solidity: function members(uint256 ) view returns(bool) -func (_RLN *RLNSession) Members(arg0 *big.Int) (bool, error) { - return _RLN.Contract.Members(&_RLN.CallOpts, arg0) -} - -// Members is a free data retrieval call binding the contract method 0x5daf08ca. -// -// Solidity: function members(uint256 ) view returns(bool) -func (_RLN *RLNCallerSession) Members(arg0 *big.Int) (bool, error) { - return _RLN.Contract.Members(&_RLN.CallOpts, arg0) -} - -// PoseidonHasher is a free data retrieval call binding the contract method 0x331b6ab3. -// -// Solidity: function poseidonHasher() view returns(address) -func (_RLN *RLNCaller) PoseidonHasher(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _RLN.contract.Call(opts, &out, "poseidonHasher") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// PoseidonHasher is a free data retrieval call binding the contract method 0x331b6ab3. -// -// Solidity: function poseidonHasher() view returns(address) -func (_RLN *RLNSession) PoseidonHasher() (common.Address, error) { - return _RLN.Contract.PoseidonHasher(&_RLN.CallOpts) -} - -// PoseidonHasher is a free data retrieval call binding the contract method 0x331b6ab3. -// -// Solidity: function poseidonHasher() view returns(address) -func (_RLN *RLNCallerSession) PoseidonHasher() (common.Address, error) { - return _RLN.Contract.PoseidonHasher(&_RLN.CallOpts) -} - -// StakedAmounts is a free data retrieval call binding the contract method 0xbc499128. -// -// Solidity: function stakedAmounts(uint256 ) view returns(uint256) -func (_RLN *RLNCaller) StakedAmounts(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { - var out []interface{} - err := _RLN.contract.Call(opts, &out, "stakedAmounts", arg0) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -// StakedAmounts is a free data retrieval call binding the contract method 0xbc499128. -// -// Solidity: function stakedAmounts(uint256 ) view returns(uint256) -func (_RLN *RLNSession) StakedAmounts(arg0 *big.Int) (*big.Int, error) { - return _RLN.Contract.StakedAmounts(&_RLN.CallOpts, arg0) -} - -// StakedAmounts is a free data retrieval call binding the contract method 0xbc499128. -// -// Solidity: function stakedAmounts(uint256 ) view returns(uint256) -func (_RLN *RLNCallerSession) StakedAmounts(arg0 *big.Int) (*big.Int, error) { - return _RLN.Contract.StakedAmounts(&_RLN.CallOpts, arg0) -} - -// Register is a paid mutator transaction binding the contract method 0xf207564e. -// -// Solidity: function register(uint256 idCommitment) payable returns() -func (_RLN *RLNTransactor) Register(opts *bind.TransactOpts, idCommitment *big.Int) (*types.Transaction, error) { - return _RLN.contract.Transact(opts, "register", idCommitment) -} - -// Register is a paid mutator transaction binding the contract method 0xf207564e. -// -// Solidity: function register(uint256 idCommitment) payable returns() -func (_RLN *RLNSession) Register(idCommitment *big.Int) (*types.Transaction, error) { - return _RLN.Contract.Register(&_RLN.TransactOpts, idCommitment) -} - -// Register is a paid mutator transaction binding the contract method 0xf207564e. -// -// Solidity: function register(uint256 idCommitment) payable returns() -func (_RLN *RLNTransactorSession) Register(idCommitment *big.Int) (*types.Transaction, error) { - return _RLN.Contract.Register(&_RLN.TransactOpts, idCommitment) -} - -// RegisterBatch is a paid mutator transaction binding the contract method 0x69e4863f. -// -// Solidity: function registerBatch(uint256[] idCommitments) payable returns() -func (_RLN *RLNTransactor) RegisterBatch(opts *bind.TransactOpts, idCommitments []*big.Int) (*types.Transaction, error) { - return _RLN.contract.Transact(opts, "registerBatch", idCommitments) -} - -// RegisterBatch is a paid mutator transaction binding the contract method 0x69e4863f. -// -// Solidity: function registerBatch(uint256[] idCommitments) payable returns() -func (_RLN *RLNSession) RegisterBatch(idCommitments []*big.Int) (*types.Transaction, error) { - return _RLN.Contract.RegisterBatch(&_RLN.TransactOpts, idCommitments) -} - -// RegisterBatch is a paid mutator transaction binding the contract method 0x69e4863f. -// -// Solidity: function registerBatch(uint256[] idCommitments) payable returns() -func (_RLN *RLNTransactorSession) RegisterBatch(idCommitments []*big.Int) (*types.Transaction, error) { - return _RLN.Contract.RegisterBatch(&_RLN.TransactOpts, idCommitments) -} - -// Withdraw is a paid mutator transaction binding the contract method 0x00f714ce. -// -// Solidity: function withdraw(uint256 secret, address receiver) returns() -func (_RLN *RLNTransactor) Withdraw(opts *bind.TransactOpts, secret *big.Int, receiver common.Address) (*types.Transaction, error) { - return _RLN.contract.Transact(opts, "withdraw", secret, receiver) -} - -// Withdraw is a paid mutator transaction binding the contract method 0x00f714ce. -// -// Solidity: function withdraw(uint256 secret, address receiver) returns() -func (_RLN *RLNSession) Withdraw(secret *big.Int, receiver common.Address) (*types.Transaction, error) { - return _RLN.Contract.Withdraw(&_RLN.TransactOpts, secret, receiver) -} - -// Withdraw is a paid mutator transaction binding the contract method 0x00f714ce. -// -// Solidity: function withdraw(uint256 secret, address receiver) returns() -func (_RLN *RLNTransactorSession) Withdraw(secret *big.Int, receiver common.Address) (*types.Transaction, error) { - return _RLN.Contract.Withdraw(&_RLN.TransactOpts, secret, receiver) -} - -// WithdrawBatch is a paid mutator transaction binding the contract method 0x40070712. -// -// Solidity: function withdrawBatch(uint256[] secrets, address[] receivers) returns() -func (_RLN *RLNTransactor) WithdrawBatch(opts *bind.TransactOpts, secrets []*big.Int, receivers []common.Address) (*types.Transaction, error) { - return _RLN.contract.Transact(opts, "withdrawBatch", secrets, receivers) -} - -// WithdrawBatch is a paid mutator transaction binding the contract method 0x40070712. -// -// Solidity: function withdrawBatch(uint256[] secrets, address[] receivers) returns() -func (_RLN *RLNSession) WithdrawBatch(secrets []*big.Int, receivers []common.Address) (*types.Transaction, error) { - return _RLN.Contract.WithdrawBatch(&_RLN.TransactOpts, secrets, receivers) -} - -// WithdrawBatch is a paid mutator transaction binding the contract method 0x40070712. -// -// Solidity: function withdrawBatch(uint256[] secrets, address[] receivers) returns() -func (_RLN *RLNTransactorSession) WithdrawBatch(secrets []*big.Int, receivers []common.Address) (*types.Transaction, error) { - return _RLN.Contract.WithdrawBatch(&_RLN.TransactOpts, secrets, receivers) -} - -// RLNMemberRegisteredIterator is returned from FilterMemberRegistered and is used to iterate over the raw logs and unpacked data for MemberRegistered events raised by the RLN contract. -type RLNMemberRegisteredIterator struct { - Event *RLNMemberRegistered // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *RLNMemberRegisteredIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(RLNMemberRegistered) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(RLNMemberRegistered) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *RLNMemberRegisteredIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *RLNMemberRegisteredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// RLNMemberRegistered represents a MemberRegistered event raised by the RLN contract. -type RLNMemberRegistered struct { - IdCommitment *big.Int - Index *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterMemberRegistered is a free log retrieval operation binding the contract event 0x5a92c2530f207992057b9c3e544108ffce3beda4a63719f316967c49bf6159d2. -// -// Solidity: event MemberRegistered(uint256 idCommitment, uint256 index) -func (_RLN *RLNFilterer) FilterMemberRegistered(opts *bind.FilterOpts) (*RLNMemberRegisteredIterator, error) { - - logs, sub, err := _RLN.contract.FilterLogs(opts, "MemberRegistered") - if err != nil { - return nil, err - } - return &RLNMemberRegisteredIterator{contract: _RLN.contract, event: "MemberRegistered", logs: logs, sub: sub}, nil -} - -// WatchMemberRegistered is a free log subscription operation binding the contract event 0x5a92c2530f207992057b9c3e544108ffce3beda4a63719f316967c49bf6159d2. -// -// Solidity: event MemberRegistered(uint256 idCommitment, uint256 index) -func (_RLN *RLNFilterer) WatchMemberRegistered(opts *bind.WatchOpts, sink chan<- *RLNMemberRegistered) (event.Subscription, error) { - - logs, sub, err := _RLN.contract.WatchLogs(opts, "MemberRegistered") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(RLNMemberRegistered) - if err := _RLN.contract.UnpackLog(event, "MemberRegistered", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseMemberRegistered is a log parse operation binding the contract event 0x5a92c2530f207992057b9c3e544108ffce3beda4a63719f316967c49bf6159d2. -// -// Solidity: event MemberRegistered(uint256 idCommitment, uint256 index) -func (_RLN *RLNFilterer) ParseMemberRegistered(log types.Log) (*RLNMemberRegistered, error) { - event := new(RLNMemberRegistered) - if err := _RLN.contract.UnpackLog(event, "MemberRegistered", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// RLNMemberWithdrawnIterator is returned from FilterMemberWithdrawn and is used to iterate over the raw logs and unpacked data for MemberWithdrawn events raised by the RLN contract. -type RLNMemberWithdrawnIterator struct { - Event *RLNMemberWithdrawn // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *RLNMemberWithdrawnIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(RLNMemberWithdrawn) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(RLNMemberWithdrawn) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *RLNMemberWithdrawnIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *RLNMemberWithdrawnIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// RLNMemberWithdrawn represents a MemberWithdrawn event raised by the RLN contract. -type RLNMemberWithdrawn struct { - IdCommitment *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterMemberWithdrawn is a free log retrieval operation binding the contract event 0xad2d771c5ad1c1e6f50cc769e53ec1e194002c29f28c3dd2af5639b60d8072a6. -// -// Solidity: event MemberWithdrawn(uint256 idCommitment) -func (_RLN *RLNFilterer) FilterMemberWithdrawn(opts *bind.FilterOpts) (*RLNMemberWithdrawnIterator, error) { - - logs, sub, err := _RLN.contract.FilterLogs(opts, "MemberWithdrawn") - if err != nil { - return nil, err - } - return &RLNMemberWithdrawnIterator{contract: _RLN.contract, event: "MemberWithdrawn", logs: logs, sub: sub}, nil -} - -// WatchMemberWithdrawn is a free log subscription operation binding the contract event 0xad2d771c5ad1c1e6f50cc769e53ec1e194002c29f28c3dd2af5639b60d8072a6. -// -// Solidity: event MemberWithdrawn(uint256 idCommitment) -func (_RLN *RLNFilterer) WatchMemberWithdrawn(opts *bind.WatchOpts, sink chan<- *RLNMemberWithdrawn) (event.Subscription, error) { - - logs, sub, err := _RLN.contract.WatchLogs(opts, "MemberWithdrawn") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(RLNMemberWithdrawn) - if err := _RLN.contract.UnpackLog(event, "MemberWithdrawn", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseMemberWithdrawn is a log parse operation binding the contract event 0xad2d771c5ad1c1e6f50cc769e53ec1e194002c29f28c3dd2af5639b60d8072a6. -// -// Solidity: event MemberWithdrawn(uint256 idCommitment) -func (_RLN *RLNFilterer) ParseMemberWithdrawn(log types.Log) (*RLNMemberWithdrawn, error) { - event := new(RLNMemberWithdrawn) - if err := _RLN.contract.UnpackLog(event, "MemberWithdrawn", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} diff --git a/waku/v2/protocol/rln/contracts/compile_contracts.sh b/waku/v2/protocol/rln/contracts/compile_contracts.sh new file mode 100755 index 00000000..683b2f46 --- /dev/null +++ b/waku/v2/protocol/rln/contracts/compile_contracts.sh @@ -0,0 +1,24 @@ +#!/bin/sh + +# Generate solc_output.json +cat import.json | solcjs --bin --standard-json --base-path . > solc_output.json +tail -n +2 solc_output.json > solc_output.tmp # Removes ">>> Cannot retry compilation with SMT because there are no SMT solvers available." +mv solc_output.tmp solc_output.json + +# Generate abi and binary files for each smart contract +jq '.contracts."WakuRln.sol".WakuRln.abi' -r -c solc_output.json > WakuRln.abi +jq '.contracts."WakuRln.sol".WakuRln.evm.bytecode.object' -r -c solc_output.json > WakuRln.bin +jq '.contracts."WakuRlnRegistry.sol".WakuRlnRegistry.abi' -r -c solc_output.json > WakuRlnRegistry.abi +jq '.contracts."WakuRlnRegistry.sol".WakuRlnRegistry.evm.bytecode.object' -r -c solc_output.json > WakuRlnRegistry.bin +jq '.contracts."rln-contract/PoseidonHasher.sol".PoseidonHasher.abi' -r -c solc_output.json > PoseidonHasher.abi +jq '.contracts."rln-contract/PoseidonHasher.sol".PoseidonHasher.evm.bytecode.object' -r -c solc_output.json > PoseidonHasher.bin + +# Generate golang types for each contract +abigen --abi ./WakuRln.abi --pkg contracts --type RLN --out ./rln.go --bin ./WakuRln.bin +abigen --abi ./WakuRlnRegistry.abi --pkg contracts --type RLNRegistry --out ./registry.go --bin ./WakuRlnRegistry.bin +abigen --abi ./PoseidonHasher.abi --pkg contracts --type PoseidonHasher --out ./poseidon.go --bin ./PoseidonHasher.bin + +# Cleanup +rm *.bin +rm *.abi +rm solc_output.json \ No newline at end of file diff --git a/waku/v2/protocol/rln/contracts/generate.go b/waku/v2/protocol/rln/contracts/generate.go index 254bad18..07963231 100644 --- a/waku/v2/protocol/rln/contracts/generate.go +++ b/waku/v2/protocol/rln/contracts/generate.go @@ -1,5 +1,3 @@ package contracts -//go:generate solcjs --abi --bin ./rln-contract/contracts/Rln.sol -o ./ -//go:generate abigen --abi ./rln-contract_contracts_Rln_sol_RLN.abi --pkg contracts --type RLN --out ./RLN.go --bin ./rln-contract_contracts_Rln_sol_RLN.bin -//go:generate abigen --abi ./rln-contract_contracts_PoseidonHasher_sol_PoseidonHasher.abi --pkg contracts --type PoseidonHasher --out ./PoseidonHasher.go --bin ./rln-contract_contracts_PoseidonHasher_sol_PoseidonHasher.bin +//go:generate ./compile_contracts.sh diff --git a/waku/v2/protocol/rln/contracts/import.json b/waku/v2/protocol/rln/contracts/import.json new file mode 100644 index 00000000..39559564 --- /dev/null +++ b/waku/v2/protocol/rln/contracts/import.json @@ -0,0 +1,31 @@ +{ + "language": "Solidity", + "sources": { + "WakuRln.sol": { + "urls": ["./waku-rln-contract/contracts/WakuRln.sol"] + }, + "WakuRlnRegistry.sol": { + "urls": ["./waku-rln-contract/contracts/WakuRlnRegistry.sol"] + }, + "rln-contract/PoseidonHasher.sol": { + "urls": [ + "./waku-rln-contract/lib/rln-contract/contracts/PoseidonHasher.sol" + ] + }, + "rln-contract/RlnBase.sol": { + "urls": ["./waku-rln-contract/lib/rln-contract/contracts/RlnBase.sol"] + }, + "rln-contract/IVerifier.sol": { + "urls": ["./waku-rln-contract/lib/rln-contract/contracts/IVerifier.sol"] + }, + "openzeppelin-contracts/contracts/access/Ownable.sol": { + "urls": ["./waku-rln-contract/lib/openzeppelin-contracts/contracts/access/Ownable.sol"] + }, + "openzeppelin-contracts/contracts/utils/Context.sol": { + "urls": ["./waku-rln-contract/lib/openzeppelin-contracts/contracts/utils/Context.sol"] + } + }, + "settings": { + "outputSelection": { "*": { "*": ["abi", "evm.bytecode.object"] } } + } +} diff --git a/waku/v2/protocol/rln/contracts/PoseidonHasher.go b/waku/v2/protocol/rln/contracts/poseidon.go similarity index 57% rename from waku/v2/protocol/rln/contracts/PoseidonHasher.go rename to waku/v2/protocol/rln/contracts/poseidon.go index e22e0810..ac64c6a2 100644 --- a/waku/v2/protocol/rln/contracts/PoseidonHasher.go +++ b/waku/v2/protocol/rln/contracts/poseidon.go @@ -31,8 +31,8 @@ var ( // PoseidonHasherMetaData contains all meta data concerning the PoseidonHasher contract. var PoseidonHasherMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"input\",\"type\":\"uint256\"}],\"name\":\"hash\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"result\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b50613e0b806100206000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c8063b189fd4c14610030575b600080fd5b61004a60048036038101906100459190613d7e565b610060565b6040516100579190613dba565b60405180910390f35b600061006b82610072565b9050919050565b60007f30644e72e131a029b85045b68181585d2833e84879b9709143e1f593f00000017f09c46e9ec68e9bd4fe1faaba294cba38a71aa177534cdd1b6c7dc0dbd0abd7a77f0c0356530896eec42a97ed937f3135cfc5142b3ae405b8343c1d83ffa604cb81840182828309838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1e28a1d935698ad1142e51182bb54cf4a00ea5aabd6268bd317ea977cc154a30830192507f27af2d831a9d2748080965db30e298e40e5757c3e008db964cf9e2b12b91251f82019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1e6f11ce60fc8f513a6a3cfe16ae175a41291462f214cd0879aaf43545b74e03830192507f2a67384d3bbd5e438541819cb681f0be04462ed14c3613d8f719206268d142d382019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0b66fdf356093a611609f8e12fbfecf0b985e381f025188936408f5d5c9f45d0830192507f012ee3ec1e78d470830c61093c2ade370b26c83cc5cebeeddaa6852dbdb09e2182019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0252ba5f6760bfbdfd88f67f8175e3fd6cd1c431b099b6bb2d108e7b445bb1b9830192507f179474cceca5ff676c6bec3cef54296354391a8935ff71d6ef5aeaad7ca932f182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2c24261379a51bfa9228ff4a503fd4ed9c1f974a264969b37e1a2589bbed2b91830192507f1cc1d7b62692e63eac2f288bd0695b43c2f63f5001fc0fc553e66c0551801b0582019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f255059301aada98bb2ed55f852979e9600784dbf17fbacd05d9eff5fd9c91b56830192507f28437be3ac1cb2e479e1f5c0eccd32b3aea24234970a8193b11c29ce7e59efd982019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f28216a442f2e1f711ca4fa6b53766eb118548da8fb4f78d4338762c37f5f2043830192507f2c1f47cd17fa5adf1f39f4e7056dd03feee1efce03094581131f2377323482c982019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f07abad02b7a5ebc48632bcc9356ceb7dd9dafca276638a63646b8566a621afc9830192507f0230264601ffdf29275b33ffaab51dfe9429f90880a69cd137da0c4d15f96c3c82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1bc973054e51d905a0f168656497ca40a864414557ee289e717e5d66899aa0a9830192507f2e1c22f964435008206c3157e86341edd249aff5c2d8421f2a6b22288f0a67fc82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1224f38df67c5378121c1d5f461bbc509e8ea1598e46c9f7a70452bc2bba86b8830192507f02e4e69d8ba59e519280b4bd9ed0068fd7bfe8cd9dfeda1969d2989186cde20e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1f1eccc34aaba0137f5df81fc04ff3ee4f19ee364e653f076d47e9735d98018e830192507f1672ad3d709a353974266c3039a9a7311424448032cd1819eacb8a4d4284f58282019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f283e3fdc2c6e420c56f44af5192b4ae9cda6961f284d24991d2ed602df8c8fc7830192507f1c2a3d120c550ecfd0db0957170fa013683751f8fdff59d6614fbd69ff394bcc82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f216f84877aac6172f7897a7323456efe143a9a43773ea6f296cb6b8177653fbd830192507f2c0d272becf2a75764ba7e8e3e28d12bceaa47ea61ca59a411a1f51552f9478882019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f16e34299865c0e28484ee7a74c454e9f170a5480abe0508fcb4a6c3d89546f43830192507f175ceba599e96f5b375a232a6fb9cc71772047765802290f48cd939755488fc582019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0c7594440dc48c16fead9e1758b028066aa410bfbc354f54d8c5ffbb44a1ee32830192507f1a3c29bc39f21bb5c466db7d7eb6fd8f760e20013ccf912c92479882d919fd8d82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0ccfdd906f3426e5c0986ea049b253400855d349074f5a6695c8eeabcd22e68f830192507f14f6bc81d9f186f62bdb475ce6c9411866a7a8a3fd065b3ce0e699b67dd9e79682019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0962b82789fb3d129702ca70b2f6c5aacc099810c9c495c888edeb7386b97052830192507f1a880af7074d18b3bf20c79de25127bc13284ab01ef02575afef0c8f6a31a86d82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f10cba18419a6a332cd5e77f0211c154b20af2924fc20ff3f4c3012bb7ae9311b830192507f057e62a9a8f89b3ebdc76ba63a9eaca8fa27b7319cae3406756a2849f302f10d82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f287c971de91dc0abd44adf5384b4988cb961303bbf65cff5afa0413b44280cee830192507f21df3388af1687bbb3bca9da0cca908f1e562bc46d4aba4e6f7f7960e306891d82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1be5c887d25bce703e25cc974d0934cd789df8f70b498fd83eff8b560e1682b3830192507f268da36f76e568fb68117175cea2cd0dd2cb5d42fda5acea48d59c2706a0d5c182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0e17ab091f6eae50c609beaf5510ececc5d8bb74135ebd05bd06460cc26a5ed6830192507f04d727e728ffa0a67aee535ab074a43091ef62d8cf83d270040f5caa1f62af4082019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0ddbd7bf9c29341581b549762bc022ed33702ac10f1bfd862b15417d7e39ca6e830192507f2790eb3351621752768162e82989c6c234f5b0d1d3af9b588a29c49c8789654b82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1e457c601a63b73e4471950193d8a570395f3d9ab8b2fd0984b764206142f9e9830192507f21ae64301dca9625638d6ab2bbe7135ffa90ecd0c43ff91fc4c686fc46e091b082019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0379f63c8ce3468d4da293166f494928854be9e3432e09555858534eed8d350b830192507e2d56420359d0266a744a080809e054ca0e4921a46686ac8c9f58a324c3504982019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f123158e5965b5d9b1d68b3cd32e10bbeda8d62459e21f4090fc2c5af963515a6830192507f0be29fc40847a941661d14bbf6cbe0420fbb2b6f52836d4e60c80eb49cad9ec182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1ac96991dec2bb0557716142015a453c36db9d859cad5f9a233802f24fdf4c1a830192507f1596443f763dbcc25f4964fc61d23b3e5e12c9fa97f18a9251ca3355bcb0627e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f12e0bcd3654bdfa76b2861d4ec3aeae0f1857d9f17e715aed6d049eae3ba3212830192507f0fc92b4f1bbea82b9ea73d4af9af2a50ceabac7f37154b1904e6c76c7cf964ba82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1f9c0b1610446442d6f2e592a8013f40b14f7c7722236f4f9c7e965233872762830192507f0ebd74244ae72675f8cde06157a782f4050d914da38b4c058d159f643dbbf4d382019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2cb7f0ed39e16e9f69a9fafd4ab951c03b0671e97346ee397a839839dccfc6d1830192507f1a9d6e2ecff022cc5605443ee41bab20ce761d0514ce526690c72bca7352d9bf82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2a115439607f335a5ea83c3bc44a9331d0c13326a9a7ba3087da182d648ec72f830192507f23f9b6529b5d040d15b8fa7aee3e3410e738b56305cd44f29535c115c5a4c06082019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f05872c16db0f72a2249ac6ba484bb9c3a3ce97c16d58b68b260eb939f0e6e8a7830192507f1300bdee08bb7824ca20fb80118075f40219b6151d55b5c52b624a7cdeddf6a782019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f19b9b63d2f108e17e63817863a8f6c288d7ad29916d98cb1072e4e7b7d52b376830192507f015bee1357e3c015b5bda237668522f613d1c88726b5ec4224a20128481b4f7f82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2953736e94bb6b9f1b9707a4f1615e4efe1e1ce4bab218cbea92c785b128ffd1830192507f0b069353ba091618862f806180c0385f851b98d372b45f544ce7266ed6608dfc82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f304f74d461ccc13115e4e0bcfb93817e55aeb7eb9306b64e4f588ac97d81f429830192507f15bbf146ce9bca09e8a33f5e77dfe4f5aad2a164a4617a4cb8ee5415cde913fc82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0ab4dfe0c2742cde44901031487964ed9b8f4b850405c10ca9ff23859572c8c6830192507f0e32db320a044e3197f45f7649a19675ef5eedfea546dea9251de39f9639779a82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0a1756aa1f378ca4b27635a78b6888e66797733a82774896a3078efa516da016830192507f044c4a33b10f693447fd17177f952ef895e61d328f85efa94254d6a2a25d93ef82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2ed3611b725b8a70be655b537f66f700fe0879d79a496891d37b07b5466c4b8b830192507f1f9ba4e8bab7ce42c8ecc3d722aa2e0eadfdeb9cfdd347b5d8339ea7120858aa82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1b233043052e8c288f7ee907a84e518aa38e82ac4502066db74056f865c5d3da830192507f2431e1cc164bb8d074031ab72bd55b4c902053bfc0f14db0ca2f97b02087595482019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f082f934c91f5aac330cd6953a0a7db45a13e322097583319a791f273965801fd830192507f2b9a0a223e7538b0a34be074315542a3c77245e2ae7cbe999ad6bb930c48997c82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0e1cd91edd2cfa2cceb85483b887a9be8164163e75a8a00eb0b589cc70214e7d830192507f2e1eac0f2bfdfd63c951f61477e3698999774f19854d00f588d324601cebe2f982019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0cbfa95f37fb74060c76158e769d6d157345784d8efdb33c23d748115b500b83830192507f08f05b3be923ed44d65ad49d8a61e9a676d991e3a77513d9980c232dfa4a4f8482019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f22719e2a070bcd0852bf8e21984d0443e7284925dc0758a325a2dd510c047ef6830192507f041f596a9ee1cb2bc060f7fcc3a1ab4c7bdbf036119982c0f41f62b2f26830c082019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f233fd35de1be520a87628eb06f6b1d4c021be1c2d0dc464a19fcdd0986b10f89830192507f0524b46d1aa87a5e4325e0a423ebc810d31e078aa1b4707eefcb453c61c9c26782019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2c34f424c81e5716ce47fcac894b85824227bb954b0f3199cc4486237c515211830192507f0b5f2a4b63387819207effc2b5541fb72dd2025b5457cc97f33010327de4915e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f22207856082ccc54c5b72fe439d2cfd6c17435d2f57af6ceaefac41fe05c659f830192507f24d57a8bf5da63fe4e24159b7f8950b5cdfb210194caf79f27854048ce2c817182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0afab181fdd5e0583b371d75bd693f98374ad7097bb01a8573919bb23b79396e830192507f2dba9b108f208772998a52efac7cbd5676c0057194c16c0bf16290d62b1128ee82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f26349b66edb8b16f56f881c788f53f83cbb83de0bd592b255aff13e6bce420b3830192507f25af7ce0e5e10357685e95f92339753ad81a56d28ecc193b235288a3e6f137db82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f25b4ce7bd2294390c094d6a55edd68b970eed7aae88b2bff1f7c0187fe35011f830192507f22c543f10f6c89ec387e53f1908a88e5de9cef28ebdf30b18cb9d54c1e02b63182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0236f93e7789c4724fc7908a9f191e1e425e906a919d7a34df668e74882f87a9830192507f29350b401166ca010e7d27e37d05da99652bdae114eb01659cb497af980c4b5282019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0eed787d65820d3f6bd31bbab547f75a65edb75d844ebb89ee1260916652363f830192507f07cc1170f13b46f2036a753f520b3291fdcd0e99bd94297d1906f656f4de6fad82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f22b939233b1d7205f49bcf613a3d30b1908786d7f9f5d10c2059435689e8acea830192507f01451762a0aab81c8aad1dc8bc33e870740f083a5aa85438add650ace60ae5a682019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f23506bb5d8727d4461fabf1025d46d1fe32eaa61dec7da57e704fec0892fce89830192507f2e484c44e838aea0bac06ae3f71bdd092a3709531e1efea97f8bd6890735552282019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0f4bc7d07ebafd64379e78c50bd2e42baf4a594545cedc2545418da26835b54c830192507f1f4d3c8f6583e9e5fa76637862faaee851582388725df460e620996d50d8e74e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f093514e0c70711f82660d07be0e4a988fae02abc7b681d9153eb9bcb48fe7389830192507f1adab0c8e2b3bad346699a2b5f3bc03643ee83ece47228f24a58e0a347e153d882019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1672b1726057d99dd14709ebb474641a378c1b94b8072bac1a22dbef9e80dad2830192507f1dfd53d4576af2e38f44f53fdcab468cc5d8e2fae0acc4ee30d47b239b479c1482019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0c6888a10b75b0f3a70a36263a37e17fe6d77d640f6fc3debc7f207753205c60830192507f1addb933a65be77092b34a7e77d12fe8611a61e00ee6848b85091ecca9d1e50882019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507ed7540dcd268a845c10ae18d1de933cf638ff5425f0afff7935628e299d1791830192507f140c0e42687e9ead01b2827a5664ca9c26fedde4acd99db1d316939d20b82c0e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2f0c3a115d4317d191ba89b8d13d1806c20a0f9b24f8c5edc091e2ae56565984830192507f0c4ee778ff7c14553006ed220cf9c81008a0cff670b22b82d8c538a1dc958c6182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1704f2766d46f82c3693f00440ccc3609424ed26c0acc66227c3d7485de74c69830192507f2f2d19cc3ea5d78ea7a02c1b51d244abf0769c9f8544e40239b66fe9009c3cfa82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1ae03853b75fcaba5053f112e2a8e8dcdd7ee6cb9cfed9c7d6c766a806fc6629830192507f0971aabf795241df51d131d0fa61aa5f3556921b2d6f014e4e41a86ddaf056d582019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1408c316e6014e1a91d4cf6b6e0de73eda624f8380df1c875f5c29f7bfe2f646830192507f1667f3fe2edbe850248abe42b543093b6c89f1f773ef285341691f39822ef5bd82019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f13bf7c5d0d2c4376a48b0a03557cdf915b81718409e5c133424c69576500fe37830192507f07620a6dfb0b6cec3016adf3d3533c24024b95347856b79719bc0ba743a62c2c82019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1574c7ef0c43545f36a8ca08bdbdd8b075d2959e2f322b731675de3e1982b4d0830192507f269e4b5b7a2eb21afd567970a717ceec5bd4184571c254fdc06e03a7ff8378f08201915083838409905083838583840909925083828309905083828583840909915083847f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88409857f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad586090106925082945050505050919050565b600080fd5b6000819050919050565b613d5b81613d48565b8114613d6657600080fd5b50565b600081359050613d7881613d52565b92915050565b600060208284031215613d9457613d93613d43565b5b6000613da284828501613d69565b91505092915050565b613db481613d48565b82525050565b6000602082019050613dcf6000830184613dab565b9291505056fea26469706673582212203d18c927061837bdb4f1a2ec6136959ba8b89f7bfc14d06d40fe24096592b8ec64736f6c634300080f0033", + ABI: "[{\"inputs\":[],\"name\":\"Q\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"input\",\"type\":\"uint256\"}],\"name\":\"hash\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"result\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50613e58806100206000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c8063b189fd4c1461003b578063e493ef8c1461006b575b600080fd5b61005560048036038101906100509190613dcb565b610089565b6040516100629190613e07565b60405180910390f35b61007361009b565b6040516100809190613e07565b60405180910390f35b6000610094826100bf565b9050919050565b7f30644e72e131a029b85045b68181585d2833e84879b9709143e1f593f000000181565b60007f30644e72e131a029b85045b68181585d2833e84879b9709143e1f593f00000017f09c46e9ec68e9bd4fe1faaba294cba38a71aa177534cdd1b6c7dc0dbd0abd7a77f0c0356530896eec42a97ed937f3135cfc5142b3ae405b8343c1d83ffa604cb81840182828309838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1e28a1d935698ad1142e51182bb54cf4a00ea5aabd6268bd317ea977cc154a30830192507f27af2d831a9d2748080965db30e298e40e5757c3e008db964cf9e2b12b91251f82019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1e6f11ce60fc8f513a6a3cfe16ae175a41291462f214cd0879aaf43545b74e03830192507f2a67384d3bbd5e438541819cb681f0be04462ed14c3613d8f719206268d142d382019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0b66fdf356093a611609f8e12fbfecf0b985e381f025188936408f5d5c9f45d0830192507f012ee3ec1e78d470830c61093c2ade370b26c83cc5cebeeddaa6852dbdb09e2182019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0252ba5f6760bfbdfd88f67f8175e3fd6cd1c431b099b6bb2d108e7b445bb1b9830192507f179474cceca5ff676c6bec3cef54296354391a8935ff71d6ef5aeaad7ca932f182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2c24261379a51bfa9228ff4a503fd4ed9c1f974a264969b37e1a2589bbed2b91830192507f1cc1d7b62692e63eac2f288bd0695b43c2f63f5001fc0fc553e66c0551801b0582019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f255059301aada98bb2ed55f852979e9600784dbf17fbacd05d9eff5fd9c91b56830192507f28437be3ac1cb2e479e1f5c0eccd32b3aea24234970a8193b11c29ce7e59efd982019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f28216a442f2e1f711ca4fa6b53766eb118548da8fb4f78d4338762c37f5f2043830192507f2c1f47cd17fa5adf1f39f4e7056dd03feee1efce03094581131f2377323482c982019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f07abad02b7a5ebc48632bcc9356ceb7dd9dafca276638a63646b8566a621afc9830192507f0230264601ffdf29275b33ffaab51dfe9429f90880a69cd137da0c4d15f96c3c82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1bc973054e51d905a0f168656497ca40a864414557ee289e717e5d66899aa0a9830192507f2e1c22f964435008206c3157e86341edd249aff5c2d8421f2a6b22288f0a67fc82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1224f38df67c5378121c1d5f461bbc509e8ea1598e46c9f7a70452bc2bba86b8830192507f02e4e69d8ba59e519280b4bd9ed0068fd7bfe8cd9dfeda1969d2989186cde20e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1f1eccc34aaba0137f5df81fc04ff3ee4f19ee364e653f076d47e9735d98018e830192507f1672ad3d709a353974266c3039a9a7311424448032cd1819eacb8a4d4284f58282019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f283e3fdc2c6e420c56f44af5192b4ae9cda6961f284d24991d2ed602df8c8fc7830192507f1c2a3d120c550ecfd0db0957170fa013683751f8fdff59d6614fbd69ff394bcc82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f216f84877aac6172f7897a7323456efe143a9a43773ea6f296cb6b8177653fbd830192507f2c0d272becf2a75764ba7e8e3e28d12bceaa47ea61ca59a411a1f51552f9478882019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f16e34299865c0e28484ee7a74c454e9f170a5480abe0508fcb4a6c3d89546f43830192507f175ceba599e96f5b375a232a6fb9cc71772047765802290f48cd939755488fc582019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0c7594440dc48c16fead9e1758b028066aa410bfbc354f54d8c5ffbb44a1ee32830192507f1a3c29bc39f21bb5c466db7d7eb6fd8f760e20013ccf912c92479882d919fd8d82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0ccfdd906f3426e5c0986ea049b253400855d349074f5a6695c8eeabcd22e68f830192507f14f6bc81d9f186f62bdb475ce6c9411866a7a8a3fd065b3ce0e699b67dd9e79682019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0962b82789fb3d129702ca70b2f6c5aacc099810c9c495c888edeb7386b97052830192507f1a880af7074d18b3bf20c79de25127bc13284ab01ef02575afef0c8f6a31a86d82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f10cba18419a6a332cd5e77f0211c154b20af2924fc20ff3f4c3012bb7ae9311b830192507f057e62a9a8f89b3ebdc76ba63a9eaca8fa27b7319cae3406756a2849f302f10d82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f287c971de91dc0abd44adf5384b4988cb961303bbf65cff5afa0413b44280cee830192507f21df3388af1687bbb3bca9da0cca908f1e562bc46d4aba4e6f7f7960e306891d82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1be5c887d25bce703e25cc974d0934cd789df8f70b498fd83eff8b560e1682b3830192507f268da36f76e568fb68117175cea2cd0dd2cb5d42fda5acea48d59c2706a0d5c182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0e17ab091f6eae50c609beaf5510ececc5d8bb74135ebd05bd06460cc26a5ed6830192507f04d727e728ffa0a67aee535ab074a43091ef62d8cf83d270040f5caa1f62af4082019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0ddbd7bf9c29341581b549762bc022ed33702ac10f1bfd862b15417d7e39ca6e830192507f2790eb3351621752768162e82989c6c234f5b0d1d3af9b588a29c49c8789654b82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1e457c601a63b73e4471950193d8a570395f3d9ab8b2fd0984b764206142f9e9830192507f21ae64301dca9625638d6ab2bbe7135ffa90ecd0c43ff91fc4c686fc46e091b082019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0379f63c8ce3468d4da293166f494928854be9e3432e09555858534eed8d350b830192507e2d56420359d0266a744a080809e054ca0e4921a46686ac8c9f58a324c3504982019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f123158e5965b5d9b1d68b3cd32e10bbeda8d62459e21f4090fc2c5af963515a6830192507f0be29fc40847a941661d14bbf6cbe0420fbb2b6f52836d4e60c80eb49cad9ec182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1ac96991dec2bb0557716142015a453c36db9d859cad5f9a233802f24fdf4c1a830192507f1596443f763dbcc25f4964fc61d23b3e5e12c9fa97f18a9251ca3355bcb0627e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f12e0bcd3654bdfa76b2861d4ec3aeae0f1857d9f17e715aed6d049eae3ba3212830192507f0fc92b4f1bbea82b9ea73d4af9af2a50ceabac7f37154b1904e6c76c7cf964ba82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1f9c0b1610446442d6f2e592a8013f40b14f7c7722236f4f9c7e965233872762830192507f0ebd74244ae72675f8cde06157a782f4050d914da38b4c058d159f643dbbf4d382019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2cb7f0ed39e16e9f69a9fafd4ab951c03b0671e97346ee397a839839dccfc6d1830192507f1a9d6e2ecff022cc5605443ee41bab20ce761d0514ce526690c72bca7352d9bf82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2a115439607f335a5ea83c3bc44a9331d0c13326a9a7ba3087da182d648ec72f830192507f23f9b6529b5d040d15b8fa7aee3e3410e738b56305cd44f29535c115c5a4c06082019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f05872c16db0f72a2249ac6ba484bb9c3a3ce97c16d58b68b260eb939f0e6e8a7830192507f1300bdee08bb7824ca20fb80118075f40219b6151d55b5c52b624a7cdeddf6a782019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f19b9b63d2f108e17e63817863a8f6c288d7ad29916d98cb1072e4e7b7d52b376830192507f015bee1357e3c015b5bda237668522f613d1c88726b5ec4224a20128481b4f7f82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2953736e94bb6b9f1b9707a4f1615e4efe1e1ce4bab218cbea92c785b128ffd1830192507f0b069353ba091618862f806180c0385f851b98d372b45f544ce7266ed6608dfc82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f304f74d461ccc13115e4e0bcfb93817e55aeb7eb9306b64e4f588ac97d81f429830192507f15bbf146ce9bca09e8a33f5e77dfe4f5aad2a164a4617a4cb8ee5415cde913fc82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0ab4dfe0c2742cde44901031487964ed9b8f4b850405c10ca9ff23859572c8c6830192507f0e32db320a044e3197f45f7649a19675ef5eedfea546dea9251de39f9639779a82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0a1756aa1f378ca4b27635a78b6888e66797733a82774896a3078efa516da016830192507f044c4a33b10f693447fd17177f952ef895e61d328f85efa94254d6a2a25d93ef82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2ed3611b725b8a70be655b537f66f700fe0879d79a496891d37b07b5466c4b8b830192507f1f9ba4e8bab7ce42c8ecc3d722aa2e0eadfdeb9cfdd347b5d8339ea7120858aa82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1b233043052e8c288f7ee907a84e518aa38e82ac4502066db74056f865c5d3da830192507f2431e1cc164bb8d074031ab72bd55b4c902053bfc0f14db0ca2f97b02087595482019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f082f934c91f5aac330cd6953a0a7db45a13e322097583319a791f273965801fd830192507f2b9a0a223e7538b0a34be074315542a3c77245e2ae7cbe999ad6bb930c48997c82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0e1cd91edd2cfa2cceb85483b887a9be8164163e75a8a00eb0b589cc70214e7d830192507f2e1eac0f2bfdfd63c951f61477e3698999774f19854d00f588d324601cebe2f982019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0cbfa95f37fb74060c76158e769d6d157345784d8efdb33c23d748115b500b83830192507f08f05b3be923ed44d65ad49d8a61e9a676d991e3a77513d9980c232dfa4a4f8482019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f22719e2a070bcd0852bf8e21984d0443e7284925dc0758a325a2dd510c047ef6830192507f041f596a9ee1cb2bc060f7fcc3a1ab4c7bdbf036119982c0f41f62b2f26830c082019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f233fd35de1be520a87628eb06f6b1d4c021be1c2d0dc464a19fcdd0986b10f89830192507f0524b46d1aa87a5e4325e0a423ebc810d31e078aa1b4707eefcb453c61c9c26782019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2c34f424c81e5716ce47fcac894b85824227bb954b0f3199cc4486237c515211830192507f0b5f2a4b63387819207effc2b5541fb72dd2025b5457cc97f33010327de4915e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f22207856082ccc54c5b72fe439d2cfd6c17435d2f57af6ceaefac41fe05c659f830192507f24d57a8bf5da63fe4e24159b7f8950b5cdfb210194caf79f27854048ce2c817182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0afab181fdd5e0583b371d75bd693f98374ad7097bb01a8573919bb23b79396e830192507f2dba9b108f208772998a52efac7cbd5676c0057194c16c0bf16290d62b1128ee82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f26349b66edb8b16f56f881c788f53f83cbb83de0bd592b255aff13e6bce420b3830192507f25af7ce0e5e10357685e95f92339753ad81a56d28ecc193b235288a3e6f137db82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f25b4ce7bd2294390c094d6a55edd68b970eed7aae88b2bff1f7c0187fe35011f830192507f22c543f10f6c89ec387e53f1908a88e5de9cef28ebdf30b18cb9d54c1e02b63182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0236f93e7789c4724fc7908a9f191e1e425e906a919d7a34df668e74882f87a9830192507f29350b401166ca010e7d27e37d05da99652bdae114eb01659cb497af980c4b5282019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0eed787d65820d3f6bd31bbab547f75a65edb75d844ebb89ee1260916652363f830192507f07cc1170f13b46f2036a753f520b3291fdcd0e99bd94297d1906f656f4de6fad82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f22b939233b1d7205f49bcf613a3d30b1908786d7f9f5d10c2059435689e8acea830192507f01451762a0aab81c8aad1dc8bc33e870740f083a5aa85438add650ace60ae5a682019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f23506bb5d8727d4461fabf1025d46d1fe32eaa61dec7da57e704fec0892fce89830192507f2e484c44e838aea0bac06ae3f71bdd092a3709531e1efea97f8bd6890735552282019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0f4bc7d07ebafd64379e78c50bd2e42baf4a594545cedc2545418da26835b54c830192507f1f4d3c8f6583e9e5fa76637862faaee851582388725df460e620996d50d8e74e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f093514e0c70711f82660d07be0e4a988fae02abc7b681d9153eb9bcb48fe7389830192507f1adab0c8e2b3bad346699a2b5f3bc03643ee83ece47228f24a58e0a347e153d882019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1672b1726057d99dd14709ebb474641a378c1b94b8072bac1a22dbef9e80dad2830192507f1dfd53d4576af2e38f44f53fdcab468cc5d8e2fae0acc4ee30d47b239b479c1482019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f0c6888a10b75b0f3a70a36263a37e17fe6d77d640f6fc3debc7f207753205c60830192507f1addb933a65be77092b34a7e77d12fe8611a61e00ee6848b85091ecca9d1e50882019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507ed7540dcd268a845c10ae18d1de933cf638ff5425f0afff7935628e299d1791830192507f140c0e42687e9ead01b2827a5664ca9c26fedde4acd99db1d316939d20b82c0e82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f2f0c3a115d4317d191ba89b8d13d1806c20a0f9b24f8c5edc091e2ae56565984830192507f0c4ee778ff7c14553006ed220cf9c81008a0cff670b22b82d8c538a1dc958c6182019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1704f2766d46f82c3693f00440ccc3609424ed26c0acc66227c3d7485de74c69830192507f2f2d19cc3ea5d78ea7a02c1b51d244abf0769c9f8544e40239b66fe9009c3cfa82019150838384099050838385838409099250837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1ae03853b75fcaba5053f112e2a8e8dcdd7ee6cb9cfed9c7d6c766a806fc6629830192507f0971aabf795241df51d131d0fa61aa5f3556921b2d6f014e4e41a86ddaf056d582019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1408c316e6014e1a91d4cf6b6e0de73eda624f8380df1c875f5c29f7bfe2f646830192507f1667f3fe2edbe850248abe42b543093b6c89f1f773ef285341691f39822ef5bd82019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f13bf7c5d0d2c4376a48b0a03557cdf915b81718409e5c133424c69576500fe37830192507f07620a6dfb0b6cec3016adf3d3533c24024b95347856b79719bc0ba743a62c2c82019150838384099050838385838409099250838283099050838285838409099150837f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88309847f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad58509019050837f1274e649a32ed355a31a6ed69724e1adade857e86eb5c3a121bcd147943203c88309847f0cc57cdbb08507d62bf67a4493cc262fb6c09d557013fff1f573f431221f8ff985090191508092507f1574c7ef0c43545f36a8ca08bdbdd8b075d2959e2f322b731675de3e1982b4d0830192507f269e4b5b7a2eb21afd567970a717ceec5bd4184571c254fdc06e03a7ff8378f08201915083838409905083838583840909925083828309905083828583840909915083847f2b9d4b4110c9ae997782e1509b1d0fdb20a7c02bbd8bea7305462b9f8125b1e88409857f066f6f85d6f68a85ec10345351a23a3aaf07f38af8c952a7bceca70bd2af7ad586090106925082945050505050919050565b600080fd5b6000819050919050565b613da881613d95565b8114613db357600080fd5b50565b600081359050613dc581613d9f565b92915050565b600060208284031215613de157613de0613d90565b5b6000613def84828501613db6565b91505092915050565b613e0181613d95565b82525050565b6000602082019050613e1c6000830184613df8565b9291505056fea2646970667358221220d8b907b02354ff280e53b5ea28cac49c22e678d7444e97927780ec9c8d72dcb464736f6c634300080f0033", } // PoseidonHasherABI is the input ABI used to generate the binding from. @@ -202,6 +202,37 @@ func (_PoseidonHasher *PoseidonHasherTransactorRaw) Transact(opts *bind.Transact return _PoseidonHasher.Contract.contract.Transact(opts, method, params...) } +// Q is a free data retrieval call binding the contract method 0xe493ef8c. +// +// Solidity: function Q() view returns(uint256) +func (_PoseidonHasher *PoseidonHasherCaller) Q(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _PoseidonHasher.contract.Call(opts, &out, "Q") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +// Q is a free data retrieval call binding the contract method 0xe493ef8c. +// +// Solidity: function Q() view returns(uint256) +func (_PoseidonHasher *PoseidonHasherSession) Q() (*big.Int, error) { + return _PoseidonHasher.Contract.Q(&_PoseidonHasher.CallOpts) +} + +// Q is a free data retrieval call binding the contract method 0xe493ef8c. +// +// Solidity: function Q() view returns(uint256) +func (_PoseidonHasher *PoseidonHasherCallerSession) Q() (*big.Int, error) { + return _PoseidonHasher.Contract.Q(&_PoseidonHasher.CallOpts) +} + // Hash is a free data retrieval call binding the contract method 0xb189fd4c. // // Solidity: function hash(uint256 input) pure returns(uint256 result) diff --git a/waku/v2/protocol/rln/contracts/registry.go b/waku/v2/protocol/rln/contracts/registry.go new file mode 100644 index 00000000..45772f7e --- /dev/null +++ b/waku/v2/protocol/rln/contracts/registry.go @@ -0,0 +1,814 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package contracts + +import ( + "errors" + "math/big" + "strings" + + ethereum "github.com/ethereum/go-ethereum" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/event" +) + +// Reference imports to suppress errors if they are not otherwise used. +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +// RLNRegistryMetaData contains all meta data concerning the RLNRegistry contract. +var RLNRegistryMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_poseidonHasher\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"IncompatibleStorage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncompatibleStorageIndex\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoStorageContractAvailable\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"storageAddress\",\"type\":\"address\"}],\"name\":\"StorageAlreadyExists\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"index\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"storageAddress\",\"type\":\"address\"}],\"name\":\"NewStorageContract\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"forceProgress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"newStorage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nextStorageIndex\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"poseidonHasher\",\"outputs\":[{\"internalType\":\"contractIPoseidonHasher\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"storageIndex\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"commitment\",\"type\":\"uint256\"}],\"name\":\"register\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"commitments\",\"type\":\"uint256[]\"}],\"name\":\"register\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"storageIndex\",\"type\":\"uint16\"},{\"internalType\":\"uint256[]\",\"name\":\"commitments\",\"type\":\"uint256[]\"}],\"name\":\"register\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"storageAddress\",\"type\":\"address\"}],\"name\":\"registerStorage\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"name\":\"storages\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"usingStorageIndex\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x60a06040526000600260006101000a81548161ffff021916908361ffff1602179055503480156200002f57600080fd5b5060405162002ec138038062002ec18339818101604052810190620000559190620001e6565b6200007562000069620000b060201b60201c565b620000b860201b60201c565b8073ffffffffffffffffffffffffffffffffffffffff1660808173ffffffffffffffffffffffffffffffffffffffff16815250505062000218565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000620001ae8262000181565b9050919050565b620001c081620001a1565b8114620001cc57600080fd5b50565b600081519050620001e081620001b5565b92915050565b600060208284031215620001ff57620001fe6200017c565b5b60006200020f84828501620001cf565b91505092915050565b608051612c7f62000242600039600081816103e2015281816104120152610ad80152612c7f6000f3fe60806040523480156200001157600080fd5b5060043610620000e25760003560e01c8063ab02492a1162000099578063ef653d5e116200006f578063ef653d5e14620001d1578063f184ef4c14620001f1578063f2fde38b1462000213578063f5542147146200023357620000e2565b8063ab02492a1462000183578063cf61637414620001a3578063d44fda1f14620001c557620000e2565b806326e0fc1f14620000e7578063331b6ab3146200010757806342f542e21462000129578063715018a614620001355780637a34289d14620001415780638da5cb5b1462000161575b600080fd5b620001056004803603810190620000ff919062001045565b62000269565b005b62000111620003e0565b60405162000120919062001117565b60405180910390f35b6200013362000404565b005b6200013f6200048b565b005b6200015f6004803603810190620001599190620011a2565b620004a3565b005b6200016b6200075f565b6040516200017a91906200121c565b60405180910390f35b620001a160048036038101906200019b919062001239565b62000788565b005b620001ad6200088b565b604051620001bc9190620012b4565b60405180910390f35b620001cf6200089f565b005b620001ef6004803603810190620001e9919062001302565b62000a09565b005b620001fb62000c9e565b6040516200020a9190620012b4565b60405180910390f35b6200023160048036038101906200022b919062001302565b62000cb2565b005b6200025160048036038101906200024b919062001334565b62000d3c565b6040516200026091906200121c565b60405180910390f35b600060149054906101000a900461ffff1661ffff168261ffff1610620002bb576040517fd23276a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600167ffffffffffffffff811115620002db57620002da62001366565b5b6040519080825280602002602001820160405280156200030a5781602001602082028036833780820191505090505b509050818160008151811062000325576200032462001395565b5b602002602001018181525050600160008461ffff1661ffff16815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637a34289d826040518263ffffffff1660e01b8152600401620003a7919062001492565b600060405180830381600087803b158015620003c257600080fd5b505af1158015620003d7573d6000803e3d6000fd5b50505050505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b6200040e62000d6f565b60007f0000000000000000000000000000000000000000000000000000000000000000600060149054906101000a900461ffff16604051620004509062000fb3565b6200045d929190620014b6565b604051809103906000f0801580156200047a573d6000803e3d6000fd5b509050620004888162000df4565b50565b6200049562000d6f565b620004a1600062000ee7565b565b600060149054906101000a900461ffff1661ffff16600260009054906101000a900461ffff1661ffff161062000505576040517fd23276a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b6001156200075b5760016000600260009054906101000a900461ffff1661ffff1661ffff16815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637a34289d83836040518363ffffffff1660e01b8152600401620005969291906200155a565b600060405180830381600087803b158015620005b157600080fd5b505af1925050508015620005c3575060015b6200074f573d8060008114620005f6576040519150601f19603f3d011682016040523d82523d6000602084013e620005fb565b606091505b506040516024016040516020818303038152906040527f57f69531000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050805190602001208180519060200120146200069c57805181602001fd5b600060149054906101000a900461ffff1661ffff166001600260009054906101000a900461ffff16620006d09190620015af565b61ffff16106200070c576040517fd23276a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600260008282829054906101000a900461ffff166200072e9190620015af565b92506101000a81548161ffff021916908361ffff1602179055505062000755565b6200075b565b62000506565b5050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b600060149054906101000a900461ffff1661ffff168361ffff1610620007da576040517fd23276a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160008461ffff1661ffff16815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637a34289d83836040518363ffffffff1660e01b8152600401620008529291906200155a565b600060405180830381600087803b1580156200086d57600080fd5b505af115801562000882573d6000803e3d6000fd5b50505050505050565b600260009054906101000a900461ffff1681565b620008a962000d6f565b600060149054906101000a900461ffff1661ffff16600260009054906101000a900461ffff1661ffff16106200090b576040517fd23276a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff16600160006001600260009054906101000a900461ffff16620009469190620015af565b61ffff1661ffff16815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1603620009cb576040517fd23276a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600260008282829054906101000a900461ffff16620009ed9190620015af565b92506101000a81548161ffff021916908361ffff160217905550565b62000a1362000d6f565b600073ffffffffffffffffffffffffffffffffffffffff16600160008060149054906101000a900461ffff1661ffff1661ffff16815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161462000ad157806040517f9cfabd1600000000000000000000000000000000000000000000000000000000815260040162000ac891906200121c565b60405180910390fd5b60008190507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1663331b6ab36040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000b59573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000b7f919062001633565b73ffffffffffffffffffffffffffffffffffffffff161462000bcc576040517eaec95400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060149054906101000a900461ffff1661ffff168173ffffffffffffffffffffffffffffffffffffffff166328b070e06040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000c2d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000c5391906200167c565b61ffff161462000c8f576040517fb893b72300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b62000c9a8262000df4565b5050565b600060149054906101000a900461ffff1681565b62000cbc62000d6f565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff160362000d2e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000d259062001735565b60405180910390fd5b62000d398162000ee7565b50565b60016020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b62000d7962000fab565b73ffffffffffffffffffffffffffffffffffffffff1662000d996200075f565b73ffffffffffffffffffffffffffffffffffffffff161462000df2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000de990620017a7565b60405180910390fd5b565b80600160008060149054906101000a900461ffff1661ffff1661ffff16815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055507fcf6a3b406170499209d0fcf152a1605c7c5a5c99c855e2bb803433fc960718eb600060149054906101000a900461ffff168260405162000ea0929190620017c9565b60405180910390a16001600060148282829054906101000a900461ffff1662000eca9190620015af565b92506101000a81548161ffff021916908361ffff16021790555050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600033905090565b61145380620017f783390190565b600080fd5b600080fd5b600061ffff82169050919050565b62000fe48162000fcb565b811462000ff057600080fd5b50565b600081359050620010048162000fd9565b92915050565b6000819050919050565b6200101f816200100a565b81146200102b57600080fd5b50565b6000813590506200103f8162001014565b92915050565b600080604083850312156200105f576200105e62000fc1565b5b60006200106f8582860162000ff3565b925050602062001082858286016200102e565b9150509250929050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b6000620010d7620010d1620010cb846200108c565b620010ac565b6200108c565b9050919050565b6000620010eb82620010b6565b9050919050565b6000620010ff82620010de565b9050919050565b6200111181620010f2565b82525050565b60006020820190506200112e600083018462001106565b92915050565b600080fd5b600080fd5b600080fd5b60008083601f8401126200115c576200115b62001134565b5b8235905067ffffffffffffffff8111156200117c576200117b62001139565b5b6020830191508360208202830111156200119b576200119a6200113e565b5b9250929050565b60008060208385031215620011bc57620011bb62000fc1565b5b600083013567ffffffffffffffff811115620011dd57620011dc62000fc6565b5b620011eb8582860162001143565b92509250509250929050565b600062001204826200108c565b9050919050565b6200121681620011f7565b82525050565b60006020820190506200123360008301846200120b565b92915050565b60008060006040848603121562001255576200125462000fc1565b5b6000620012658682870162000ff3565b935050602084013567ffffffffffffffff81111562001289576200128862000fc6565b5b620012978682870162001143565b92509250509250925092565b620012ae8162000fcb565b82525050565b6000602082019050620012cb6000830184620012a3565b92915050565b620012dc81620011f7565b8114620012e857600080fd5b50565b600081359050620012fc81620012d1565b92915050565b6000602082840312156200131b576200131a62000fc1565b5b60006200132b84828501620012eb565b91505092915050565b6000602082840312156200134d576200134c62000fc1565b5b60006200135d8482850162000ff3565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b620013fb816200100a565b82525050565b60006200140f8383620013f0565b60208301905092915050565b6000602082019050919050565b60006200143582620013c4565b620014418185620013cf565b93506200144e83620013e0565b8060005b838110156200148557815162001469888262001401565b975062001476836200141b565b92505060018101905062001452565b5085935050505092915050565b60006020820190508181036000830152620014ae818462001428565b905092915050565b6000604082019050620014cd60008301856200120b565b620014dc6020830184620012a3565b9392505050565b600080fd5b82818337600083830152505050565b6000620015058385620013cf565b93507f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8311156200153b576200153a620014e3565b5b6020830292506200154e838584620014e8565b82840190509392505050565b6000602082019050818103600083015262001577818486620014f7565b90509392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000620015bc8262000fcb565b9150620015c98362000fcb565b92508261ffff03821115620015e357620015e262001580565b5b828201905092915050565b6000620015fb82620011f7565b9050919050565b6200160d81620015ee565b81146200161957600080fd5b50565b6000815190506200162d8162001602565b92915050565b6000602082840312156200164c576200164b62000fc1565b5b60006200165c848285016200161c565b91505092915050565b600081519050620016768162000fd9565b92915050565b60006020828403121562001695576200169462000fc1565b5b6000620016a58482850162001665565b91505092915050565b600082825260208201905092915050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b60006200171d602683620016ae565b91506200172a82620016bf565b604082019050919050565b6000602082019050818103600083015262001750816200170e565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b60006200178f602083620016ae565b91506200179c8262001757565b602082019050919050565b60006020820190508181036000830152620017c28162001780565b9050919050565b6000604082019050620017e06000830185620012a3565b620017ef60208301846200120b565b939250505056fe610160604052600180553480156200001657600080fd5b50604051620014533803806200145383398181016040528101906200003c91906200028f565b6000601483600062000063620000576200011a60201b60201c565b6200012260201b60201c565b83608081815250508260a08181525050826001901b60c081815250508173ffffffffffffffffffffffffffffffffffffffff1660e08173ffffffffffffffffffffffffffffffffffffffff16815250508073ffffffffffffffffffffffffffffffffffffffff166101008173ffffffffffffffffffffffffffffffffffffffff16815250504363ffffffff166101208163ffffffff1681525050505050508061ffff166101408161ffff16815250505050620002d6565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006200021882620001eb565b9050919050565b6200022a816200020b565b81146200023657600080fd5b50565b6000815190506200024a816200021f565b92915050565b600061ffff82169050919050565b620002698162000250565b81146200027557600080fd5b50565b60008151905062000289816200025e565b92915050565b60008060408385031215620002a957620002a8620001e6565b5b6000620002b98582860162000239565b9250506020620002cc8582860162000278565b9150509250929050565b60805160a05160c05160e0516101005161012051610140516111146200033f60003960006104fd0152600061059b0152600061052101526000818161046401526105450152600081816106ee0152610a44015260006106940152600061074401526111146000f3fe6080604052600436106101145760003560e01c80638be9b119116100a0578063c5b208ff11610064578063c5b208ff1461037d578063d0383d68146103ba578063f207564e146103e5578063f220b9ec14610401578063f2fde38b1461042c57610114565b80638be9b119146102965780638da5cb5b146102bf57806398366e35146102ea578063ae74552a14610315578063bc4991281461034057610114565b80633ccfd60b116100e75780633ccfd60b146101d75780634add651e146101ee5780635daf08ca14610219578063715018a6146102565780637a34289d1461026d57610114565b806322d9730c1461011957806328b070e0146101565780632b7ac3f314610181578063331b6ab3146101ac575b600080fd5b34801561012557600080fd5b50610140600480360381019061013b9190610ae0565b610455565b60405161014d9190610b28565b60405180910390f35b34801561016257600080fd5b5061016b6104fb565b6040516101789190610b60565b60405180910390f35b34801561018d57600080fd5b5061019661051f565b6040516101a39190610bfa565b60405180910390f35b3480156101b857600080fd5b506101c1610543565b6040516101ce9190610c36565b60405180910390f35b3480156101e357600080fd5b506101ec610567565b005b3480156101fa57600080fd5b50610203610599565b6040516102109190610c70565b60405180910390f35b34801561022557600080fd5b50610240600480360381019061023b9190610ae0565b6105bd565b60405161024d9190610c9a565b60405180910390f35b34801561026257600080fd5b5061026b6105d5565b005b34801561027957600080fd5b50610294600480360381019061028f9190610d1a565b6105e9565b005b3480156102a257600080fd5b506102bd60048036038101906102b89190610dc7565b610637565b005b3480156102cb57600080fd5b506102d4610669565b6040516102e19190610e3c565b60405180910390f35b3480156102f657600080fd5b506102ff610692565b60405161030c9190610c9a565b60405180910390f35b34801561032157600080fd5b5061032a6106b6565b6040516103379190610c9a565b60405180910390f35b34801561034c57600080fd5b5061036760048036038101906103629190610ae0565b6106bc565b6040516103749190610c9a565b60405180910390f35b34801561038957600080fd5b506103a4600480360381019061039f9190610e83565b6106d4565b6040516103b19190610c9a565b60405180910390f35b3480156103c657600080fd5b506103cf6106ec565b6040516103dc9190610c9a565b60405180910390f35b6103ff60048036038101906103fa9190610ae0565b610710565b005b34801561040d57600080fd5b50610416610742565b6040516104239190610c9a565b60405180910390f35b34801561043857600080fd5b50610453600480360381019061044e9190610e83565b610766565b005b60008082141580156104f457507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663e493ef8c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156104cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104f19190610ec5565b82105b9050919050565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b6040517fd623472500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000081565b60036020528060005260406000206000915090505481565b6105dd6107e9565b6105e76000610867565b565b6105f16107e9565b600082829050905060005b818110156106315761062684848381811061061a57610619610ef2565b5b9050602002013561092b565b8060010190506105fc565b50505050565b6040517fd623472500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b7f000000000000000000000000000000000000000000000000000000000000000081565b60015481565b60026020528060005260406000206000915090505481565b60046020528060005260406000206000915090505481565b7f000000000000000000000000000000000000000000000000000000000000000081565b6040517fd623472500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000081565b61076e6107e9565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036107dd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d490610fa4565b60405180910390fd5b6107e681610867565b50565b6107f16109a4565b73ffffffffffffffffffffffffffffffffffffffff1661080f610669565b73ffffffffffffffffffffffffffffffffffffffff1614610865576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161085c90611010565b60405180910390fd5b565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b610934816109ac565b600160036000838152602001908152602001600020819055507f5a92c2530f207992057b9c3e544108ffce3beda4a63719f316967c49bf6159d281600154604051610980929190611030565b60405180910390a1600180600082825461099a9190611088565b9250508190555050565b600033905090565b6109b581610455565b6109f657806040517f7f3e75af0000000000000000000000000000000000000000000000000000000081526004016109ed9190610c9a565b60405180910390fd5b6000600360008381526020019081526020016000205414610a42576040517e0a60f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000060015410610a9d576040517f57f6953100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50565b600080fd5b600080fd5b6000819050919050565b610abd81610aaa565b8114610ac857600080fd5b50565b600081359050610ada81610ab4565b92915050565b600060208284031215610af657610af5610aa0565b5b6000610b0484828501610acb565b91505092915050565b60008115159050919050565b610b2281610b0d565b82525050565b6000602082019050610b3d6000830184610b19565b92915050565b600061ffff82169050919050565b610b5a81610b43565b82525050565b6000602082019050610b756000830184610b51565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b6000610bc0610bbb610bb684610b7b565b610b9b565b610b7b565b9050919050565b6000610bd282610ba5565b9050919050565b6000610be482610bc7565b9050919050565b610bf481610bd9565b82525050565b6000602082019050610c0f6000830184610beb565b92915050565b6000610c2082610bc7565b9050919050565b610c3081610c15565b82525050565b6000602082019050610c4b6000830184610c27565b92915050565b600063ffffffff82169050919050565b610c6a81610c51565b82525050565b6000602082019050610c856000830184610c61565b92915050565b610c9481610aaa565b82525050565b6000602082019050610caf6000830184610c8b565b92915050565b600080fd5b600080fd5b600080fd5b60008083601f840112610cda57610cd9610cb5565b5b8235905067ffffffffffffffff811115610cf757610cf6610cba565b5b602083019150836020820283011115610d1357610d12610cbf565b5b9250929050565b60008060208385031215610d3157610d30610aa0565b5b600083013567ffffffffffffffff811115610d4f57610d4e610aa5565b5b610d5b85828601610cc4565b92509250509250929050565b6000610d7282610b7b565b9050919050565b610d8281610d67565b8114610d8d57600080fd5b50565b600081359050610d9f81610d79565b92915050565b600081905082602060080282011115610dc157610dc0610cbf565b5b92915050565b60008060006101408486031215610de157610de0610aa0565b5b6000610def86828701610acb565b9350506020610e0086828701610d90565b9250506040610e1186828701610da5565b9150509250925092565b6000610e2682610b7b565b9050919050565b610e3681610e1b565b82525050565b6000602082019050610e516000830184610e2d565b92915050565b610e6081610e1b565b8114610e6b57600080fd5b50565b600081359050610e7d81610e57565b92915050565b600060208284031215610e9957610e98610aa0565b5b6000610ea784828501610e6e565b91505092915050565b600081519050610ebf81610ab4565b92915050565b600060208284031215610edb57610eda610aa0565b5b6000610ee984828501610eb0565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082825260208201905092915050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b6000610f8e602683610f21565b9150610f9982610f32565b604082019050919050565b60006020820190508181036000830152610fbd81610f81565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000610ffa602083610f21565b915061100582610fc4565b602082019050919050565b6000602082019050818103600083015261102981610fed565b9050919050565b60006040820190506110456000830185610c8b565b6110526020830184610c8b565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061109382610aaa565b915061109e83610aaa565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156110d3576110d2611059565b5b82820190509291505056fea2646970667358221220418f43f842c2bfcb16498620d0ec8af5bf2c69e3f7aa005ef11baa07a9c199c864736f6c634300080f0033a264697066735822122053779d5559168fc231e25bef89a31ee66672e272f446bfb501650510b89e437864736f6c634300080f0033", +} + +// RLNRegistryABI is the input ABI used to generate the binding from. +// Deprecated: Use RLNRegistryMetaData.ABI instead. +var RLNRegistryABI = RLNRegistryMetaData.ABI + +// RLNRegistryBin is the compiled bytecode used for deploying new contracts. +// Deprecated: Use RLNRegistryMetaData.Bin instead. +var RLNRegistryBin = RLNRegistryMetaData.Bin + +// DeployRLNRegistry deploys a new Ethereum contract, binding an instance of RLNRegistry to it. +func DeployRLNRegistry(auth *bind.TransactOpts, backend bind.ContractBackend, _poseidonHasher common.Address) (common.Address, *types.Transaction, *RLNRegistry, error) { + parsed, err := RLNRegistryMetaData.GetAbi() + if err != nil { + return common.Address{}, nil, nil, err + } + if parsed == nil { + return common.Address{}, nil, nil, errors.New("GetABI returned nil") + } + + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(RLNRegistryBin), backend, _poseidonHasher) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &RLNRegistry{RLNRegistryCaller: RLNRegistryCaller{contract: contract}, RLNRegistryTransactor: RLNRegistryTransactor{contract: contract}, RLNRegistryFilterer: RLNRegistryFilterer{contract: contract}}, nil +} + +// RLNRegistry is an auto generated Go binding around an Ethereum contract. +type RLNRegistry struct { + RLNRegistryCaller // Read-only binding to the contract + RLNRegistryTransactor // Write-only binding to the contract + RLNRegistryFilterer // Log filterer for contract events +} + +// RLNRegistryCaller is an auto generated read-only Go binding around an Ethereum contract. +type RLNRegistryCaller struct { + contract *bind.BoundContract // Generic contract wrapper for the low level calls +} + +// RLNRegistryTransactor is an auto generated write-only Go binding around an Ethereum contract. +type RLNRegistryTransactor struct { + contract *bind.BoundContract // Generic contract wrapper for the low level calls +} + +// RLNRegistryFilterer is an auto generated log filtering Go binding around an Ethereum contract events. +type RLNRegistryFilterer struct { + contract *bind.BoundContract // Generic contract wrapper for the low level calls +} + +// RLNRegistrySession is an auto generated Go binding around an Ethereum contract, +// with pre-set call and transact options. +type RLNRegistrySession struct { + Contract *RLNRegistry // Generic contract binding to set the session for + CallOpts bind.CallOpts // Call options to use throughout this session + TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session +} + +// RLNRegistryCallerSession is an auto generated read-only Go binding around an Ethereum contract, +// with pre-set call options. +type RLNRegistryCallerSession struct { + Contract *RLNRegistryCaller // Generic contract caller binding to set the session for + CallOpts bind.CallOpts // Call options to use throughout this session +} + +// RLNRegistryTransactorSession is an auto generated write-only Go binding around an Ethereum contract, +// with pre-set transact options. +type RLNRegistryTransactorSession struct { + Contract *RLNRegistryTransactor // Generic contract transactor binding to set the session for + TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session +} + +// RLNRegistryRaw is an auto generated low-level Go binding around an Ethereum contract. +type RLNRegistryRaw struct { + Contract *RLNRegistry // Generic contract binding to access the raw methods on +} + +// RLNRegistryCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. +type RLNRegistryCallerRaw struct { + Contract *RLNRegistryCaller // Generic read-only contract binding to access the raw methods on +} + +// RLNRegistryTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. +type RLNRegistryTransactorRaw struct { + Contract *RLNRegistryTransactor // Generic write-only contract binding to access the raw methods on +} + +// NewRLNRegistry creates a new instance of RLNRegistry, bound to a specific deployed contract. +func NewRLNRegistry(address common.Address, backend bind.ContractBackend) (*RLNRegistry, error) { + contract, err := bindRLNRegistry(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &RLNRegistry{RLNRegistryCaller: RLNRegistryCaller{contract: contract}, RLNRegistryTransactor: RLNRegistryTransactor{contract: contract}, RLNRegistryFilterer: RLNRegistryFilterer{contract: contract}}, nil +} + +// NewRLNRegistryCaller creates a new read-only instance of RLNRegistry, bound to a specific deployed contract. +func NewRLNRegistryCaller(address common.Address, caller bind.ContractCaller) (*RLNRegistryCaller, error) { + contract, err := bindRLNRegistry(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &RLNRegistryCaller{contract: contract}, nil +} + +// NewRLNRegistryTransactor creates a new write-only instance of RLNRegistry, bound to a specific deployed contract. +func NewRLNRegistryTransactor(address common.Address, transactor bind.ContractTransactor) (*RLNRegistryTransactor, error) { + contract, err := bindRLNRegistry(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &RLNRegistryTransactor{contract: contract}, nil +} + +// NewRLNRegistryFilterer creates a new log filterer instance of RLNRegistry, bound to a specific deployed contract. +func NewRLNRegistryFilterer(address common.Address, filterer bind.ContractFilterer) (*RLNRegistryFilterer, error) { + contract, err := bindRLNRegistry(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &RLNRegistryFilterer{contract: contract}, nil +} + +// bindRLNRegistry binds a generic wrapper to an already deployed contract. +func bindRLNRegistry(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := RLNRegistryMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +// Call invokes the (constant) contract method with params as input values and +// sets the output to result. The result type might be a single field for simple +// returns, a slice of interfaces for anonymous returns and a struct for named +// returns. +func (_RLNRegistry *RLNRegistryRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _RLNRegistry.Contract.RLNRegistryCaller.contract.Call(opts, result, method, params...) +} + +// Transfer initiates a plain transaction to move funds to the contract, calling +// its default method if one is available. +func (_RLNRegistry *RLNRegistryRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RLNRegistry.Contract.RLNRegistryTransactor.contract.Transfer(opts) +} + +// Transact invokes the (paid) contract method with params as input values. +func (_RLNRegistry *RLNRegistryRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _RLNRegistry.Contract.RLNRegistryTransactor.contract.Transact(opts, method, params...) +} + +// Call invokes the (constant) contract method with params as input values and +// sets the output to result. The result type might be a single field for simple +// returns, a slice of interfaces for anonymous returns and a struct for named +// returns. +func (_RLNRegistry *RLNRegistryCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _RLNRegistry.Contract.contract.Call(opts, result, method, params...) +} + +// Transfer initiates a plain transaction to move funds to the contract, calling +// its default method if one is available. +func (_RLNRegistry *RLNRegistryTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RLNRegistry.Contract.contract.Transfer(opts) +} + +// Transact invokes the (paid) contract method with params as input values. +func (_RLNRegistry *RLNRegistryTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _RLNRegistry.Contract.contract.Transact(opts, method, params...) +} + +// NextStorageIndex is a free data retrieval call binding the contract method 0xf184ef4c. +// +// Solidity: function nextStorageIndex() view returns(uint16) +func (_RLNRegistry *RLNRegistryCaller) NextStorageIndex(opts *bind.CallOpts) (uint16, error) { + var out []interface{} + err := _RLNRegistry.contract.Call(opts, &out, "nextStorageIndex") + + if err != nil { + return *new(uint16), err + } + + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + + return out0, err + +} + +// NextStorageIndex is a free data retrieval call binding the contract method 0xf184ef4c. +// +// Solidity: function nextStorageIndex() view returns(uint16) +func (_RLNRegistry *RLNRegistrySession) NextStorageIndex() (uint16, error) { + return _RLNRegistry.Contract.NextStorageIndex(&_RLNRegistry.CallOpts) +} + +// NextStorageIndex is a free data retrieval call binding the contract method 0xf184ef4c. +// +// Solidity: function nextStorageIndex() view returns(uint16) +func (_RLNRegistry *RLNRegistryCallerSession) NextStorageIndex() (uint16, error) { + return _RLNRegistry.Contract.NextStorageIndex(&_RLNRegistry.CallOpts) +} + +// Owner is a free data retrieval call binding the contract method 0x8da5cb5b. +// +// Solidity: function owner() view returns(address) +func (_RLNRegistry *RLNRegistryCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _RLNRegistry.contract.Call(opts, &out, "owner") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +// Owner is a free data retrieval call binding the contract method 0x8da5cb5b. +// +// Solidity: function owner() view returns(address) +func (_RLNRegistry *RLNRegistrySession) Owner() (common.Address, error) { + return _RLNRegistry.Contract.Owner(&_RLNRegistry.CallOpts) +} + +// Owner is a free data retrieval call binding the contract method 0x8da5cb5b. +// +// Solidity: function owner() view returns(address) +func (_RLNRegistry *RLNRegistryCallerSession) Owner() (common.Address, error) { + return _RLNRegistry.Contract.Owner(&_RLNRegistry.CallOpts) +} + +// PoseidonHasher is a free data retrieval call binding the contract method 0x331b6ab3. +// +// Solidity: function poseidonHasher() view returns(address) +func (_RLNRegistry *RLNRegistryCaller) PoseidonHasher(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _RLNRegistry.contract.Call(opts, &out, "poseidonHasher") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +// PoseidonHasher is a free data retrieval call binding the contract method 0x331b6ab3. +// +// Solidity: function poseidonHasher() view returns(address) +func (_RLNRegistry *RLNRegistrySession) PoseidonHasher() (common.Address, error) { + return _RLNRegistry.Contract.PoseidonHasher(&_RLNRegistry.CallOpts) +} + +// PoseidonHasher is a free data retrieval call binding the contract method 0x331b6ab3. +// +// Solidity: function poseidonHasher() view returns(address) +func (_RLNRegistry *RLNRegistryCallerSession) PoseidonHasher() (common.Address, error) { + return _RLNRegistry.Contract.PoseidonHasher(&_RLNRegistry.CallOpts) +} + +// Storages is a free data retrieval call binding the contract method 0xf5542147. +// +// Solidity: function storages(uint16 ) view returns(address) +func (_RLNRegistry *RLNRegistryCaller) Storages(opts *bind.CallOpts, arg0 uint16) (common.Address, error) { + var out []interface{} + err := _RLNRegistry.contract.Call(opts, &out, "storages", arg0) + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +// Storages is a free data retrieval call binding the contract method 0xf5542147. +// +// Solidity: function storages(uint16 ) view returns(address) +func (_RLNRegistry *RLNRegistrySession) Storages(arg0 uint16) (common.Address, error) { + return _RLNRegistry.Contract.Storages(&_RLNRegistry.CallOpts, arg0) +} + +// Storages is a free data retrieval call binding the contract method 0xf5542147. +// +// Solidity: function storages(uint16 ) view returns(address) +func (_RLNRegistry *RLNRegistryCallerSession) Storages(arg0 uint16) (common.Address, error) { + return _RLNRegistry.Contract.Storages(&_RLNRegistry.CallOpts, arg0) +} + +// UsingStorageIndex is a free data retrieval call binding the contract method 0xcf616374. +// +// Solidity: function usingStorageIndex() view returns(uint16) +func (_RLNRegistry *RLNRegistryCaller) UsingStorageIndex(opts *bind.CallOpts) (uint16, error) { + var out []interface{} + err := _RLNRegistry.contract.Call(opts, &out, "usingStorageIndex") + + if err != nil { + return *new(uint16), err + } + + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + + return out0, err + +} + +// UsingStorageIndex is a free data retrieval call binding the contract method 0xcf616374. +// +// Solidity: function usingStorageIndex() view returns(uint16) +func (_RLNRegistry *RLNRegistrySession) UsingStorageIndex() (uint16, error) { + return _RLNRegistry.Contract.UsingStorageIndex(&_RLNRegistry.CallOpts) +} + +// UsingStorageIndex is a free data retrieval call binding the contract method 0xcf616374. +// +// Solidity: function usingStorageIndex() view returns(uint16) +func (_RLNRegistry *RLNRegistryCallerSession) UsingStorageIndex() (uint16, error) { + return _RLNRegistry.Contract.UsingStorageIndex(&_RLNRegistry.CallOpts) +} + +// ForceProgress is a paid mutator transaction binding the contract method 0xd44fda1f. +// +// Solidity: function forceProgress() returns() +func (_RLNRegistry *RLNRegistryTransactor) ForceProgress(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RLNRegistry.contract.Transact(opts, "forceProgress") +} + +// ForceProgress is a paid mutator transaction binding the contract method 0xd44fda1f. +// +// Solidity: function forceProgress() returns() +func (_RLNRegistry *RLNRegistrySession) ForceProgress() (*types.Transaction, error) { + return _RLNRegistry.Contract.ForceProgress(&_RLNRegistry.TransactOpts) +} + +// ForceProgress is a paid mutator transaction binding the contract method 0xd44fda1f. +// +// Solidity: function forceProgress() returns() +func (_RLNRegistry *RLNRegistryTransactorSession) ForceProgress() (*types.Transaction, error) { + return _RLNRegistry.Contract.ForceProgress(&_RLNRegistry.TransactOpts) +} + +// NewStorage is a paid mutator transaction binding the contract method 0x42f542e2. +// +// Solidity: function newStorage() returns() +func (_RLNRegistry *RLNRegistryTransactor) NewStorage(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RLNRegistry.contract.Transact(opts, "newStorage") +} + +// NewStorage is a paid mutator transaction binding the contract method 0x42f542e2. +// +// Solidity: function newStorage() returns() +func (_RLNRegistry *RLNRegistrySession) NewStorage() (*types.Transaction, error) { + return _RLNRegistry.Contract.NewStorage(&_RLNRegistry.TransactOpts) +} + +// NewStorage is a paid mutator transaction binding the contract method 0x42f542e2. +// +// Solidity: function newStorage() returns() +func (_RLNRegistry *RLNRegistryTransactorSession) NewStorage() (*types.Transaction, error) { + return _RLNRegistry.Contract.NewStorage(&_RLNRegistry.TransactOpts) +} + +// Register is a paid mutator transaction binding the contract method 0x26e0fc1f. +// +// Solidity: function register(uint16 storageIndex, uint256 commitment) returns() +func (_RLNRegistry *RLNRegistryTransactor) Register(opts *bind.TransactOpts, storageIndex uint16, commitment *big.Int) (*types.Transaction, error) { + return _RLNRegistry.contract.Transact(opts, "register", storageIndex, commitment) +} + +// Register is a paid mutator transaction binding the contract method 0x26e0fc1f. +// +// Solidity: function register(uint16 storageIndex, uint256 commitment) returns() +func (_RLNRegistry *RLNRegistrySession) Register(storageIndex uint16, commitment *big.Int) (*types.Transaction, error) { + return _RLNRegistry.Contract.Register(&_RLNRegistry.TransactOpts, storageIndex, commitment) +} + +// Register is a paid mutator transaction binding the contract method 0x26e0fc1f. +// +// Solidity: function register(uint16 storageIndex, uint256 commitment) returns() +func (_RLNRegistry *RLNRegistryTransactorSession) Register(storageIndex uint16, commitment *big.Int) (*types.Transaction, error) { + return _RLNRegistry.Contract.Register(&_RLNRegistry.TransactOpts, storageIndex, commitment) +} + +// Register0 is a paid mutator transaction binding the contract method 0x7a34289d. +// +// Solidity: function register(uint256[] commitments) returns() +func (_RLNRegistry *RLNRegistryTransactor) Register0(opts *bind.TransactOpts, commitments []*big.Int) (*types.Transaction, error) { + return _RLNRegistry.contract.Transact(opts, "register0", commitments) +} + +// Register0 is a paid mutator transaction binding the contract method 0x7a34289d. +// +// Solidity: function register(uint256[] commitments) returns() +func (_RLNRegistry *RLNRegistrySession) Register0(commitments []*big.Int) (*types.Transaction, error) { + return _RLNRegistry.Contract.Register0(&_RLNRegistry.TransactOpts, commitments) +} + +// Register0 is a paid mutator transaction binding the contract method 0x7a34289d. +// +// Solidity: function register(uint256[] commitments) returns() +func (_RLNRegistry *RLNRegistryTransactorSession) Register0(commitments []*big.Int) (*types.Transaction, error) { + return _RLNRegistry.Contract.Register0(&_RLNRegistry.TransactOpts, commitments) +} + +// Register1 is a paid mutator transaction binding the contract method 0xab02492a. +// +// Solidity: function register(uint16 storageIndex, uint256[] commitments) returns() +func (_RLNRegistry *RLNRegistryTransactor) Register1(opts *bind.TransactOpts, storageIndex uint16, commitments []*big.Int) (*types.Transaction, error) { + return _RLNRegistry.contract.Transact(opts, "register1", storageIndex, commitments) +} + +// Register1 is a paid mutator transaction binding the contract method 0xab02492a. +// +// Solidity: function register(uint16 storageIndex, uint256[] commitments) returns() +func (_RLNRegistry *RLNRegistrySession) Register1(storageIndex uint16, commitments []*big.Int) (*types.Transaction, error) { + return _RLNRegistry.Contract.Register1(&_RLNRegistry.TransactOpts, storageIndex, commitments) +} + +// Register1 is a paid mutator transaction binding the contract method 0xab02492a. +// +// Solidity: function register(uint16 storageIndex, uint256[] commitments) returns() +func (_RLNRegistry *RLNRegistryTransactorSession) Register1(storageIndex uint16, commitments []*big.Int) (*types.Transaction, error) { + return _RLNRegistry.Contract.Register1(&_RLNRegistry.TransactOpts, storageIndex, commitments) +} + +// RegisterStorage is a paid mutator transaction binding the contract method 0xef653d5e. +// +// Solidity: function registerStorage(address storageAddress) returns() +func (_RLNRegistry *RLNRegistryTransactor) RegisterStorage(opts *bind.TransactOpts, storageAddress common.Address) (*types.Transaction, error) { + return _RLNRegistry.contract.Transact(opts, "registerStorage", storageAddress) +} + +// RegisterStorage is a paid mutator transaction binding the contract method 0xef653d5e. +// +// Solidity: function registerStorage(address storageAddress) returns() +func (_RLNRegistry *RLNRegistrySession) RegisterStorage(storageAddress common.Address) (*types.Transaction, error) { + return _RLNRegistry.Contract.RegisterStorage(&_RLNRegistry.TransactOpts, storageAddress) +} + +// RegisterStorage is a paid mutator transaction binding the contract method 0xef653d5e. +// +// Solidity: function registerStorage(address storageAddress) returns() +func (_RLNRegistry *RLNRegistryTransactorSession) RegisterStorage(storageAddress common.Address) (*types.Transaction, error) { + return _RLNRegistry.Contract.RegisterStorage(&_RLNRegistry.TransactOpts, storageAddress) +} + +// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. +// +// Solidity: function renounceOwnership() returns() +func (_RLNRegistry *RLNRegistryTransactor) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RLNRegistry.contract.Transact(opts, "renounceOwnership") +} + +// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. +// +// Solidity: function renounceOwnership() returns() +func (_RLNRegistry *RLNRegistrySession) RenounceOwnership() (*types.Transaction, error) { + return _RLNRegistry.Contract.RenounceOwnership(&_RLNRegistry.TransactOpts) +} + +// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. +// +// Solidity: function renounceOwnership() returns() +func (_RLNRegistry *RLNRegistryTransactorSession) RenounceOwnership() (*types.Transaction, error) { + return _RLNRegistry.Contract.RenounceOwnership(&_RLNRegistry.TransactOpts) +} + +// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. +// +// Solidity: function transferOwnership(address newOwner) returns() +func (_RLNRegistry *RLNRegistryTransactor) TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error) { + return _RLNRegistry.contract.Transact(opts, "transferOwnership", newOwner) +} + +// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. +// +// Solidity: function transferOwnership(address newOwner) returns() +func (_RLNRegistry *RLNRegistrySession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { + return _RLNRegistry.Contract.TransferOwnership(&_RLNRegistry.TransactOpts, newOwner) +} + +// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. +// +// Solidity: function transferOwnership(address newOwner) returns() +func (_RLNRegistry *RLNRegistryTransactorSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { + return _RLNRegistry.Contract.TransferOwnership(&_RLNRegistry.TransactOpts, newOwner) +} + +// RLNRegistryNewStorageContractIterator is returned from FilterNewStorageContract and is used to iterate over the raw logs and unpacked data for NewStorageContract events raised by the RLNRegistry contract. +type RLNRegistryNewStorageContractIterator struct { + Event *RLNRegistryNewStorageContract // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RLNRegistryNewStorageContractIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RLNRegistryNewStorageContract) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RLNRegistryNewStorageContract) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RLNRegistryNewStorageContractIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RLNRegistryNewStorageContractIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RLNRegistryNewStorageContract represents a NewStorageContract event raised by the RLNRegistry contract. +type RLNRegistryNewStorageContract struct { + Index uint16 + StorageAddress common.Address + Raw types.Log // Blockchain specific contextual infos +} + +// FilterNewStorageContract is a free log retrieval operation binding the contract event 0xcf6a3b406170499209d0fcf152a1605c7c5a5c99c855e2bb803433fc960718eb. +// +// Solidity: event NewStorageContract(uint16 index, address storageAddress) +func (_RLNRegistry *RLNRegistryFilterer) FilterNewStorageContract(opts *bind.FilterOpts) (*RLNRegistryNewStorageContractIterator, error) { + + logs, sub, err := _RLNRegistry.contract.FilterLogs(opts, "NewStorageContract") + if err != nil { + return nil, err + } + return &RLNRegistryNewStorageContractIterator{contract: _RLNRegistry.contract, event: "NewStorageContract", logs: logs, sub: sub}, nil +} + +// WatchNewStorageContract is a free log subscription operation binding the contract event 0xcf6a3b406170499209d0fcf152a1605c7c5a5c99c855e2bb803433fc960718eb. +// +// Solidity: event NewStorageContract(uint16 index, address storageAddress) +func (_RLNRegistry *RLNRegistryFilterer) WatchNewStorageContract(opts *bind.WatchOpts, sink chan<- *RLNRegistryNewStorageContract) (event.Subscription, error) { + + logs, sub, err := _RLNRegistry.contract.WatchLogs(opts, "NewStorageContract") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RLNRegistryNewStorageContract) + if err := _RLNRegistry.contract.UnpackLog(event, "NewStorageContract", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseNewStorageContract is a log parse operation binding the contract event 0xcf6a3b406170499209d0fcf152a1605c7c5a5c99c855e2bb803433fc960718eb. +// +// Solidity: event NewStorageContract(uint16 index, address storageAddress) +func (_RLNRegistry *RLNRegistryFilterer) ParseNewStorageContract(log types.Log) (*RLNRegistryNewStorageContract, error) { + event := new(RLNRegistryNewStorageContract) + if err := _RLNRegistry.contract.UnpackLog(event, "NewStorageContract", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +// RLNRegistryOwnershipTransferredIterator is returned from FilterOwnershipTransferred and is used to iterate over the raw logs and unpacked data for OwnershipTransferred events raised by the RLNRegistry contract. +type RLNRegistryOwnershipTransferredIterator struct { + Event *RLNRegistryOwnershipTransferred // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RLNRegistryOwnershipTransferredIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RLNRegistryOwnershipTransferred) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RLNRegistryOwnershipTransferred) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RLNRegistryOwnershipTransferredIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RLNRegistryOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RLNRegistryOwnershipTransferred represents a OwnershipTransferred event raised by the RLNRegistry contract. +type RLNRegistryOwnershipTransferred struct { + PreviousOwner common.Address + NewOwner common.Address + Raw types.Log // Blockchain specific contextual infos +} + +// FilterOwnershipTransferred is a free log retrieval operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0. +// +// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner) +func (_RLNRegistry *RLNRegistryFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, previousOwner []common.Address, newOwner []common.Address) (*RLNRegistryOwnershipTransferredIterator, error) { + + var previousOwnerRule []interface{} + for _, previousOwnerItem := range previousOwner { + previousOwnerRule = append(previousOwnerRule, previousOwnerItem) + } + var newOwnerRule []interface{} + for _, newOwnerItem := range newOwner { + newOwnerRule = append(newOwnerRule, newOwnerItem) + } + + logs, sub, err := _RLNRegistry.contract.FilterLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) + if err != nil { + return nil, err + } + return &RLNRegistryOwnershipTransferredIterator{contract: _RLNRegistry.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +// WatchOwnershipTransferred is a free log subscription operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0. +// +// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner) +func (_RLNRegistry *RLNRegistryFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *RLNRegistryOwnershipTransferred, previousOwner []common.Address, newOwner []common.Address) (event.Subscription, error) { + + var previousOwnerRule []interface{} + for _, previousOwnerItem := range previousOwner { + previousOwnerRule = append(previousOwnerRule, previousOwnerItem) + } + var newOwnerRule []interface{} + for _, newOwnerItem := range newOwner { + newOwnerRule = append(newOwnerRule, newOwnerItem) + } + + logs, sub, err := _RLNRegistry.contract.WatchLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RLNRegistryOwnershipTransferred) + if err := _RLNRegistry.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseOwnershipTransferred is a log parse operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0. +// +// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner) +func (_RLNRegistry *RLNRegistryFilterer) ParseOwnershipTransferred(log types.Log) (*RLNRegistryOwnershipTransferred, error) { + event := new(RLNRegistryOwnershipTransferred) + if err := _RLNRegistry.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} diff --git a/waku/v2/protocol/rln/contracts/rln-contract b/waku/v2/protocol/rln/contracts/rln-contract deleted file mode 160000 index f99eb2aa..00000000 --- a/waku/v2/protocol/rln/contracts/rln-contract +++ /dev/null @@ -1 +0,0 @@ -Subproject commit f99eb2aa0d62bb27631f6ffb4c6161ceb334d2a3 diff --git a/waku/v2/protocol/rln/contracts/rln.go b/waku/v2/protocol/rln/contracts/rln.go new file mode 100644 index 00000000..d36081e1 --- /dev/null +++ b/waku/v2/protocol/rln/contracts/rln.go @@ -0,0 +1,1171 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package contracts + +import ( + "errors" + "math/big" + "strings" + + ethereum "github.com/ethereum/go-ethereum" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/event" +) + +// Reference imports to suppress errors if they are not otherwise used. +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +// RLNMetaData contains all meta data concerning the RLN contract. +var RLNMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_poseidonHasher\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"_contractIndex\",\"type\":\"uint16\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"DuplicateIdCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FullTree\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"idCommitment\",\"type\":\"uint256\"}],\"name\":\"InvalidIdCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotImplemented\",\"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\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"}],\"name\":\"MemberWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"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\":\"contractIndex\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"deployedBlockNumber\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"idCommitmentIndex\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"idCommitment\",\"type\":\"uint256\"}],\"name\":\"isValidCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"members\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"poseidonHasher\",\"outputs\":[{\"internalType\":\"contractPoseidonHasher\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"idCommitments\",\"type\":\"uint256[]\"}],\"name\":\"register\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"idCommitment\",\"type\":\"uint256\"}],\"name\":\"register\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"idCommitment\",\"type\":\"uint256\"},{\"internalType\":\"addresspayable\",\"name\":\"receiver\",\"type\":\"address\"},{\"internalType\":\"uint256[8]\",\"name\":\"proof\",\"type\":\"uint256[8]\"}],\"name\":\"slash\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"stakedAmounts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"verifier\",\"outputs\":[{\"internalType\":\"contractIVerifier\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"withdrawalBalance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x610160604052600180553480156200001657600080fd5b50604051620014533803806200145383398181016040528101906200003c91906200028f565b6000601483600062000063620000576200011a60201b60201c565b6200012260201b60201c565b83608081815250508260a08181525050826001901b60c081815250508173ffffffffffffffffffffffffffffffffffffffff1660e08173ffffffffffffffffffffffffffffffffffffffff16815250508073ffffffffffffffffffffffffffffffffffffffff166101008173ffffffffffffffffffffffffffffffffffffffff16815250504363ffffffff166101208163ffffffff1681525050505050508061ffff166101408161ffff16815250505050620002d6565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006200021882620001eb565b9050919050565b6200022a816200020b565b81146200023657600080fd5b50565b6000815190506200024a816200021f565b92915050565b600061ffff82169050919050565b620002698162000250565b81146200027557600080fd5b50565b60008151905062000289816200025e565b92915050565b60008060408385031215620002a957620002a8620001e6565b5b6000620002b98582860162000239565b9250506020620002cc8582860162000278565b9150509250929050565b60805160a05160c05160e0516101005161012051610140516111146200033f60003960006104fd0152600061059b0152600061052101526000818161046401526105450152600081816106ee0152610a44015260006106940152600061074401526111146000f3fe6080604052600436106101145760003560e01c80638be9b119116100a0578063c5b208ff11610064578063c5b208ff1461037d578063d0383d68146103ba578063f207564e146103e5578063f220b9ec14610401578063f2fde38b1461042c57610114565b80638be9b119146102965780638da5cb5b146102bf57806398366e35146102ea578063ae74552a14610315578063bc4991281461034057610114565b80633ccfd60b116100e75780633ccfd60b146101d75780634add651e146101ee5780635daf08ca14610219578063715018a6146102565780637a34289d1461026d57610114565b806322d9730c1461011957806328b070e0146101565780632b7ac3f314610181578063331b6ab3146101ac575b600080fd5b34801561012557600080fd5b50610140600480360381019061013b9190610ae0565b610455565b60405161014d9190610b28565b60405180910390f35b34801561016257600080fd5b5061016b6104fb565b6040516101789190610b60565b60405180910390f35b34801561018d57600080fd5b5061019661051f565b6040516101a39190610bfa565b60405180910390f35b3480156101b857600080fd5b506101c1610543565b6040516101ce9190610c36565b60405180910390f35b3480156101e357600080fd5b506101ec610567565b005b3480156101fa57600080fd5b50610203610599565b6040516102109190610c70565b60405180910390f35b34801561022557600080fd5b50610240600480360381019061023b9190610ae0565b6105bd565b60405161024d9190610c9a565b60405180910390f35b34801561026257600080fd5b5061026b6105d5565b005b34801561027957600080fd5b50610294600480360381019061028f9190610d1a565b6105e9565b005b3480156102a257600080fd5b506102bd60048036038101906102b89190610dc7565b610637565b005b3480156102cb57600080fd5b506102d4610669565b6040516102e19190610e3c565b60405180910390f35b3480156102f657600080fd5b506102ff610692565b60405161030c9190610c9a565b60405180910390f35b34801561032157600080fd5b5061032a6106b6565b6040516103379190610c9a565b60405180910390f35b34801561034c57600080fd5b5061036760048036038101906103629190610ae0565b6106bc565b6040516103749190610c9a565b60405180910390f35b34801561038957600080fd5b506103a4600480360381019061039f9190610e83565b6106d4565b6040516103b19190610c9a565b60405180910390f35b3480156103c657600080fd5b506103cf6106ec565b6040516103dc9190610c9a565b60405180910390f35b6103ff60048036038101906103fa9190610ae0565b610710565b005b34801561040d57600080fd5b50610416610742565b6040516104239190610c9a565b60405180910390f35b34801561043857600080fd5b50610453600480360381019061044e9190610e83565b610766565b005b60008082141580156104f457507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663e493ef8c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156104cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104f19190610ec5565b82105b9050919050565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b6040517fd623472500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000081565b60036020528060005260406000206000915090505481565b6105dd6107e9565b6105e76000610867565b565b6105f16107e9565b600082829050905060005b818110156106315761062684848381811061061a57610619610ef2565b5b9050602002013561092b565b8060010190506105fc565b50505050565b6040517fd623472500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b7f000000000000000000000000000000000000000000000000000000000000000081565b60015481565b60026020528060005260406000206000915090505481565b60046020528060005260406000206000915090505481565b7f000000000000000000000000000000000000000000000000000000000000000081565b6040517fd623472500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000081565b61076e6107e9565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036107dd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d490610fa4565b60405180910390fd5b6107e681610867565b50565b6107f16109a4565b73ffffffffffffffffffffffffffffffffffffffff1661080f610669565b73ffffffffffffffffffffffffffffffffffffffff1614610865576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161085c90611010565b60405180910390fd5b565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b610934816109ac565b600160036000838152602001908152602001600020819055507f5a92c2530f207992057b9c3e544108ffce3beda4a63719f316967c49bf6159d281600154604051610980929190611030565b60405180910390a1600180600082825461099a9190611088565b9250508190555050565b600033905090565b6109b581610455565b6109f657806040517f7f3e75af0000000000000000000000000000000000000000000000000000000081526004016109ed9190610c9a565b60405180910390fd5b6000600360008381526020019081526020016000205414610a42576040517e0a60f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000060015410610a9d576040517f57f6953100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50565b600080fd5b600080fd5b6000819050919050565b610abd81610aaa565b8114610ac857600080fd5b50565b600081359050610ada81610ab4565b92915050565b600060208284031215610af657610af5610aa0565b5b6000610b0484828501610acb565b91505092915050565b60008115159050919050565b610b2281610b0d565b82525050565b6000602082019050610b3d6000830184610b19565b92915050565b600061ffff82169050919050565b610b5a81610b43565b82525050565b6000602082019050610b756000830184610b51565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b6000610bc0610bbb610bb684610b7b565b610b9b565b610b7b565b9050919050565b6000610bd282610ba5565b9050919050565b6000610be482610bc7565b9050919050565b610bf481610bd9565b82525050565b6000602082019050610c0f6000830184610beb565b92915050565b6000610c2082610bc7565b9050919050565b610c3081610c15565b82525050565b6000602082019050610c4b6000830184610c27565b92915050565b600063ffffffff82169050919050565b610c6a81610c51565b82525050565b6000602082019050610c856000830184610c61565b92915050565b610c9481610aaa565b82525050565b6000602082019050610caf6000830184610c8b565b92915050565b600080fd5b600080fd5b600080fd5b60008083601f840112610cda57610cd9610cb5565b5b8235905067ffffffffffffffff811115610cf757610cf6610cba565b5b602083019150836020820283011115610d1357610d12610cbf565b5b9250929050565b60008060208385031215610d3157610d30610aa0565b5b600083013567ffffffffffffffff811115610d4f57610d4e610aa5565b5b610d5b85828601610cc4565b92509250509250929050565b6000610d7282610b7b565b9050919050565b610d8281610d67565b8114610d8d57600080fd5b50565b600081359050610d9f81610d79565b92915050565b600081905082602060080282011115610dc157610dc0610cbf565b5b92915050565b60008060006101408486031215610de157610de0610aa0565b5b6000610def86828701610acb565b9350506020610e0086828701610d90565b9250506040610e1186828701610da5565b9150509250925092565b6000610e2682610b7b565b9050919050565b610e3681610e1b565b82525050565b6000602082019050610e516000830184610e2d565b92915050565b610e6081610e1b565b8114610e6b57600080fd5b50565b600081359050610e7d81610e57565b92915050565b600060208284031215610e9957610e98610aa0565b5b6000610ea784828501610e6e565b91505092915050565b600081519050610ebf81610ab4565b92915050565b600060208284031215610edb57610eda610aa0565b5b6000610ee984828501610eb0565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082825260208201905092915050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b6000610f8e602683610f21565b9150610f9982610f32565b604082019050919050565b60006020820190508181036000830152610fbd81610f81565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000610ffa602083610f21565b915061100582610fc4565b602082019050919050565b6000602082019050818103600083015261102981610fed565b9050919050565b60006040820190506110456000830185610c8b565b6110526020830184610c8b565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061109382610aaa565b915061109e83610aaa565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156110d3576110d2611059565b5b82820190509291505056fea2646970667358221220418f43f842c2bfcb16498620d0ec8af5bf2c69e3f7aa005ef11baa07a9c199c864736f6c634300080f0033", +} + +// RLNABI is the input ABI used to generate the binding from. +// Deprecated: Use RLNMetaData.ABI instead. +var RLNABI = RLNMetaData.ABI + +// RLNBin is the compiled bytecode used for deploying new contracts. +// Deprecated: Use RLNMetaData.Bin instead. +var RLNBin = RLNMetaData.Bin + +// DeployRLN deploys a new Ethereum contract, binding an instance of RLN to it. +func DeployRLN(auth *bind.TransactOpts, backend bind.ContractBackend, _poseidonHasher common.Address, _contractIndex uint16) (common.Address, *types.Transaction, *RLN, error) { + parsed, err := RLNMetaData.GetAbi() + if err != nil { + return common.Address{}, nil, nil, err + } + if parsed == nil { + return common.Address{}, nil, nil, errors.New("GetABI returned nil") + } + + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(RLNBin), backend, _poseidonHasher, _contractIndex) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &RLN{RLNCaller: RLNCaller{contract: contract}, RLNTransactor: RLNTransactor{contract: contract}, RLNFilterer: RLNFilterer{contract: contract}}, nil +} + +// RLN is an auto generated Go binding around an Ethereum contract. +type RLN struct { + RLNCaller // Read-only binding to the contract + RLNTransactor // Write-only binding to the contract + RLNFilterer // Log filterer for contract events +} + +// RLNCaller is an auto generated read-only Go binding around an Ethereum contract. +type RLNCaller struct { + contract *bind.BoundContract // Generic contract wrapper for the low level calls +} + +// RLNTransactor is an auto generated write-only Go binding around an Ethereum contract. +type RLNTransactor struct { + contract *bind.BoundContract // Generic contract wrapper for the low level calls +} + +// RLNFilterer is an auto generated log filtering Go binding around an Ethereum contract events. +type RLNFilterer struct { + contract *bind.BoundContract // Generic contract wrapper for the low level calls +} + +// RLNSession is an auto generated Go binding around an Ethereum contract, +// with pre-set call and transact options. +type RLNSession struct { + Contract *RLN // Generic contract binding to set the session for + CallOpts bind.CallOpts // Call options to use throughout this session + TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session +} + +// RLNCallerSession is an auto generated read-only Go binding around an Ethereum contract, +// with pre-set call options. +type RLNCallerSession struct { + Contract *RLNCaller // Generic contract caller binding to set the session for + CallOpts bind.CallOpts // Call options to use throughout this session +} + +// RLNTransactorSession is an auto generated write-only Go binding around an Ethereum contract, +// with pre-set transact options. +type RLNTransactorSession struct { + Contract *RLNTransactor // Generic contract transactor binding to set the session for + TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session +} + +// RLNRaw is an auto generated low-level Go binding around an Ethereum contract. +type RLNRaw struct { + Contract *RLN // Generic contract binding to access the raw methods on +} + +// RLNCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. +type RLNCallerRaw struct { + Contract *RLNCaller // Generic read-only contract binding to access the raw methods on +} + +// RLNTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. +type RLNTransactorRaw struct { + Contract *RLNTransactor // Generic write-only contract binding to access the raw methods on +} + +// NewRLN creates a new instance of RLN, bound to a specific deployed contract. +func NewRLN(address common.Address, backend bind.ContractBackend) (*RLN, error) { + contract, err := bindRLN(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &RLN{RLNCaller: RLNCaller{contract: contract}, RLNTransactor: RLNTransactor{contract: contract}, RLNFilterer: RLNFilterer{contract: contract}}, nil +} + +// NewRLNCaller creates a new read-only instance of RLN, bound to a specific deployed contract. +func NewRLNCaller(address common.Address, caller bind.ContractCaller) (*RLNCaller, error) { + contract, err := bindRLN(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &RLNCaller{contract: contract}, nil +} + +// NewRLNTransactor creates a new write-only instance of RLN, bound to a specific deployed contract. +func NewRLNTransactor(address common.Address, transactor bind.ContractTransactor) (*RLNTransactor, error) { + contract, err := bindRLN(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &RLNTransactor{contract: contract}, nil +} + +// NewRLNFilterer creates a new log filterer instance of RLN, bound to a specific deployed contract. +func NewRLNFilterer(address common.Address, filterer bind.ContractFilterer) (*RLNFilterer, error) { + contract, err := bindRLN(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &RLNFilterer{contract: contract}, nil +} + +// bindRLN binds a generic wrapper to an already deployed contract. +func bindRLN(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := RLNMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +// Call invokes the (constant) contract method with params as input values and +// sets the output to result. The result type might be a single field for simple +// returns, a slice of interfaces for anonymous returns and a struct for named +// returns. +func (_RLN *RLNRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _RLN.Contract.RLNCaller.contract.Call(opts, result, method, params...) +} + +// Transfer initiates a plain transaction to move funds to the contract, calling +// its default method if one is available. +func (_RLN *RLNRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RLN.Contract.RLNTransactor.contract.Transfer(opts) +} + +// Transact invokes the (paid) contract method with params as input values. +func (_RLN *RLNRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _RLN.Contract.RLNTransactor.contract.Transact(opts, method, params...) +} + +// Call invokes the (constant) contract method with params as input values and +// sets the output to result. The result type might be a single field for simple +// returns, a slice of interfaces for anonymous returns and a struct for named +// returns. +func (_RLN *RLNCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _RLN.Contract.contract.Call(opts, result, method, params...) +} + +// Transfer initiates a plain transaction to move funds to the contract, calling +// its default method if one is available. +func (_RLN *RLNTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RLN.Contract.contract.Transfer(opts) +} + +// Transact invokes the (paid) contract method with params as input values. +func (_RLN *RLNTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _RLN.Contract.contract.Transact(opts, method, params...) +} + +// DEPTH is a free data retrieval call binding the contract method 0x98366e35. +// +// Solidity: function DEPTH() view returns(uint256) +func (_RLN *RLNCaller) DEPTH(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "DEPTH") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +// DEPTH is a free data retrieval call binding the contract method 0x98366e35. +// +// Solidity: function DEPTH() view returns(uint256) +func (_RLN *RLNSession) DEPTH() (*big.Int, error) { + return _RLN.Contract.DEPTH(&_RLN.CallOpts) +} + +// DEPTH is a free data retrieval call binding the contract method 0x98366e35. +// +// Solidity: function DEPTH() view returns(uint256) +func (_RLN *RLNCallerSession) DEPTH() (*big.Int, error) { + return _RLN.Contract.DEPTH(&_RLN.CallOpts) +} + +// MEMBERSHIPDEPOSIT is a free data retrieval call binding the contract method 0xf220b9ec. +// +// Solidity: function MEMBERSHIP_DEPOSIT() view returns(uint256) +func (_RLN *RLNCaller) MEMBERSHIPDEPOSIT(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "MEMBERSHIP_DEPOSIT") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +// MEMBERSHIPDEPOSIT is a free data retrieval call binding the contract method 0xf220b9ec. +// +// Solidity: function MEMBERSHIP_DEPOSIT() view returns(uint256) +func (_RLN *RLNSession) MEMBERSHIPDEPOSIT() (*big.Int, error) { + return _RLN.Contract.MEMBERSHIPDEPOSIT(&_RLN.CallOpts) +} + +// MEMBERSHIPDEPOSIT is a free data retrieval call binding the contract method 0xf220b9ec. +// +// Solidity: function MEMBERSHIP_DEPOSIT() view returns(uint256) +func (_RLN *RLNCallerSession) MEMBERSHIPDEPOSIT() (*big.Int, error) { + return _RLN.Contract.MEMBERSHIPDEPOSIT(&_RLN.CallOpts) +} + +// SETSIZE is a free data retrieval call binding the contract method 0xd0383d68. +// +// Solidity: function SET_SIZE() view returns(uint256) +func (_RLN *RLNCaller) SETSIZE(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "SET_SIZE") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +// SETSIZE is a free data retrieval call binding the contract method 0xd0383d68. +// +// Solidity: function SET_SIZE() view returns(uint256) +func (_RLN *RLNSession) SETSIZE() (*big.Int, error) { + return _RLN.Contract.SETSIZE(&_RLN.CallOpts) +} + +// SETSIZE is a free data retrieval call binding the contract method 0xd0383d68. +// +// Solidity: function SET_SIZE() view returns(uint256) +func (_RLN *RLNCallerSession) SETSIZE() (*big.Int, error) { + return _RLN.Contract.SETSIZE(&_RLN.CallOpts) +} + +// ContractIndex is a free data retrieval call binding the contract method 0x28b070e0. +// +// Solidity: function contractIndex() view returns(uint16) +func (_RLN *RLNCaller) ContractIndex(opts *bind.CallOpts) (uint16, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "contractIndex") + + if err != nil { + return *new(uint16), err + } + + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + + return out0, err + +} + +// ContractIndex is a free data retrieval call binding the contract method 0x28b070e0. +// +// Solidity: function contractIndex() view returns(uint16) +func (_RLN *RLNSession) ContractIndex() (uint16, error) { + return _RLN.Contract.ContractIndex(&_RLN.CallOpts) +} + +// ContractIndex is a free data retrieval call binding the contract method 0x28b070e0. +// +// Solidity: function contractIndex() view returns(uint16) +func (_RLN *RLNCallerSession) ContractIndex() (uint16, error) { + return _RLN.Contract.ContractIndex(&_RLN.CallOpts) +} + +// DeployedBlockNumber is a free data retrieval call binding the contract method 0x4add651e. +// +// Solidity: function deployedBlockNumber() view returns(uint32) +func (_RLN *RLNCaller) DeployedBlockNumber(opts *bind.CallOpts) (uint32, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "deployedBlockNumber") + + if err != nil { + return *new(uint32), err + } + + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + + return out0, err + +} + +// DeployedBlockNumber is a free data retrieval call binding the contract method 0x4add651e. +// +// Solidity: function deployedBlockNumber() view returns(uint32) +func (_RLN *RLNSession) DeployedBlockNumber() (uint32, error) { + return _RLN.Contract.DeployedBlockNumber(&_RLN.CallOpts) +} + +// DeployedBlockNumber is a free data retrieval call binding the contract method 0x4add651e. +// +// Solidity: function deployedBlockNumber() view returns(uint32) +func (_RLN *RLNCallerSession) DeployedBlockNumber() (uint32, error) { + return _RLN.Contract.DeployedBlockNumber(&_RLN.CallOpts) +} + +// IdCommitmentIndex is a free data retrieval call binding the contract method 0xae74552a. +// +// Solidity: function idCommitmentIndex() view returns(uint256) +func (_RLN *RLNCaller) IdCommitmentIndex(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "idCommitmentIndex") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +// IdCommitmentIndex is a free data retrieval call binding the contract method 0xae74552a. +// +// Solidity: function idCommitmentIndex() view returns(uint256) +func (_RLN *RLNSession) IdCommitmentIndex() (*big.Int, error) { + return _RLN.Contract.IdCommitmentIndex(&_RLN.CallOpts) +} + +// IdCommitmentIndex is a free data retrieval call binding the contract method 0xae74552a. +// +// Solidity: function idCommitmentIndex() view returns(uint256) +func (_RLN *RLNCallerSession) IdCommitmentIndex() (*big.Int, error) { + return _RLN.Contract.IdCommitmentIndex(&_RLN.CallOpts) +} + +// IsValidCommitment is a free data retrieval call binding the contract method 0x22d9730c. +// +// Solidity: function isValidCommitment(uint256 idCommitment) view returns(bool) +func (_RLN *RLNCaller) IsValidCommitment(opts *bind.CallOpts, idCommitment *big.Int) (bool, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "isValidCommitment", idCommitment) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +// IsValidCommitment is a free data retrieval call binding the contract method 0x22d9730c. +// +// Solidity: function isValidCommitment(uint256 idCommitment) view returns(bool) +func (_RLN *RLNSession) IsValidCommitment(idCommitment *big.Int) (bool, error) { + return _RLN.Contract.IsValidCommitment(&_RLN.CallOpts, idCommitment) +} + +// IsValidCommitment is a free data retrieval call binding the contract method 0x22d9730c. +// +// Solidity: function isValidCommitment(uint256 idCommitment) view returns(bool) +func (_RLN *RLNCallerSession) IsValidCommitment(idCommitment *big.Int) (bool, error) { + return _RLN.Contract.IsValidCommitment(&_RLN.CallOpts, idCommitment) +} + +// Members is a free data retrieval call binding the contract method 0x5daf08ca. +// +// Solidity: function members(uint256 ) view returns(uint256) +func (_RLN *RLNCaller) Members(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "members", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +// Members is a free data retrieval call binding the contract method 0x5daf08ca. +// +// Solidity: function members(uint256 ) view returns(uint256) +func (_RLN *RLNSession) Members(arg0 *big.Int) (*big.Int, error) { + return _RLN.Contract.Members(&_RLN.CallOpts, arg0) +} + +// Members is a free data retrieval call binding the contract method 0x5daf08ca. +// +// Solidity: function members(uint256 ) view returns(uint256) +func (_RLN *RLNCallerSession) Members(arg0 *big.Int) (*big.Int, error) { + return _RLN.Contract.Members(&_RLN.CallOpts, arg0) +} + +// Owner is a free data retrieval call binding the contract method 0x8da5cb5b. +// +// Solidity: function owner() view returns(address) +func (_RLN *RLNCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "owner") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +// Owner is a free data retrieval call binding the contract method 0x8da5cb5b. +// +// Solidity: function owner() view returns(address) +func (_RLN *RLNSession) Owner() (common.Address, error) { + return _RLN.Contract.Owner(&_RLN.CallOpts) +} + +// Owner is a free data retrieval call binding the contract method 0x8da5cb5b. +// +// Solidity: function owner() view returns(address) +func (_RLN *RLNCallerSession) Owner() (common.Address, error) { + return _RLN.Contract.Owner(&_RLN.CallOpts) +} + +// PoseidonHasher is a free data retrieval call binding the contract method 0x331b6ab3. +// +// Solidity: function poseidonHasher() view returns(address) +func (_RLN *RLNCaller) PoseidonHasher(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "poseidonHasher") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +// PoseidonHasher is a free data retrieval call binding the contract method 0x331b6ab3. +// +// Solidity: function poseidonHasher() view returns(address) +func (_RLN *RLNSession) PoseidonHasher() (common.Address, error) { + return _RLN.Contract.PoseidonHasher(&_RLN.CallOpts) +} + +// PoseidonHasher is a free data retrieval call binding the contract method 0x331b6ab3. +// +// Solidity: function poseidonHasher() view returns(address) +func (_RLN *RLNCallerSession) PoseidonHasher() (common.Address, error) { + return _RLN.Contract.PoseidonHasher(&_RLN.CallOpts) +} + +// Slash is a free data retrieval call binding the contract method 0x8be9b119. +// +// Solidity: function slash(uint256 idCommitment, address receiver, uint256[8] proof) pure returns() +func (_RLN *RLNCaller) Slash(opts *bind.CallOpts, idCommitment *big.Int, receiver common.Address, proof [8]*big.Int) error { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "slash", idCommitment, receiver, proof) + + if err != nil { + return err + } + + return err + +} + +// Slash is a free data retrieval call binding the contract method 0x8be9b119. +// +// Solidity: function slash(uint256 idCommitment, address receiver, uint256[8] proof) pure returns() +func (_RLN *RLNSession) Slash(idCommitment *big.Int, receiver common.Address, proof [8]*big.Int) error { + return _RLN.Contract.Slash(&_RLN.CallOpts, idCommitment, receiver, proof) +} + +// Slash is a free data retrieval call binding the contract method 0x8be9b119. +// +// Solidity: function slash(uint256 idCommitment, address receiver, uint256[8] proof) pure returns() +func (_RLN *RLNCallerSession) Slash(idCommitment *big.Int, receiver common.Address, proof [8]*big.Int) error { + return _RLN.Contract.Slash(&_RLN.CallOpts, idCommitment, receiver, proof) +} + +// StakedAmounts is a free data retrieval call binding the contract method 0xbc499128. +// +// Solidity: function stakedAmounts(uint256 ) view returns(uint256) +func (_RLN *RLNCaller) StakedAmounts(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "stakedAmounts", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +// StakedAmounts is a free data retrieval call binding the contract method 0xbc499128. +// +// Solidity: function stakedAmounts(uint256 ) view returns(uint256) +func (_RLN *RLNSession) StakedAmounts(arg0 *big.Int) (*big.Int, error) { + return _RLN.Contract.StakedAmounts(&_RLN.CallOpts, arg0) +} + +// StakedAmounts is a free data retrieval call binding the contract method 0xbc499128. +// +// Solidity: function stakedAmounts(uint256 ) view returns(uint256) +func (_RLN *RLNCallerSession) StakedAmounts(arg0 *big.Int) (*big.Int, error) { + return _RLN.Contract.StakedAmounts(&_RLN.CallOpts, arg0) +} + +// Verifier is a free data retrieval call binding the contract method 0x2b7ac3f3. +// +// Solidity: function verifier() view returns(address) +func (_RLN *RLNCaller) Verifier(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "verifier") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +// Verifier is a free data retrieval call binding the contract method 0x2b7ac3f3. +// +// Solidity: function verifier() view returns(address) +func (_RLN *RLNSession) Verifier() (common.Address, error) { + return _RLN.Contract.Verifier(&_RLN.CallOpts) +} + +// Verifier is a free data retrieval call binding the contract method 0x2b7ac3f3. +// +// Solidity: function verifier() view returns(address) +func (_RLN *RLNCallerSession) Verifier() (common.Address, error) { + return _RLN.Contract.Verifier(&_RLN.CallOpts) +} + +// Withdraw is a free data retrieval call binding the contract method 0x3ccfd60b. +// +// Solidity: function withdraw() pure returns() +func (_RLN *RLNCaller) Withdraw(opts *bind.CallOpts) error { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "withdraw") + + if err != nil { + return err + } + + return err + +} + +// Withdraw is a free data retrieval call binding the contract method 0x3ccfd60b. +// +// Solidity: function withdraw() pure returns() +func (_RLN *RLNSession) Withdraw() error { + return _RLN.Contract.Withdraw(&_RLN.CallOpts) +} + +// Withdraw is a free data retrieval call binding the contract method 0x3ccfd60b. +// +// Solidity: function withdraw() pure returns() +func (_RLN *RLNCallerSession) Withdraw() error { + return _RLN.Contract.Withdraw(&_RLN.CallOpts) +} + +// WithdrawalBalance is a free data retrieval call binding the contract method 0xc5b208ff. +// +// Solidity: function withdrawalBalance(address ) view returns(uint256) +func (_RLN *RLNCaller) WithdrawalBalance(opts *bind.CallOpts, arg0 common.Address) (*big.Int, error) { + var out []interface{} + err := _RLN.contract.Call(opts, &out, "withdrawalBalance", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +// WithdrawalBalance is a free data retrieval call binding the contract method 0xc5b208ff. +// +// Solidity: function withdrawalBalance(address ) view returns(uint256) +func (_RLN *RLNSession) WithdrawalBalance(arg0 common.Address) (*big.Int, error) { + return _RLN.Contract.WithdrawalBalance(&_RLN.CallOpts, arg0) +} + +// WithdrawalBalance is a free data retrieval call binding the contract method 0xc5b208ff. +// +// Solidity: function withdrawalBalance(address ) view returns(uint256) +func (_RLN *RLNCallerSession) WithdrawalBalance(arg0 common.Address) (*big.Int, error) { + return _RLN.Contract.WithdrawalBalance(&_RLN.CallOpts, arg0) +} + +// Register is a paid mutator transaction binding the contract method 0x7a34289d. +// +// Solidity: function register(uint256[] idCommitments) returns() +func (_RLN *RLNTransactor) Register(opts *bind.TransactOpts, idCommitments []*big.Int) (*types.Transaction, error) { + return _RLN.contract.Transact(opts, "register", idCommitments) +} + +// Register is a paid mutator transaction binding the contract method 0x7a34289d. +// +// Solidity: function register(uint256[] idCommitments) returns() +func (_RLN *RLNSession) Register(idCommitments []*big.Int) (*types.Transaction, error) { + return _RLN.Contract.Register(&_RLN.TransactOpts, idCommitments) +} + +// Register is a paid mutator transaction binding the contract method 0x7a34289d. +// +// Solidity: function register(uint256[] idCommitments) returns() +func (_RLN *RLNTransactorSession) Register(idCommitments []*big.Int) (*types.Transaction, error) { + return _RLN.Contract.Register(&_RLN.TransactOpts, idCommitments) +} + +// Register0 is a paid mutator transaction binding the contract method 0xf207564e. +// +// Solidity: function register(uint256 idCommitment) payable returns() +func (_RLN *RLNTransactor) Register0(opts *bind.TransactOpts, idCommitment *big.Int) (*types.Transaction, error) { + return _RLN.contract.Transact(opts, "register0", idCommitment) +} + +// Register0 is a paid mutator transaction binding the contract method 0xf207564e. +// +// Solidity: function register(uint256 idCommitment) payable returns() +func (_RLN *RLNSession) Register0(idCommitment *big.Int) (*types.Transaction, error) { + return _RLN.Contract.Register0(&_RLN.TransactOpts, idCommitment) +} + +// Register0 is a paid mutator transaction binding the contract method 0xf207564e. +// +// Solidity: function register(uint256 idCommitment) payable returns() +func (_RLN *RLNTransactorSession) Register0(idCommitment *big.Int) (*types.Transaction, error) { + return _RLN.Contract.Register0(&_RLN.TransactOpts, idCommitment) +} + +// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. +// +// Solidity: function renounceOwnership() returns() +func (_RLN *RLNTransactor) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RLN.contract.Transact(opts, "renounceOwnership") +} + +// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. +// +// Solidity: function renounceOwnership() returns() +func (_RLN *RLNSession) RenounceOwnership() (*types.Transaction, error) { + return _RLN.Contract.RenounceOwnership(&_RLN.TransactOpts) +} + +// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. +// +// Solidity: function renounceOwnership() returns() +func (_RLN *RLNTransactorSession) RenounceOwnership() (*types.Transaction, error) { + return _RLN.Contract.RenounceOwnership(&_RLN.TransactOpts) +} + +// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. +// +// Solidity: function transferOwnership(address newOwner) returns() +func (_RLN *RLNTransactor) TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error) { + return _RLN.contract.Transact(opts, "transferOwnership", newOwner) +} + +// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. +// +// Solidity: function transferOwnership(address newOwner) returns() +func (_RLN *RLNSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { + return _RLN.Contract.TransferOwnership(&_RLN.TransactOpts, newOwner) +} + +// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. +// +// Solidity: function transferOwnership(address newOwner) returns() +func (_RLN *RLNTransactorSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { + return _RLN.Contract.TransferOwnership(&_RLN.TransactOpts, newOwner) +} + +// RLNMemberRegisteredIterator is returned from FilterMemberRegistered and is used to iterate over the raw logs and unpacked data for MemberRegistered events raised by the RLN contract. +type RLNMemberRegisteredIterator struct { + Event *RLNMemberRegistered // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RLNMemberRegisteredIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RLNMemberRegistered) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RLNMemberRegistered) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RLNMemberRegisteredIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RLNMemberRegisteredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RLNMemberRegistered represents a MemberRegistered event raised by the RLN contract. +type RLNMemberRegistered struct { + IdCommitment *big.Int + Index *big.Int + Raw types.Log // Blockchain specific contextual infos +} + +// FilterMemberRegistered is a free log retrieval operation binding the contract event 0x5a92c2530f207992057b9c3e544108ffce3beda4a63719f316967c49bf6159d2. +// +// Solidity: event MemberRegistered(uint256 idCommitment, uint256 index) +func (_RLN *RLNFilterer) FilterMemberRegistered(opts *bind.FilterOpts) (*RLNMemberRegisteredIterator, error) { + + logs, sub, err := _RLN.contract.FilterLogs(opts, "MemberRegistered") + if err != nil { + return nil, err + } + return &RLNMemberRegisteredIterator{contract: _RLN.contract, event: "MemberRegistered", logs: logs, sub: sub}, nil +} + +// WatchMemberRegistered is a free log subscription operation binding the contract event 0x5a92c2530f207992057b9c3e544108ffce3beda4a63719f316967c49bf6159d2. +// +// Solidity: event MemberRegistered(uint256 idCommitment, uint256 index) +func (_RLN *RLNFilterer) WatchMemberRegistered(opts *bind.WatchOpts, sink chan<- *RLNMemberRegistered) (event.Subscription, error) { + + logs, sub, err := _RLN.contract.WatchLogs(opts, "MemberRegistered") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RLNMemberRegistered) + if err := _RLN.contract.UnpackLog(event, "MemberRegistered", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseMemberRegistered is a log parse operation binding the contract event 0x5a92c2530f207992057b9c3e544108ffce3beda4a63719f316967c49bf6159d2. +// +// Solidity: event MemberRegistered(uint256 idCommitment, uint256 index) +func (_RLN *RLNFilterer) ParseMemberRegistered(log types.Log) (*RLNMemberRegistered, error) { + event := new(RLNMemberRegistered) + if err := _RLN.contract.UnpackLog(event, "MemberRegistered", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +// RLNMemberWithdrawnIterator is returned from FilterMemberWithdrawn and is used to iterate over the raw logs and unpacked data for MemberWithdrawn events raised by the RLN contract. +type RLNMemberWithdrawnIterator struct { + Event *RLNMemberWithdrawn // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RLNMemberWithdrawnIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RLNMemberWithdrawn) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RLNMemberWithdrawn) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RLNMemberWithdrawnIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RLNMemberWithdrawnIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RLNMemberWithdrawn represents a MemberWithdrawn event raised by the RLN contract. +type RLNMemberWithdrawn struct { + IdCommitment *big.Int + Index *big.Int + Raw types.Log // Blockchain specific contextual infos +} + +// FilterMemberWithdrawn is a free log retrieval operation binding the contract event 0x62ec3a516d22a993ce5cb4e7593e878c74f4d799dde522a88dc27a994fd5a943. +// +// Solidity: event MemberWithdrawn(uint256 idCommitment, uint256 index) +func (_RLN *RLNFilterer) FilterMemberWithdrawn(opts *bind.FilterOpts) (*RLNMemberWithdrawnIterator, error) { + + logs, sub, err := _RLN.contract.FilterLogs(opts, "MemberWithdrawn") + if err != nil { + return nil, err + } + return &RLNMemberWithdrawnIterator{contract: _RLN.contract, event: "MemberWithdrawn", logs: logs, sub: sub}, nil +} + +// WatchMemberWithdrawn is a free log subscription operation binding the contract event 0x62ec3a516d22a993ce5cb4e7593e878c74f4d799dde522a88dc27a994fd5a943. +// +// Solidity: event MemberWithdrawn(uint256 idCommitment, uint256 index) +func (_RLN *RLNFilterer) WatchMemberWithdrawn(opts *bind.WatchOpts, sink chan<- *RLNMemberWithdrawn) (event.Subscription, error) { + + logs, sub, err := _RLN.contract.WatchLogs(opts, "MemberWithdrawn") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RLNMemberWithdrawn) + if err := _RLN.contract.UnpackLog(event, "MemberWithdrawn", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseMemberWithdrawn is a log parse operation binding the contract event 0x62ec3a516d22a993ce5cb4e7593e878c74f4d799dde522a88dc27a994fd5a943. +// +// Solidity: event MemberWithdrawn(uint256 idCommitment, uint256 index) +func (_RLN *RLNFilterer) ParseMemberWithdrawn(log types.Log) (*RLNMemberWithdrawn, error) { + event := new(RLNMemberWithdrawn) + if err := _RLN.contract.UnpackLog(event, "MemberWithdrawn", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +// RLNOwnershipTransferredIterator is returned from FilterOwnershipTransferred and is used to iterate over the raw logs and unpacked data for OwnershipTransferred events raised by the RLN contract. +type RLNOwnershipTransferredIterator struct { + Event *RLNOwnershipTransferred // Event containing the contract specifics and raw log + + contract *bind.BoundContract // Generic contract to use for unpacking event data + event string // Event name to use for unpacking event data + + logs chan types.Log // Log channel receiving the found contract events + sub ethereum.Subscription // Subscription for errors, completion and termination + done bool // Whether the subscription completed delivering logs + fail error // Occurred error to stop iteration +} + +// Next advances the iterator to the subsequent event, returning whether there +// are any more events found. In case of a retrieval or parsing error, false is +// returned and Error() can be queried for the exact failure. +func (it *RLNOwnershipTransferredIterator) Next() bool { + // If the iterator failed, stop iterating + if it.fail != nil { + return false + } + // If the iterator completed, deliver directly whatever's available + if it.done { + select { + case log := <-it.logs: + it.Event = new(RLNOwnershipTransferred) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + // Iterator still in progress, wait for either a data or an error event + select { + case log := <-it.logs: + it.Event = new(RLNOwnershipTransferred) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +// Error returns any retrieval or parsing error occurred during filtering. +func (it *RLNOwnershipTransferredIterator) Error() error { + return it.fail +} + +// Close terminates the iteration process, releasing any pending underlying +// resources. +func (it *RLNOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +// RLNOwnershipTransferred represents a OwnershipTransferred event raised by the RLN contract. +type RLNOwnershipTransferred struct { + PreviousOwner common.Address + NewOwner common.Address + Raw types.Log // Blockchain specific contextual infos +} + +// FilterOwnershipTransferred is a free log retrieval operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0. +// +// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner) +func (_RLN *RLNFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, previousOwner []common.Address, newOwner []common.Address) (*RLNOwnershipTransferredIterator, error) { + + var previousOwnerRule []interface{} + for _, previousOwnerItem := range previousOwner { + previousOwnerRule = append(previousOwnerRule, previousOwnerItem) + } + var newOwnerRule []interface{} + for _, newOwnerItem := range newOwner { + newOwnerRule = append(newOwnerRule, newOwnerItem) + } + + logs, sub, err := _RLN.contract.FilterLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) + if err != nil { + return nil, err + } + return &RLNOwnershipTransferredIterator{contract: _RLN.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +// WatchOwnershipTransferred is a free log subscription operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0. +// +// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner) +func (_RLN *RLNFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *RLNOwnershipTransferred, previousOwner []common.Address, newOwner []common.Address) (event.Subscription, error) { + + var previousOwnerRule []interface{} + for _, previousOwnerItem := range previousOwner { + previousOwnerRule = append(previousOwnerRule, previousOwnerItem) + } + var newOwnerRule []interface{} + for _, newOwnerItem := range newOwner { + newOwnerRule = append(newOwnerRule, newOwnerItem) + } + + logs, sub, err := _RLN.contract.WatchLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + // New log arrived, parse the event and forward to the user + event := new(RLNOwnershipTransferred) + if err := _RLN.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +// ParseOwnershipTransferred is a log parse operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0. +// +// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner) +func (_RLN *RLNFilterer) ParseOwnershipTransferred(log types.Log) (*RLNOwnershipTransferred, error) { + event := new(RLNOwnershipTransferred) + if err := _RLN.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} diff --git a/waku/v2/protocol/rln/contracts/waku-rln-contract b/waku/v2/protocol/rln/contracts/waku-rln-contract new file mode 160000 index 00000000..63a7856e --- /dev/null +++ b/waku/v2/protocol/rln/contracts/waku-rln-contract @@ -0,0 +1 @@ +Subproject commit 63a7856eb29f08644d1e963e3edfc2c182469257