diff --git a/.gitmodules b/.gitmodules index 8315de1190..083c521ccc 100644 --- a/.gitmodules +++ b/.gitmodules @@ -2,6 +2,6 @@ path = tests/tests url = https://github.com/ethereum/tests.git shallow = true -[submodule "core-contracts"] - path = core-contracts - url = https://github.com/0xPolygon/core-contracts +[submodule "blade-contracts"] + path = blade-contracts + url = https://github.com/Ethernal-Tech/blade-contracts diff --git a/Makefile b/Makefile index 7cf889e935..c83d4526bd 100644 --- a/Makefile +++ b/Makefile @@ -81,9 +81,9 @@ test-property-polybft: check-go env EDGE_BINARY=${PWD}/artifacts/blade E2E_TESTS=true E2E_LOGS=true go test -v -timeout=30m ./e2e-polybft/property/... \ -rapid.checks=10 -.PHONY: compile-core-contracts -compile-core-contracts: check-npm - cd core-contracts && npm install && npm run compile +.PHONY: compile-blade-contracts +compile-blade-contracts: check-npm + cd blade-contracts && npm install && npm run compile $(MAKE) generate-smart-contract-bindings .PHONY: generate-smart-contract-bindings @@ -117,7 +117,7 @@ help: @printf " %-35s - %s\n" "test-e2e" "Run end-to-end tests" @printf " %-35s - %s\n" "test-e2e-polybft" "Run end-to-end tests for PolyBFT" @printf " %-35s - %s\n" "test-property-polybft" "Run property tests for PolyBFT" - @printf " %-35s - %s\n" "compile-core-contracts" "Compile core contracts" + @printf " %-35s - %s\n" "compile-blade-contracts" "Compile blade contracts" @printf " %-35s - %s\n" "generate-smart-contract-bindings" "Generate smart contract bindings" @printf " %-35s - %s\n" "run-docker" "Run Docker cluster for PolyBFT" @printf " %-35s - %s\n" "stop-docker" "Stop Docker cluster for PolyBFT" diff --git a/blade-contracts b/blade-contracts new file mode 160000 index 0000000000..de420a2678 --- /dev/null +++ b/blade-contracts @@ -0,0 +1 @@ +Subproject commit de420a2678ef3a4651a0ae39a681894c5af7360e diff --git a/chain/params.go b/chain/params.go index 8969ea4c2b..ab143ebb3c 100644 --- a/chain/params.go +++ b/chain/params.go @@ -78,18 +78,15 @@ func (p *Params) GetEngine() string { // predefined forks const ( - Homestead = "homestead" - Byzantium = "byzantium" - Constantinople = "constantinople" - Petersburg = "petersburg" - Istanbul = "istanbul" - London = "london" - EIP150 = "EIP150" - EIP158 = "EIP158" - EIP155 = "EIP155" - QuorumCalcAlignment = "quorumcalcalignment" - TxHashWithType = "txHashWithType" - LondonFix = "londonfix" + Homestead = "homestead" + Byzantium = "byzantium" + Constantinople = "constantinople" + Petersburg = "petersburg" + Istanbul = "istanbul" + London = "london" + EIP150 = "EIP150" + EIP158 = "EIP158" + EIP155 = "EIP155" ) // Forks is map which contains all forks and their starting blocks from genesis @@ -116,18 +113,15 @@ func (f *Forks) RemoveFork(name string) *Forks { // At returns ForksInTime instance that shows which supported forks are enabled for the block func (f *Forks) At(block uint64) ForksInTime { return ForksInTime{ - Homestead: f.IsActive(Homestead, block), - Byzantium: f.IsActive(Byzantium, block), - Constantinople: f.IsActive(Constantinople, block), - Petersburg: f.IsActive(Petersburg, block), - Istanbul: f.IsActive(Istanbul, block), - London: f.IsActive(London, block), - EIP150: f.IsActive(EIP150, block), - EIP158: f.IsActive(EIP158, block), - EIP155: f.IsActive(EIP155, block), - QuorumCalcAlignment: f.IsActive(QuorumCalcAlignment, block), - TxHashWithType: f.IsActive(TxHashWithType, block), - LondonFix: f.IsActive(LondonFix, block), + Homestead: f.IsActive(Homestead, block), + Byzantium: f.IsActive(Byzantium, block), + Constantinople: f.IsActive(Constantinople, block), + Petersburg: f.IsActive(Petersburg, block), + Istanbul: f.IsActive(Istanbul, block), + London: f.IsActive(London, block), + EIP150: f.IsActive(EIP150, block), + EIP158: f.IsActive(EIP158, block), + EIP155: f.IsActive(EIP155, block), } } @@ -177,24 +171,18 @@ type ForksInTime struct { London, EIP150, EIP158, - EIP155, - QuorumCalcAlignment, - TxHashWithType, - LondonFix bool + EIP155 bool } // AllForksEnabled should contain all supported forks by current edge version var AllForksEnabled = &Forks{ - Homestead: NewFork(0), - EIP150: NewFork(0), - EIP155: NewFork(0), - EIP158: NewFork(0), - Byzantium: NewFork(0), - Constantinople: NewFork(0), - Petersburg: NewFork(0), - Istanbul: NewFork(0), - London: NewFork(0), - QuorumCalcAlignment: NewFork(0), - TxHashWithType: NewFork(0), - LondonFix: NewFork(0), + Homestead: NewFork(0), + EIP150: NewFork(0), + EIP155: NewFork(0), + EIP158: NewFork(0), + Byzantium: NewFork(0), + Constantinople: NewFork(0), + Petersburg: NewFork(0), + Istanbul: NewFork(0), + London: NewFork(0), } diff --git a/command/bridge/bridge.go b/command/bridge/bridge.go index de826ac67e..9b41862b01 100644 --- a/command/bridge/bridge.go +++ b/command/bridge/bridge.go @@ -3,11 +3,13 @@ package bridge import ( "github.com/spf13/cobra" + deploy "github.com/0xPolygon/polygon-edge/command/bridge/deploy" depositERC1155 "github.com/0xPolygon/polygon-edge/command/bridge/deposit/erc1155" depositERC20 "github.com/0xPolygon/polygon-edge/command/bridge/deposit/erc20" depositERC721 "github.com/0xPolygon/polygon-edge/command/bridge/deposit/erc721" "github.com/0xPolygon/polygon-edge/command/bridge/exit" - "github.com/0xPolygon/polygon-edge/command/bridge/mint" + "github.com/0xPolygon/polygon-edge/command/bridge/fund" + "github.com/0xPolygon/polygon-edge/command/bridge/server" withdrawERC1155 "github.com/0xPolygon/polygon-edge/command/bridge/withdraw/erc1155" withdrawERC20 "github.com/0xPolygon/polygon-edge/command/bridge/withdraw/erc20" withdrawERC721 "github.com/0xPolygon/polygon-edge/command/bridge/withdraw/erc721" @@ -41,7 +43,11 @@ func registerSubcommands(baseCmd *cobra.Command) { withdrawERC1155.GetCommand(), // bridge exit exit.GetCommand(), - // bridge mint erc-20 - mint.GetCommand(), + // bridge deploy + deploy.GetCommand(), + // bridge server + server.GetCommand(), + // bridge fund + fund.GetCommand(), ) } diff --git a/command/rootchain/deploy/deploy.go b/command/bridge/deploy/deploy.go similarity index 77% rename from command/rootchain/deploy/deploy.go rename to command/bridge/deploy/deploy.go index 4aef877289..7a6575e6bd 100644 --- a/command/rootchain/deploy/deploy.go +++ b/command/bridge/deploy/deploy.go @@ -2,8 +2,8 @@ package deploy import ( "context" - "errors" "fmt" + "math/big" "sync" "github.com/spf13/cobra" @@ -13,12 +13,11 @@ import ( "github.com/0xPolygon/polygon-edge/chain" "github.com/0xPolygon/polygon-edge/command" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" cmdHelper "github.com/0xPolygon/polygon-edge/command/helper" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi/artifact" - "github.com/0xPolygon/polygon-edge/consensus/polybft/signer" "github.com/0xPolygon/polygon-edge/consensus/polybft/validator" "github.com/0xPolygon/polygon-edge/contracts" "github.com/0xPolygon/polygon-edge/txrelayer" @@ -26,7 +25,7 @@ import ( ) const ( - contractsDeploymentTitle = "[ROOTCHAIN - CONTRACTS DEPLOYMENT]" + contractsDeploymentTitle = "[BRIDGE - CONTRACTS DEPLOYMENT]" ProxySufix = "Proxy" stateSenderName = "StateSender" @@ -36,7 +35,6 @@ const ( exitHelperName = "ExitHelper" rootERC20PredicateName = "RootERC20Predicate" childERC20MintablePredicateName = "ChildERC20MintablePredicate" - rootERC20Name = "RootERC20" erc20TemplateName = "ERC20Template" rootERC721PredicateName = "RootERC721Predicate" childERC721MintablePredicateName = "ChildERC721MintablePredicate" @@ -44,8 +42,6 @@ const ( rootERC1155PredicateName = "RootERC1155Predicate" childERC1155MintablePredicateName = "ChildERC1155MintablePredicate" erc1155TemplateName = "ERC1155Template" - customSupernetManagerName = "CustomSupernetManager" - stakeManagerName = "StakeManager" ) var ( @@ -80,9 +76,6 @@ var ( rootchainConfig *polybft.RootchainConfig, addr types.Address) { rootchainConfig.ChildMintableERC20PredicateAddress = addr }, - rootERC20Name: func(rootchainConfig *polybft.RootchainConfig, addr types.Address) { - rootchainConfig.RootNativeERC20Address = addr - }, erc20TemplateName: func(rootchainConfig *polybft.RootchainConfig, addr types.Address) { rootchainConfig.ChildERC20Address = addr }, @@ -106,36 +99,39 @@ var ( erc1155TemplateName: func(rootchainConfig *polybft.RootchainConfig, addr types.Address) { rootchainConfig.ChildERC1155Address = addr }, - getProxyNameForImpl(customSupernetManagerName): func(rootchainConfig *polybft.RootchainConfig, addr types.Address) { - rootchainConfig.CustomSupernetManagerAddress = addr - }, } // initializersMap maps rootchain contract names to initializer function callbacks initializersMap = map[string]func(command.OutputFormatter, txrelayer.TxRelayer, - *polybft.RootchainConfig, ethgo.Key) error{ - getProxyNameForImpl(customSupernetManagerName): func(fmt command.OutputFormatter, + []*validator.GenesisValidator, + *polybft.RootchainConfig, ethgo.Key, int64) error{ + getProxyNameForImpl(checkpointManagerName): func(fmt command.OutputFormatter, relayer txrelayer.TxRelayer, + genesisValidators []*validator.GenesisValidator, config *polybft.RootchainConfig, - key ethgo.Key) error { - initParams := &contractsapi.InitializeCustomSupernetManagerFn{ - NewStakeManager: config.StakeManagerAddress, - NewBls: config.BLSAddress, - NewStateSender: config.StateSenderAddress, - NewMatic: types.StringToAddress(params.stakeTokenAddr), - NewChildValidatorSet: contracts.ValidatorSetContract, - NewExitHelper: config.ExitHelperAddress, - NewDomain: signer.DomainValidatorSetString, - NewRootERC20Predicate: config.RootERC20PredicateAddress, + key ethgo.Key, + chainID int64) error { + validatorSet, err := getValidatorSetForCheckpointManager(fmt, genesisValidators) + if err != nil { + return err } - return initContract(fmt, relayer, initParams, - config.CustomSupernetManagerAddress, customSupernetManagerName, key) + inputParams := &contractsapi.InitializeCheckpointManagerFn{ + NewBls: config.BLSAddress, + NewBn256G2: config.BN256G2Address, + ChainID_: big.NewInt(chainID), + NewValidatorSet: validatorSet, + } + + return initContract(fmt, relayer, inputParams, config.CheckpointManagerAddress, + checkpointManagerName, key) }, getProxyNameForImpl(exitHelperName): func(fmt command.OutputFormatter, relayer txrelayer.TxRelayer, + genesisValidators []*validator.GenesisValidator, config *polybft.RootchainConfig, - key ethgo.Key) error { + key ethgo.Key, + chainID int64) error { inputParams := &contractsapi.InitializeExitHelperFn{ NewCheckpointManager: config.CheckpointManagerAddress, } @@ -144,16 +140,17 @@ var ( }, getProxyNameForImpl(rootERC20PredicateName): func(fmt command.OutputFormatter, relayer txrelayer.TxRelayer, + genesisValidators []*validator.GenesisValidator, config *polybft.RootchainConfig, - key ethgo.Key) error { - + key ethgo.Key, + chainID int64) error { inputParams := &contractsapi.InitializeRootERC20PredicateFn{ NewStateSender: config.StateSenderAddress, NewExitHelper: config.ExitHelperAddress, NewChildERC20Predicate: contracts.ChildERC20PredicateContract, NewChildTokenTemplate: contracts.ChildERC20Contract, // map root native token address should be non-zero only if native token is non-mintable on a childchain - NewNativeTokenRoot: config.RootNativeERC20Address, + NewNativeTokenRoot: types.ZeroAddress, } return initContract(fmt, relayer, inputParams, @@ -161,8 +158,10 @@ var ( }, getProxyNameForImpl(childERC20MintablePredicateName): func(fmt command.OutputFormatter, relayer txrelayer.TxRelayer, + genesisValidators []*validator.GenesisValidator, config *polybft.RootchainConfig, - key ethgo.Key) error { + key ethgo.Key, + chainID int64) error { initParams := &contractsapi.InitializeChildMintableERC20PredicateFn{ NewStateSender: config.StateSenderAddress, NewExitHelper: config.ExitHelperAddress, @@ -175,8 +174,10 @@ var ( }, getProxyNameForImpl(rootERC721PredicateName): func(fmt command.OutputFormatter, relayer txrelayer.TxRelayer, + genesisValidators []*validator.GenesisValidator, config *polybft.RootchainConfig, - key ethgo.Key) error { + key ethgo.Key, + chainID int64) error { initParams := &contractsapi.InitializeRootERC721PredicateFn{ NewStateSender: config.StateSenderAddress, NewExitHelper: config.ExitHelperAddress, @@ -189,8 +190,10 @@ var ( }, getProxyNameForImpl(childERC721MintablePredicateName): func(fmt command.OutputFormatter, relayer txrelayer.TxRelayer, + genesisValidators []*validator.GenesisValidator, config *polybft.RootchainConfig, - key ethgo.Key) error { + key ethgo.Key, + chainID int64) error { initParams := &contractsapi.InitializeChildMintableERC721PredicateFn{ NewStateSender: config.StateSenderAddress, NewExitHelper: config.ExitHelperAddress, @@ -203,8 +206,10 @@ var ( }, getProxyNameForImpl(rootERC1155PredicateName): func(fmt command.OutputFormatter, relayer txrelayer.TxRelayer, + genesisValidators []*validator.GenesisValidator, config *polybft.RootchainConfig, - key ethgo.Key) error { + key ethgo.Key, + chainID int64) error { initParams := &contractsapi.InitializeRootERC1155PredicateFn{ NewStateSender: config.StateSenderAddress, NewExitHelper: config.ExitHelperAddress, @@ -217,8 +222,10 @@ var ( }, getProxyNameForImpl(childERC1155MintablePredicateName): func(fmt command.OutputFormatter, relayer txrelayer.TxRelayer, + genesisValidators []*validator.GenesisValidator, config *polybft.RootchainConfig, - key ethgo.Key) error { + key ethgo.Key, + chainID int64) error { initParams := &contractsapi.InitializeChildMintableERC1155PredicateFn{ NewStateSender: config.StateSenderAddress, NewExitHelper: config.ExitHelperAddress, @@ -234,11 +241,10 @@ var ( type deploymentResultInfo struct { RootchainCfg *polybft.RootchainConfig - SupernetID int64 CommandResults []command.CommandResult } -// GetCommand returns the rootchain deploy command +// GetCommand returns the bridge deploy command func GetCommand() *cobra.Command { cmd := &cobra.Command{ Use: "deploy", @@ -268,13 +274,6 @@ func GetCommand() *cobra.Command { "the JSON RPC rootchain IP address", ) - cmd.Flags().StringVar( - ¶ms.rootERC20TokenAddr, - erc20AddrFlag, - "", - "existing root chain root native token address", - ) - cmd.Flags().BoolVar( ¶ms.isTestMode, helper.TestModeFlag, @@ -283,20 +282,6 @@ func GetCommand() *cobra.Command { " (otherwise provided secrets are used to resolve deployer account)", ) - cmd.Flags().StringVar( - ¶ms.stakeTokenAddr, - helper.StakeTokenFlag, - "", - helper.StakeTokenFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.stakeManagerAddr, - helper.StakeManagerFlag, - "", - helper.StakeManagerFlagDesc, - ) - cmd.Flags().StringVar( ¶ms.proxyContractsAdmin, helper.ProxyContractsAdminFlag, @@ -305,8 +290,6 @@ func GetCommand() *cobra.Command { ) cmd.MarkFlagsMutuallyExclusive(helper.TestModeFlag, deployerKeyFlag) - _ = cmd.MarkFlagRequired(helper.StakeManagerFlag) - _ = cmd.MarkFlagRequired(helper.StakeTokenFlag) return cmd } @@ -373,20 +356,11 @@ func runCommand(cmd *cobra.Command, _ []string) { } // populate bridge configuration - bridgeConfig := deploymentResultInfo.RootchainCfg.ToBridgeConfig() - if consensusCfg.Bridge != nil { - // only true if stake-manager-deploy command was executed - // users can still deploy stake manager manually - // only used for e2e tests - bridgeConfig.StakeTokenAddr = consensusCfg.Bridge.StakeTokenAddr - } - - consensusCfg.Bridge = bridgeConfig + consensusCfg.Bridge = deploymentResultInfo.RootchainCfg.ToBridgeConfig() consensusCfg.Bridge.EventTrackerStartBlocks = map[types.Address]uint64{ deploymentResultInfo.RootchainCfg.StateSenderAddress: blockNum, } - consensusCfg.SupernetID = deploymentResultInfo.SupernetID // write updated consensus configuration chainConfig.Params.Engine[polybft.ConsensusName] = consensusCfg @@ -409,13 +383,13 @@ func deployContracts(outputter command.OutputFormatter, client *jsonrpc.Client, initialValidators []*validator.GenesisValidator, cmdCtx context.Context) (deploymentResultInfo, error) { txRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithClient(client), txrelayer.WithWriter(outputter)) if err != nil { - return deploymentResultInfo{RootchainCfg: nil, SupernetID: 0, CommandResults: nil}, + return deploymentResultInfo{RootchainCfg: nil, CommandResults: nil}, fmt.Errorf("failed to initialize tx relayer: %w", err) } deployerKey, err := helper.DecodePrivateKey(params.deployerKey) if err != nil { - return deploymentResultInfo{RootchainCfg: nil, SupernetID: 0, CommandResults: nil}, + return deploymentResultInfo{RootchainCfg: nil, CommandResults: nil}, fmt.Errorf("failed to initialize deployer key: %w", err) } @@ -424,7 +398,7 @@ func deployContracts(outputter command.OutputFormatter, client *jsonrpc.Client, txn := helper.CreateTransaction(ethgo.ZeroAddress, &deployerAddr, nil, ethgo.Ether(1), true) if _, err = txRelayer.SendTransactionLocal(txn); err != nil { - return deploymentResultInfo{RootchainCfg: nil, SupernetID: 0, CommandResults: nil}, err + return deploymentResultInfo{RootchainCfg: nil, CommandResults: nil}, err } } @@ -435,28 +409,7 @@ func deployContracts(outputter command.OutputFormatter, client *jsonrpc.Client, byteCodeBuilder func() ([]byte, error) } - rootchainConfig := &polybft.RootchainConfig{ - JSONRPCAddr: params.jsonRPCAddress, - // update stake manager address in genesis in case if stake manager was deployed manually - StakeManagerAddress: types.StringToAddress(params.stakeManagerAddr), - } - - tokenContracts := []*contractInfo{} - - // deploy root ERC20 token only if non-mintable native token flavor is used on a child chain - if !consensusCfg.NativeTokenConfig.IsMintable { - if params.rootERC20TokenAddr != "" { - // use existing root chain ERC20 token - if err := populateExistingTokenAddr(client.Eth(), - params.rootERC20TokenAddr, rootERC20Name, rootchainConfig); err != nil { - return deploymentResultInfo{RootchainCfg: nil, SupernetID: 0, CommandResults: nil}, err - } - } else { - // deploy MockERC20 as a root chain root native token - tokenContracts = append(tokenContracts, - &contractInfo{name: rootERC20Name, artifact: contractsapi.RootERC20}) - } - } + rootchainConfig := &polybft.RootchainConfig{JSONRPCAddr: params.jsonRPCAddress} allContracts := []*contractInfo{ { @@ -537,15 +490,8 @@ func deployContracts(outputter command.OutputFormatter, client *jsonrpc.Client, name: erc1155TemplateName, artifact: contractsapi.ChildERC1155, }, - { - name: customSupernetManagerName, - artifact: contractsapi.CustomSupernetManager, - hasProxy: true, - }, } - allContracts = append(tokenContracts, allContracts...) - g, ctx := errgroup.WithContext(cmdCtx) results := make(map[string]*deployContractResult, len(allContracts)) resultsLock := sync.Mutex{} @@ -649,24 +595,17 @@ func deployContracts(outputter command.OutputFormatter, client *jsonrpc.Client, case <-cmdCtx.Done(): return cmdCtx.Err() default: - return initializer(outputter, txRelayer, rootchainConfig, deployerKey) + return initializer(outputter, txRelayer, initialValidators, rootchainConfig, deployerKey, chainID) } }) } if err := g.Wait(); err != nil { - return deploymentResultInfo{RootchainCfg: nil, SupernetID: 0, CommandResults: nil}, err - } - - // register supernets manager on stake manager - supernetID, err := registerChainOnStakeManager(txRelayer, rootchainConfig, deployerKey) - if err != nil { - return deploymentResultInfo{RootchainCfg: nil, SupernetID: 0, CommandResults: nil}, err + return deploymentResultInfo{RootchainCfg: nil, CommandResults: nil}, err } return deploymentResultInfo{ RootchainCfg: rootchainConfig, - SupernetID: supernetID, CommandResults: commandResults}, nil } @@ -693,53 +632,6 @@ func populateExistingTokenAddr(eth *jsonrpc.Eth, tokenAddr, tokenName string, return nil } -// registerChainOnStakeManager registers child chain and its supernet manager on rootchain -func registerChainOnStakeManager(txRelayer txrelayer.TxRelayer, - rootchainCfg *polybft.RootchainConfig, deployerKey ethgo.Key) (int64, error) { - registerChainFn := &contractsapi.RegisterChildChainStakeManagerFn{ - Manager: rootchainCfg.CustomSupernetManagerAddress, - } - - encoded, err := registerChainFn.EncodeAbi() - if err != nil { - return 0, fmt.Errorf("failed to encode parameters for registering child chain on supernets. error: %w", err) - } - - receipt, err := helper.SendTransaction(txRelayer, ethgo.Address(rootchainCfg.StakeManagerAddress), - encoded, stakeManagerName, deployerKey) - if err != nil { - return 0, err - } - - var ( - childChainRegisteredEvent contractsapi.ChildManagerRegisteredEvent - found bool - supernetID int64 - ) - - for _, log := range receipt.Logs { - doesMatch, err := childChainRegisteredEvent.ParseLog(log) - if err != nil { - return 0, err - } - - if !doesMatch { - continue - } - - supernetID = childChainRegisteredEvent.ID.Int64() - found = true - - break - } - - if !found { - return 0, errors.New("could not find a log that child chain was registered on stake manager") - } - - return supernetID, nil -} - // initContract initializes arbitrary contract with given parameters deployed on a given address func initContract(cmdOutput command.OutputFormatter, txRelayer txrelayer.TxRelayer, initInputFn contractsapi.StateTransactionInput, contractAddr types.Address, @@ -765,7 +657,7 @@ func initContract(cmdOutput command.OutputFormatter, txRelayer txrelayer.TxRelay func collectResultsOnError(results map[string]*deployContractResult) deploymentResultInfo { commandResults := make([]command.CommandResult, 0, len(results)+1) - messageResult := helper.MessageResult{Message: "[ROOTCHAIN - DEPLOY] Successfully deployed the following contracts\n"} + messageResult := helper.MessageResult{Message: "[BRIDGE - DEPLOY] Successfully deployed the following contracts\n"} for _, result := range results { if result != nil { @@ -778,11 +670,51 @@ func collectResultsOnError(results map[string]*deployContractResult) deploymentR commandResults = append([]command.CommandResult{messageResult}, commandResults...) return deploymentResultInfo{ - RootchainCfg: nil, - SupernetID: 0, + RootchainCfg: nil, + CommandResults: commandResults} } func getProxyNameForImpl(input string) string { return input + ProxySufix } + +// getValidatorSetForCheckpointManager converts given validators to generic map +// which is used for ABI encoding validator set being sent to the CheckpointManager contract +func getValidatorSetForCheckpointManager(o command.OutputFormatter, + validators []*validator.GenesisValidator) ([]*contractsapi.Validator, error) { + accSet := make(validator.AccountSet, len(validators)) + + if _, err := o.Write([]byte("[VALIDATORS - CHECKPOINT MANAGER] \n")); err != nil { + return nil, err + } + + for i, val := range validators { + if _, err := o.Write([]byte(fmt.Sprintf("%v\n", val))); err != nil { + return nil, err + } + + blsKey, err := val.UnmarshalBLSPublicKey() + if err != nil { + return nil, err + } + + accSet[i] = &validator.ValidatorMetadata{ + Address: val.Address, + BlsKey: blsKey, + VotingPower: new(big.Int).Set(val.Stake), + } + } + + hash, err := accSet.Hash() + if err != nil { + return nil, err + } + + if _, err := o.Write([]byte( + fmt.Sprintf("[VALIDATORS - CHECKPOINT MANAGER] Validators hash: %s\n", hash))); err != nil { + return nil, err + } + + return accSet.ToAPIBinding(), nil +} diff --git a/command/rootchain/deploy/deploy_test.go b/command/bridge/deploy/deploy_test.go similarity index 59% rename from command/rootchain/deploy/deploy_test.go rename to command/bridge/deploy/deploy_test.go index 4cce046356..37cd824dd2 100644 --- a/command/rootchain/deploy/deploy_test.go +++ b/command/bridge/deploy/deploy_test.go @@ -6,14 +6,11 @@ import ( "testing" "github.com/stretchr/testify/require" - "github.com/umbracle/ethgo" "github.com/umbracle/ethgo/jsonrpc" "github.com/umbracle/ethgo/testutil" "github.com/0xPolygon/polygon-edge/command" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" - "github.com/0xPolygon/polygon-edge/consensus/polybft" - "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/validator" "github.com/0xPolygon/polygon-edge/types" ) @@ -38,27 +35,8 @@ func TestDeployContracts_NoPanics(t *testing.T) { require.NoError(t, err) require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) - txn := ðgo.Transaction{ - To: nil, // contract deployment - Input: contractsapi.StakeManager.Bytecode, - } - - receipt, err = server.SendTxn(txn) - require.NoError(t, err) - require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) - outputter := command.InitializeOutputter(GetCommand()) - params.stakeManagerAddr = receipt.ContractAddress.String() - params.stakeTokenAddr = types.StringToAddress("0x123456789").String() params.proxyContractsAdmin = "0x5aaeb6053f3e94c9b9a09f33669435e7ef1beaed" - consensusCfg = polybft.PolyBFTConfig{ - NativeTokenConfig: &polybft.TokenConfig{ - Name: "Test", - Symbol: "TST", - Decimals: 18, - IsMintable: false, - }, - } require.NotPanics(t, func() { _, err = deployContracts(outputter, client, 1, []*validator.GenesisValidator{}, context.Background()) diff --git a/command/rootchain/deploy/params.go b/command/bridge/deploy/params.go similarity index 55% rename from command/rootchain/deploy/params.go rename to command/bridge/deploy/params.go index 33ab529856..15626537a9 100644 --- a/command/rootchain/deploy/params.go +++ b/command/bridge/deploy/params.go @@ -1,7 +1,6 @@ package deploy import ( - "errors" "fmt" "os" @@ -12,16 +11,12 @@ import ( const ( deployerKeyFlag = "deployer-key" jsonRPCFlag = "json-rpc" - erc20AddrFlag = "erc20-token" ) type deployParams struct { genesisPath string deployerKey string jsonRPCAddress string - stakeTokenAddr string - rootERC20TokenAddr string - stakeManagerAddr string proxyContractsAdmin string isTestMode bool } @@ -38,18 +33,5 @@ func (ip *deployParams) validateFlags() error { return err } - if consensusCfg.NativeTokenConfig == nil { - return errors.New("native token configuration is undefined") - } - - // when using mintable native token, child native token on root chain gets mapped automatically - if consensusCfg.NativeTokenConfig.IsMintable && ip.rootERC20TokenAddr != "" { - return errors.New("if child chain native token is mintable, root native token must not pre-exist on root chain") - } - - if params.stakeTokenAddr == "" { - return errors.New("stake token address is not provided") - } - return helper.ValidateProxyContractsAdmin(ip.proxyContractsAdmin) } diff --git a/command/rootchain/deploy/result.go b/command/bridge/deploy/result.go similarity index 95% rename from command/rootchain/deploy/result.go rename to command/bridge/deploy/result.go index 4fcdc040ab..24a4e2f3d8 100644 --- a/command/rootchain/deploy/result.go +++ b/command/bridge/deploy/result.go @@ -30,7 +30,7 @@ func newDeployContractsResult(name string, func (r deployContractResult) GetOutput() string { var buffer bytes.Buffer - buffer.WriteString("\n[ROOTCHAIN - DEPLOY CONTRACT]\n") + buffer.WriteString("\n[BRIDGE - DEPLOY CONTRACT]\n") vals := make([]string, 0, 4) vals = append(vals, fmt.Sprintf("Name|%s", r.Name)) diff --git a/command/bridge/deposit/erc1155/deposit_erc1155.go b/command/bridge/deposit/erc1155/deposit_erc1155.go index c17f24a780..99124db61a 100644 --- a/command/bridge/deposit/erc1155/deposit_erc1155.go +++ b/command/bridge/deposit/erc1155/deposit_erc1155.go @@ -10,7 +10,7 @@ import ( "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/bridge/common" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" helperCommon "github.com/0xPolygon/polygon-edge/helper/common" "github.com/0xPolygon/polygon-edge/txrelayer" diff --git a/command/bridge/deposit/erc20/deposit_erc20.go b/command/bridge/deposit/erc20/deposit_erc20.go index 6ff0f6225a..141c77fea9 100644 --- a/command/bridge/deposit/erc20/deposit_erc20.go +++ b/command/bridge/deposit/erc20/deposit_erc20.go @@ -10,7 +10,7 @@ import ( "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/bridge/common" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" helperCommon "github.com/0xPolygon/polygon-edge/helper/common" "github.com/0xPolygon/polygon-edge/txrelayer" diff --git a/command/bridge/deposit/erc721/deposit_erc721.go b/command/bridge/deposit/erc721/deposit_erc721.go index 1ad195da83..75582dd4e2 100644 --- a/command/bridge/deposit/erc721/deposit_erc721.go +++ b/command/bridge/deposit/erc721/deposit_erc721.go @@ -7,7 +7,7 @@ import ( "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/bridge/common" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" helperCommon "github.com/0xPolygon/polygon-edge/helper/common" "github.com/0xPolygon/polygon-edge/txrelayer" diff --git a/command/bridge/exit/exit.go b/command/bridge/exit/exit.go index dceba85281..7f4660bdd9 100644 --- a/command/bridge/exit/exit.go +++ b/command/bridge/exit/exit.go @@ -14,8 +14,8 @@ import ( "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/bridge/common" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" cmdHelper "github.com/0xPolygon/polygon-edge/command/helper" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" diff --git a/command/rootchain/fund/fund.go b/command/bridge/fund/fund.go similarity index 70% rename from command/rootchain/fund/fund.go rename to command/bridge/fund/fund.go index 8ff0aee011..1b992f9688 100644 --- a/command/rootchain/fund/fund.go +++ b/command/bridge/fund/fund.go @@ -8,7 +8,7 @@ import ( "golang.org/x/sync/errgroup" "github.com/0xPolygon/polygon-edge/command" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" @@ -18,7 +18,7 @@ var ( params fundParams ) -// GetCommand returns the rootchain fund command +// GetCommand returns the bridge fund command func GetCommand() *cobra.Command { rootchainFundCmd := &cobra.Command{ Use: "fund", @@ -54,20 +54,6 @@ func setFlags(cmd *cobra.Command) { "the rootchain JSON RPC endpoint", ) - cmd.Flags().StringVar( - ¶ms.stakeTokenAddr, - helper.StakeTokenFlag, - "", - helper.StakeTokenFlagDesc, - ) - - cmd.Flags().BoolVar( - ¶ms.mintStakeToken, - mintStakeTokenFlag, - false, - "indicates if stake token deployer should mint root tokens to given validators", - ) - cmd.Flags().StringVar( ¶ms.deployerPrivateKey, polybftsecrets.PrivateKeyFlag, @@ -98,12 +84,6 @@ func runCommand(cmd *cobra.Command, _ []string) { return } - var stakeTokenAddr types.Address - - if params.mintStakeToken { - stakeTokenAddr = types.StringToAddress(params.stakeTokenAddr) - } - results := make([]command.CommandResult, len(params.addresses)) g, ctx := errgroup.WithContext(cmd.Context()) @@ -139,28 +119,9 @@ func runCommand(cmd *cobra.Command, _ []string) { return fmt.Errorf("failed to fund validator '%s'", validatorAddr) } - if params.mintStakeToken { - // mint tokens to validator, so he is able to send them - mintTxn, err := helper.CreateMintTxn(validatorAddr, stakeTokenAddr, params.amountValues[i], true) - if err != nil { - return fmt.Errorf("failed to create mint native tokens transaction for validator '%s'. err: %w", - validatorAddr, err) - } - - receipt, err := txRelayer.SendTransaction(mintTxn, deployerKey) - if err != nil { - return fmt.Errorf("failed to send mint native tokens transaction to validator '%s'. err: %w", validatorAddr, err) - } - - if receipt.Status == uint64(types.ReceiptFailed) { - return fmt.Errorf("failed to mint native tokens to validator '%s'", validatorAddr) - } - } - results[i] = &result{ ValidatorAddr: validatorAddr, TxHash: types.Hash(receipt.TransactionHash), - IsMinted: params.mintStakeToken, } } @@ -170,7 +131,7 @@ func runCommand(cmd *cobra.Command, _ []string) { if err := g.Wait(); err != nil { outputter.SetError(err) - _, _ = outputter.Write([]byte("[ROOTCHAIN FUND] Successfully funded following accounts\n")) + _, _ = outputter.Write([]byte("[BRIDGE FUND] Successfully funded following accounts\n")) for _, result := range results { if result != nil { diff --git a/command/rootchain/fund/params.go b/command/bridge/fund/params.go similarity index 68% rename from command/rootchain/fund/params.go rename to command/bridge/fund/params.go index 55885910c3..a5d5cf6173 100644 --- a/command/rootchain/fund/params.go +++ b/command/bridge/fund/params.go @@ -2,11 +2,10 @@ package fund import ( "errors" - "fmt" "math/big" + bridgeHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" cmdhelper "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" "github.com/0xPolygon/polygon-edge/types" ) @@ -23,9 +22,7 @@ var ( type fundParams struct { addresses []string amounts []string - stakeTokenAddr string deployerPrivateKey string - mintStakeToken bool jsonRPCAddress string amountValues []*big.Int @@ -33,11 +30,11 @@ type fundParams struct { func (fp *fundParams) validateFlags() error { if len(fp.addresses) == 0 { - return rootHelper.ErrNoAddressesProvided + return bridgeHelper.ErrNoAddressesProvided } if len(fp.amounts) != len(fp.addresses) { - return rootHelper.ErrInconsistentLength + return bridgeHelper.ErrInconsistentLength } for _, addr := range fp.addresses { @@ -56,15 +53,5 @@ func (fp *fundParams) validateFlags() error { fp.amountValues[i] = amountValue } - if fp.mintStakeToken { - if fp.stakeTokenAddr == "" { - return rootHelper.ErrMandatoryStakeToken - } - - if err := types.IsValidAddress(fp.stakeTokenAddr); err != nil { - return fmt.Errorf("invalid stake token address is provided: %w", err) - } - } - return nil } diff --git a/command/rootchain/fund/params_test.go b/command/bridge/fund/params_test.go similarity index 64% rename from command/rootchain/fund/params_test.go rename to command/bridge/fund/params_test.go index 4a1500ac80..1477bf7609 100644 --- a/command/rootchain/fund/params_test.go +++ b/command/bridge/fund/params_test.go @@ -6,7 +6,6 @@ import ( "github.com/stretchr/testify/require" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" "github.com/0xPolygon/polygon-edge/types" ) @@ -44,33 +43,6 @@ func Test_validateFlags(t *testing.T) { }, err: "address \x10 has invalid length", }, - { - // stake token address omitted - buildParamsFn: func() *fundParams { - return &fundParams{ - mintStakeToken: true, - addresses: []string{ - types.StringToAddress("0x10").String(), - types.StringToAddress("0x20").String()}, - amounts: []string{"10", "20"}, - } - }, - err: rootHelper.ErrMandatoryStakeToken.Error(), - }, - { - // stake token address omitted - buildParamsFn: func() *fundParams { - return &fundParams{ - mintStakeToken: true, - stakeTokenAddr: "0xA", - addresses: []string{ - types.StringToAddress("0x10").String(), - types.StringToAddress("0x20").String()}, - amounts: []string{"10", "20"}, - } - }, - err: "invalid stake token address is provided", - }, { // valid scenario buildParamsFn: func() *fundParams { diff --git a/command/rootchain/fund/result.go b/command/bridge/fund/result.go similarity index 75% rename from command/rootchain/fund/result.go rename to command/bridge/fund/result.go index add7a63fa5..0df546ecae 100644 --- a/command/rootchain/fund/result.go +++ b/command/bridge/fund/result.go @@ -11,18 +11,16 @@ import ( type result struct { ValidatorAddr types.Address `json:"address"` TxHash types.Hash `json:"tx_hash"` - IsMinted bool `json:"mint"` } func (r *result) GetOutput() string { var buffer bytes.Buffer - vals := make([]string, 0, 3) + vals := make([]string, 0, 2) vals = append(vals, fmt.Sprintf("Validator (address)|%s", r.ValidatorAddr)) vals = append(vals, fmt.Sprintf("Transaction (hash)|%s", r.TxHash)) - vals = append(vals, fmt.Sprintf("Is minted|%v", r.IsMinted)) - buffer.WriteString("\n[ROOTCHAIN FUND]\n") + buffer.WriteString("\n[BRIDGE FUND]\n") buffer.WriteString(helper.FormatKV(vals)) buffer.WriteString("\n") diff --git a/command/rootchain/helper/utils.go b/command/bridge/helper/utils.go similarity index 90% rename from command/rootchain/helper/utils.go rename to command/bridge/helper/utils.go index 887de67054..6bdaf9deff 100644 --- a/command/rootchain/helper/utils.go +++ b/command/bridge/helper/utils.go @@ -26,29 +26,22 @@ import ( const ( TestAccountPrivKey = "aa75e9a7d427efc732f8e4f1a5b7646adcc61fd5bae40f80d13c8419c9f43d6d" TestModeFlag = "test" - SupernetManagerFlag = "supernet-manager" - SupernetManagerFlagDesc = "address of supernet manager contract" - StakeManagerFlag = "stake-manager" - StakeManagerFlagDesc = "address of stake manager contract" - NativeRootTokenFlag = "native-root-token" - NativeRootTokenFlagDesc = "address of native root token" GenesisPathFlag = "genesis" GenesisPathFlagDesc = "genesis file path, which contains chain configuration" DefaultGenesisPath = "./genesis.json" - StakeTokenFlag = "stake-token" - StakeTokenFlagDesc = "address of ERC20 token used for staking on rootchain" ProxyContractsAdminFlag = "proxy-contracts-admin" ProxyContractsAdminDesc = "admin for proxy contracts" + StakeTokenFlag = "stake-token" + StakeTokenFlagDesc = "address of ERC20 token used for staking" AddressesFlag = "addresses" AmountsFlag = "amounts" Erc20TokenFlag = "erc20-token" //nolint:gosec ) var ( - ErrRootchainNotFound = errors.New("rootchain not found") - ErrRootchainPortBind = errors.New("port 8545 is not bind with localhost") - ErrMandatoryStakeToken = errors.New("stake token address is mandatory") - errTestModeSecrets = errors.New("rootchain test mode does not imply specifying secrets parameters") + ErrRootchainNotFound = errors.New("rootchain not found") + ErrRootchainPortBind = errors.New("port 8545 is not bind with localhost") + errTestModeSecrets = errors.New("rootchain test mode does not imply specifying secrets parameters") ErrNoAddressesProvided = errors.New("no addresses provided") ErrInconsistentLength = errors.New("addresses and amounts must be equal length") @@ -159,9 +152,9 @@ func GetECDSAKey(privateKey, accountDir, accountConfig string) (ethgo.Key, error // GetValidatorInfo queries SupernetManager smart contract on root // and retrieves validator info for given address func GetValidatorInfo(validatorAddr ethgo.Address, supernetManagerAddr, stakeManagerAddr types.Address, - chainID int64, txRelayer txrelayer.TxRelayer) (*polybft.ValidatorInfo, error) { + txRelayer txrelayer.TxRelayer) (*polybft.ValidatorInfo, error) { caller := ethgo.Address(contracts.SystemCaller) - getValidatorMethod := contractsapi.CustomSupernetManager.Abi.GetMethod("getValidator") + getValidatorMethod := contractsapi.StakeManager.Abi.GetMethod("stakeOf") encode, err := getValidatorMethod.Encode([]interface{}{validatorAddr}) if err != nil { @@ -201,7 +194,6 @@ func GetValidatorInfo(validatorAddr ethgo.Address, supernetManagerAddr, stakeMan } stakeOfFn := &contractsapi.StakeOfStakeManagerFn{ - ID: new(big.Int).SetInt64(chainID), Validator: types.Address(validatorAddr), } @@ -283,7 +275,7 @@ func SendTransaction(txRelayer txrelayer.TxRelayer, addr ethgo.Address, input [] // CreateTransaction is a helper function that creates either dynamic fee or legacy transaction based on provided flag func CreateTransaction(sender ethgo.Address, receiver *ethgo.Address, - input []byte, value *big.Int, isDynamicFee bool) *ethgo.Transaction { + input []byte, value *big.Int, isDynamicFeeTx bool) *ethgo.Transaction { txn := ðgo.Transaction{ From: sender, To: receiver, @@ -291,7 +283,7 @@ func CreateTransaction(sender ethgo.Address, receiver *ethgo.Address, Value: value, } - if isDynamicFee { + if isDynamicFeeTx { txn.Type = ethgo.TransactionDynamicFee } else { txn.Type = ethgo.TransactionLegacy diff --git a/command/rootchain/server/params.go b/command/bridge/server/params.go similarity index 100% rename from command/rootchain/server/params.go rename to command/bridge/server/params.go diff --git a/command/rootchain/server/result.go b/command/bridge/server/result.go similarity index 93% rename from command/rootchain/server/result.go rename to command/bridge/server/result.go index 2071633425..22acf5007e 100644 --- a/command/rootchain/server/result.go +++ b/command/bridge/server/result.go @@ -33,7 +33,7 @@ func (r containerStopResult) GetOutput() string { vals = append(vals, fmt.Sprintf("Status|%d", r.Status)) vals = append(vals, fmt.Sprintf("Error|%s", r.Err)) - buffer.WriteString("\n[ROOTCHAIN SERVER - STOP]\n") + buffer.WriteString("\n[BRIDGE SERVER - STOP]\n") buffer.WriteString(helper.FormatKV(vals)) buffer.WriteString("\n") diff --git a/command/rootchain/server/server.go b/command/bridge/server/server.go similarity index 98% rename from command/rootchain/server/server.go rename to command/bridge/server/server.go index 162f1ca6eb..475ce543fe 100644 --- a/command/rootchain/server/server.go +++ b/command/bridge/server/server.go @@ -22,7 +22,7 @@ import ( "github.com/spf13/cobra" "github.com/0xPolygon/polygon-edge/command" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/helper/common" ) @@ -40,7 +40,7 @@ var ( dockerContainerID string ) -// GetCommand returns the rootchain server command +// GetCommand returns the bridge server command func GetCommand() *cobra.Command { rootchainServerCmd := &cobra.Command{ Use: "server", diff --git a/command/bridge/withdraw/erc1155/withdraw_erc1155.go b/command/bridge/withdraw/erc1155/withdraw_erc1155.go index 458a97d9a7..d38dec4edf 100644 --- a/command/bridge/withdraw/erc1155/withdraw_erc1155.go +++ b/command/bridge/withdraw/erc1155/withdraw_erc1155.go @@ -12,7 +12,7 @@ import ( "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/bridge/common" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/contracts" helperCommon "github.com/0xPolygon/polygon-edge/helper/common" diff --git a/command/bridge/withdraw/erc20/withdraw_erc20.go b/command/bridge/withdraw/erc20/withdraw_erc20.go index 68d36d9d01..360b1c4fd2 100644 --- a/command/bridge/withdraw/erc20/withdraw_erc20.go +++ b/command/bridge/withdraw/erc20/withdraw_erc20.go @@ -11,7 +11,7 @@ import ( "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/bridge/common" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/contracts" helperCommon "github.com/0xPolygon/polygon-edge/helper/common" diff --git a/command/bridge/withdraw/erc721/withdraw_erc721.go b/command/bridge/withdraw/erc721/withdraw_erc721.go index eae3404e3a..b5e65be949 100644 --- a/command/bridge/withdraw/erc721/withdraw_erc721.go +++ b/command/bridge/withdraw/erc721/withdraw_erc721.go @@ -8,7 +8,7 @@ import ( "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/bridge/common" - "github.com/0xPolygon/polygon-edge/command/rootchain/helper" + "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/contracts" helperCommon "github.com/0xPolygon/polygon-edge/helper/common" diff --git a/command/default.go b/command/default.go index 8625f578f4..47bf5b1226 100644 --- a/command/default.go +++ b/command/default.go @@ -23,7 +23,7 @@ const ( ) var ( - DefaultStake = ethgo.Ether(1e6) + DefaultStake = ethgo.Ether(1000) DefaultPremineBalance = ethgo.Ether(1e6) DefaultGenesisBaseFee = chain.GenesisBaseFee DefaultGenesisBaseFeeConfig = fmt.Sprintf( diff --git a/command/genesis/genesis.go b/command/genesis/genesis.go index 4002cc64e3..ea5a2a3a0b 100644 --- a/command/genesis/genesis.go +++ b/command/genesis/genesis.go @@ -60,6 +60,16 @@ func setFlags(cmd *cobra.Command) { ), ) + cmd.Flags().StringArrayVar( + ¶ms.stake, + stakeFlag, + []string{}, + fmt.Sprintf( + "the staked accounts and balances (format:
[:]). Default staked balance: %d", + command.DefaultStake, + ), + ) + cmd.Flags().Uint64Var( ¶ms.blockGasLimit, blockGasLimitFlag, @@ -67,17 +77,10 @@ func setFlags(cmd *cobra.Command) { "the maximum amount of gas used by all transactions in a block", ) - cmd.Flags().StringVar( - ¶ms.burnContract, - burnContractFlag, - "", - "the burn contract block and address (format: :
[:])", - ) - cmd.Flags().StringVar( ¶ms.baseFeeConfig, genesisBaseFeeConfigFlag, - command.DefaultGenesisBaseFeeConfig, + "", `initial base fee(in wei), base fee elasticity multiplier, and base fee change denominator (provided in the following format: [][:][:]). BaseFeeChangeDenom represents the value to bound the amount the base fee can change between blocks. @@ -187,7 +190,7 @@ func setFlags(cmd *cobra.Command) { nativeTokenConfigFlag, "", "native token configuration, provided in the following format: "+ - "", + "", ) cmd.Flags().StringVar( @@ -217,6 +220,13 @@ func setFlags(cmd *cobra.Command) { defaultBlockTrackerPollInterval, "interval (number of seconds) at which block tracker polls for latest block at rootchain", ) + + cmd.Flags().StringVar( + ¶ms.bladeAdmin, + bladeAdminFlag, + "", + "address of owner/admin of NativeERC20 token and StakeManager", + ) } // Access Control Lists diff --git a/command/genesis/params.go b/command/genesis/params.go index e90305431b..a1b1fd07cd 100644 --- a/command/genesis/params.go +++ b/command/genesis/params.go @@ -3,6 +3,7 @@ package genesis import ( "errors" "fmt" + "math/big" "os" "time" @@ -18,11 +19,11 @@ const ( dirFlag = "dir" nameFlag = "name" premineFlag = "premine" + stakeFlag = "stake" chainIDFlag = "chain-id" epochSizeFlag = "epoch-size" epochRewardFlag = "epoch-reward" blockGasLimitFlag = "block-gas-limit" - burnContractFlag = "burn-contract" genesisBaseFeeConfigFlag = "base-fee-config" nativeTokenConfigFlag = "native-token-config" rewardTokenCodeFlag = "reward-token-code" @@ -46,9 +47,7 @@ var ( errBaseFeeEMZero = errors.New("base fee elasticity multiplier must be greater than 0") errBaseFeeZero = errors.New("base fee must be greater than 0") errRewardWalletNotDefined = errors.New("reward wallet address must be defined") - errRewardTokenOnNonMintable = errors.New("a custom reward token must be defined when " + - "native ERC20 token is non-mintable") - errRewardWalletZero = errors.New("reward wallet address must not be zero address") + errRewardWalletZero = errors.New("reward wallet address must not be zero address") ) type genesisParams struct { @@ -56,6 +55,7 @@ type genesisParams struct { name string consensusRaw string premine []string + stake []string bootnodes []string chainID uint64 @@ -63,7 +63,6 @@ type genesisParams struct { blockGasLimit uint64 - burnContract string baseFeeConfig string parsedBaseFeeConfig *baseFeeInfo @@ -103,6 +102,7 @@ type genesisParams struct { nativeTokenConfig *polybft.TokenConfig premineInfos []*helper.PremineInfo + stakeInfos map[types.Address]*big.Int // rewards rewardTokenCode string @@ -111,6 +111,7 @@ type genesisParams struct { blockTrackerPollInterval time.Duration proxyContractsAdmin string + bladeAdmin string } func (p *genesisParams) validateFlags() error { @@ -138,7 +139,27 @@ func (p *genesisParams) validateFlags() error { } if p.isPolyBFTConsensus() { - if err := p.validatePolyBFTParams(); err != nil { + if err := p.extractNativeTokenMetadata(); err != nil { + return err + } + + if err := p.validateRewardWalletAndToken(); err != nil { + return err + } + + if err := p.validatePremineInfo(); err != nil { + return err + } + + if err := p.validateProxyContractsAdmin(); err != nil { + return err + } + + if err := p.validateBladeAdminFlag(); err != nil { + return err + } + + if err := p.parseStakeInfo(); err != nil { return err } } @@ -182,9 +203,8 @@ func (p *genesisParams) generateGenesis() error { } func (p *genesisParams) initGenesisConfig() error { - // Disable london hardfork if burn contract address is not provided - enabledForks := chain.AllForksEnabled - if !p.isBurnContractEnabled() { + enabledForks := chain.AllForksEnabled.Copy() + if p.parsedBaseFeeConfig == nil { enabledForks.RemoveFork(chain.London) } @@ -207,22 +227,15 @@ func (p *genesisParams) initGenesisConfig() error { Bootnodes: p.bootnodes, } - // burn contract can be set only for non mintable native token - if p.isBurnContractEnabled() { + if p.parsedBaseFeeConfig != nil { chainConfig.Genesis.BaseFee = p.parsedBaseFeeConfig.baseFee - chainConfig.Genesis.BaseFeeEM = p.parsedBaseFeeConfig.baseFeeEM chainConfig.Genesis.BaseFeeChangeDenom = p.parsedBaseFeeConfig.baseFeeChangeDenom - chainConfig.Params.BurnContract = make(map[uint64]types.Address, 1) - - burnContractInfo, err := parseBurnContractInfo(p.burnContract) - if err != nil { - return err - } - - chainConfig.Params.BurnContract[burnContractInfo.BlockNumber] = burnContractInfo.Address - chainConfig.Params.BurnContractDestinationAddress = burnContractInfo.DestinationAddress + chainConfig.Genesis.BaseFeeEM = p.parsedBaseFeeConfig.baseFeeEM } + chainConfig.Params.BurnContract = make(map[uint64]types.Address, 1) + chainConfig.Params.BurnContract[0] = types.ZeroAddress + for _, premineInfo := range p.premineInfos { chainConfig.Genesis.Alloc[premineInfo.Address] = &chain.GenesisAccount{ Balance: premineInfo.Amount, @@ -250,9 +263,46 @@ func (p *genesisParams) parsePremineInfo() error { return nil } +func (p *genesisParams) parseStakeInfo() error { + p.stakeInfos = make(map[types.Address]*big.Int, len(p.stake)) + + for _, stake := range p.stake { + stakeInfo, err := helper.ParsePremineInfo(stake) + if err != nil { + return fmt.Errorf("invalid stake amount provided: %w", err) + } + + p.stakeInfos[stakeInfo.Address] = stakeInfo.Amount + } + + return nil +} + +// validatePremineInfo validates whether reserve account (0x0 address) is premined +func (p *genesisParams) validatePremineInfo() error { + for _, premineInfo := range p.premineInfos { + if premineInfo.Address == types.ZeroAddress { + // we have premine of zero address, just return + return nil + } + } + + return errReserveAccMustBePremined +} + +// validateBlockTrackerPollInterval validates block tracker block interval +// which can not be 0 +func (p *genesisParams) validateBlockTrackerPollInterval() error { + if p.blockTrackerPollInterval == 0 { + return helper.ErrBlockTrackerPollInterval + } + + return nil +} + func (p *genesisParams) validateGenesisBaseFeeConfig() error { if p.baseFeeConfig == "" { - return errors.New("invalid input(empty string) for genesis base fee config flag") + return nil } baseFeeInfo, err := parseBaseFeeConfig(p.baseFeeConfig) @@ -277,11 +327,6 @@ func (p *genesisParams) validateGenesisBaseFeeConfig() error { return nil } -// isBurnContractEnabled returns true in case burn contract info is provided -func (p *genesisParams) isBurnContractEnabled() bool { - return p.burnContract != "" -} - func (p *genesisParams) getResult() command.CommandResult { return &GenesisResult{ Message: fmt.Sprintf("\nGenesis written to %s\n", p.genesisPath), diff --git a/command/genesis/params_test.go b/command/genesis/params_test.go index cce50d0d03..c393d2e2b3 100644 --- a/command/genesis/params_test.go +++ b/command/genesis/params_test.go @@ -30,17 +30,17 @@ func Test_extractNativeTokenMetadata(t *testing.T) { }, { name: "not enough params provided", - rawConfig: "Test:TST:18", + rawConfig: "Test:TST", expectErr: true, }, { name: "empty name provided", - rawConfig: ":TST:18:false", + rawConfig: ":TST:18", expectErr: true, }, { name: "empty symbol provided", - rawConfig: "Test::18:false", + rawConfig: "Test::18", expectErr: true, }, { @@ -49,48 +49,12 @@ func Test_extractNativeTokenMetadata(t *testing.T) { expectErr: true, }, { - name: "invalid mintable flag provided", - rawConfig: "Test:TST:18:bar", - expectErr: true, - }, - { - name: "mintable token not enough params provided", - rawConfig: "Test:TST:18:true", - expectErr: true, - }, - { - name: "non-mintable valid config", - rawConfig: "MyToken:MTK:9:false", - expectedCfg: &polybft.TokenConfig{ - Name: "MyToken", - Symbol: "MTK", - Decimals: 9, - IsMintable: false, - Owner: types.ZeroAddress, - }, - expectErr: false, - }, - { - name: "non-mintable token config, owner provided but ignored", - rawConfig: "MyToken:MTK:9:false:0x123456789", - expectedCfg: &polybft.TokenConfig{ - Name: "MyToken", - Symbol: "MTK", - Decimals: 9, - IsMintable: false, - Owner: types.ZeroAddress, - }, - expectErr: false, - }, - { - name: "mintable token valid config", - rawConfig: "MyMintToken:MMTK:9:true:0x123456789", + name: "valid config", + rawConfig: "MyToken:MTK:9", expectedCfg: &polybft.TokenConfig{ - Name: "MyMintToken", - Symbol: "MMTK", - Decimals: 9, - IsMintable: true, - Owner: types.StringToAddress("0x123456789"), + Name: "MyToken", + Symbol: "MTK", + Decimals: 9, }, expectErr: false, }, @@ -219,13 +183,6 @@ func Test_validateRewardWallet(t *testing.T) { isNativeERC20Mintable: true, expectValidateErr: nil, }, - { - name: "valid reward wallet: native ERC20 mintable", - rewardWallet: types.StringToAddress("1").String() + ":0", - epochReward: 0, - isNativeERC20Mintable: false, - expectValidateErr: errRewardTokenOnNonMintable, - }, } for _, c := range cases { c := c @@ -235,7 +192,7 @@ func Test_validateRewardWallet(t *testing.T) { p := &genesisParams{ rewardWallet: c.rewardWallet, epochReward: c.epochReward, - nativeTokenConfig: &polybft.TokenConfig{IsMintable: c.isNativeERC20Mintable}, + nativeTokenConfig: &polybft.TokenConfig{}, } err := p.validateRewardWalletAndToken() require.ErrorIs(t, err, c.expectValidateErr) diff --git a/command/genesis/polybft_params.go b/command/genesis/polybft_params.go index b31ab35260..31b24bd1fe 100644 --- a/command/genesis/polybft_params.go +++ b/command/genesis/polybft_params.go @@ -49,6 +49,7 @@ const ( bridgeAllowListEnabledFlag = "bridge-allow-list-enabled" bridgeBlockListAdminFlag = "bridge-block-list-admin" bridgeBlockListEnabledFlag = "bridge-block-list-enabled" + bladeAdminFlag = "blade-admin" bootnodePortStart = 30301 @@ -57,9 +58,13 @@ const ( ) var ( - errNoGenesisValidators = errors.New("genesis validators aren't provided") - errNoPremineAllowed = errors.New("native token is not mintable, so no premine is allowed " + - "except for zero address and reward wallet if native token is used as reward token") + errNoGenesisValidators = errors.New("genesis validators aren't provided") + errProxyAdminNotProvided = errors.New("proxy contracts admin address must be set") + errProxyAdminIsZeroAddress = errors.New("proxy contracts admin address must not be zero address") + errProxyAdminIsSystemCaller = errors.New("proxy contracts admin address must not be system caller address") + errBladeAdminNotProvided = errors.New("blade admin address must be set") + errBladeAdminIsZeroAddress = errors.New("blade admin address must not be zero address") + errBladeAdminIsSystemCaller = errors.New("blade admin address must not be system caller address") ) type contractInfo struct { @@ -81,16 +86,6 @@ func (p *genesisParams) generateChainConfig(o command.OutputFormatter) error { return fmt.Errorf("invalid reward wallet configuration provided '%s' : %w", p.rewardWallet, err) } - if !p.nativeTokenConfig.IsMintable { - // validate premine map, no premine is allowed if token is not mintable, - // except for the reward wallet (if native token is used as reward token) and zero address - for a := range premineBalances { - if a != types.ZeroAddress && (p.rewardTokenCode != "" || a != walletPremineInfo.Address) { - return errNoPremineAllowed - } - } - } - var ( rewardTokenByteCode []byte rewardTokenAddr = contracts.NativeERC20TokenContract @@ -151,11 +146,12 @@ func (p *genesisParams) generateChainConfig(o command.OutputFormatter) error { BlockTimeDrift: p.blockTimeDrift, BlockTrackerPollInterval: common.Duration{Duration: p.blockTrackerPollInterval}, ProxyContractsAdmin: types.StringToAddress(p.proxyContractsAdmin), + BladeAdmin: types.StringToAddress(p.bladeAdmin), } - // Disable london hardfork if burn contract address is not provided - enabledForks := chain.AllForksEnabled - if !p.isBurnContractEnabled() { + enabledForks := chain.AllForksEnabled.Copy() + + if p.parsedBaseFeeConfig == nil { enabledForks.RemoveFork(chain.London) } @@ -171,45 +167,15 @@ func (p *genesisParams) generateChainConfig(o command.OutputFormatter) error { Bootnodes: p.bootnodes, } - burnContractAddr := types.ZeroAddress - - if p.isBurnContractEnabled() { - chainConfig.Params.BurnContract = make(map[uint64]types.Address, 1) - - burnContractInfo, err := parseBurnContractInfo(p.burnContract) - if err != nil { - return err - } - - if !p.nativeTokenConfig.IsMintable { - // burn contract can be specified on arbitrary address for non-mintable native tokens - burnContractAddr = burnContractInfo.Address - chainConfig.Params.BurnContract[burnContractInfo.BlockNumber] = burnContractAddr - chainConfig.Params.BurnContractDestinationAddress = burnContractInfo.DestinationAddress - } else { - // burnt funds are sent to zero address when dealing with mintable native tokens - chainConfig.Params.BurnContract[burnContractInfo.BlockNumber] = types.ZeroAddress - } - } + chainConfig.Params.BurnContract = make(map[uint64]types.Address, 1) + chainConfig.Params.BurnContract[0] = types.ZeroAddress // deploy genesis contracts - allocs, err := p.deployContracts(rewardTokenByteCode, polyBftConfig, chainConfig, burnContractAddr) + allocs, err := p.deployContracts(rewardTokenByteCode, polyBftConfig, chainConfig) if err != nil { return err } - // premine other accounts - for _, premine := range premineBalances { - // validators have already been premined, so no need to premine them again - if _, ok := allocs[premine.Address]; ok { - continue - } - - allocs[premine.Address] = &chain.GenesisAccount{ - Balance: premine.Amount, - } - } - validatorMetadata := make([]*validator.ValidatorMetadata, len(initialValidators)) for i, validator := range initialValidators { @@ -225,6 +191,26 @@ func (p *genesisParams) generateChainConfig(o command.OutputFormatter) error { if len(p.bootnodes) == 0 { chainConfig.Bootnodes = append(chainConfig.Bootnodes, validator.MultiAddr) } + + // add default premine for a validator if it is not specified in genesis command + if _, exists := premineBalances[validator.Address]; !exists { + premineBalances[validator.Address] = &helper.PremineInfo{ + Address: validator.Address, + Amount: command.DefaultPremineBalance, + } + } + } + + // premine other accounts + for _, premine := range premineBalances { + // validators have already been premined, so no need to premine them again + if _, ok := allocs[premine.Address]; ok { + continue + } + + allocs[premine.Address] = &chain.GenesisAccount{ + Balance: premine.Amount, + } } genesisExtraData, err := GenerateExtraDataPolyBft(validatorMetadata) @@ -242,6 +228,12 @@ func (p *genesisParams) generateChainConfig(o command.OutputFormatter) error { Mixhash: polybft.PolyBFTMixDigest, } + if p.parsedBaseFeeConfig != nil { + chainConfig.Genesis.BaseFee = p.parsedBaseFeeConfig.baseFee + chainConfig.Genesis.BaseFeeChangeDenom = p.parsedBaseFeeConfig.baseFeeChangeDenom + chainConfig.Genesis.BaseFeeEM = p.parsedBaseFeeConfig.baseFeeEM + } + if len(p.contractDeployerAllowListAdmin) != 0 { // only enable allow list if there is at least one address as **admin**, otherwise // the allow list could never be updated @@ -296,22 +288,13 @@ func (p *genesisParams) generateChainConfig(o command.OutputFormatter) error { } } - if p.isBurnContractEnabled() { - // only populate base fee and base fee multiplier values if burn contract(s) - // is provided - chainConfig.Genesis.BaseFee = p.parsedBaseFeeConfig.baseFee - chainConfig.Genesis.BaseFeeEM = p.parsedBaseFeeConfig.baseFeeEM - chainConfig.Genesis.BaseFeeChangeDenom = p.parsedBaseFeeConfig.baseFeeChangeDenom - } - return helper.WriteGenesisConfigToDisk(chainConfig, params.genesisPath) } func (p *genesisParams) deployContracts( rewardTokenByteCode []byte, polybftConfig *polybft.PolyBFTConfig, - chainConfig *chain.Chain, - burnContractAddr types.Address) (map[types.Address]*chain.GenesisAccount, error) { + chainConfig *chain.Chain) (map[types.Address]*chain.GenesisAccount, error) { proxyToImplAddrMap := contracts.GetProxyImplementationMapping() proxyAddresses := make([]types.Address, 0, len(proxyToImplAddrMap)) @@ -356,39 +339,21 @@ func (p *genesisParams) deployContracts( address: contracts.L2StateSenderContractV1, }, { - artifact: contractsapi.ValidatorSet, - address: contracts.ValidatorSetContractV1, + artifact: contractsapi.EpochManager, + address: contracts.EpochManagerContractV1, }, { - artifact: contractsapi.RewardPool, - address: contracts.RewardPoolContractV1, + artifact: contractsapi.StakeManager, + address: contracts.StakeManagerContractV1, + }, + { + artifact: contractsapi.RootERC20, + address: contracts.ERC20Contract, + }, + { + artifact: contractsapi.NativeERC20, + address: contracts.NativeERC20TokenContractV1, }, - } - - if !params.nativeTokenConfig.IsMintable { - genesisContracts = append(genesisContracts, - &contractInfo{ - artifact: contractsapi.NativeERC20, - address: contracts.NativeERC20TokenContractV1, - }) - - // burn contract can be set only for non-mintable native token. If burn contract is set, - // default EIP1559 contract will be deployed. - if p.isBurnContractEnabled() { - genesisContracts = append(genesisContracts, - &contractInfo{ - artifact: contractsapi.EIP1559Burn, - address: burnContractAddr, - }) - - proxyAddresses = append(proxyAddresses, contracts.DefaultBurnContract) - } - } else { - genesisContracts = append(genesisContracts, - &contractInfo{ - artifact: contractsapi.NativeERC20Mintable, - address: contracts.NativeERC20TokenContractV1, - }) } if len(params.bridgeAllowListAdmin) != 0 || len(params.bridgeBlockListAdmin) != 0 { @@ -522,11 +487,17 @@ func (p *genesisParams) getValidatorAccounts() ([]*validator.GenesisValidator, e } addr := types.StringToAddress(trimmedAddress) + + stake, exists := p.stakeInfos[addr] + if !exists { + stake = command.DefaultStake + } + validators[i] = &validator.GenesisValidator{ MultiAddr: parts[0], Address: addr, BlsKey: trimmedBLSKey, - Stake: big.NewInt(0), + Stake: stake, } } @@ -538,7 +509,7 @@ func (p *genesisParams) getValidatorAccounts() ([]*validator.GenesisValidator, e validatorsPath = path.Dir(p.genesisPath) } - validators, err := ReadValidatorsByPrefix(validatorsPath, p.validatorsPrefixPath) + validators, err := ReadValidatorsByPrefix(validatorsPath, p.validatorsPrefixPath, p.stakeInfos) if err != nil { return nil, err } @@ -546,44 +517,12 @@ func (p *genesisParams) getValidatorAccounts() ([]*validator.GenesisValidator, e return validators, nil } -// validatePolyBFTParams validates params for polybft consensus -func (p *genesisParams) validatePolyBFTParams() error { - if err := p.extractNativeTokenMetadata(); err != nil { - return err - } - - if err := p.validateBurnContract(); err != nil { - return err - } - - if err := p.validateRewardWalletAndToken(); err != nil { - return err - } - - if err := p.validatePremineInfo(); err != nil { - return err - } - - if p.epochSize < 2 { - // Epoch size must be greater than 1, so new transactions have a chance to be added to a block. - // Otherwise, every block would be an endblock (meaning it will not have any transactions). - // Check is placed here to avoid additional parsing if epochSize < 2 - return errInvalidEpochSize - } - - return p.validateProxyContractsAdmin() -} - // validateRewardWalletAndToken validates reward wallet flag func (p *genesisParams) validateRewardWalletAndToken() error { if p.rewardWallet == "" { return errRewardWalletNotDefined } - if !p.nativeTokenConfig.IsMintable && p.rewardTokenCode == "" { - return errRewardTokenOnNonMintable - } - premineInfo, err := helper.ParsePremineInfo(p.rewardWallet) if err != nil { return err @@ -601,64 +540,43 @@ func (p *genesisParams) validateRewardWalletAndToken() error { return nil } -// validatePremineInfo validates whether reserve account (0x0 address) is premined -func (p *genesisParams) validatePremineInfo() error { - for _, premineInfo := range p.premineInfos { - if premineInfo.Address == types.ZeroAddress { - // we have premine of zero address, just return - return nil - } +func (p *genesisParams) validateProxyContractsAdmin() error { + if strings.TrimSpace(p.proxyContractsAdmin) == "" { + return errProxyAdminNotProvided } - return errReserveAccMustBePremined -} - -// validateBlockTrackerPollInterval validates block tracker block interval -// which can not be 0 -func (p *genesisParams) validateBlockTrackerPollInterval() error { - if p.blockTrackerPollInterval == 0 { - return helper.ErrBlockTrackerPollInterval + if err := types.IsValidAddress(p.proxyContractsAdmin); err != nil { + return fmt.Errorf("proxy contracts admin address is not a valid address: %w", err) } - return nil -} - -// validateBurnContract validates burn contract. If native token is mintable, -// burn contract flag must not be set. If native token is non mintable only one burn contract -// can be set and the specified address will be used to predeploy default EIP1559 burn contract. -func (p *genesisParams) validateBurnContract() error { - if p.isBurnContractEnabled() { - burnContractInfo, err := parseBurnContractInfo(p.burnContract) - if err != nil { - return fmt.Errorf("invalid burn contract info provided: %w", err) - } + proxyContractsAdminAddr := types.StringToAddress(p.proxyContractsAdmin) + if proxyContractsAdminAddr == types.ZeroAddress { + return errProxyAdminIsZeroAddress + } - if p.nativeTokenConfig.IsMintable { - if burnContractInfo.Address != types.ZeroAddress { - return errors.New("only zero address is allowed as burn destination for mintable native token") - } - } else { - if burnContractInfo.Address == types.ZeroAddress { - return errors.New("it is not allowed to deploy burn contract to 0x0 address") - } - } + if proxyContractsAdminAddr == contracts.SystemCaller { + return errProxyAdminIsSystemCaller } return nil } -func (p *genesisParams) validateProxyContractsAdmin() error { - if strings.TrimSpace(p.proxyContractsAdmin) == "" { - return errors.New("proxy contracts admin address must be set") +func (p *genesisParams) validateBladeAdminFlag() error { + if strings.TrimSpace(p.bladeAdmin) == "" { + return errBladeAdminNotProvided } - proxyContractsAdminAddr := types.StringToAddress(p.proxyContractsAdmin) - if proxyContractsAdminAddr == types.ZeroAddress { - return errors.New("proxy contracts admin address must not be zero address") + if err := types.IsValidAddress(p.bladeAdmin); err != nil { + return fmt.Errorf("blade admin address is not a valid address: %w", err) } - if proxyContractsAdminAddr == contracts.SystemCaller { - return errors.New("proxy contracts admin address must not be system caller address") + bladeAdminAddr := types.StringToAddress(p.proxyContractsAdmin) + if bladeAdminAddr == types.ZeroAddress { + return errBladeAdminIsZeroAddress + } + + if bladeAdminAddr == contracts.SystemCaller { + return errBladeAdminIsSystemCaller } return nil diff --git a/command/genesis/utils.go b/command/genesis/utils.go index 76b9f0cbeb..2d935566e3 100644 --- a/command/genesis/utils.go +++ b/command/genesis/utils.go @@ -92,46 +92,6 @@ func parseTrackerStartBlocks(trackerStartBlocksRaw []string) (map[types.Address] return trackerStartBlocksConfig, nil } -// parseBurnContractInfo parses provided burn contract information and returns burn contract block and address -func parseBurnContractInfo(burnContractInfoRaw string) (*polybft.BurnContractInfo, error) { - // :
[:] - burnContractParts := strings.Split(burnContractInfoRaw, ":") - if len(burnContractParts) < 2 || len(burnContractParts) > 3 { - return nil, fmt.Errorf("expected format: :
[:]") - } - - blockRaw := burnContractParts[0] - - blockNum, err := common.ParseUint64orHex(&blockRaw) - if err != nil { - return nil, fmt.Errorf("failed to parse block number %s: %w", blockRaw, err) - } - - contractAddress := burnContractParts[1] - if err = types.IsValidAddress(contractAddress); err != nil { - return nil, fmt.Errorf("failed to parse contract address %s: %w", contractAddress, err) - } - - if len(burnContractParts) == 2 { - return &polybft.BurnContractInfo{ - BlockNumber: blockNum, - Address: types.StringToAddress(contractAddress), - DestinationAddress: types.ZeroAddress, - }, nil - } - - destinationAddress := burnContractParts[2] - if err = types.IsValidAddress(destinationAddress); err != nil { - return nil, fmt.Errorf("failed to parse burn destination address %s: %w", destinationAddress, err) - } - - return &polybft.BurnContractInfo{ - BlockNumber: blockNum, - Address: types.StringToAddress(contractAddress), - DestinationAddress: types.StringToAddress(destinationAddress), - }, nil -} - type baseFeeInfo struct { baseFee uint64 baseFeeEM uint64 @@ -148,7 +108,7 @@ func parseBaseFeeConfig(baseFeeConfigRaw string) (*baseFeeInfo, error) { baseFeeConfig := strings.Split(baseFeeConfigRaw, ":") if len(baseFeeConfig) > 3 { - return baseFeeInfo, errors.New("invalid number of arguments for base fee configuration") + return baseFeeInfo, errors.New("invalid number of arguments provided for the base fee configuration") } if len(baseFeeConfig) >= 1 && baseFeeConfig[0] != "" { @@ -219,7 +179,8 @@ func GetValidatorKeyFiles(rootDir, filePrefix string) ([]string, error) { } // ReadValidatorsByPrefix reads validators secrets on a given root directory and with given folder prefix -func ReadValidatorsByPrefix(dir, prefix string) ([]*validator.GenesisValidator, error) { +func ReadValidatorsByPrefix(dir, prefix string, + stakeInfos map[types.Address]*big.Int) ([]*validator.GenesisValidator, error) { validatorKeyFiles, err := GetValidatorKeyFiles(dir, prefix) if err != nil { return nil, err @@ -235,11 +196,16 @@ func ReadValidatorsByPrefix(dir, prefix string) ([]*validator.GenesisValidator, return nil, err } + stake, exists := stakeInfos[types.Address(account.Ecdsa.Address())] + if !exists { + stake = command.DefaultStake + } + validators[i] = &validator.GenesisValidator{ Address: types.Address(account.Ecdsa.Address()), BlsKey: hex.EncodeToString(account.Bls.PublicKey().Marshal()), MultiAddr: fmt.Sprintf("/ip4/%s/tcp/%d/p2p/%s", "127.0.0.1", bootnodePortStart+int64(i), nodeID), - Stake: big.NewInt(0), + Stake: stake, } } diff --git a/command/helper/helper.go b/command/helper/helper.go index ef22f4b240..2e1624de57 100644 --- a/command/helper/helper.go +++ b/command/helper/helper.go @@ -267,7 +267,6 @@ func ValidateProxyContractsAdmin(proxyContractsAdmin string) error { type PremineInfo struct { Address types.Address Amount *big.Int - Key string // only used for tests } // parsePremineInfo parses provided premine information and returns premine address and amount @@ -275,7 +274,6 @@ func ParsePremineInfo(premineInfoRaw string) (*PremineInfo, error) { var ( address types.Address amount = command.DefaultPremineBalance - key string err error ) @@ -288,14 +286,10 @@ func ParsePremineInfo(premineInfoRaw string) (*PremineInfo, error) { } address = types.StringToAddress(parts[0]) - - if len(parts) == 3 { // :: - key = parts[2] - } } else { // address = types.StringToAddress(premineInfoRaw) } - return &PremineInfo{Address: address, Amount: amount, Key: key}, nil + return &PremineInfo{Address: address, Amount: amount}, nil } diff --git a/command/license/license.go b/command/license/license.go deleted file mode 100644 index af4494714c..0000000000 --- a/command/license/license.go +++ /dev/null @@ -1,35 +0,0 @@ -package license - -import ( - "github.com/0xPolygon/polygon-edge/command" - "github.com/spf13/cobra" - - "github.com/0xPolygon/polygon-edge/licenses" -) - -func GetCommand() *cobra.Command { - return &cobra.Command{ - Use: "license", - Short: "Returns Polygon Edge license and dependency attributions", - Args: cobra.NoArgs, - Run: runCommand, - } -} - -func runCommand(cmd *cobra.Command, _ []string) { - outputter := command.InitializeOutputter(cmd) - defer outputter.WriteOutput() - - bsdLicenses, err := licenses.GetBSDLicenses() - if err != nil { - outputter.SetError(err) - - return - } - - outputter.SetCommandResult( - &LicenseResult{ - BSDLicenses: bsdLicenses, - }, - ) -} diff --git a/command/license/result.go b/command/license/result.go deleted file mode 100644 index 76fe9423e5..0000000000 --- a/command/license/result.go +++ /dev/null @@ -1,44 +0,0 @@ -package license - -import ( - "bytes" - "fmt" - - "github.com/0xPolygon/polygon-edge/licenses" -) - -type LicenseResult struct { - BSDLicenses []licenses.DepLicense `json:"bsd_licenses"` -} - -func (r *LicenseResult) GetOutput() string { - var buffer bytes.Buffer - - buffer.WriteString("\n[LICENSE]\n\n") - buffer.WriteString(licenses.License) - - buffer.WriteString("\n[DEPENDENCY ATTRIBUTIONS]\n\n") - - for idx, l := range r.BSDLicenses { - // put a blank line between attributions - if idx != 0 { - buffer.WriteString("\n") - } - - name := l.Name - if l.Version != nil { - name += " " + *l.Version - } - - buffer.WriteString(fmt.Sprintf( - " This product bundles %s,\n"+ - " which is available under a \"%s\" license.\n"+ - " For details, see %s.\n", - name, - l.Type, - l.Path, - )) - } - - return buffer.String() -} diff --git a/command/bridge/mint/mint_erc20.go b/command/mint/mint_erc20.go similarity index 78% rename from command/bridge/mint/mint_erc20.go rename to command/mint/mint_erc20.go index c549ad1c58..3650a743d8 100644 --- a/command/bridge/mint/mint_erc20.go +++ b/command/mint/mint_erc20.go @@ -4,8 +4,8 @@ import ( "fmt" "github.com/0xPolygon/polygon-edge/command" + bridgeHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" @@ -40,33 +40,51 @@ func preRunCommand(cmd *cobra.Command, _ []string) error { } func setFlags(cmd *cobra.Command) { + cmd.Flags().StringVar( + ¶ms.accountDir, + polybftsecrets.AccountDirFlag, + "", + polybftsecrets.AccountDirFlagDesc, + ) + + cmd.Flags().StringVar( + ¶ms.accountConfig, + polybftsecrets.AccountConfigFlag, + "", + polybftsecrets.AccountConfigFlagDesc, + ) + + cmd.Flags().StringVar( + ¶ms.deployerPrivateKey, + polybftsecrets.PrivateKeyFlag, + "", + "private key of the token deployer (minter)", + ) + cmd.Flags().StringSliceVar( ¶ms.addresses, - rootHelper.AddressesFlag, + bridgeHelper.AddressesFlag, nil, "addresses to which tokens should be minted", ) cmd.Flags().StringSliceVar( ¶ms.amounts, - rootHelper.AmountsFlag, + bridgeHelper.AmountsFlag, nil, "token amounts which should be minted to given addresses", ) cmd.Flags().StringVar( ¶ms.tokenAddr, - rootHelper.Erc20TokenFlag, + bridgeHelper.Erc20TokenFlag, "", "address of the erc20 token to be minted", ) - cmd.Flags().StringVar( - ¶ms.deployerPrivateKey, - polybftsecrets.PrivateKeyFlag, - "", - "private key of the token deployer (minter)", - ) + cmd.MarkFlagsMutuallyExclusive(polybftsecrets.AccountDirFlag, polybftsecrets.AccountConfigFlag) + cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountConfigFlag) + cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountDirFlag) } func runCommand(cmd *cobra.Command, _ []string) { @@ -80,7 +98,7 @@ func runCommand(cmd *cobra.Command, _ []string) { return } - deployerKey, err := rootHelper.DecodePrivateKey(params.deployerPrivateKey) + deployerKey, err := bridgeHelper.GetECDSAKey(params.deployerPrivateKey, params.accountDir, params.accountConfig) if err != nil { outputter.SetError(fmt.Errorf("failed to initialize deployer private key: %w", err)) @@ -105,7 +123,7 @@ func runCommand(cmd *cobra.Command, _ []string) { addr := types.StringToAddress(params.addresses[i]) amount := params.amountValues[i] - mintTxn, err := rootHelper.CreateMintTxn(addr, tokenAddr, amount, true) + mintTxn, err := bridgeHelper.CreateMintTxn(addr, tokenAddr, amount, true) if err != nil { return fmt.Errorf("failed to create mint native tokens transaction for validator '%s'. err: %w", addr, err) diff --git a/command/bridge/mint/params.go b/command/mint/params.go similarity index 93% rename from command/bridge/mint/params.go rename to command/mint/params.go index c461d51b01..70efa0481d 100644 --- a/command/bridge/mint/params.go +++ b/command/mint/params.go @@ -5,14 +5,16 @@ import ( "fmt" "math/big" + rootHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" "github.com/0xPolygon/polygon-edge/types" ) type mintParams struct { addresses []string amounts []string + accountDir string + accountConfig string tokenAddr string deployerPrivateKey string jsonRPCAddress string diff --git a/command/polybft/polybft_command.go b/command/polybft/polybft_command.go deleted file mode 100644 index af5bed0800..0000000000 --- a/command/polybft/polybft_command.go +++ /dev/null @@ -1,48 +0,0 @@ -package polybft - -import ( - "github.com/0xPolygon/polygon-edge/command/rootchain/registration" - "github.com/0xPolygon/polygon-edge/command/rootchain/staking" - "github.com/0xPolygon/polygon-edge/command/rootchain/supernet" - "github.com/0xPolygon/polygon-edge/command/rootchain/supernet/stakemanager" - "github.com/0xPolygon/polygon-edge/command/rootchain/validators" - "github.com/0xPolygon/polygon-edge/command/rootchain/whitelist" - "github.com/0xPolygon/polygon-edge/command/rootchain/withdraw" - "github.com/0xPolygon/polygon-edge/command/sidechain/rewards" - "github.com/0xPolygon/polygon-edge/command/sidechain/unstaking" - sidechainWithdraw "github.com/0xPolygon/polygon-edge/command/sidechain/withdraw" - "github.com/spf13/cobra" -) - -func GetCommand() *cobra.Command { - polybftCmd := &cobra.Command{ - Use: "polybft", - Short: "Polybft command", - } - - polybftCmd.AddCommand( - // sidechain (validator set) command to unstake on child chain - unstaking.GetCommand(), - // sidechain (validator set) command to withdraw stake on child chain - sidechainWithdraw.GetCommand(), - // sidechain (reward pool) command to withdraw pending rewards - rewards.GetCommand(), - // rootchain (stake manager) command to withdraw stake - withdraw.GetCommand(), - // rootchain (supernet manager) command that queries validator info - validators.GetCommand(), - // rootchain (supernet manager) whitelist validator - whitelist.GetCommand(), - // rootchain (supernet manager) register validator - registration.GetCommand(), - // rootchain (stake manager) stake command - staking.GetCommand(), - // rootchain (supernet manager) command for finalizing genesis - // validator set and enabling staking - supernet.GetCommand(), - // rootchain command for deploying stake manager - stakemanager.GetCommand(), - ) - - return polybftCmd -} diff --git a/command/root/root.go b/command/root/root.go index 98945b7a9e..38572fd8e9 100644 --- a/command/root/root.go +++ b/command/root/root.go @@ -10,17 +10,16 @@ import ( "github.com/0xPolygon/polygon-edge/command/bridge" "github.com/0xPolygon/polygon-edge/command/genesis" "github.com/0xPolygon/polygon-edge/command/helper" - "github.com/0xPolygon/polygon-edge/command/license" + "github.com/0xPolygon/polygon-edge/command/mint" "github.com/0xPolygon/polygon-edge/command/monitor" "github.com/0xPolygon/polygon-edge/command/peers" - "github.com/0xPolygon/polygon-edge/command/polybft" "github.com/0xPolygon/polygon-edge/command/regenesis" - "github.com/0xPolygon/polygon-edge/command/rootchain" "github.com/0xPolygon/polygon-edge/command/secrets" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" "github.com/0xPolygon/polygon-edge/command/server" "github.com/0xPolygon/polygon-edge/command/status" "github.com/0xPolygon/polygon-edge/command/txpool" + "github.com/0xPolygon/polygon-edge/command/validator" "github.com/0xPolygon/polygon-edge/command/version" ) @@ -49,16 +48,15 @@ func (rc *RootCommand) registerSubCommands() { status.GetCommand(), secrets.GetCommand(), peers.GetCommand(), - rootchain.GetCommand(), monitor.GetCommand(), backup.GetCommand(), genesis.GetCommand(), server.GetCommand(), - license.GetCommand(), polybftsecrets.GetCommand(), - polybft.GetCommand(), bridge.GetCommand(), regenesis.GetCommand(), + mint.GetCommand(), + validator.GetCommand(), ) } diff --git a/command/rootchain/README.md b/command/rootchain/README.md deleted file mode 100644 index 44ee096398..0000000000 --- a/command/rootchain/README.md +++ /dev/null @@ -1,41 +0,0 @@ -# Rootchain helper command - -Top level command for manipulating rootchain server. - -## Start rootchain server - -This command starts `ethereum/client-go` container which is Geth node started in dev mode. - -```bash -$ polygon-edge rootchain server -``` - -## Fund initialized accounts - -This command funds the initialized accounts via `polygon-edge secrets init` command. - -```bash -$ polygon-edge rootchain fund --data-dir data-dir- --num 2 -``` - -or - -```bash -$ polygon-edge rootchain fund --data-dir data-dir-1 -``` - -## Deploy and initialize contracts - -This command deploys and initializes rootchain contracts. Transactions are being sent to given `--json-rpc` endpoint and are signed by private key provided by `--adminKey` flag. - -```bash -$ polygon-edge rootchain deploy \ - --genesis \ - --deployer-key \ - --stake-manager \ - --stake-token \ - --json-rpc \ - --proxy-contracts-admin
-``` - -**Note:** In case `test` flag is provided, it engages test mode, which uses predefined test account private key to send transactions to the rootchain. diff --git a/command/rootchain/premine/params.go b/command/rootchain/premine/params.go deleted file mode 100644 index 30bca7d95c..0000000000 --- a/command/rootchain/premine/params.go +++ /dev/null @@ -1,94 +0,0 @@ -package premine - -import ( - "bytes" - "errors" - "fmt" - "math/big" - - "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" - "github.com/0xPolygon/polygon-edge/types" -) - -var ( - errMandatorySupernetManagerAddr = errors.New("custom supernet manager address not defined") - errMandatoryRootPredicateAddr = errors.New("root erc20 predicate address not defined") -) - -const rootERC20PredicateFlag = "root-erc20-predicate" - -type premineParams struct { - accountDir string - accountConfig string - privateKey string - customSupernetManager string - rootERC20Predicate string - nativeTokenRoot string - jsonRPC string - amount string - - amountValue *big.Int -} - -func (p *premineParams) validateFlags() (err error) { - if p.nativeTokenRoot == "" { - return rootHelper.ErrMandatoryERC20Token - } - - if err := types.IsValidAddress(p.nativeTokenRoot); err != nil { - return fmt.Errorf("invalid erc20 token address is provided: %w", err) - } - - if p.customSupernetManager == "" { - return errMandatorySupernetManagerAddr - } - - if err := types.IsValidAddress(p.customSupernetManager); err != nil { - return fmt.Errorf("invalid supernet manager address is provided: %w", err) - } - - if p.rootERC20Predicate == "" { - return errMandatoryRootPredicateAddr - } - - if err := types.IsValidAddress(p.rootERC20Predicate); err != nil { - return fmt.Errorf("invalid root erc20 predicate address is provided: %w", err) - } - - if p.amountValue, err = helper.ParseAmount(p.amount); err != nil { - return err - } - - // validate jsonrpc address - if _, err := helper.ParseJSONRPCAddress(p.jsonRPC); err != nil { - return fmt.Errorf("failed to parse json rpc address. Error: %w", err) - } - - if p.privateKey == "" { - return sidechainHelper.ValidateSecretFlags(p.accountDir, p.accountConfig) - } - - return nil -} - -type premineResult struct { - Address string `json:"address"` - Amount *big.Int `json:"amount"` -} - -func (p premineResult) GetOutput() string { - var buffer bytes.Buffer - - buffer.WriteString("\n[NATIVE ROOT TOKEN PREMINE]\n") - - vals := make([]string, 0, 2) - vals = append(vals, fmt.Sprintf("Address|%s", p.Address)) - vals = append(vals, fmt.Sprintf("Amount Premined|%d", p.Amount)) - - buffer.WriteString(helper.FormatKV(vals)) - buffer.WriteString("\n") - - return buffer.String() -} diff --git a/command/rootchain/premine/premine.go b/command/rootchain/premine/premine.go deleted file mode 100644 index f7309d5b3c..0000000000 --- a/command/rootchain/premine/premine.go +++ /dev/null @@ -1,158 +0,0 @@ -package premine - -import ( - "fmt" - "time" - - "github.com/0xPolygon/polygon-edge/command" - "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" - polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" - "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" - "github.com/0xPolygon/polygon-edge/txrelayer" - "github.com/0xPolygon/polygon-edge/types" - "github.com/spf13/cobra" - "github.com/umbracle/ethgo" -) - -var ( - params premineParams -) - -func GetCommand() *cobra.Command { - premineCmd := &cobra.Command{ - Use: "premine", - Short: "Premine native root token to the caller, which determines genesis balances. " + - "This command is used in case Supernets native token is rootchain originated.", - PreRunE: runPreRun, - RunE: runCommand, - } - - helper.RegisterJSONRPCFlag(premineCmd) - setFlags(premineCmd) - - return premineCmd -} - -func setFlags(cmd *cobra.Command) { - cmd.Flags().StringVar( - ¶ms.accountDir, - polybftsecrets.AccountDirFlag, - "", - polybftsecrets.AccountDirFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.accountConfig, - polybftsecrets.AccountConfigFlag, - "", - polybftsecrets.AccountConfigFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.privateKey, - polybftsecrets.PrivateKeyFlag, - "", - polybftsecrets.PrivateKeyFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.customSupernetManager, - rootHelper.SupernetManagerFlag, - "", - rootHelper.SupernetManagerFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.nativeTokenRoot, - rootHelper.Erc20TokenFlag, - "", - "address of root erc20 native token", - ) - - cmd.Flags().StringVar( - ¶ms.rootERC20Predicate, - rootERC20PredicateFlag, - "", - "address of root erc20 predicate", - ) - - cmd.Flags().StringVar( - ¶ms.amount, - sidechainHelper.AmountFlag, - "", - "amount to premine", - ) - - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.AccountDirFlag, polybftsecrets.AccountConfigFlag) - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountConfigFlag) - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountDirFlag) -} - -func runPreRun(cmd *cobra.Command, _ []string) error { - params.jsonRPC = helper.GetJSONRPCAddress(cmd) - - return params.validateFlags() -} - -func runCommand(cmd *cobra.Command, _ []string) error { - outputter := command.InitializeOutputter(cmd) - defer outputter.WriteOutput() - - ownerKey, err := rootHelper.GetECDSAKey(params.privateKey, params.accountDir, params.accountConfig) - if err != nil { - return err - } - - txRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(params.jsonRPC), - txrelayer.WithReceiptTimeout(150*time.Millisecond)) - if err != nil { - return err - } - - approveTxn, err := rootHelper.CreateApproveERC20Txn( - params.amountValue, - types.StringToAddress(params.customSupernetManager), - types.StringToAddress(params.nativeTokenRoot), true) - if err != nil { - return err - } - - receipt, err := txRelayer.SendTransaction(approveTxn, ownerKey) - if err != nil { - return err - } - - if receipt == nil || receipt.Status == uint64(types.ReceiptFailed) { - return fmt.Errorf("approve transaction failed on block %d", receipt.BlockNumber) - } - - premineFn := &contractsapi.AddGenesisBalanceCustomSupernetManagerFn{ - Amount: params.amountValue, - } - - premineInput, err := premineFn.EncodeAbi() - if err != nil { - return err - } - - supernetManagerAddr := ethgo.Address(types.StringToAddress(params.customSupernetManager)) - txn := rootHelper.CreateTransaction(ownerKey.Address(), &supernetManagerAddr, premineInput, nil, true) - - receipt, err = txRelayer.SendTransaction(txn, ownerKey) - if err != nil { - return err - } - - if receipt == nil || receipt.Status == uint64(types.ReceiptFailed) { - return fmt.Errorf("premine transaction failed on block %d", receipt.BlockNumber) - } - - outputter.WriteCommandResult(&premineResult{ - Address: ownerKey.Address().String(), - Amount: params.amountValue, - }) - - return nil -} diff --git a/command/rootchain/rootchain.go b/command/rootchain/rootchain.go deleted file mode 100644 index 8832ea0149..0000000000 --- a/command/rootchain/rootchain.go +++ /dev/null @@ -1,31 +0,0 @@ -package rootchain - -import ( - "github.com/spf13/cobra" - - "github.com/0xPolygon/polygon-edge/command/rootchain/deploy" - "github.com/0xPolygon/polygon-edge/command/rootchain/fund" - "github.com/0xPolygon/polygon-edge/command/rootchain/premine" - "github.com/0xPolygon/polygon-edge/command/rootchain/server" -) - -// GetCommand creates "rootchain" helper command -func GetCommand() *cobra.Command { - rootchainCmd := &cobra.Command{ - Use: "rootchain", - Short: "Top level rootchain helper command.", - } - - rootchainCmd.AddCommand( - // rootchain server - server.GetCommand(), - // rootchain deploy - deploy.GetCommand(), - // rootchain fund - fund.GetCommand(), - // rootchain premine - premine.GetCommand(), - ) - - return rootchainCmd -} diff --git a/command/rootchain/supernet/params.go b/command/rootchain/supernet/params.go deleted file mode 100644 index a43ba94d22..0000000000 --- a/command/rootchain/supernet/params.go +++ /dev/null @@ -1,69 +0,0 @@ -package supernet - -import ( - "bytes" - "fmt" - "os" - - "github.com/0xPolygon/polygon-edge/command/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" -) - -const ( - finalizeGenesisSetFlag = "finalize-genesis-set" - enableStakingFlag = "enable-staking" -) - -type supernetParams struct { - accountDir string - accountConfig string - privateKey string - jsonRPC string - supernetManagerAddress string - genesisPath string - stakeManagerAddress string - finalizeGenesisSet bool - enableStaking bool -} - -func (sp *supernetParams) validateFlags() error { - if sp.privateKey == "" { - return sidechainHelper.ValidateSecretFlags(sp.accountDir, sp.accountConfig) - } - - if _, err := os.Stat(sp.genesisPath); err != nil { - return fmt.Errorf("provided genesis path '%s' is invalid. Error: %w ", sp.genesisPath, err) - } - - // validate jsonrpc address - _, err := helper.ParseJSONRPCAddress(sp.jsonRPC) - - return err -} - -type supernetResult struct { - IsGenesisSetFinalized bool `json:"isGenesisSetFinalized"` - IsStakingEnabled bool `json:"isStakingEnabled"` -} - -func (sr supernetResult) GetOutput() string { - var ( - buffer bytes.Buffer - vals []string - ) - - buffer.WriteString("\n[SUPERNET COMMAND]\n") - - if sr.IsGenesisSetFinalized { - vals = append(vals, "Genesis validator set finalized on supernet manager") - } - - if sr.IsStakingEnabled { - vals = append(vals, "Staking enabled on supernet manager") - } - - buffer.WriteString(helper.FormatKV(vals)) - buffer.WriteString("\n") - - return buffer.String() -} diff --git a/command/rootchain/supernet/stakemanager/params.go b/command/rootchain/supernet/stakemanager/params.go deleted file mode 100644 index 13f9492be5..0000000000 --- a/command/rootchain/supernet/stakemanager/params.go +++ /dev/null @@ -1,53 +0,0 @@ -package stakemanager - -import ( - "fmt" - "os" - - "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" - "github.com/0xPolygon/polygon-edge/types" -) - -type stakeManagerDeployParams struct { - accountDir string - accountConfig string - privateKey string - jsonRPC string - genesisPath string - stakeTokenAddress string - proxyContractsAdmin string - isTestMode bool -} - -func (s *stakeManagerDeployParams) validateFlags() error { - if !s.isTestMode { - // private key is mandatory - if s.privateKey == "" { - return sidechainHelper.ValidateSecretFlags(s.accountDir, s.accountConfig) - } - - // stake token address is mandatory - if s.stakeTokenAddress == "" { - return rootHelper.ErrMandatoryStakeToken - } - - if err := types.IsValidAddress(s.stakeTokenAddress); err != nil { - return fmt.Errorf("invalid stake token address is provided: %w", err) - } - } - - // check if provided genesis path is valid - if _, err := os.Stat(s.genesisPath); err != nil { - return fmt.Errorf("provided genesis path '%s' is invalid. Error: %w ", s.genesisPath, err) - } - - // validate jsonrpc address - _, err := helper.ParseJSONRPCAddress(s.jsonRPC) - if err != nil { - return err - } - - return helper.ValidateProxyContractsAdmin(s.proxyContractsAdmin) -} diff --git a/command/rootchain/supernet/stakemanager/params_test.go b/command/rootchain/supernet/stakemanager/params_test.go deleted file mode 100644 index bbcb03d0c0..0000000000 --- a/command/rootchain/supernet/stakemanager/params_test.go +++ /dev/null @@ -1,48 +0,0 @@ -package stakemanager - -import ( - "fmt" - "testing" - - "github.com/stretchr/testify/require" - - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" -) - -func TestValidateFlags(t *testing.T) { - t.Parallel() - - testCases := []struct { - params *stakeManagerDeployParams - errMsg string - }{ - { - params: &stakeManagerDeployParams{ - isTestMode: false, - privateKey: rootHelper.TestAccountPrivKey, - stakeTokenAddress: "", - }, - errMsg: rootHelper.ErrMandatoryStakeToken.Error(), - }, - { - params: &stakeManagerDeployParams{ - isTestMode: false, - privateKey: rootHelper.TestAccountPrivKey, - stakeTokenAddress: "0x1B", - }, - errMsg: "invalid stake token address is provided", - }, - } - - for i, tc := range testCases { - i := i - tc := tc - - t.Run(fmt.Sprintf("case#%d", i+1), func(t *testing.T) { - t.Parallel() - - err := tc.params.validateFlags() - require.ErrorContains(t, err, tc.errMsg) - }) - } -} diff --git a/command/rootchain/supernet/stakemanager/stake_manager_deploy.go b/command/rootchain/supernet/stakemanager/stake_manager_deploy.go deleted file mode 100644 index 8cf8057c18..0000000000 --- a/command/rootchain/supernet/stakemanager/stake_manager_deploy.go +++ /dev/null @@ -1,282 +0,0 @@ -package stakemanager - -import ( - "errors" - "fmt" - - "github.com/0xPolygon/polygon-edge/chain" - "github.com/0xPolygon/polygon-edge/command" - "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" - polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" - "github.com/0xPolygon/polygon-edge/consensus/polybft" - "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" - "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi/artifact" - "github.com/0xPolygon/polygon-edge/txrelayer" - "github.com/0xPolygon/polygon-edge/types" - "github.com/spf13/cobra" - "github.com/umbracle/ethgo" - "golang.org/x/sync/errgroup" -) - -var params stakeManagerDeployParams - -func GetCommand() *cobra.Command { - stakeMgrDeployCmd := &cobra.Command{ - Use: "stake-manager-deploy", - Short: "Command for deploying stake manager contract on rootchain", - PreRunE: preRunCommand, - RunE: runCommand, - } - - setFlags(stakeMgrDeployCmd) - - return stakeMgrDeployCmd -} - -func preRunCommand(cmd *cobra.Command, _ []string) error { - params.jsonRPC = helper.GetJSONRPCAddress(cmd) - - return params.validateFlags() -} - -func setFlags(cmd *cobra.Command) { - cmd.Flags().StringVar( - ¶ms.accountDir, - polybftsecrets.AccountDirFlag, - "", - polybftsecrets.AccountDirFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.accountConfig, - polybftsecrets.AccountConfigFlag, - "", - polybftsecrets.AccountConfigFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.privateKey, - polybftsecrets.PrivateKeyFlag, - "", - polybftsecrets.PrivateKeyFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.genesisPath, - rootHelper.GenesisPathFlag, - rootHelper.DefaultGenesisPath, - rootHelper.GenesisPathFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.stakeTokenAddress, - rootHelper.StakeTokenFlag, - "", - rootHelper.StakeTokenFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.proxyContractsAdmin, - rootHelper.ProxyContractsAdminFlag, - "", - rootHelper.ProxyContractsAdminDesc, - ) - - cmd.Flags().BoolVar( - ¶ms.isTestMode, - rootHelper.TestModeFlag, - false, - "indicates if command is run in test mode. If test mode is used contract will be deployed using test account "+ - "and a test stake ERC20 token will be deployed to be used for staking", - ) - - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.AccountDirFlag, polybftsecrets.AccountConfigFlag) - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountConfigFlag) - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountDirFlag) - cmd.MarkFlagsMutuallyExclusive(rootHelper.TestModeFlag, polybftsecrets.PrivateKeyFlag) - cmd.MarkFlagsMutuallyExclusive(rootHelper.TestModeFlag, polybftsecrets.AccountConfigFlag) - cmd.MarkFlagsMutuallyExclusive(rootHelper.TestModeFlag, polybftsecrets.AccountDirFlag) - cmd.MarkFlagsMutuallyExclusive(rootHelper.TestModeFlag, rootHelper.StakeTokenFlag) - - helper.RegisterJSONRPCFlag(cmd) -} - -func runCommand(cmd *cobra.Command, _ []string) error { - outputter := command.InitializeOutputter(cmd) - defer outputter.WriteOutput() - - var ( - deployerKey ethgo.Key - err error - ) - - if params.isTestMode { - deployerKey, err = rootHelper.DecodePrivateKey("") - } else { - deployerKey, err = rootHelper.GetECDSAKey(params.privateKey, params.accountDir, params.accountConfig) - } - - if err != nil { - return fmt.Errorf("failed to get deployer key: %w", err) - } - - txRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(params.jsonRPC)) - if err != nil { - return fmt.Errorf("deploying stake manager failed: %w", err) - } - - if params.isTestMode { - // fund deployer so that he can deploy contracts - deployerAddr := deployerKey.Address() - txn := rootHelper.CreateTransaction(ethgo.ZeroAddress, &deployerAddr, nil, ethgo.Ether(1), true) - - if _, err = txRelayer.SendTransactionLocal(txn); err != nil { - return fmt.Errorf("failed to send local transaction: %w", err) - } - } - - var ( - stakeManagerAddress types.Address - stakeTokenAddress = types.StringToAddress(params.stakeTokenAddress) - g, ctx = errgroup.WithContext(cmd.Context()) - ) - - g.Go(func() error { - select { - case <-ctx.Done(): - return ctx.Err() - default: - // deploy stake manager - contractAddress, err := deployContract(txRelayer, deployerKey, - contractsapi.StakeManager, "StakeManager") - if err != nil { - return err - } - - // deploy stake manager proxy - receipt, err := rootHelper.DeployProxyContract(txRelayer, deployerKey, "StakeManagerProxy", - types.StringToAddress(params.proxyContractsAdmin), contractAddress) - if err != nil { - return err - } - - if receipt == nil || receipt.Status != uint64(types.ReceiptSuccess) { - return errors.New("deployment of StakeManagerProxy contract failed") - } - - outputter.WriteCommandResult(&rootHelper.MessageResult{ - Message: "[STAKEMANAGER - DEPLOY] Successfully deployed StakeManager contract", - }) - - stakeManagerAddress = types.Address(receipt.ContractAddress) - - return nil - } - }) - - if params.isTestMode { - g.Go(func() error { - select { - case <-ctx.Done(): - return ctx.Err() - default: - // this is only used for testing, we are deploying a test ERC20 token to use for staking - // this should not be used in production - // deploy stake manager - contractAddress, err := deployContract(txRelayer, deployerKey, - contractsapi.RootERC20, "MockERC20StakeToken") - if err != nil { - return err - } - - outputter.WriteCommandResult(&rootHelper.MessageResult{ - Message: "[STAKEMANAGER - DEPLOY] Successfully deployed MockERC20StakeToken contract", - }) - - stakeTokenAddress = contractAddress - - return nil - } - }) - } - - if err := g.Wait(); err != nil { - return err - } - - // initialize stake manager - if err := initializeStakeManager(outputter, txRelayer, - stakeManagerAddress, stakeTokenAddress, deployerKey); err != nil { - return fmt.Errorf("could not initialize stake manager contract. Error: %w", err) - } - - // update stake manager address in genesis - chainConfig, err := chain.ImportFromFile(params.genesisPath) - if err != nil { - return fmt.Errorf("failed to read chain configuration: %w", err) - } - - consensusConfig, err := polybft.GetPolyBFTConfig(chainConfig) - if err != nil { - return fmt.Errorf("failed to retrieve consensus configuration: %w", err) - } - - if consensusConfig.Bridge == nil { - consensusConfig.Bridge = &polybft.BridgeConfig{} - } - - consensusConfig.Bridge.StakeManagerAddr = stakeManagerAddress - consensusConfig.Bridge.StakeTokenAddr = stakeTokenAddress - - // write updated chain configuration - chainConfig.Params.Engine[polybft.ConsensusName] = consensusConfig - - if err = helper.WriteGenesisConfigToDisk(chainConfig, params.genesisPath); err != nil { - return fmt.Errorf("failed to save chain configuration bridge data: %w", err) - } - - return nil -} - -// initializeStakeManager invokes initialize function on StakeManager contract -func initializeStakeManager(cmdOutput command.OutputFormatter, - txRelayer txrelayer.TxRelayer, - stakeManagerAddress types.Address, - stakeTokenAddress types.Address, - deployerKey ethgo.Key) error { - initFn := &contractsapi.InitializeStakeManagerFn{NewStakingToken: stakeTokenAddress} - - input, err := initFn.EncodeAbi() - if err != nil { - return err - } - - if _, err := rootHelper.SendTransaction(txRelayer, ethgo.Address(stakeManagerAddress), - input, "StakeManager", deployerKey); err != nil { - return err - } - - cmdOutput.WriteCommandResult(&rootHelper.MessageResult{ - Message: "[STAKEMANAGER - DEPLOY] StakeManager contract is initialized", - }) - - return nil -} - -func deployContract(txRelayer txrelayer.TxRelayer, deployerKey ethgo.Key, - artifact *artifact.Artifact, contractName string) (types.Address, error) { - txn := rootHelper.CreateTransaction(ethgo.ZeroAddress, nil, artifact.Bytecode, nil, true) - - receipt, err := txRelayer.SendTransaction(txn, deployerKey) - if err != nil { - return types.ZeroAddress, - fmt.Errorf("failed sending %s contract deploy transaction: %w", contractName, err) - } - - if receipt == nil || receipt.Status != uint64(types.ReceiptSuccess) { - return types.ZeroAddress, fmt.Errorf("deployment of %s contract failed", contractName) - } - - return types.Address(receipt.ContractAddress), nil -} diff --git a/command/rootchain/supernet/supernet.go b/command/rootchain/supernet/supernet.go deleted file mode 100644 index 490b2172de..0000000000 --- a/command/rootchain/supernet/supernet.go +++ /dev/null @@ -1,400 +0,0 @@ -package supernet - -import ( - "errors" - "fmt" - "math/big" - "strings" - - "github.com/spf13/cobra" - "github.com/umbracle/ethgo" - - "github.com/0xPolygon/polygon-edge/chain" - "github.com/0xPolygon/polygon-edge/command" - "github.com/0xPolygon/polygon-edge/command/genesis" - "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" - polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" - "github.com/0xPolygon/polygon-edge/consensus/polybft" - "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" - "github.com/0xPolygon/polygon-edge/consensus/polybft/validator" - "github.com/0xPolygon/polygon-edge/helper/common" - "github.com/0xPolygon/polygon-edge/helper/hex" - "github.com/0xPolygon/polygon-edge/txrelayer" - "github.com/0xPolygon/polygon-edge/types" -) - -var ( - params supernetParams - genesisSetABIFn = contractsapi.CustomSupernetManager.Abi.Methods["genesisSet"] - genesisBalancesABIFn = contractsapi.CustomSupernetManager.Abi.Methods["genesisBalances"] -) - -func GetCommand() *cobra.Command { - registerCmd := &cobra.Command{ - Use: "supernet", - Short: "Supernet initialization & finalization command", - PreRunE: runPreRun, - RunE: runCommand, - } - - setFlags(registerCmd) - - return registerCmd -} - -func runPreRun(cmd *cobra.Command, _ []string) error { - params.jsonRPC = helper.GetJSONRPCAddress(cmd) - - return params.validateFlags() -} - -func setFlags(cmd *cobra.Command) { - cmd.Flags().StringVar( - ¶ms.accountDir, - polybftsecrets.AccountDirFlag, - "", - polybftsecrets.AccountDirFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.accountConfig, - polybftsecrets.AccountConfigFlag, - "", - polybftsecrets.AccountConfigFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.privateKey, - polybftsecrets.PrivateKeyFlag, - "", - polybftsecrets.PrivateKeyFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.genesisPath, - rootHelper.GenesisPathFlag, - rootHelper.DefaultGenesisPath, - rootHelper.GenesisPathFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.supernetManagerAddress, - rootHelper.SupernetManagerFlag, - "", - rootHelper.SupernetManagerFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.stakeManagerAddress, - rootHelper.StakeManagerFlag, - "", - fmt.Sprintf("[DEPRECATED] %s", rootHelper.StakeManagerFlagDesc), - ) - - cmd.Flags().BoolVar( - ¶ms.finalizeGenesisSet, - finalizeGenesisSetFlag, - false, - "indicates if genesis validator set should be finalized on rootchain", - ) - - cmd.Flags().BoolVar( - ¶ms.enableStaking, - enableStakingFlag, - false, - "indicates if staking will be enabled after finalization of genesis validators on rootchain", - ) - - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.AccountDirFlag, polybftsecrets.AccountConfigFlag) - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountConfigFlag) - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountDirFlag) - - helper.RegisterJSONRPCFlag(cmd) -} - -func runCommand(cmd *cobra.Command, _ []string) error { - outputter := command.InitializeOutputter(cmd) - defer outputter.WriteOutput() - - ownerKey, err := rootHelper.GetECDSAKey(params.privateKey, params.accountDir, params.accountConfig) - if err != nil { - return err - } - - txRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(params.jsonRPC)) - if err != nil { - return fmt.Errorf("enlist validator failed: %w", err) - } - - supernetAddr := ethgo.Address(types.StringToAddress(params.supernetManagerAddress)) - - if params.finalizeGenesisSet { - encoded, err := contractsapi.CustomSupernetManager.Abi.Methods["finalizeGenesis"].Encode([]interface{}{}) - if err != nil { - return err - } - - txn := rootHelper.CreateTransaction(ownerKey.Address(), &supernetAddr, encoded, nil, true) - - if _, err = txRelayer.Call(ownerKey.Address(), supernetAddr, encoded); err == nil { - receipt, err := txRelayer.SendTransaction(txn, ownerKey) - if err != nil { - return fmt.Errorf("finalizing genesis validator set failed. Error: %w", err) - } - - if receipt.Status == uint64(types.ReceiptFailed) { - return fmt.Errorf("finalizing genesis validator set transaction failed on block %d", receipt.BlockNumber) - } - } else if !strings.Contains(err.Error(), "execution reverted: GenesisLib: already finalized") { - return err - } - - chainConfig, err := chain.ImportFromFile(params.genesisPath) - if err != nil { - return fmt.Errorf("failed to read chain configuration: %w", err) - } - - consensusConfig, err := polybft.GetPolyBFTConfig(chainConfig) - if err != nil { - return fmt.Errorf("failed to retrieve consensus configuration: %w", err) - } - - validatorMetadata := make([]*validator.ValidatorMetadata, len(consensusConfig.InitialValidatorSet)) - - genesisSetInput, err := genesisSetABIFn.Encode([]interface{}{}) - if err != nil { - return fmt.Errorf("failed to encode genesis set input: %w", err) - } - - genesisSetHexOut, err := txRelayer.Call(ethgo.ZeroAddress, supernetAddr, genesisSetInput) - if err != nil { - return fmt.Errorf("failed to retrieve genesis set: %w", err) - } - - genesisAccounts, err := decodeGenesisAccounts(genesisSetHexOut) - if err != nil { - return err - } - - genesisAccsMap := make(map[types.Address]*validator.GenesisValidator, len(genesisAccounts)) - - for _, genesisAcc := range genesisAccounts { - genesisBalanceInput, err := genesisBalancesABIFn.Encode([]interface{}{genesisAcc.Address}) - if err != nil { - return err - } - - genesisBalanceRaw, err := txRelayer.Call(ethgo.ZeroAddress, supernetAddr, genesisBalanceInput) - if err != nil { - return err - } - - genesisBalance, err := common.ParseUint256orHex(&genesisBalanceRaw) - if err != nil { - return fmt.Errorf("failed to convert genesis balance '%s' to number: %w", - genesisBalanceRaw, err) - } - - genesisAccsMap[genesisAcc.Address] = genesisAcc - - if genesisBalance.Sign() > 0 { - // premine genesis accounts - chainConfig.Genesis.Alloc[genesisAcc.Address] = - &chain.GenesisAccount{Balance: genesisBalance} - } - } - - // update Stake field of validators in genesis file - // based on their finalized stake on rootchain - for i, v := range consensusConfig.InitialValidatorSet { - genesisAcc, exists := genesisAccsMap[v.Address] - if !exists { - return fmt.Errorf("validator with address %s not found among genesis accounts", v.Address) - } - - v.Stake = genesisAcc.Stake - - metadata, err := v.ToValidatorMetadata() - if err != nil { - return err - } - - validatorMetadata[i] = metadata - } - - // update the voting power in genesis block extra - // based on finalized stake on rootchain - genesisExtraData, err := genesis.GenerateExtraDataPolyBft(validatorMetadata) - if err != nil { - return err - } - - chainConfig.Genesis.ExtraData = genesisExtraData - chainConfig.Params.Engine[polybft.ConsensusName] = consensusConfig - - // save updated stake and genesis extra to genesis file on disk - if err := helper.WriteGenesisConfigToDisk(chainConfig, params.genesisPath); err != nil { - return fmt.Errorf("failed to save chain configuration bridge data: %w", err) - } - - // initialize CheckpointManager contract since it needs to have a valid VotingPowers of validators - if err := initializeCheckpointManager(outputter, txRelayer, - consensusConfig, chainConfig.Params.ChainID, ownerKey); err != nil { - return fmt.Errorf("could not initialize CheckpointManager with finalized genesis validator set: %w", err) - } - } - - if params.enableStaking { - encoded, err := contractsapi.CustomSupernetManager.Abi.Methods["enableStaking"].Encode([]interface{}{}) - if err != nil { - return err - } - - txn := rootHelper.CreateTransaction(ownerKey.Address(), &supernetAddr, encoded, nil, true) - - receipt, err := txRelayer.SendTransaction(txn, ownerKey) - if err != nil { - return fmt.Errorf("enabling staking on supernet manager failed. Error: %w", err) - } - - if receipt.Status == uint64(types.ReceiptFailed) { - return fmt.Errorf("enable staking transaction failed on block %d", receipt.BlockNumber) - } - } - - result := &supernetResult{ - IsGenesisSetFinalized: params.finalizeGenesisSet, - IsStakingEnabled: params.enableStaking, - } - - outputter.WriteCommandResult(result) - - return nil -} - -// decodeGenesisAccounts decodes genesis set retrieved from CustomSupernetManager contract -func decodeGenesisAccounts(genesisSetRaw string) ([]*validator.GenesisValidator, error) { - decodeAccount := func(rawAccount map[string]interface{}) (*validator.GenesisValidator, error) { - addr, ok := rawAccount["addr"].(ethgo.Address) - if !ok { - return nil, errors.New("failed to retrieve genesis account address") - } - - stake, ok := rawAccount["initialStake"].(*big.Int) - if !ok { - return nil, errors.New("failed to retrieve genesis account stake") - } - - return &validator.GenesisValidator{ - Address: types.Address(addr), - Stake: stake, - }, nil - } - - genesisSetRawOut, err := hex.DecodeHex(genesisSetRaw) - if err != nil { - return nil, fmt.Errorf("failed to decode genesis set from hex format: %w", err) - } - - decodedGenesisSet, err := genesisSetABIFn.Outputs.Decode(genesisSetRawOut) - if err != nil { - return nil, fmt.Errorf("failed to decode genesis set from raw format: %w", err) - } - - decodedGenesisSetMap, ok := decodedGenesisSet.(map[string]interface{}) - if !ok { - return nil, errors.New("failed to convert genesis set to map") - } - - decodedGenesisSetSliceMap, ok := decodedGenesisSetMap["0"].([]map[string]interface{}) - if !ok { - return nil, errors.New("failed to convert genesis set to slice") - } - - genesisAccounts := make([]*validator.GenesisValidator, len(decodedGenesisSetSliceMap)) - for i, rawGenesisAccount := range decodedGenesisSetSliceMap { - genesisAccounts[i], err = decodeAccount(rawGenesisAccount) - if err != nil { - return nil, err - } - } - - return genesisAccounts, nil -} - -// validatorSetToABISlice converts given validators to generic map -// which is used for ABI encoding validator set being sent to the rootchain contract -func validatorSetToABISlice(o command.OutputFormatter, - validators []*validator.GenesisValidator) ([]*contractsapi.Validator, error) { - accSet := make(validator.AccountSet, len(validators)) - - if _, err := o.Write([]byte("[VALIDATORS - CHECKPOINT MANAGER] \n")); err != nil { - return nil, err - } - - for i, val := range validators { - if _, err := o.Write([]byte(fmt.Sprintf("%v\n", val))); err != nil { - return nil, err - } - - blsKey, err := val.UnmarshalBLSPublicKey() - if err != nil { - return nil, err - } - - accSet[i] = &validator.ValidatorMetadata{ - Address: val.Address, - BlsKey: blsKey, - VotingPower: new(big.Int).Set(val.Stake), - } - } - - hash, err := accSet.Hash() - if err != nil { - return nil, err - } - - if _, err := o.Write([]byte( - fmt.Sprintf("[VALIDATORS - CHECKPOINT MANAGER] Validators hash: %s\n", hash))); err != nil { - return nil, err - } - - return accSet.ToAPIBinding(), nil -} - -// initializeCheckpointManager initializes CheckpointManager contract on rootchain -// based on finalized stake (voting power) of genesis validators on root -func initializeCheckpointManager(outputter command.OutputFormatter, - txRelayer txrelayer.TxRelayer, - consensusConfig polybft.PolyBFTConfig, chainID int64, - deployerKey ethgo.Key) error { - validatorSet, err := validatorSetToABISlice(outputter, consensusConfig.InitialValidatorSet) - if err != nil { - return fmt.Errorf("failed to convert validators to map: %w", err) - } - - initParams := &contractsapi.InitializeCheckpointManagerFn{ - ChainID_: big.NewInt(chainID), - NewBls: consensusConfig.Bridge.BLSAddress, - NewBn256G2: consensusConfig.Bridge.BN256G2Address, - NewValidatorSet: validatorSet, - } - - input, err := initParams.EncodeAbi() - if err != nil { - return fmt.Errorf("failed to encode initialization params for CheckpointManager.initialize. error: %w", err) - } - - if _, err := rootHelper.SendTransaction(txRelayer, ethgo.Address(consensusConfig.Bridge.CheckpointManagerAddr), - input, "CheckpointManager", deployerKey); err != nil { - return err - } - - outputter.WriteCommandResult( - &rootHelper.MessageResult{ - Message: fmt.Sprintf("CheckpointManager contract is initialized"), - }) - - return nil -} diff --git a/command/server/config/config.go b/command/server/config/config.go index f2704b767b..6ec9c61824 100644 --- a/command/server/config/config.go +++ b/command/server/config/config.go @@ -33,13 +33,14 @@ type Config struct { JSONLogFormat bool `json:"json_log_format" yaml:"json_log_format"` CorsAllowedOrigins []string `json:"cors_allowed_origins" yaml:"cors_allowed_origins"` - Relayer bool `json:"relayer" yaml:"relayer"` - NumBlockConfirmations uint64 `json:"num_block_confirmations" yaml:"num_block_confirmations"` + Relayer bool `json:"relayer" yaml:"relayer"` ConcurrentRequestsDebug uint64 `json:"concurrent_requests_debug" yaml:"concurrent_requests_debug"` WebSocketReadLimit uint64 `json:"web_socket_read_limit" yaml:"web_socket_read_limit"` MetricsInterval time.Duration `json:"metrics_interval" yaml:"metrics_interval"` + + EventTracker *EventTracker `json:"event_tracker" yaml:"event_tracker"` } // Telemetry holds the config details for metric services. @@ -70,6 +71,13 @@ type Headers struct { AccessControlAllowOrigins []string `json:"access_control_allow_origins" yaml:"access_control_allow_origins"` } +// EventTracker defines configuration parameters for EventTracker +type EventTracker struct { + SyncBatchSize uint64 `json:"sync_batch_size" yaml:"sync_batch_size"` + NumBlockConfirmations uint64 `json:"num_block_confirmations" yaml:"num_block_confirmations"` + NumOfBlocksToReconcile uint64 `json:"num_blocks_reconcile" yaml:"num_blocks_reconcile"` +} + const ( // DefaultJSONRPCBatchRequestLimit maximum length allowed for json_rpc batch requests DefaultJSONRPCBatchRequestLimit uint64 = 20 @@ -78,10 +86,6 @@ const ( // requests with fromBlock/toBlock values (e.g. eth_getLogs) DefaultJSONRPCBlockRangeLimit uint64 = 1000 - // DefaultNumBlockConfirmations minimal number of child blocks required for the parent block to be considered final - // on ethereum epoch lasts for 32 blocks. more details: https://www.alchemy.com/overviews/ethereum-commitment-levels - DefaultNumBlockConfirmations uint64 = 64 - // DefaultConcurrentRequestsDebug specifies max number of allowed concurrent requests for debug endpoints DefaultConcurrentRequestsDebug uint64 = 32 @@ -93,6 +97,20 @@ const ( // DefaultMetricsInterval specifies the time interval after which Prometheus metrics will be generated. // A value of 0 means the metrics are disabled. DefaultMetricsInterval time.Duration = time.Second * 8 + + // event tracker + + // DefaultNumBlockConfirmations minimal number of child blocks required for the parent block + // to be considered final on tracked chain + DefaultNumBlockConfirmations uint64 = 64 + + // DefaultNumOfBlocksToReconcile is the default number of how many blocks + // the tracker will sync up from the latest block on tracked chain + DefaultNumOfBlocksToReconcile uint64 = 10_000 + + // DefaultSyncBatchSize defines a default batch size of blocks that will be gotten from tracked chain, + // when tracker is out of sync and needs to sync a number of blocks + DefaultSyncBatchSize = DefaultNumBlockConfirmations * 2 ) // DefaultConfig returns the default server configuration @@ -129,10 +147,14 @@ func DefaultConfig() *Config { JSONRPCBatchRequestLimit: DefaultJSONRPCBatchRequestLimit, JSONRPCBlockRangeLimit: DefaultJSONRPCBlockRangeLimit, Relayer: false, - NumBlockConfirmations: DefaultNumBlockConfirmations, ConcurrentRequestsDebug: DefaultConcurrentRequestsDebug, WebSocketReadLimit: DefaultWebSocketReadLimit, MetricsInterval: DefaultMetricsInterval, + EventTracker: &EventTracker{ + SyncBatchSize: DefaultSyncBatchSize, + NumBlockConfirmations: DefaultNumBlockConfirmations, + NumOfBlocksToReconcile: DefaultNumOfBlocksToReconcile, + }, } } diff --git a/command/server/params.go b/command/server/params.go index 66c527ce03..e88a754ca8 100644 --- a/command/server/params.go +++ b/command/server/params.go @@ -38,13 +38,17 @@ const ( corsOriginFlag = "access-control-allow-origins" logFileLocationFlag = "log-to" - relayerFlag = "relayer" - numBlockConfirmationsFlag = "num-block-confirmations" + relayerFlag = "relayer" concurrentRequestsDebugFlag = "concurrent-requests-debug" webSocketReadLimitFlag = "websocket-read-limit" metricsIntervalFlag = "metrics-interval" + + // event tracker + trackerSyncBatchSizeFlag = "sync-batch-size" + trackerNumBlockConfirmationsFlag = "num-block-confirmations" + trackerNumOfBlocksToReconcileFlag = "num-blocks-reconcile" ) const ( @@ -54,9 +58,10 @@ const ( var ( params = &serverParams{ rawConfig: &config.Config{ - Telemetry: &config.Telemetry{}, - Network: &config.Network{}, - TxPool: &config.TxPool{}, + Telemetry: &config.Telemetry{}, + Network: &config.Network{}, + TxPool: &config.TxPool{}, + EventTracker: &config.EventTracker{}, }, } ) @@ -179,8 +184,12 @@ func (p *serverParams) generateConfig() *server.Config { JSONLogFormat: p.rawConfig.JSONLogFormat, LogFilePath: p.logFileLocation, - Relayer: p.relayer, - NumBlockConfirmations: p.rawConfig.NumBlockConfirmations, - MetricsInterval: p.rawConfig.MetricsInterval, + Relayer: p.relayer, + MetricsInterval: p.rawConfig.MetricsInterval, + EventTracker: &server.EventTracker{ + SyncBatchSize: p.rawConfig.EventTracker.SyncBatchSize, + NumBlockConfirmations: p.rawConfig.EventTracker.NumBlockConfirmations, + NumOfBlocksToReconcile: p.rawConfig.EventTracker.NumOfBlocksToReconcile, + }, } } diff --git a/command/server/server.go b/command/server/server.go index cccbb148d8..3479a6f669 100644 --- a/command/server/server.go +++ b/command/server/server.go @@ -221,13 +221,6 @@ func setFlags(cmd *cobra.Command) { "start the state sync relayer service (PolyBFT only)", ) - cmd.Flags().Uint64Var( - ¶ms.rawConfig.NumBlockConfirmations, - numBlockConfirmationsFlag, - defaultConfig.NumBlockConfirmations, - "minimal number of child blocks required for the parent block to be considered final", - ) - cmd.Flags().Uint64Var( ¶ms.rawConfig.ConcurrentRequestsDebug, concurrentRequestsDebugFlag, @@ -249,6 +242,38 @@ func setFlags(cmd *cobra.Command) { "the interval (in seconds) at which special metrics are generated. a value of zero means the metrics are disabled", ) + { // event tracker + cmd.Flags().Uint64Var( + ¶ms.rawConfig.EventTracker.SyncBatchSize, + trackerSyncBatchSizeFlag, + defaultConfig.EventTracker.SyncBatchSize, + `defines a batch size of blocks that will be gotten from tracked chain, + when tracker is out of sync and needs to sync a number of blocks. + (e.g., SyncBatchSize = 10, trackers last processed block is 10, latest block on tracked chain is 100, + it will get blocks 11-20, get logs from confirmed blocks of given batch, remove processed confirm logs + from memory, and continue to the next batch)`, + ) + + cmd.Flags().Uint64Var( + ¶ms.rawConfig.EventTracker.NumBlockConfirmations, + trackerNumBlockConfirmationsFlag, + defaultConfig.EventTracker.NumBlockConfirmations, + "minimal number of child blocks required for the parent block to be considered final on tracked chain", + ) + + cmd.Flags().Uint64Var( + ¶ms.rawConfig.EventTracker.NumOfBlocksToReconcile, + trackerNumOfBlocksToReconcileFlag, + defaultConfig.EventTracker.NumBlockConfirmations, + `defines how many blocks we will sync up from the latest block on tracked chain. + If a node that has a tracker, was offline for days, months, a year, it is going to miss a lot of blocks potentially. + In the meantime, we expect the rest of nodes to have collected the desired events and did their + logic with them, continuing consensus and relayer stuff. + In order to not waste too much unnecessary time in syncing all those blocks, with NumOfBlocksToReconcile, + we tell the tracker to sync only latestBlock.Number - NumOfBlocksToReconcile number of blocks.`, + ) + } + setDevFlags(cmd) } diff --git a/command/sidechain/withdraw/params.go b/command/sidechain/withdraw/params.go deleted file mode 100644 index 0f10bf1532..0000000000 --- a/command/sidechain/withdraw/params.go +++ /dev/null @@ -1,48 +0,0 @@ -package withdraw - -import ( - "bytes" - "fmt" - "math/big" - - "github.com/0xPolygon/polygon-edge/command/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" -) - -type withdrawParams struct { - accountDir string - accountConfig string - jsonRPC string -} - -func (w *withdrawParams) validateFlags() error { - if _, err := helper.ParseJSONRPCAddress(w.jsonRPC); err != nil { - return fmt.Errorf("failed to parse json rpc address. Error: %w", err) - } - - return sidechainHelper.ValidateSecretFlags(w.accountDir, w.accountConfig) -} - -type withdrawResult struct { - ValidatorAddress string `json:"validatorAddress"` - Amount *big.Int `json:"amount"` - ExitEventIDs []*big.Int `json:"exitEventIDs"` - BlockNumber uint64 `json:"blockNumber"` -} - -func (r *withdrawResult) GetOutput() string { - var buffer bytes.Buffer - - buffer.WriteString("\n[WITHDRAWAL]\n") - - vals := make([]string, 0, 4) - vals = append(vals, fmt.Sprintf("Validator Address|%s", r.ValidatorAddress)) - vals = append(vals, fmt.Sprintf("Amount Withdrawn|%d", r.Amount)) - vals = append(vals, fmt.Sprintf("Exit Event IDs|%d", r.ExitEventIDs)) - vals = append(vals, fmt.Sprintf("Inclusion Block Number|%d", r.BlockNumber)) - - buffer.WriteString(helper.FormatKV(vals)) - buffer.WriteString("\n") - - return buffer.String() -} diff --git a/command/sidechain/withdraw/withdraw.go b/command/sidechain/withdraw/withdraw.go deleted file mode 100644 index 31d8f26cd7..0000000000 --- a/command/sidechain/withdraw/withdraw.go +++ /dev/null @@ -1,131 +0,0 @@ -package withdraw - -import ( - "fmt" - "time" - - "github.com/spf13/cobra" - "github.com/umbracle/ethgo" - - "github.com/0xPolygon/polygon-edge/command" - "github.com/0xPolygon/polygon-edge/command/bridge/common" - "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" - polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" - "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" - "github.com/0xPolygon/polygon-edge/contracts" - "github.com/0xPolygon/polygon-edge/txrelayer" - "github.com/0xPolygon/polygon-edge/types" -) - -var params withdrawParams - -func GetCommand() *cobra.Command { - unstakeCmd := &cobra.Command{ - Use: "withdraw-child", - Short: "Withdraws pending withdrawals on child chain for given validator", - PreRunE: runPreRun, - RunE: runCommand, - } - - helper.RegisterJSONRPCFlag(unstakeCmd) - setFlags(unstakeCmd) - - return unstakeCmd -} - -func setFlags(cmd *cobra.Command) { - cmd.Flags().StringVar( - ¶ms.accountDir, - polybftsecrets.AccountDirFlag, - "", - polybftsecrets.AccountDirFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.accountConfig, - polybftsecrets.AccountConfigFlag, - "", - polybftsecrets.AccountConfigFlagDesc, - ) - - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.AccountDirFlag, polybftsecrets.AccountConfigFlag) -} - -func runPreRun(cmd *cobra.Command, _ []string) error { - params.jsonRPC = helper.GetJSONRPCAddress(cmd) - - return params.validateFlags() -} - -func runCommand(cmd *cobra.Command, _ []string) error { - outputter := command.InitializeOutputter(cmd) - defer outputter.WriteOutput() - - validatorAccount, err := sidechainHelper.GetAccount(params.accountDir, params.accountConfig) - if err != nil { - return err - } - - txRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(params.jsonRPC), - txrelayer.WithReceiptTimeout(150*time.Millisecond)) - if err != nil { - return err - } - - encoded, err := contractsapi.ValidatorSet.Abi.Methods["withdraw"].Encode([]interface{}{}) - if err != nil { - return err - } - - receiver := (*ethgo.Address)(&contracts.ValidatorSetContract) - txn := rootHelper.CreateTransaction(validatorAccount.Ecdsa.Address(), receiver, encoded, nil, false) - - receipt, err := txRelayer.SendTransaction(txn, validatorAccount.Ecdsa) - if err != nil { - return err - } - - if receipt.Status != uint64(types.ReceiptSuccess) { - return fmt.Errorf("withdraw transaction failed on block: %d", receipt.BlockNumber) - } - - var ( - withdrawalEvent contractsapi.WithdrawalEvent - foundLog bool - ) - - // check the logs to check for the result - for _, log := range receipt.Logs { - doesMatch, err := withdrawalEvent.ParseLog(log) - if err != nil { - return err - } - - if doesMatch { - foundLog = true - - break - } - } - - if !foundLog { - return fmt.Errorf("could not find an appropriate log in receipt that withdraw happened on ValidatorSet") - } - - exitEventIDs, err := common.ExtractExitEventIDs(receipt) - if err != nil { - return fmt.Errorf("withdrawal failed: %w", err) - } - - outputter.WriteCommandResult( - &withdrawResult{ - ValidatorAddress: validatorAccount.Ecdsa.Address().String(), - Amount: withdrawalEvent.Amount, - ExitEventIDs: exitEventIDs, - BlockNumber: receipt.BlockNumber, - }) - - return nil -} diff --git a/command/sidechain/helper.go b/command/validator/helper/helper.go similarity index 50% rename from command/sidechain/helper.go rename to command/validator/helper/helper.go index f100a51226..6ca1e981b3 100644 --- a/command/sidechain/helper.go +++ b/command/validator/helper/helper.go @@ -1,17 +1,17 @@ -package sidechain +package helper import ( "errors" "fmt" "os" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" "github.com/0xPolygon/polygon-edge/consensus/polybft" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/consensus/polybft/wallet" "github.com/0xPolygon/polygon-edge/contracts" "github.com/0xPolygon/polygon-edge/helper/common" + "github.com/0xPolygon/polygon-edge/helper/hex" "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" "github.com/umbracle/ethgo" @@ -59,22 +59,77 @@ func GetAccountFromDir(accountDir string) (*wallet.Account, error) { // GetValidatorInfo queries CustomSupernetManager, StakeManager and RewardPool smart contracts // to retrieve validator info for given address -func GetValidatorInfo(validatorAddr ethgo.Address, supernetManager, stakeManager types.Address, - chainID int64, rootRelayer, childRelayer txrelayer.TxRelayer) (*polybft.ValidatorInfo, error) { - validatorInfo, err := rootHelper.GetValidatorInfo(validatorAddr, supernetManager, stakeManager, - chainID, rootRelayer) +func GetValidatorInfo(validatorAddr ethgo.Address, childRelayer txrelayer.TxRelayer) (*polybft.ValidatorInfo, error) { + getValidatorMethod := contractsapi.StakeManager.Abi.GetMethod("getValidator") + + encode, err := getValidatorMethod.Encode([]interface{}{validatorAddr}) + if err != nil { + return nil, err + } + + response, err := childRelayer.Call(ethgo.Address(contracts.SystemCaller), + ethgo.Address(contracts.StakeManagerContract), encode) if err != nil { return nil, err } - withdrawableFn := contractsapi.RewardPool.Abi.GetMethod("pendingRewards") + byteResponse, err := hex.DecodeHex(response) + if err != nil { + return nil, fmt.Errorf("unable to decode hex response, %w", err) + } + + decoded, err := getValidatorMethod.Outputs.Decode(byteResponse) + if err != nil { + return nil, err + } + + decodedOutputsMap, ok := decoded.(map[string]interface{}) + if !ok { + return nil, fmt.Errorf("could not convert decoded outputs to map") + } + + innerMap, ok := decodedOutputsMap["0"].(map[string]interface{}) + if !ok { + return nil, fmt.Errorf("could not convert decoded outputs map to inner map") + } + + //nolint:forcetypeassert + validatorInfo := &polybft.ValidatorInfo{ + Address: validatorAddr, + IsActive: innerMap["isActive"].(bool), + IsWhitelisted: innerMap["isWhitelisted"].(bool), + } + + stakeOfFn := &contractsapi.StakeOfStakeManagerFn{ + Validator: types.Address(validatorAddr), + } + + encode, err = stakeOfFn.EncodeAbi() + if err != nil { + return nil, err + } + + response, err = childRelayer.Call(ethgo.Address(contracts.SystemCaller), + ethgo.Address(contracts.StakeManagerContract), encode) + if err != nil { + return nil, err + } + + stake, err := common.ParseUint256orHex(&response) + if err != nil { + return nil, err + } + + validatorInfo.Stake = stake + + withdrawableFn := contractsapi.EpochManager.Abi.GetMethod("pendingRewards") - encode, err := withdrawableFn.Encode([]interface{}{validatorAddr}) + encode, err = withdrawableFn.Encode([]interface{}{validatorAddr}) if err != nil { return nil, err } - response, err := childRelayer.Call(ethgo.ZeroAddress, ethgo.Address(contracts.RewardPoolContract), encode) + response, err = childRelayer.Call(ethgo.ZeroAddress, ethgo.Address(contracts.EpochManagerContract), encode) if err != nil { return nil, err } diff --git a/command/rootchain/registration/params.go b/command/validator/registration/params.go similarity index 82% rename from command/rootchain/registration/params.go rename to command/validator/registration/params.go index faa1cd61ff..d212e3d5d5 100644 --- a/command/rootchain/registration/params.go +++ b/command/validator/registration/params.go @@ -5,14 +5,13 @@ import ( "fmt" "github.com/0xPolygon/polygon-edge/command/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + sidechainHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" ) type registerParams struct { - accountDir string - accountConfig string - supernetManagerAddress string - jsonRPC string + accountDir string + accountConfig string + jsonRPC string } func (rp *registerParams) validateFlags() error { diff --git a/command/rootchain/registration/register_validator.go b/command/validator/registration/register_validator.go similarity index 86% rename from command/rootchain/registration/register_validator.go rename to command/validator/registration/register_validator.go index 451c75b870..f3aec2b7e8 100644 --- a/command/rootchain/registration/register_validator.go +++ b/command/validator/registration/register_validator.go @@ -7,12 +7,13 @@ import ( "github.com/0xPolygon/polygon-edge/bls" "github.com/0xPolygon/polygon-edge/command" + bridgeHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/consensus/polybft/signer" "github.com/0xPolygon/polygon-edge/consensus/polybft/wallet" + "github.com/0xPolygon/polygon-edge/contracts" "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" "github.com/spf13/cobra" @@ -49,13 +50,6 @@ func setFlags(cmd *cobra.Command) { polybftsecrets.AccountConfigFlagDesc, ) - cmd.Flags().StringVar( - ¶ms.supernetManagerAddress, - rootHelper.SupernetManagerFlag, - "", - rootHelper.SupernetManagerFlagDesc, - ) - helper.RegisterJSONRPCFlag(cmd) cmd.MarkFlagsMutuallyExclusive(polybftsecrets.AccountConfigFlag, polybftsecrets.AccountDirFlag) } @@ -92,7 +86,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { koskSignature, err := signer.MakeKOSKSignature( newValidatorAccount.Bls, newValidatorAccount.Address(), - rootChainID.Int64(), signer.DomainValidatorSet, types.StringToAddress(params.supernetManagerAddress)) + rootChainID.Int64(), signer.DomainValidatorSet, contracts.StakeManagerContract) if err != nil { return err } @@ -149,7 +143,7 @@ func registerValidator(sender txrelayer.TxRelayer, account *wallet.Account, return nil, fmt.Errorf("register validator failed: %w", err) } - registerFn := &contractsapi.RegisterCustomSupernetManagerFn{ + registerFn := &contractsapi.RegisterStakeManagerFn{ Signature: sigMarshal, Pubkey: account.Bls.PublicKey().ToBigInt(), } @@ -159,8 +153,8 @@ func registerValidator(sender txrelayer.TxRelayer, account *wallet.Account, return nil, fmt.Errorf("register validator failed: %w", err) } - supernetAddr := ethgo.Address(types.StringToAddress(params.supernetManagerAddress)) - txn := rootHelper.CreateTransaction(ethgo.ZeroAddress, &supernetAddr, input, nil, true) + stakeManagerAddr := ethgo.Address(contracts.StakeManagerContract) + txn := bridgeHelper.CreateTransaction(ethgo.ZeroAddress, &stakeManagerAddr, input, nil, true) return sender.SendTransaction(txn, account.Ecdsa) } diff --git a/command/rootchain/staking/params.go b/command/validator/stake/params.go similarity index 77% rename from command/rootchain/staking/params.go rename to command/validator/stake/params.go index c2fb9102ac..4b1ede9176 100644 --- a/command/rootchain/staking/params.go +++ b/command/validator/stake/params.go @@ -6,19 +6,16 @@ import ( "math/big" "github.com/0xPolygon/polygon-edge/command/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" ) var supernetIDFlag = "supernet-id" type stakeParams struct { - accountDir string - accountConfig string - stakeManagerAddr string - stakeTokenAddr string - jsonRPC string - supernetID int64 - amount string + accountDir string + accountConfig string + jsonRPC string + amount string amountValue *big.Int } @@ -33,7 +30,7 @@ func (sp *stakeParams) validateFlags() (err error) { return fmt.Errorf("failed to parse json rpc address. Error: %w", err) } - return sidechainHelper.ValidateSecretFlags(sp.accountDir, sp.accountConfig) + return validatorHelper.ValidateSecretFlags(sp.accountDir, sp.accountConfig) } type stakeResult struct { diff --git a/command/rootchain/staking/stake.go b/command/validator/stake/stake.go similarity index 71% rename from command/rootchain/staking/stake.go rename to command/validator/stake/stake.go index f6bec3d3a1..725374367f 100644 --- a/command/rootchain/staking/stake.go +++ b/command/validator/stake/stake.go @@ -2,15 +2,15 @@ package staking import ( "fmt" - "math/big" "time" "github.com/0xPolygon/polygon-edge/command" + bridgeHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" + "github.com/0xPolygon/polygon-edge/contracts" "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" "github.com/spf13/cobra" @@ -24,7 +24,7 @@ var ( func GetCommand() *cobra.Command { stakeCmd := &cobra.Command{ Use: "stake", - Short: "Stakes the amount sent for validator on rootchain", + Short: "Stakes the amount sent for validator", PreRunE: runPreRun, RunE: runCommand, } @@ -50,34 +50,13 @@ func setFlags(cmd *cobra.Command) { polybftsecrets.AccountConfigFlagDesc, ) - cmd.Flags().StringVar( - ¶ms.stakeManagerAddr, - rootHelper.StakeManagerFlag, - "", - rootHelper.StakeManagerFlagDesc, - ) - cmd.Flags().StringVar( ¶ms.amount, - sidechainHelper.AmountFlag, + validatorHelper.AmountFlag, "", "amount to stake", ) - cmd.Flags().Int64Var( - ¶ms.supernetID, - supernetIDFlag, - 0, - "ID of supernet provided by stake manager on supernet registration", - ) - - cmd.Flags().StringVar( - ¶ms.stakeTokenAddr, - rootHelper.StakeTokenFlag, - "", - rootHelper.StakeTokenFlagDesc, - ) - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.AccountDirFlag, polybftsecrets.AccountConfigFlag) } @@ -91,7 +70,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { outputter := command.InitializeOutputter(cmd) defer outputter.WriteOutput() - validatorAccount, err := sidechainHelper.GetAccount(params.accountDir, params.accountConfig) + validatorAccount, err := validatorHelper.GetAccount(params.accountDir, params.accountConfig) if err != nil { return err } @@ -102,8 +81,8 @@ func runCommand(cmd *cobra.Command, _ []string) error { return err } - approveTxn, err := rootHelper.CreateApproveERC20Txn(params.amountValue, - types.StringToAddress(params.stakeManagerAddr), types.StringToAddress(params.stakeTokenAddr), true) + approveTxn, err := bridgeHelper.CreateApproveERC20Txn(params.amountValue, + contracts.StakeManagerContract, contracts.NativeERC20TokenContract, true) if err != nil { return err } @@ -117,8 +96,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { return fmt.Errorf("approve transaction failed on block %d", receipt.BlockNumber) } - stakeFn := contractsapi.StakeForStakeManagerFn{ - ID: new(big.Int).SetInt64(params.supernetID), + stakeFn := contractsapi.StakeStakeManagerFn{ Amount: params.amountValue, } @@ -127,9 +105,9 @@ func runCommand(cmd *cobra.Command, _ []string) error { return err } - stakeManagerAddr := ethgo.Address(types.StringToAddress(params.stakeManagerAddr)) + stakeManagerAddr := ethgo.Address(contracts.StakeManagerContract) - txn := rootHelper.CreateTransaction(validatorAccount.Ecdsa.Address(), &stakeManagerAddr, encoded, nil, true) + txn := bridgeHelper.CreateTransaction(validatorAccount.Ecdsa.Address(), &stakeManagerAddr, encoded, nil, true) receipt, err = txRelayer.SendTransaction(txn, validatorAccount.Ecdsa) if err != nil { diff --git a/command/sidechain/unstaking/params.go b/command/validator/unstake/params.go similarity index 88% rename from command/sidechain/unstaking/params.go rename to command/validator/unstake/params.go index 4fa6cd9a15..99dea6c2b2 100644 --- a/command/sidechain/unstaking/params.go +++ b/command/validator/unstake/params.go @@ -6,7 +6,7 @@ import ( "math/big" "github.com/0xPolygon/polygon-edge/command/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" ) var ( @@ -31,7 +31,7 @@ func (v *unstakeParams) validateFlags() (err error) { return fmt.Errorf("failed to parse json rpc address. Error: %w", err) } - return sidechainHelper.ValidateSecretFlags(v.accountDir, v.accountConfig) + return validatorHelper.ValidateSecretFlags(v.accountDir, v.accountConfig) } type unstakeResult struct { diff --git a/command/sidechain/unstaking/unstake.go b/command/validator/unstake/unstake.go similarity index 84% rename from command/sidechain/unstaking/unstake.go rename to command/validator/unstake/unstake.go index 2c5afb7ae3..24292b5507 100644 --- a/command/sidechain/unstaking/unstake.go +++ b/command/validator/unstake/unstake.go @@ -7,7 +7,7 @@ import ( "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/contracts" "github.com/0xPolygon/polygon-edge/txrelayer" @@ -49,7 +49,7 @@ func setFlags(cmd *cobra.Command) { cmd.Flags().StringVar( ¶ms.amount, - sidechainHelper.AmountFlag, + validatorHelper.AmountFlag, "", "amount to unstake from validator", ) @@ -67,7 +67,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { outputter := command.InitializeOutputter(cmd) defer outputter.WriteOutput() - validatorAccount, err := sidechainHelper.GetAccount(params.accountDir, params.accountConfig) + validatorAccount, err := validatorHelper.GetAccount(params.accountDir, params.accountConfig) if err != nil { return err } @@ -78,7 +78,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { return err } - unstakeFn := &contractsapi.UnstakeValidatorSetFn{ + unstakeFn := &contractsapi.UnstakeStakeManagerFn{ Amount: params.amountValue, } @@ -90,7 +90,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { txn := ðgo.Transaction{ From: validatorAccount.Ecdsa.Address(), Input: encoded, - To: (*ethgo.Address)(&contracts.ValidatorSetContract), + To: (*ethgo.Address)(&contracts.StakeManagerContract), } receipt, err := txRelayer.SendTransaction(txn, validatorAccount.Ecdsa) @@ -103,8 +103,8 @@ func runCommand(cmd *cobra.Command, _ []string) error { } var ( - withdrawalRegisteredEvent contractsapi.WithdrawalRegisteredEvent - foundLog bool + stakeRemovedEvent contractsapi.StakeRemovedEvent + foundLog bool ) result := &unstakeResult{ @@ -113,14 +113,14 @@ func runCommand(cmd *cobra.Command, _ []string) error { // check the logs to check for the result for _, log := range receipt.Logs { - doesMatch, err := withdrawalRegisteredEvent.ParseLog(log) + doesMatch, err := stakeRemovedEvent.ParseLog(log) if err != nil { return err } if doesMatch { foundLog = true - result.Amount = withdrawalRegisteredEvent.Amount.Uint64() + result.Amount = stakeRemovedEvent.Amount.Uint64() break } diff --git a/command/validator/validator_command.go b/command/validator/validator_command.go new file mode 100644 index 0000000000..25a102b38f --- /dev/null +++ b/command/validator/validator_command.go @@ -0,0 +1,38 @@ +package validator + +import ( + "github.com/0xPolygon/polygon-edge/command/validator/registration" + staking "github.com/0xPolygon/polygon-edge/command/validator/stake" + unstaking "github.com/0xPolygon/polygon-edge/command/validator/unstake" + "github.com/0xPolygon/polygon-edge/command/validator/validators" + "github.com/0xPolygon/polygon-edge/command/validator/whitelist" + "github.com/0xPolygon/polygon-edge/command/validator/withdraw" + withdrawRewards "github.com/0xPolygon/polygon-edge/command/validator/withdraw-rewards" + "github.com/spf13/cobra" +) + +func GetCommand() *cobra.Command { + polybftCmd := &cobra.Command{ + Use: "validator", + Short: "Validator command", + } + + polybftCmd.AddCommand( + // sidechain (validator set) command to unstake on child chain + unstaking.GetCommand(), + // sidechain (validator set) command to withdraw stake on child chain + withdraw.GetCommand(), + // sidechain (reward pool) command to withdraw pending rewards + withdrawRewards.GetCommand(), + // rootchain (supernet manager) command that queries validator info + validators.GetCommand(), + // rootchain (supernet manager) whitelist validator + whitelist.GetCommand(), + // rootchain (supernet manager) register validator + registration.GetCommand(), + // rootchain (stake manager) stake command + staking.GetCommand(), + ) + + return polybftCmd +} diff --git a/command/rootchain/validators/params.go b/command/validator/validators/params.go similarity index 89% rename from command/rootchain/validators/params.go rename to command/validator/validators/params.go index 1b51d00034..9edb5af1ef 100644 --- a/command/rootchain/validators/params.go +++ b/command/validator/validators/params.go @@ -5,7 +5,7 @@ import ( "fmt" "github.com/0xPolygon/polygon-edge/command/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" ) type validatorInfoParams struct { @@ -22,7 +22,7 @@ func (v *validatorInfoParams) validateFlags() error { return fmt.Errorf("failed to parse json rpc address. Error: %w", err) } - return sidechainHelper.ValidateSecretFlags(v.accountDir, v.accountConfig) + return validatorHelper.ValidateSecretFlags(v.accountDir, v.accountConfig) } type validatorsInfoResult struct { diff --git a/command/rootchain/validators/validator_info.go b/command/validator/validators/validator_info.go similarity index 76% rename from command/rootchain/validators/validator_info.go rename to command/validator/validators/validator_info.go index 6369d2aecc..c9505ce5b3 100644 --- a/command/rootchain/validators/validator_info.go +++ b/command/validator/validators/validator_info.go @@ -4,10 +4,10 @@ import ( "fmt" "github.com/0xPolygon/polygon-edge/command" + bridgeHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" "github.com/spf13/cobra" @@ -19,7 +19,7 @@ var ( func GetCommand() *cobra.Command { validatorInfoCmd := &cobra.Command{ - Use: "validator-info", + Use: "info", Short: "Gets validator info", PreRunE: runPreRun, RunE: runCommand, @@ -46,20 +46,6 @@ func setFlags(cmd *cobra.Command) { polybftsecrets.AccountConfigFlagDesc, ) - cmd.Flags().StringVar( - ¶ms.supernetManagerAddress, - rootHelper.SupernetManagerFlag, - "", - rootHelper.SupernetManagerFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.stakeManagerAddress, - rootHelper.StakeManagerFlag, - "", - rootHelper.StakeManagerFlagDesc, - ) - cmd.Flags().Int64Var( ¶ms.chainID, polybftsecrets.ChainIDFlag, @@ -80,7 +66,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { outputter := command.InitializeOutputter(cmd) defer outputter.WriteOutput() - validatorAccount, err := sidechainHelper.GetAccount(params.accountDir, params.accountConfig) + validatorAccount, err := validatorHelper.GetAccount(params.accountDir, params.accountConfig) if err != nil { return err } @@ -94,8 +80,8 @@ func runCommand(cmd *cobra.Command, _ []string) error { supernetManagerAddr := types.StringToAddress(params.supernetManagerAddress) stakeManagerAddr := types.StringToAddress(params.stakeManagerAddress) - validatorInfo, err := rootHelper.GetValidatorInfo(validatorAddr, - supernetManagerAddr, stakeManagerAddr, params.chainID, txRelayer) + validatorInfo, err := bridgeHelper.GetValidatorInfo(validatorAddr, + supernetManagerAddr, stakeManagerAddr, txRelayer) if err != nil { return fmt.Errorf("failed to get validator info for %s: %w", validatorAddr, err) } diff --git a/command/rootchain/whitelist/params.go b/command/validator/whitelist/params.go similarity index 76% rename from command/rootchain/whitelist/params.go rename to command/validator/whitelist/params.go index aa3101b9e4..b8a467cd06 100644 --- a/command/rootchain/whitelist/params.go +++ b/command/validator/whitelist/params.go @@ -6,7 +6,7 @@ import ( "fmt" "github.com/0xPolygon/polygon-edge/command/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" ) const ( @@ -18,12 +18,11 @@ var ( ) type whitelistParams struct { - accountDir string - accountConfig string - privateKey string - jsonRPC string - newValidatorAddresses []string - supernetManagerAddress string + accountDir string + accountConfig string + privateKey string + jsonRPC string + newValidatorAddresses []string } func (ep *whitelistParams) validateFlags() error { @@ -32,7 +31,7 @@ func (ep *whitelistParams) validateFlags() error { } if ep.privateKey == "" { - return sidechainHelper.ValidateSecretFlags(ep.accountDir, ep.accountConfig) + return validatorHelper.ValidateSecretFlags(ep.accountDir, ep.accountConfig) } // validate jsonrpc address diff --git a/command/rootchain/whitelist/whitelist_validators.go b/command/validator/whitelist/whitelist_validators.go similarity index 86% rename from command/rootchain/whitelist/whitelist_validators.go rename to command/validator/whitelist/whitelist_validators.go index ce498b4dfb..37d8a6af0b 100644 --- a/command/rootchain/whitelist/whitelist_validators.go +++ b/command/validator/whitelist/whitelist_validators.go @@ -5,10 +5,11 @@ import ( "time" "github.com/0xPolygon/polygon-edge/command" + bridgeHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" + "github.com/0xPolygon/polygon-edge/contracts" "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" "github.com/spf13/cobra" @@ -59,13 +60,6 @@ func setFlags(cmd *cobra.Command) { "account addresses of a possible validators", ) - cmd.Flags().StringVar( - ¶ms.supernetManagerAddress, - rootHelper.SupernetManagerFlag, - "", - rootHelper.SupernetManagerFlagDesc, - ) - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.AccountDirFlag, polybftsecrets.AccountConfigFlag) cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountConfigFlag) cmd.MarkFlagsMutuallyExclusive(polybftsecrets.PrivateKeyFlag, polybftsecrets.AccountDirFlag) @@ -83,7 +77,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { outputter := command.InitializeOutputter(cmd) defer outputter.WriteOutput() - ecdsaKey, err := rootHelper.GetECDSAKey(params.privateKey, params.accountDir, params.accountConfig) + ecdsaKey, err := bridgeHelper.GetECDSAKey(params.privateKey, params.accountDir, params.accountConfig) if err != nil { return err } @@ -94,7 +88,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { return fmt.Errorf("whitelist validator failed. Could not create tx relayer: %w", err) } - whitelistFn := &contractsapi.WhitelistValidatorsCustomSupernetManagerFn{ + whitelistFn := &contractsapi.WhitelistValidatorsStakeManagerFn{ Validators_: stringSliceToAddressSlice(params.newValidatorAddresses), } @@ -103,8 +97,8 @@ func runCommand(cmd *cobra.Command, _ []string) error { return fmt.Errorf("whitelist validator failed. Could not abi encode whitelist function: %w", err) } - supernetAddr := ethgo.Address(types.StringToAddress(params.supernetManagerAddress)) - txn := rootHelper.CreateTransaction(ecdsaKey.Address(), &supernetAddr, encoded, nil, true) + stakeManagerAddr := ethgo.Address(contracts.StakeManagerContract) + txn := bridgeHelper.CreateTransaction(ecdsaKey.Address(), &stakeManagerAddr, encoded, nil, true) receipt, err := txRelayer.SendTransaction(txn, ecdsaKey) if err != nil { diff --git a/command/sidechain/rewards/params.go b/command/validator/withdraw-rewards/params.go similarity index 87% rename from command/sidechain/rewards/params.go rename to command/validator/withdraw-rewards/params.go index 7b9db61523..5f53e94bb9 100644 --- a/command/sidechain/rewards/params.go +++ b/command/validator/withdraw-rewards/params.go @@ -5,7 +5,7 @@ import ( "fmt" "github.com/0xPolygon/polygon-edge/command/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" ) type withdrawRewardsParams struct { @@ -24,7 +24,7 @@ func (w *withdrawRewardsParams) validateFlags() error { return fmt.Errorf("failed to parse json rpc address. Error: %w", err) } - return sidechainHelper.ValidateSecretFlags(w.accountDir, w.accountConfig) + return validatorHelper.ValidateSecretFlags(w.accountDir, w.accountConfig) } func (wr withdrawRewardResult) GetOutput() string { diff --git a/command/sidechain/rewards/rewards.go b/command/validator/withdraw-rewards/rewards.go similarity index 78% rename from command/sidechain/rewards/rewards.go rename to command/validator/withdraw-rewards/rewards.go index d120c9d6bb..ac21e0e5a8 100644 --- a/command/sidechain/rewards/rewards.go +++ b/command/validator/withdraw-rewards/rewards.go @@ -8,10 +8,10 @@ import ( "github.com/umbracle/ethgo" "github.com/0xPolygon/polygon-edge/command" + bridgeHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/contracts" "github.com/0xPolygon/polygon-edge/helper/common" @@ -63,13 +63,13 @@ func runCommand(cmd *cobra.Command, _ []string) error { outputter := command.InitializeOutputter(cmd) defer outputter.WriteOutput() - validatorAccount, err := sidechainHelper.GetAccount(params.accountDir, params.accountConfig) + validatorAccount, err := validatorHelper.GetAccount(params.accountDir, params.accountConfig) if err != nil { return err } validatorAddr := validatorAccount.Ecdsa.Address() - rewardPoolAddr := ethgo.Address(contracts.RewardPoolContract) + epochManagerContract := ethgo.Address(contracts.EpochManagerContract) txRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(params.jsonRPC), txrelayer.WithReceiptTimeout(150*time.Millisecond)) @@ -77,12 +77,12 @@ func runCommand(cmd *cobra.Command, _ []string) error { return err } - encoded, err := contractsapi.RewardPool.Abi.Methods["pendingRewards"].Encode([]interface{}{validatorAddr}) + encoded, err := contractsapi.EpochManager.Abi.Methods["pendingRewards"].Encode([]interface{}{validatorAddr}) if err != nil { return err } - response, err := txRelayer.Call(validatorAddr, rewardPoolAddr, encoded) + response, err := txRelayer.Call(validatorAddr, epochManagerContract, encoded) if err != nil { return err } @@ -92,12 +92,12 @@ func runCommand(cmd *cobra.Command, _ []string) error { return err } - encoded, err = contractsapi.RewardPool.Abi.Methods["withdrawReward"].Encode([]interface{}{}) + encoded, err = contractsapi.EpochManager.Abi.Methods["withdrawReward"].Encode([]interface{}{}) if err != nil { return err } - txn := rootHelper.CreateTransaction(validatorAddr, &rewardPoolAddr, encoded, nil, false) + txn := bridgeHelper.CreateTransaction(validatorAddr, &epochManagerContract, encoded, nil, false) receipt, err := txRelayer.SendTransaction(txn, validatorAccount.Ecdsa) if err != nil { diff --git a/command/rootchain/withdraw/params.go b/command/validator/withdraw/params.go similarity index 60% rename from command/rootchain/withdraw/params.go rename to command/validator/withdraw/params.go index 33fc7734a7..95baa417ca 100644 --- a/command/rootchain/withdraw/params.go +++ b/command/validator/withdraw/params.go @@ -3,10 +3,9 @@ package withdraw import ( "bytes" "fmt" - "math/big" "github.com/0xPolygon/polygon-edge/command/helper" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" ) var ( @@ -14,32 +13,22 @@ var ( ) type withdrawParams struct { - accountDir string - accountConfig string - jsonRPC string - stakeManagerAddr string - addressTo string - amount string - - amountValue *big.Int + accountDir string + accountConfig string + jsonRPC string } func (v *withdrawParams) validateFlags() (err error) { - if v.amountValue, err = helper.ParseAmount(v.amount); err != nil { - return err - } - if _, err = helper.ParseJSONRPCAddress(v.jsonRPC); err != nil { return fmt.Errorf("failed to parse json rpc address. Error: %w", err) } - return sidechainHelper.ValidateSecretFlags(v.accountDir, v.accountConfig) + return validatorHelper.ValidateSecretFlags(v.accountDir, v.accountConfig) } type withdrawResult struct { ValidatorAddress string `json:"validatorAddress"` Amount uint64 `json:"amount"` - WithdrawnTo string `json:"withdrawnTo"` } func (wr withdrawResult) GetOutput() string { @@ -47,10 +36,9 @@ func (wr withdrawResult) GetOutput() string { buffer.WriteString("\n[WITHDRAWN AMOUNT]\n") - vals := make([]string, 0, 3) + vals := make([]string, 0, 2) vals = append(vals, fmt.Sprintf("Validator Address|%s", wr.ValidatorAddress)) vals = append(vals, fmt.Sprintf("Amount Withdrawn|%v", wr.Amount)) - vals = append(vals, fmt.Sprintf("Withdrawn To|%s", wr.WithdrawnTo)) buffer.WriteString(helper.FormatKV(vals)) buffer.WriteString("\n") diff --git a/command/rootchain/withdraw/withdraw.go b/command/validator/withdraw/withdraw.go similarity index 68% rename from command/rootchain/withdraw/withdraw.go rename to command/validator/withdraw/withdraw.go index 9de0148367..75d727d4e9 100644 --- a/command/rootchain/withdraw/withdraw.go +++ b/command/validator/withdraw/withdraw.go @@ -5,11 +5,12 @@ import ( "time" "github.com/0xPolygon/polygon-edge/command" + bridgeHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" - sidechainHelper "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" + "github.com/0xPolygon/polygon-edge/contracts" "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" "github.com/spf13/cobra" @@ -20,8 +21,8 @@ var params withdrawParams func GetCommand() *cobra.Command { withdrawCmd := &cobra.Command{ - Use: "withdraw-root", - Short: "Withdraws sender's withdrawable amount to specified address on the root chain", + Use: "withdraw", + Short: "Withdraws validator's withdrawable stake", PreRunE: runPreRun, RunE: runCommand, } @@ -46,27 +47,6 @@ func setFlags(cmd *cobra.Command) { polybftsecrets.AccountConfigFlagDesc, ) - cmd.Flags().StringVar( - ¶ms.addressTo, - addressToFlag, - "", - "address where to withdraw withdrawable amount", - ) - - cmd.Flags().StringVar( - ¶ms.stakeManagerAddr, - rootHelper.StakeManagerFlag, - "", - rootHelper.StakeManagerFlagDesc, - ) - - cmd.Flags().StringVar( - ¶ms.amount, - sidechainHelper.AmountFlag, - "", - "amount to withdraw", - ) - cmd.MarkFlagsMutuallyExclusive(polybftsecrets.AccountDirFlag, polybftsecrets.AccountConfigFlag) helper.RegisterJSONRPCFlag(cmd) } @@ -81,7 +61,7 @@ func runCommand(cmd *cobra.Command, _ []string) error { outputter := command.InitializeOutputter(cmd) defer outputter.WriteOutput() - validatorAccount, err := sidechainHelper.GetAccount(params.accountDir, params.accountConfig) + validatorAccount, err := validatorHelper.GetAccount(params.accountDir, params.accountConfig) if err != nil { return err } @@ -92,18 +72,13 @@ func runCommand(cmd *cobra.Command, _ []string) error { return err } - withdrawFn := &contractsapi.WithdrawStakeStakeManagerFn{ - To: types.StringToAddress(params.addressTo), - Amount: params.amountValue, - } - - encoded, err := withdrawFn.EncodeAbi() + encoded, err := contractsapi.StakeManager.Abi.Methods["withdraw"].Encode([]interface{}{}) if err != nil { return err } - stakeManagerAddr := ethgo.Address(types.StringToAddress(params.stakeManagerAddr)) - txn := rootHelper.CreateTransaction(validatorAccount.Ecdsa.Address(), &stakeManagerAddr, encoded, nil, true) + receiver := (*ethgo.Address)(&contracts.StakeManagerContract) + txn := bridgeHelper.CreateTransaction(validatorAccount.Ecdsa.Address(), receiver, encoded, nil, false) receipt, err := txRelayer.SendTransaction(txn, validatorAccount.Ecdsa) if err != nil { @@ -134,7 +109,6 @@ func runCommand(cmd *cobra.Command, _ []string) error { } result.Amount = withdrawalEvent.Amount.Uint64() - result.WithdrawnTo = withdrawalEvent.Recipient.String() foundLog = true break diff --git a/consensus/consensus.go b/consensus/consensus.go index 160faf4523..599df5970c 100644 --- a/consensus/consensus.go +++ b/consensus/consensus.go @@ -84,8 +84,10 @@ type Params struct { SecretsManager secrets.SecretsManager BlockTime uint64 - NumBlockConfirmations uint64 - MetricsInterval time.Duration + MetricsInterval time.Duration + + // event tracker + EventTracker *EventTracker } // Factory is the factory function to create a discovery consensus @@ -99,3 +101,9 @@ type BridgeDataProvider interface { // GetStateSyncProof retrieves the StateSync proof GetStateSyncProof(stateSyncID uint64) (types.Proof, error) } + +type EventTracker struct { + NumBlockConfirmations uint64 + SyncBatchSize uint64 + NumOfBlocksToReconcile uint64 +} diff --git a/consensus/polybft/blockchain_wrapper.go b/consensus/polybft/blockchain_wrapper.go index a957518302..98b3ebbe9f 100644 --- a/consensus/polybft/blockchain_wrapper.go +++ b/consensus/polybft/blockchain_wrapper.go @@ -179,7 +179,7 @@ func (p *blockchainWrapper) NewBlockBuilder( // GetSystemState is an implementation of blockchainBackend interface func (p *blockchainWrapper) GetSystemState(provider contract.Provider) SystemState { - return NewSystemState(contracts.ValidatorSetContract, contracts.StateReceiverContract, provider) + return NewSystemState(contracts.EpochManagerContract, contracts.StateReceiverContract, provider) } func (p *blockchainWrapper) SubscribeEvents() blockchain.Subscription { diff --git a/consensus/polybft/consensus_runtime.go b/consensus/polybft/consensus_runtime.go index f3068f7b61..6b77474fed 100644 --- a/consensus/polybft/consensus_runtime.go +++ b/consensus/polybft/consensus_runtime.go @@ -74,16 +74,19 @@ type guardedDataDTO struct { // runtimeConfig is a struct that holds configuration data for given consensus runtime type runtimeConfig struct { - PolyBFTConfig *PolyBFTConfig - DataDir string - Key *wallet.Key - State *State - blockchain blockchainBackend - polybftBackend polybftBackend - txPool txPoolInterface - bridgeTopic topic - numBlockConfirmations uint64 - consensusConfig *consensus.Config + PolyBFTConfig *PolyBFTConfig + DataDir string + Key *wallet.Key + State *State + blockchain blockchainBackend + polybftBackend polybftBackend + txPool txPoolInterface + bridgeTopic topic + + // event tracker + eventTracker *consensus.EventTracker + + consensusConfig *consensus.Config } // consensusRuntime is a struct that provides consensus runtime features like epoch, state and event management @@ -197,15 +200,17 @@ func (c *consensusRuntime) initStateSyncManager(logger hcf.Logger) error { logger.Named("state-sync-manager"), c.config.State, &stateSyncConfig{ - key: c.config.Key, - stateSenderAddr: stateSenderAddr, - stateSenderStartBlock: c.config.PolyBFTConfig.Bridge.EventTrackerStartBlocks[stateSenderAddr], - jsonrpcAddr: c.config.PolyBFTConfig.Bridge.JSONRPCEndpoint, - dataDir: c.config.DataDir, - topic: c.config.bridgeTopic, - maxCommitmentSize: maxCommitmentSize, - numBlockConfirmations: c.config.numBlockConfirmations, - blockTrackerPollInterval: c.config.PolyBFTConfig.BlockTrackerPollInterval.Duration, + key: c.config.Key, + dataDir: c.config.DataDir, + topic: c.config.bridgeTopic, + maxCommitmentSize: maxCommitmentSize, + eventTrackerConfig: &eventTrackerConfig{ + jsonrpcAddr: c.config.PolyBFTConfig.Bridge.JSONRPCEndpoint, + stateSenderAddr: stateSenderAddr, + stateSenderStartBlock: c.config.PolyBFTConfig.Bridge.EventTrackerStartBlocks[stateSenderAddr], + trackerPollInterval: c.config.PolyBFTConfig.BlockTrackerPollInterval.Duration, + EventTracker: *c.config.eventTracker, + }, }, c, ) @@ -251,7 +256,7 @@ func (c *consensusRuntime) initCheckpointManager(logger hcf.Logger) error { // initStateSyncRelayer initializes state sync relayer // if not enabled, then a dummy state sync relayer will be used func (c *consensusRuntime) initStateSyncRelayer(logger hcf.Logger) error { - if c.config.consensusConfig.IsRelayer { + if c.IsBridgeEnabled() && c.config.consensusConfig.IsRelayer { txRelayer, err := getStateSyncTxRelayer(c.config.consensusConfig.RPCEndpoint, logger) if err != nil { return err @@ -277,18 +282,13 @@ func (c *consensusRuntime) initStateSyncRelayer(logger hcf.Logger) error { // initStakeManager initializes stake manager func (c *consensusRuntime) initStakeManager(logger hcf.Logger, dbTx *bolt.Tx) error { - rootRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(c.config.PolyBFTConfig.Bridge.JSONRPCEndpoint)) - if err != nil { - return err - } + var err error c.stakeManager, err = newStakeManager( logger.Named("stake-manager"), c.state, - rootRelayer, wallet.NewEcdsaSigner(c.config.Key), - contracts.ValidatorSetContract, - c.config.PolyBFTConfig.Bridge.CustomSupernetManagerAddr, + contracts.StakeManagerContract, c.config.blockchain, c.config.polybftBackend, int(c.config.PolyBFTConfig.MaxValidatorSetSize), @@ -614,8 +614,8 @@ func (c *consensusRuntime) restartEpoch(header *types.Header, dbTx *bolt.Tx) (*e func (c *consensusRuntime) calculateCommitEpochInput( currentBlock *types.Header, epoch *epochMetadata, -) (*contractsapi.CommitEpochValidatorSetFn, - *contractsapi.DistributeRewardForRewardPoolFn, error) { +) (*contractsapi.CommitEpochEpochManagerFn, + *contractsapi.DistributeRewardForEpochManagerFn, error) { uptimeCounter := map[types.Address]int64{} blockHeader := currentBlock epochID := epoch.Number @@ -693,7 +693,7 @@ func (c *consensusRuntime) calculateCommitEpochInput( } } - commitEpoch := &contractsapi.CommitEpochValidatorSetFn{ + commitEpoch := &contractsapi.CommitEpochEpochManagerFn{ ID: new(big.Int).SetUint64(epochID), Epoch: &contractsapi.Epoch{ StartBlock: new(big.Int).SetUint64(epoch.FirstBlockInEpoch), @@ -702,7 +702,7 @@ func (c *consensusRuntime) calculateCommitEpochInput( }, } - distributeRewards := &contractsapi.DistributeRewardForRewardPoolFn{ + distributeRewards := &contractsapi.DistributeRewardForEpochManagerFn{ EpochID: new(big.Int).SetUint64(epochID), Uptime: uptime, } diff --git a/consensus/polybft/consensus_runtime_test.go b/consensus/polybft/consensus_runtime_test.go index a466485ea6..bc0534cfd3 100644 --- a/consensus/polybft/consensus_runtime_test.go +++ b/consensus/polybft/consensus_runtime_test.go @@ -483,6 +483,7 @@ func Test_NewConsensusRuntime(t *testing.T) { blockchain: blockchainMock, bridgeTopic: &mockTopic{}, consensusConfig: &consensus.Config{}, + eventTracker: &consensus.EventTracker{}, } require.NoError(t, config.State.StakeStore.insertFullValidatorSet(validatorSetState{ @@ -496,7 +497,7 @@ func Test_NewConsensusRuntime(t *testing.T) { assert.Equal(t, runtime.config.DataDir, tmpDir) assert.Equal(t, uint64(10), runtime.config.PolyBFTConfig.SprintSize) assert.Equal(t, uint64(10), runtime.config.PolyBFTConfig.EpochSize) - assert.Equal(t, "0x0000000000000000000000000000000000000101", contracts.ValidatorSetContract.String()) + assert.Equal(t, "0x0000000000000000000000000000000000000101", contracts.EpochManagerContract.String()) assert.Equal(t, "0x1300000000000000000000000000000000000000", runtime.config.PolyBFTConfig.Bridge.StateSenderAddr.String()) assert.Equal(t, "0x1000000000000000000000000000000000000000", runtime.config.PolyBFTConfig.Bridge.CheckpointManagerAddr.String()) assert.True(t, runtime.IsBridgeEnabled()) diff --git a/consensus/polybft/contracts_initializer.go b/consensus/polybft/contracts_initializer.go index fe4a36ddfa..ac9aba85e6 100644 --- a/consensus/polybft/contracts_initializer.go +++ b/consensus/polybft/contracts_initializer.go @@ -4,8 +4,11 @@ import ( "fmt" "math/big" + "github.com/0xPolygon/polygon-edge/bls" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" + "github.com/0xPolygon/polygon-edge/consensus/polybft/signer" "github.com/0xPolygon/polygon-edge/contracts" + "github.com/0xPolygon/polygon-edge/helper/hex" "github.com/0xPolygon/polygon-edge/state" "github.com/0xPolygon/polygon-edge/types" "github.com/umbracle/ethgo/abi" @@ -15,49 +18,77 @@ const ( contractCallGasLimit = 100_000_000 ) -// initValidatorSet initializes ValidatorSet SC -func initValidatorSet(polyBFTConfig PolyBFTConfig, transition *state.Transition) error { - initialValidators := make([]*contractsapi.ValidatorInit, len(polyBFTConfig.InitialValidatorSet)) +func initStakeManager(polyBFTConfig PolyBFTConfig, transition *state.Transition) error { + startValidators := make([]*contractsapi.GenesisValidator, len(polyBFTConfig.InitialValidatorSet)) + for i, validator := range polyBFTConfig.InitialValidatorSet { - initialValidators[i] = &contractsapi.ValidatorInit{ - Addr: validator.Address, - Stake: validator.Stake, + blsRaw, err := hex.DecodeHex(validator.BlsKey) + if err != nil { + return err + } + + key, err := bls.UnmarshalPublicKey(blsRaw) + if err != nil { + return err + } + + startValidators[i] = &contractsapi.GenesisValidator{ + Addr: validator.Address, + Stake: validator.Stake, + BlsKey: key.ToBigInt(), + } + + approveFn := &contractsapi.ApproveNativeERC20Fn{ + Spender: contracts.StakeManagerContract, + Amount: validator.Stake, + } + + input, err := approveFn.EncodeAbi() + if err != nil { + return fmt.Errorf("NativeERC20.approve params encoding failed: %w", err) + } + + err = callContract(validator.Address, contracts.NativeERC20TokenContract, input, "NativeERC20.approve", transition) + if err != nil { + return fmt.Errorf("Error while calling contract %w", err) } } - initFn := &contractsapi.InitializeValidatorSetFn{ - NewStateSender: contracts.L2StateSenderContract, - NewStateReceiver: contracts.StateReceiverContract, - NewRootChainManager: polyBFTConfig.Bridge.CustomSupernetManagerAddr, - NewEpochSize: new(big.Int).SetUint64(polyBFTConfig.EpochSize), - InitialValidators: initialValidators, + initFn := &contractsapi.InitializeStakeManagerFn{ + GenesisValidators: startValidators, + NewStakingToken: contracts.NativeERC20TokenContract, + NewBls: contracts.BLSContract, + EpochManager: contracts.EpochManagerContract, + NewDomain: signer.DomainValidatorSetString, + Owner: polyBFTConfig.BladeAdmin, } input, err := initFn.EncodeAbi() if err != nil { - return fmt.Errorf("ValidatorSet.initialize params encoding failed: %w", err) + return fmt.Errorf("StakeManager.initialize params encoding failed: %w", err) } return callContract(contracts.SystemCaller, - contracts.ValidatorSetContract, input, "ValidatorSet.initialize", transition) + contracts.StakeManagerContract, input, "StakeManager.initialize", transition) } -// initRewardPool initializes RewardPool SC -func initRewardPool(polybftConfig PolyBFTConfig, transition *state.Transition) error { - initFn := &contractsapi.InitializeRewardPoolFn{ +// initEpochManager initializes EpochManager SC +func initEpochManager(polybftConfig PolyBFTConfig, transition *state.Transition) error { + initFn := &contractsapi.InitializeEpochManagerFn{ NewRewardToken: polybftConfig.RewardConfig.TokenAddress, NewRewardWallet: polybftConfig.RewardConfig.WalletAddress, - NewValidatorSet: contracts.ValidatorSetContract, + NewStakeManager: contracts.StakeManagerContract, NewBaseReward: new(big.Int).SetUint64(polybftConfig.EpochReward), + NewEpochSize: new(big.Int).SetUint64(polybftConfig.EpochSize), } input, err := initFn.EncodeAbi() if err != nil { - return fmt.Errorf("RewardPool.initialize params encoding failed: %w", err) + return fmt.Errorf("EpochManager.initialize params encoding failed: %w", err) } return callContract(contracts.SystemCaller, - contracts.RewardPoolContract, input, "RewardPool.initialize", transition) + contracts.EpochManagerContract, input, "EpochManager.initialize", transition) } // getInitERC20PredicateInput builds initialization input parameters for child chain ERC20Predicate SC @@ -76,7 +107,7 @@ func getInitERC20PredicateInput(config *BridgeConfig, childChainMintable bool) ( NewStateReceiver: contracts.StateReceiverContract, NewRootERC20Predicate: config.RootERC20PredicateAddr, NewChildTokenTemplate: contracts.ChildERC20Contract, - NewNativeTokenRootAddress: config.RootNativeERC20Addr, + NewNativeTokenRootAddress: types.ZeroAddress, } } @@ -103,7 +134,7 @@ func getInitERC20PredicateACLInput(config *BridgeConfig, owner types.Address, NewStateReceiver: contracts.StateReceiverContract, NewRootERC20Predicate: config.RootERC20PredicateAddr, NewChildTokenTemplate: contracts.ChildERC20Contract, - NewNativeTokenRootAddress: config.RootNativeERC20Addr, + NewNativeTokenRootAddress: types.ZeroAddress, NewUseAllowList: useAllowList, NewUseBlockList: useBlockList, NewOwner: owner, @@ -239,11 +270,11 @@ func mintRewardTokensToWallet(polyBFTConfig PolyBFTConfig, transition *state.Tra "RewardToken.mint", transition) } -// approveRewardPoolAsSpender approves reward pool contract as reward token spender -// since reward pool distributes rewards. -func approveRewardPoolAsSpender(polyBFTConfig PolyBFTConfig, transition *state.Transition) error { +// approveEpochManagerAsSpender approves EpochManager contract as reward token spender +// since EpochManager distributes rewards +func approveEpochManagerAsSpender(polyBFTConfig PolyBFTConfig, transition *state.Transition) error { approveFn := &contractsapi.ApproveRootERC20Fn{ - Spender: contracts.RewardPoolContract, + Spender: contracts.EpochManagerContract, Amount: polyBFTConfig.RewardConfig.WalletAmount, } diff --git a/consensus/polybft/contractsapi/artifacts-gen/main.go b/consensus/polybft/contractsapi/artifacts-gen/main.go index 4f1251d0c8..138876a18e 100644 --- a/consensus/polybft/contractsapi/artifacts-gen/main.go +++ b/consensus/polybft/contractsapi/artifacts-gen/main.go @@ -22,90 +22,86 @@ const ( func main() { _, filename, _, _ := runtime.Caller(0) //nolint: dogsled currentPath := path.Dir(filename) - scpath := path.Join(currentPath, "../../../../core-contracts/artifacts/contracts/") + scpath := path.Join(currentPath, "../../../../blade-contracts/artifacts/contracts/") readContracts := []struct { Path string Name string }{ { - "child/L2StateSender.sol", + "blade/L2StateSender.sol", "L2StateSender", }, { - "child/StateReceiver.sol", + "blade/StateReceiver.sol", "StateReceiver", }, { - "child/NativeERC20.sol", + "blade/NativeERC20.sol", "NativeERC20", }, { - "child/NativeERC20Mintable.sol", - "NativeERC20Mintable", - }, - { - "child/ChildERC20.sol", + "blade/ChildERC20.sol", "ChildERC20", }, { - "child/ChildERC20Predicate.sol", + "blade/ChildERC20Predicate.sol", "ChildERC20Predicate", }, { - "child/ChildERC20PredicateAccessList.sol", + "blade/ChildERC20PredicateAccessList.sol", "ChildERC20PredicateACL", }, { - "child/RootMintableERC20Predicate.sol", + "blade/RootMintableERC20Predicate.sol", "RootMintableERC20Predicate", }, { - "child/RootMintableERC20PredicateAccessList.sol", + "blade/RootMintableERC20PredicateAccessList.sol", "RootMintableERC20PredicateACL", }, { - "child/ChildERC721.sol", + "blade/ChildERC721.sol", "ChildERC721", }, { - "child/ChildERC721Predicate.sol", + "blade/ChildERC721Predicate.sol", "ChildERC721Predicate", }, { - "child/ChildERC721PredicateAccessList.sol", + "blade/ChildERC721PredicateAccessList.sol", "ChildERC721PredicateACL", }, { - "child/RootMintableERC721Predicate.sol", + "blade/RootMintableERC721Predicate.sol", "RootMintableERC721Predicate", }, { - "child/RootMintableERC721PredicateAccessList.sol", + "blade/RootMintableERC721PredicateAccessList.sol", "RootMintableERC721PredicateACL", }, { - "child/ChildERC1155.sol", + "blade/ChildERC1155.sol", "ChildERC1155", }, { - "child/ChildERC1155Predicate.sol", + "blade/ChildERC1155Predicate.sol", "ChildERC1155Predicate", }, { - "child/ChildERC1155PredicateAccessList.sol", + "blade/ChildERC1155PredicateAccessList.sol", "ChildERC1155PredicateACL", }, { - "child/RootMintableERC1155Predicate.sol", + "blade/RootMintableERC1155Predicate.sol", "RootMintableERC1155Predicate", }, { - "child/RootMintableERC1155PredicateAccessList.sol", + "blade/RootMintableERC1155PredicateAccessList.sol", "RootMintableERC1155PredicateACL", }, { - "child/System.sol", + "blade/System.sol", "System", }, { @@ -121,15 +117,15 @@ func main() { "Merkle", }, { - "root/CheckpointManager.sol", + "bridge/CheckpointManager.sol", "CheckpointManager", }, { - "root/ExitHelper.sol", + "bridge/ExitHelper.sol", "ExitHelper", }, { - "root/StateSender.sol", + "bridge/StateSender.sol", "StateSender", }, { @@ -137,11 +133,11 @@ func main() { "MockERC20", }, { - "root/RootERC20Predicate.sol", + "bridge/RootERC20Predicate.sol", "RootERC20Predicate", }, { - "root/ChildMintableERC20Predicate.sol", + "bridge/ChildMintableERC20Predicate.sol", "ChildMintableERC20Predicate", }, { @@ -149,11 +145,11 @@ func main() { "MockERC721", }, { - "root/RootERC721Predicate.sol", + "bridge/RootERC721Predicate.sol", "RootERC721Predicate", }, { - "root/ChildMintableERC721Predicate.sol", + "bridge/ChildMintableERC721Predicate.sol", "ChildMintableERC721Predicate", }, { @@ -161,32 +157,20 @@ func main() { "MockERC1155", }, { - "root/RootERC1155Predicate.sol", + "bridge/RootERC1155Predicate.sol", "RootERC1155Predicate", }, { - "root/ChildMintableERC1155Predicate.sol", + "bridge/ChildMintableERC1155Predicate.sol", "ChildMintableERC1155Predicate", }, { - "root/staking/CustomSupernetManager.sol", - "CustomSupernetManager", - }, - { - "root/staking/StakeManager.sol", + "blade/staking/StakeManager.sol", "StakeManager", }, { - "child/validator/RewardPool.sol", - "RewardPool", - }, - { - "child/validator/ValidatorSet.sol", - "ValidatorSet", - }, - { - "child/EIP1559Burn.sol", - "EIP1559Burn", + "blade/validator/EpochManager.sol", + "EpochManager", }, { "lib/GenesisProxy.sol", diff --git a/consensus/polybft/contractsapi/bindings-gen/main.go b/consensus/polybft/contractsapi/bindings-gen/main.go index 48200897b6..24e764181a 100644 --- a/consensus/polybft/contractsapi/bindings-gen/main.go +++ b/consensus/polybft/contractsapi/bindings-gen/main.go @@ -34,7 +34,7 @@ type generatedData struct { } func main() { - cases := []struct { + contractsMetadata := []struct { contractName string artifact *artifact.Artifact generateConstructor bool @@ -140,15 +140,7 @@ func main() { false, []string{ "initialize", - }, - []string{}, - }, - { - "NativeERC20Mintable", - gensc.NativeERC20Mintable, - false, - []string{ - "initialize", + "approve", }, []string{}, }, @@ -343,74 +335,40 @@ func main() { }, []string{}, }, - { - "CustomSupernetManager", - gensc.CustomSupernetManager, - false, - []string{ - "initialize", - "whitelistValidators", - "register", - "getValidator", - "addGenesisBalance", - }, - []string{ - "ValidatorRegistered", - "AddedToWhitelist", - }, - }, { "StakeManager", gensc.StakeManager, false, []string{ "initialize", - "registerChildChain", - "stakeFor", - "releaseStakeOf", - "withdrawStake", + "stake", "stakeOf", + "withdraw", + "getValidator", + "whitelistValidators", + "register", + "unstake", }, []string{ - "ChildManagerRegistered", "StakeAdded", + "StakeRemoved", "StakeWithdrawn", - }, - }, - { - "ValidatorSet", - gensc.ValidatorSet, - false, - []string{ - "commitEpoch", - "unstake", - "initialize", - }, - []string{ + "ValidatorRegistered", + "AddedToWhitelist", "Transfer", - "WithdrawalRegistered", - "Withdrawal", }, }, { - "RewardPool", - gensc.RewardPool, + "EpochManager", + gensc.EpochManager, false, []string{ + "commitEpoch", "initialize", "distributeRewardFor", }, []string{}, }, - { - "EIP1559Burn", - gensc.EIP1559Burn, - false, - []string{ - "initialize", - }, - []string{}, - }, { "GenesisProxy", gensc.GenesisProxy, @@ -432,7 +390,7 @@ func main() { generatedData := &generatedData{} - for _, c := range cases { + for _, c := range contractsMetadata { if c.generateConstructor { if err := generateConstructor(generatedData, c.contractName, c.artifact.Abi.Constructor); err != nil { log.Fatal(err) @@ -456,12 +414,14 @@ func main() { } if err := generateFunction(generatedData, c.contractName, method, resolvedBySignature); err != nil { + fmt.Println("Contract name", c.contractName, "Function name", methodRaw) log.Fatal(err) } } for _, event := range c.events { if err := generateEvent(generatedData, c.contractName, c.artifact.Abi.Events[event]); err != nil { + fmt.Println("Contract name", c.contractName, "Event name", event) log.Fatal(err) } } diff --git a/consensus/polybft/contractsapi/contractsapi.go b/consensus/polybft/contractsapi/contractsapi.go index 87288a5f99..5afee651b7 100644 --- a/consensus/polybft/contractsapi/contractsapi.go +++ b/consensus/polybft/contractsapi/contractsapi.go @@ -493,6 +493,7 @@ func (i *InitializeRootMintableERC20PredicateACLFn) DecodeAbi(buf []byte) error type InitializeNativeERC20Fn struct { Predicate_ types.Address `abi:"predicate_"` + Owner_ types.Address `abi:"owner_"` RootToken_ types.Address `abi:"rootToken_"` Name_ string `abi:"name_"` Symbol_ string `abi:"symbol_"` @@ -512,26 +513,21 @@ func (i *InitializeNativeERC20Fn) DecodeAbi(buf []byte) error { return decodeMethod(NativeERC20.Abi.Methods["initialize"], buf, i) } -type InitializeNativeERC20MintableFn struct { - Predicate_ types.Address `abi:"predicate_"` - Owner_ types.Address `abi:"owner_"` - RootToken_ types.Address `abi:"rootToken_"` - Name_ string `abi:"name_"` - Symbol_ string `abi:"symbol_"` - Decimals_ uint8 `abi:"decimals_"` - TokenSupply_ *big.Int `abi:"tokenSupply_"` +type ApproveNativeERC20Fn struct { + Spender types.Address `abi:"spender"` + Amount *big.Int `abi:"amount"` } -func (i *InitializeNativeERC20MintableFn) Sig() []byte { - return NativeERC20Mintable.Abi.Methods["initialize"].ID() +func (a *ApproveNativeERC20Fn) Sig() []byte { + return NativeERC20.Abi.Methods["approve"].ID() } -func (i *InitializeNativeERC20MintableFn) EncodeAbi() ([]byte, error) { - return NativeERC20Mintable.Abi.Methods["initialize"].Encode(i) +func (a *ApproveNativeERC20Fn) EncodeAbi() ([]byte, error) { + return NativeERC20.Abi.Methods["approve"].Encode(a) } -func (i *InitializeNativeERC20MintableFn) DecodeAbi(buf []byte) error { - return decodeMethod(NativeERC20Mintable.Abi.Methods["initialize"], buf, i) +func (a *ApproveNativeERC20Fn) DecodeAbi(buf []byte) error { + return decodeMethod(NativeERC20.Abi.Methods["approve"], buf, a) } type InitializeRootERC20PredicateFn struct { @@ -1221,298 +1217,208 @@ func (o *OwnerOfChildERC721Fn) DecodeAbi(buf []byte) error { return decodeMethod(ChildERC721.Abi.Methods["ownerOf"], buf, o) } -type InitializeCustomSupernetManagerFn struct { - NewStakeManager types.Address `abi:"newStakeManager"` - NewBls types.Address `abi:"newBls"` - NewStateSender types.Address `abi:"newStateSender"` - NewMatic types.Address `abi:"newMatic"` - NewChildValidatorSet types.Address `abi:"newChildValidatorSet"` - NewExitHelper types.Address `abi:"newExitHelper"` - NewRootERC20Predicate types.Address `abi:"newRootERC20Predicate"` - NewDomain string `abi:"newDomain"` -} - -func (i *InitializeCustomSupernetManagerFn) Sig() []byte { - return CustomSupernetManager.Abi.Methods["initialize"].ID() -} - -func (i *InitializeCustomSupernetManagerFn) EncodeAbi() ([]byte, error) { - return CustomSupernetManager.Abi.Methods["initialize"].Encode(i) -} - -func (i *InitializeCustomSupernetManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(CustomSupernetManager.Abi.Methods["initialize"], buf, i) -} - -type WhitelistValidatorsCustomSupernetManagerFn struct { - Validators_ []ethgo.Address `abi:"validators_"` -} - -func (w *WhitelistValidatorsCustomSupernetManagerFn) Sig() []byte { - return CustomSupernetManager.Abi.Methods["whitelistValidators"].ID() -} - -func (w *WhitelistValidatorsCustomSupernetManagerFn) EncodeAbi() ([]byte, error) { - return CustomSupernetManager.Abi.Methods["whitelistValidators"].Encode(w) -} - -func (w *WhitelistValidatorsCustomSupernetManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(CustomSupernetManager.Abi.Methods["whitelistValidators"], buf, w) +type GenesisValidator struct { + Addr types.Address `abi:"addr"` + Stake *big.Int `abi:"stake"` + BlsKey [4]*big.Int `abi:"blsKey"` } -type RegisterCustomSupernetManagerFn struct { - Signature [2]*big.Int `abi:"signature"` - Pubkey [4]*big.Int `abi:"pubkey"` -} +var GenesisValidatorABIType = abi.MustNewType("tuple(address addr,uint256 stake,uint256[4] blsKey)") -func (r *RegisterCustomSupernetManagerFn) Sig() []byte { - return CustomSupernetManager.Abi.Methods["register"].ID() +func (g *GenesisValidator) EncodeAbi() ([]byte, error) { + return GenesisValidatorABIType.Encode(g) } -func (r *RegisterCustomSupernetManagerFn) EncodeAbi() ([]byte, error) { - return CustomSupernetManager.Abi.Methods["register"].Encode(r) +func (g *GenesisValidator) DecodeAbi(buf []byte) error { + return decodeStruct(GenesisValidatorABIType, buf, &g) } -func (r *RegisterCustomSupernetManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(CustomSupernetManager.Abi.Methods["register"], buf, r) -} - -type GetValidatorCustomSupernetManagerFn struct { - Validator_ types.Address `abi:"validator_"` +type InitializeStakeManagerFn struct { + NewStakingToken types.Address `abi:"newStakingToken"` + NewBls types.Address `abi:"newBls"` + EpochManager types.Address `abi:"epochManager"` + Owner types.Address `abi:"owner"` + NewDomain string `abi:"newDomain"` + GenesisValidators []*GenesisValidator `abi:"genesisValidators"` } -func (g *GetValidatorCustomSupernetManagerFn) Sig() []byte { - return CustomSupernetManager.Abi.Methods["getValidator"].ID() +func (i *InitializeStakeManagerFn) Sig() []byte { + return StakeManager.Abi.Methods["initialize"].ID() } -func (g *GetValidatorCustomSupernetManagerFn) EncodeAbi() ([]byte, error) { - return CustomSupernetManager.Abi.Methods["getValidator"].Encode(g) +func (i *InitializeStakeManagerFn) EncodeAbi() ([]byte, error) { + return StakeManager.Abi.Methods["initialize"].Encode(i) } -func (g *GetValidatorCustomSupernetManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(CustomSupernetManager.Abi.Methods["getValidator"], buf, g) +func (i *InitializeStakeManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(StakeManager.Abi.Methods["initialize"], buf, i) } -type AddGenesisBalanceCustomSupernetManagerFn struct { +type StakeStakeManagerFn struct { Amount *big.Int `abi:"amount"` } -func (a *AddGenesisBalanceCustomSupernetManagerFn) Sig() []byte { - return CustomSupernetManager.Abi.Methods["addGenesisBalance"].ID() -} - -func (a *AddGenesisBalanceCustomSupernetManagerFn) EncodeAbi() ([]byte, error) { - return CustomSupernetManager.Abi.Methods["addGenesisBalance"].Encode(a) -} - -func (a *AddGenesisBalanceCustomSupernetManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(CustomSupernetManager.Abi.Methods["addGenesisBalance"], buf, a) -} - -type ValidatorRegisteredEvent struct { - Validator types.Address `abi:"validator"` - BlsKey [4]*big.Int `abi:"blsKey"` -} - -func (*ValidatorRegisteredEvent) Sig() ethgo.Hash { - return CustomSupernetManager.Abi.Events["ValidatorRegistered"].ID() -} - -func (v *ValidatorRegisteredEvent) Encode() ([]byte, error) { - return CustomSupernetManager.Abi.Events["ValidatorRegistered"].Inputs.Encode(v) +func (s *StakeStakeManagerFn) Sig() []byte { + return StakeManager.Abi.Methods["stake"].ID() } -func (v *ValidatorRegisteredEvent) ParseLog(log *ethgo.Log) (bool, error) { - if !CustomSupernetManager.Abi.Events["ValidatorRegistered"].Match(log) { - return false, nil - } - - return true, decodeEvent(CustomSupernetManager.Abi.Events["ValidatorRegistered"], log, v) +func (s *StakeStakeManagerFn) EncodeAbi() ([]byte, error) { + return StakeManager.Abi.Methods["stake"].Encode(s) } -func (v *ValidatorRegisteredEvent) Decode(input []byte) error { - return CustomSupernetManager.Abi.Events["ValidatorRegistered"].Inputs.DecodeStruct(input, &v) +func (s *StakeStakeManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(StakeManager.Abi.Methods["stake"], buf, s) } -type AddedToWhitelistEvent struct { +type StakeOfStakeManagerFn struct { Validator types.Address `abi:"validator"` } -func (*AddedToWhitelistEvent) Sig() ethgo.Hash { - return CustomSupernetManager.Abi.Events["AddedToWhitelist"].ID() -} - -func (a *AddedToWhitelistEvent) Encode() ([]byte, error) { - return CustomSupernetManager.Abi.Events["AddedToWhitelist"].Inputs.Encode(a) +func (s *StakeOfStakeManagerFn) Sig() []byte { + return StakeManager.Abi.Methods["stakeOf"].ID() } -func (a *AddedToWhitelistEvent) ParseLog(log *ethgo.Log) (bool, error) { - if !CustomSupernetManager.Abi.Events["AddedToWhitelist"].Match(log) { - return false, nil - } - - return true, decodeEvent(CustomSupernetManager.Abi.Events["AddedToWhitelist"], log, a) +func (s *StakeOfStakeManagerFn) EncodeAbi() ([]byte, error) { + return StakeManager.Abi.Methods["stakeOf"].Encode(s) } -func (a *AddedToWhitelistEvent) Decode(input []byte) error { - return CustomSupernetManager.Abi.Events["AddedToWhitelist"].Inputs.DecodeStruct(input, &a) +func (s *StakeOfStakeManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(StakeManager.Abi.Methods["stakeOf"], buf, s) } -type InitializeStakeManagerFn struct { - NewStakingToken types.Address `abi:"newStakingToken"` +type WithdrawStakeManagerFn struct { } -func (i *InitializeStakeManagerFn) Sig() []byte { - return StakeManager.Abi.Methods["initialize"].ID() +func (w *WithdrawStakeManagerFn) Sig() []byte { + return StakeManager.Abi.Methods["withdraw"].ID() } -func (i *InitializeStakeManagerFn) EncodeAbi() ([]byte, error) { - return StakeManager.Abi.Methods["initialize"].Encode(i) +func (w *WithdrawStakeManagerFn) EncodeAbi() ([]byte, error) { + return StakeManager.Abi.Methods["withdraw"].Encode(w) } -func (i *InitializeStakeManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(StakeManager.Abi.Methods["initialize"], buf, i) +func (w *WithdrawStakeManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(StakeManager.Abi.Methods["withdraw"], buf, w) } -type RegisterChildChainStakeManagerFn struct { - Manager types.Address `abi:"manager"` +type GetValidatorStakeManagerFn struct { + Validator_ types.Address `abi:"validator_"` } -func (r *RegisterChildChainStakeManagerFn) Sig() []byte { - return StakeManager.Abi.Methods["registerChildChain"].ID() +func (g *GetValidatorStakeManagerFn) Sig() []byte { + return StakeManager.Abi.Methods["getValidator"].ID() } -func (r *RegisterChildChainStakeManagerFn) EncodeAbi() ([]byte, error) { - return StakeManager.Abi.Methods["registerChildChain"].Encode(r) +func (g *GetValidatorStakeManagerFn) EncodeAbi() ([]byte, error) { + return StakeManager.Abi.Methods["getValidator"].Encode(g) } -func (r *RegisterChildChainStakeManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(StakeManager.Abi.Methods["registerChildChain"], buf, r) +func (g *GetValidatorStakeManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(StakeManager.Abi.Methods["getValidator"], buf, g) } -type StakeForStakeManagerFn struct { - ID *big.Int `abi:"id"` - Amount *big.Int `abi:"amount"` +type WhitelistValidatorsStakeManagerFn struct { + Validators_ []ethgo.Address `abi:"validators_"` } -func (s *StakeForStakeManagerFn) Sig() []byte { - return StakeManager.Abi.Methods["stakeFor"].ID() +func (w *WhitelistValidatorsStakeManagerFn) Sig() []byte { + return StakeManager.Abi.Methods["whitelistValidators"].ID() } -func (s *StakeForStakeManagerFn) EncodeAbi() ([]byte, error) { - return StakeManager.Abi.Methods["stakeFor"].Encode(s) +func (w *WhitelistValidatorsStakeManagerFn) EncodeAbi() ([]byte, error) { + return StakeManager.Abi.Methods["whitelistValidators"].Encode(w) } -func (s *StakeForStakeManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(StakeManager.Abi.Methods["stakeFor"], buf, s) +func (w *WhitelistValidatorsStakeManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(StakeManager.Abi.Methods["whitelistValidators"], buf, w) } -type ReleaseStakeOfStakeManagerFn struct { - Validator types.Address `abi:"validator"` - Amount *big.Int `abi:"amount"` +type RegisterStakeManagerFn struct { + Signature [2]*big.Int `abi:"signature"` + Pubkey [4]*big.Int `abi:"pubkey"` } -func (r *ReleaseStakeOfStakeManagerFn) Sig() []byte { - return StakeManager.Abi.Methods["releaseStakeOf"].ID() +func (r *RegisterStakeManagerFn) Sig() []byte { + return StakeManager.Abi.Methods["register"].ID() } -func (r *ReleaseStakeOfStakeManagerFn) EncodeAbi() ([]byte, error) { - return StakeManager.Abi.Methods["releaseStakeOf"].Encode(r) +func (r *RegisterStakeManagerFn) EncodeAbi() ([]byte, error) { + return StakeManager.Abi.Methods["register"].Encode(r) } -func (r *ReleaseStakeOfStakeManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(StakeManager.Abi.Methods["releaseStakeOf"], buf, r) +func (r *RegisterStakeManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(StakeManager.Abi.Methods["register"], buf, r) } -type WithdrawStakeStakeManagerFn struct { - To types.Address `abi:"to"` - Amount *big.Int `abi:"amount"` +type UnstakeStakeManagerFn struct { + Amount *big.Int `abi:"amount"` } -func (w *WithdrawStakeStakeManagerFn) Sig() []byte { - return StakeManager.Abi.Methods["withdrawStake"].ID() +func (u *UnstakeStakeManagerFn) Sig() []byte { + return StakeManager.Abi.Methods["unstake"].ID() } -func (w *WithdrawStakeStakeManagerFn) EncodeAbi() ([]byte, error) { - return StakeManager.Abi.Methods["withdrawStake"].Encode(w) +func (u *UnstakeStakeManagerFn) EncodeAbi() ([]byte, error) { + return StakeManager.Abi.Methods["unstake"].Encode(u) } -func (w *WithdrawStakeStakeManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(StakeManager.Abi.Methods["withdrawStake"], buf, w) +func (u *UnstakeStakeManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(StakeManager.Abi.Methods["unstake"], buf, u) } -type StakeOfStakeManagerFn struct { +type StakeAddedEvent struct { Validator types.Address `abi:"validator"` - ID *big.Int `abi:"id"` -} - -func (s *StakeOfStakeManagerFn) Sig() []byte { - return StakeManager.Abi.Methods["stakeOf"].ID() -} - -func (s *StakeOfStakeManagerFn) EncodeAbi() ([]byte, error) { - return StakeManager.Abi.Methods["stakeOf"].Encode(s) -} - -func (s *StakeOfStakeManagerFn) DecodeAbi(buf []byte) error { - return decodeMethod(StakeManager.Abi.Methods["stakeOf"], buf, s) -} - -type ChildManagerRegisteredEvent struct { - ID *big.Int `abi:"id"` - Manager types.Address `abi:"manager"` + Amount *big.Int `abi:"amount"` } -func (*ChildManagerRegisteredEvent) Sig() ethgo.Hash { - return StakeManager.Abi.Events["ChildManagerRegistered"].ID() +func (*StakeAddedEvent) Sig() ethgo.Hash { + return StakeManager.Abi.Events["StakeAdded"].ID() } -func (c *ChildManagerRegisteredEvent) Encode() ([]byte, error) { - return StakeManager.Abi.Events["ChildManagerRegistered"].Inputs.Encode(c) +func (s *StakeAddedEvent) Encode() ([]byte, error) { + return StakeManager.Abi.Events["StakeAdded"].Inputs.Encode(s) } -func (c *ChildManagerRegisteredEvent) ParseLog(log *ethgo.Log) (bool, error) { - if !StakeManager.Abi.Events["ChildManagerRegistered"].Match(log) { +func (s *StakeAddedEvent) ParseLog(log *ethgo.Log) (bool, error) { + if !StakeManager.Abi.Events["StakeAdded"].Match(log) { return false, nil } - return true, decodeEvent(StakeManager.Abi.Events["ChildManagerRegistered"], log, c) + return true, decodeEvent(StakeManager.Abi.Events["StakeAdded"], log, s) } -func (c *ChildManagerRegisteredEvent) Decode(input []byte) error { - return StakeManager.Abi.Events["ChildManagerRegistered"].Inputs.DecodeStruct(input, &c) +func (s *StakeAddedEvent) Decode(input []byte) error { + return StakeManager.Abi.Events["StakeAdded"].Inputs.DecodeStruct(input, &s) } -type StakeAddedEvent struct { - ID *big.Int `abi:"id"` +type StakeRemovedEvent struct { Validator types.Address `abi:"validator"` Amount *big.Int `abi:"amount"` } -func (*StakeAddedEvent) Sig() ethgo.Hash { - return StakeManager.Abi.Events["StakeAdded"].ID() +func (*StakeRemovedEvent) Sig() ethgo.Hash { + return StakeManager.Abi.Events["StakeRemoved"].ID() } -func (s *StakeAddedEvent) Encode() ([]byte, error) { - return StakeManager.Abi.Events["StakeAdded"].Inputs.Encode(s) +func (s *StakeRemovedEvent) Encode() ([]byte, error) { + return StakeManager.Abi.Events["StakeRemoved"].Inputs.Encode(s) } -func (s *StakeAddedEvent) ParseLog(log *ethgo.Log) (bool, error) { - if !StakeManager.Abi.Events["StakeAdded"].Match(log) { +func (s *StakeRemovedEvent) ParseLog(log *ethgo.Log) (bool, error) { + if !StakeManager.Abi.Events["StakeRemoved"].Match(log) { return false, nil } - return true, decodeEvent(StakeManager.Abi.Events["StakeAdded"], log, s) + return true, decodeEvent(StakeManager.Abi.Events["StakeRemoved"], log, s) } -func (s *StakeAddedEvent) Decode(input []byte) error { - return StakeManager.Abi.Events["StakeAdded"].Inputs.DecodeStruct(input, &s) +func (s *StakeRemovedEvent) Decode(input []byte) error { + return StakeManager.Abi.Events["StakeRemoved"].Inputs.DecodeStruct(input, &s) } type StakeWithdrawnEvent struct { - Validator types.Address `abi:"validator"` - Recipient types.Address `abi:"recipient"` - Amount *big.Int `abi:"amount"` + Account types.Address `abi:"account"` + Amount *big.Int `abi:"amount"` } func (*StakeWithdrawnEvent) Sig() ethgo.Hash { @@ -1535,88 +1441,53 @@ func (s *StakeWithdrawnEvent) Decode(input []byte) error { return StakeManager.Abi.Events["StakeWithdrawn"].Inputs.DecodeStruct(input, &s) } -type Epoch struct { - StartBlock *big.Int `abi:"startBlock"` - EndBlock *big.Int `abi:"endBlock"` - EpochRoot types.Hash `abi:"epochRoot"` -} - -var EpochABIType = abi.MustNewType("tuple(uint256 startBlock,uint256 endBlock,bytes32 epochRoot)") - -func (e *Epoch) EncodeAbi() ([]byte, error) { - return EpochABIType.Encode(e) -} - -func (e *Epoch) DecodeAbi(buf []byte) error { - return decodeStruct(EpochABIType, buf, &e) -} - -type CommitEpochValidatorSetFn struct { - ID *big.Int `abi:"id"` - Epoch *Epoch `abi:"epoch"` -} - -func (c *CommitEpochValidatorSetFn) Sig() []byte { - return ValidatorSet.Abi.Methods["commitEpoch"].ID() -} - -func (c *CommitEpochValidatorSetFn) EncodeAbi() ([]byte, error) { - return ValidatorSet.Abi.Methods["commitEpoch"].Encode(c) -} - -func (c *CommitEpochValidatorSetFn) DecodeAbi(buf []byte) error { - return decodeMethod(ValidatorSet.Abi.Methods["commitEpoch"], buf, c) +type ValidatorRegisteredEvent struct { + Validator types.Address `abi:"validator"` + BlsKey [4]*big.Int `abi:"blsKey"` } -type UnstakeValidatorSetFn struct { - Amount *big.Int `abi:"amount"` +func (*ValidatorRegisteredEvent) Sig() ethgo.Hash { + return StakeManager.Abi.Events["ValidatorRegistered"].ID() } -func (u *UnstakeValidatorSetFn) Sig() []byte { - return ValidatorSet.Abi.Methods["unstake"].ID() +func (v *ValidatorRegisteredEvent) Encode() ([]byte, error) { + return StakeManager.Abi.Events["ValidatorRegistered"].Inputs.Encode(v) } -func (u *UnstakeValidatorSetFn) EncodeAbi() ([]byte, error) { - return ValidatorSet.Abi.Methods["unstake"].Encode(u) -} +func (v *ValidatorRegisteredEvent) ParseLog(log *ethgo.Log) (bool, error) { + if !StakeManager.Abi.Events["ValidatorRegistered"].Match(log) { + return false, nil + } -func (u *UnstakeValidatorSetFn) DecodeAbi(buf []byte) error { - return decodeMethod(ValidatorSet.Abi.Methods["unstake"], buf, u) + return true, decodeEvent(StakeManager.Abi.Events["ValidatorRegistered"], log, v) } -type ValidatorInit struct { - Addr types.Address `abi:"addr"` - Stake *big.Int `abi:"stake"` +func (v *ValidatorRegisteredEvent) Decode(input []byte) error { + return StakeManager.Abi.Events["ValidatorRegistered"].Inputs.DecodeStruct(input, &v) } -var ValidatorInitABIType = abi.MustNewType("tuple(address addr,uint256 stake)") - -func (v *ValidatorInit) EncodeAbi() ([]byte, error) { - return ValidatorInitABIType.Encode(v) +type AddedToWhitelistEvent struct { + Validator types.Address `abi:"validator"` } -func (v *ValidatorInit) DecodeAbi(buf []byte) error { - return decodeStruct(ValidatorInitABIType, buf, &v) +func (*AddedToWhitelistEvent) Sig() ethgo.Hash { + return StakeManager.Abi.Events["AddedToWhitelist"].ID() } -type InitializeValidatorSetFn struct { - NewStateSender types.Address `abi:"newStateSender"` - NewStateReceiver types.Address `abi:"newStateReceiver"` - NewRootChainManager types.Address `abi:"newRootChainManager"` - NewEpochSize *big.Int `abi:"newEpochSize"` - InitialValidators []*ValidatorInit `abi:"initialValidators"` +func (a *AddedToWhitelistEvent) Encode() ([]byte, error) { + return StakeManager.Abi.Events["AddedToWhitelist"].Inputs.Encode(a) } -func (i *InitializeValidatorSetFn) Sig() []byte { - return ValidatorSet.Abi.Methods["initialize"].ID() -} +func (a *AddedToWhitelistEvent) ParseLog(log *ethgo.Log) (bool, error) { + if !StakeManager.Abi.Events["AddedToWhitelist"].Match(log) { + return false, nil + } -func (i *InitializeValidatorSetFn) EncodeAbi() ([]byte, error) { - return ValidatorSet.Abi.Methods["initialize"].Encode(i) + return true, decodeEvent(StakeManager.Abi.Events["AddedToWhitelist"], log, a) } -func (i *InitializeValidatorSetFn) DecodeAbi(buf []byte) error { - return decodeMethod(ValidatorSet.Abi.Methods["initialize"], buf, i) +func (a *AddedToWhitelistEvent) Decode(input []byte) error { + return StakeManager.Abi.Events["AddedToWhitelist"].Inputs.DecodeStruct(input, &a) } type TransferEvent struct { @@ -1626,92 +1497,76 @@ type TransferEvent struct { } func (*TransferEvent) Sig() ethgo.Hash { - return ValidatorSet.Abi.Events["Transfer"].ID() + return StakeManager.Abi.Events["Transfer"].ID() } func (t *TransferEvent) Encode() ([]byte, error) { - return ValidatorSet.Abi.Events["Transfer"].Inputs.Encode(t) + return StakeManager.Abi.Events["Transfer"].Inputs.Encode(t) } func (t *TransferEvent) ParseLog(log *ethgo.Log) (bool, error) { - if !ValidatorSet.Abi.Events["Transfer"].Match(log) { + if !StakeManager.Abi.Events["Transfer"].Match(log) { return false, nil } - return true, decodeEvent(ValidatorSet.Abi.Events["Transfer"], log, t) + return true, decodeEvent(StakeManager.Abi.Events["Transfer"], log, t) } func (t *TransferEvent) Decode(input []byte) error { - return ValidatorSet.Abi.Events["Transfer"].Inputs.DecodeStruct(input, &t) + return StakeManager.Abi.Events["Transfer"].Inputs.DecodeStruct(input, &t) } -type WithdrawalRegisteredEvent struct { - Account types.Address `abi:"account"` - Amount *big.Int `abi:"amount"` -} - -func (*WithdrawalRegisteredEvent) Sig() ethgo.Hash { - return ValidatorSet.Abi.Events["WithdrawalRegistered"].ID() -} - -func (w *WithdrawalRegisteredEvent) Encode() ([]byte, error) { - return ValidatorSet.Abi.Events["WithdrawalRegistered"].Inputs.Encode(w) +type Epoch struct { + StartBlock *big.Int `abi:"startBlock"` + EndBlock *big.Int `abi:"endBlock"` + EpochRoot types.Hash `abi:"epochRoot"` } -func (w *WithdrawalRegisteredEvent) ParseLog(log *ethgo.Log) (bool, error) { - if !ValidatorSet.Abi.Events["WithdrawalRegistered"].Match(log) { - return false, nil - } - - return true, decodeEvent(ValidatorSet.Abi.Events["WithdrawalRegistered"], log, w) -} +var EpochABIType = abi.MustNewType("tuple(uint256 startBlock,uint256 endBlock,bytes32 epochRoot)") -func (w *WithdrawalRegisteredEvent) Decode(input []byte) error { - return ValidatorSet.Abi.Events["WithdrawalRegistered"].Inputs.DecodeStruct(input, &w) +func (e *Epoch) EncodeAbi() ([]byte, error) { + return EpochABIType.Encode(e) } -type WithdrawalEvent struct { - Account types.Address `abi:"account"` - Amount *big.Int `abi:"amount"` +func (e *Epoch) DecodeAbi(buf []byte) error { + return decodeStruct(EpochABIType, buf, &e) } -func (*WithdrawalEvent) Sig() ethgo.Hash { - return ValidatorSet.Abi.Events["Withdrawal"].ID() +type CommitEpochEpochManagerFn struct { + ID *big.Int `abi:"id"` + Epoch *Epoch `abi:"epoch"` } -func (w *WithdrawalEvent) Encode() ([]byte, error) { - return ValidatorSet.Abi.Events["Withdrawal"].Inputs.Encode(w) +func (c *CommitEpochEpochManagerFn) Sig() []byte { + return EpochManager.Abi.Methods["commitEpoch"].ID() } -func (w *WithdrawalEvent) ParseLog(log *ethgo.Log) (bool, error) { - if !ValidatorSet.Abi.Events["Withdrawal"].Match(log) { - return false, nil - } - - return true, decodeEvent(ValidatorSet.Abi.Events["Withdrawal"], log, w) +func (c *CommitEpochEpochManagerFn) EncodeAbi() ([]byte, error) { + return EpochManager.Abi.Methods["commitEpoch"].Encode(c) } -func (w *WithdrawalEvent) Decode(input []byte) error { - return ValidatorSet.Abi.Events["Withdrawal"].Inputs.DecodeStruct(input, &w) +func (c *CommitEpochEpochManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(EpochManager.Abi.Methods["commitEpoch"], buf, c) } -type InitializeRewardPoolFn struct { +type InitializeEpochManagerFn struct { + NewStakeManager types.Address `abi:"newStakeManager"` NewRewardToken types.Address `abi:"newRewardToken"` NewRewardWallet types.Address `abi:"newRewardWallet"` - NewValidatorSet types.Address `abi:"newValidatorSet"` NewBaseReward *big.Int `abi:"newBaseReward"` + NewEpochSize *big.Int `abi:"newEpochSize"` } -func (i *InitializeRewardPoolFn) Sig() []byte { - return RewardPool.Abi.Methods["initialize"].ID() +func (i *InitializeEpochManagerFn) Sig() []byte { + return EpochManager.Abi.Methods["initialize"].ID() } -func (i *InitializeRewardPoolFn) EncodeAbi() ([]byte, error) { - return RewardPool.Abi.Methods["initialize"].Encode(i) +func (i *InitializeEpochManagerFn) EncodeAbi() ([]byte, error) { + return EpochManager.Abi.Methods["initialize"].Encode(i) } -func (i *InitializeRewardPoolFn) DecodeAbi(buf []byte) error { - return decodeMethod(RewardPool.Abi.Methods["initialize"], buf, i) +func (i *InitializeEpochManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(EpochManager.Abi.Methods["initialize"], buf, i) } type Uptime struct { @@ -1729,38 +1584,21 @@ func (u *Uptime) DecodeAbi(buf []byte) error { return decodeStruct(UptimeABIType, buf, &u) } -type DistributeRewardForRewardPoolFn struct { +type DistributeRewardForEpochManagerFn struct { EpochID *big.Int `abi:"epochId"` Uptime []*Uptime `abi:"uptime"` } -func (d *DistributeRewardForRewardPoolFn) Sig() []byte { - return RewardPool.Abi.Methods["distributeRewardFor"].ID() -} - -func (d *DistributeRewardForRewardPoolFn) EncodeAbi() ([]byte, error) { - return RewardPool.Abi.Methods["distributeRewardFor"].Encode(d) -} - -func (d *DistributeRewardForRewardPoolFn) DecodeAbi(buf []byte) error { - return decodeMethod(RewardPool.Abi.Methods["distributeRewardFor"], buf, d) -} - -type InitializeEIP1559BurnFn struct { - NewChildERC20Predicate types.Address `abi:"newChildERC20Predicate"` - NewBurnDestination types.Address `abi:"newBurnDestination"` -} - -func (i *InitializeEIP1559BurnFn) Sig() []byte { - return EIP1559Burn.Abi.Methods["initialize"].ID() +func (d *DistributeRewardForEpochManagerFn) Sig() []byte { + return EpochManager.Abi.Methods["distributeRewardFor"].ID() } -func (i *InitializeEIP1559BurnFn) EncodeAbi() ([]byte, error) { - return EIP1559Burn.Abi.Methods["initialize"].Encode(i) +func (d *DistributeRewardForEpochManagerFn) EncodeAbi() ([]byte, error) { + return EpochManager.Abi.Methods["distributeRewardFor"].Encode(d) } -func (i *InitializeEIP1559BurnFn) DecodeAbi(buf []byte) error { - return decodeMethod(EIP1559Burn.Abi.Methods["initialize"], buf, i) +func (d *DistributeRewardForEpochManagerFn) DecodeAbi(buf []byte) error { + return decodeMethod(EpochManager.Abi.Methods["distributeRewardFor"], buf, d) } type ProtectSetUpProxyGenesisProxyFn struct { diff --git a/consensus/polybft/contractsapi/contractsapi_test.go b/consensus/polybft/contractsapi/contractsapi_test.go index 153631d73e..2052bf3ad5 100644 --- a/consensus/polybft/contractsapi/contractsapi_test.go +++ b/consensus/polybft/contractsapi/contractsapi_test.go @@ -33,7 +33,7 @@ func TestEncoding_Method(t *testing.T) { Bitmap: []byte{}, }, // empty commit epoch - &CommitEpochValidatorSetFn{ + &CommitEpochEpochManagerFn{ ID: big.NewInt(1), Epoch: &Epoch{ StartBlock: big.NewInt(1), diff --git a/consensus/polybft/contractsapi/gen_sc_data.go b/consensus/polybft/contractsapi/gen_sc_data.go index 0f26c30503..5abfd988ea 100644 --- a/consensus/polybft/contractsapi/gen_sc_data.go +++ b/consensus/polybft/contractsapi/gen_sc_data.go @@ -1,45 +1,41 @@ // This is auto-generated file. DO NOT EDIT. package contractsapi -var L2StateSenderArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"L2StateSender","sourceName":"contracts/child/L2StateSender.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"bytes","name":"data","type":"bytes"}],"name":"L2StateSynced","type":"event"},{"inputs":[],"name":"MAX_LENGTH","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"counter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"syncState","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50610297806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806316f198311461004657806361bc221a1461005b578063a6f9885c14610076575b600080fd5b61005961005436600461017a565b61007f565b005b61006460005481565b60405190815260200160405180910390f35b61006461080081565b6001600160a01b0383166100cd5760405162461bcd60e51b815260206004820152601060248201526f24a72b20a624a22fa922a1a2a4ab22a960811b60448201526064015b60405180910390fd5b6108008111156101145760405162461bcd60e51b815260206004820152601260248201527108ab0868a8a88a6be9a82b0be988a9c8ea8960731b60448201526064016100c4565b826001600160a01b0316336001600160a01b031660008081546101369061020b565b9190508190557fedaf3c471ebd67d60c29efe34b639ede7d6a1d92eaeb3f503e784971e67118a5858560405161016d929190610232565b60405180910390a4505050565b60008060006040848603121561018f57600080fd5b83356001600160a01b03811681146101a657600080fd5b9250602084013567ffffffffffffffff808211156101c357600080fd5b818601915086601f8301126101d757600080fd5b8135818111156101e657600080fd5b8760208285010111156101f857600080fd5b6020830194508093505050509250925092565b60006001820161022b57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea264697066735822122041815082e2111df07ce129b83f0000ecca6c4886247dffeae7090f8f048b665164736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100415760003560e01c806316f198311461004657806361bc221a1461005b578063a6f9885c14610076575b600080fd5b61005961005436600461017a565b61007f565b005b61006460005481565b60405190815260200160405180910390f35b61006461080081565b6001600160a01b0383166100cd5760405162461bcd60e51b815260206004820152601060248201526f24a72b20a624a22fa922a1a2a4ab22a960811b60448201526064015b60405180910390fd5b6108008111156101145760405162461bcd60e51b815260206004820152601260248201527108ab0868a8a88a6be9a82b0be988a9c8ea8960731b60448201526064016100c4565b826001600160a01b0316336001600160a01b031660008081546101369061020b565b9190508190557fedaf3c471ebd67d60c29efe34b639ede7d6a1d92eaeb3f503e784971e67118a5858560405161016d929190610232565b60405180910390a4505050565b60008060006040848603121561018f57600080fd5b83356001600160a01b03811681146101a657600080fd5b9250602084013567ffffffffffffffff808211156101c357600080fd5b818601915086601f8301126101d757600080fd5b8135818111156101e657600080fd5b8760208285010111156101f857600080fd5b6020830194508093505050509250925092565b60006001820161022b57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea264697066735822122041815082e2111df07ce129b83f0000ecca6c4886247dffeae7090f8f048b665164736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var StateReceiverArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"StateReceiver","sourceName":"contracts/child/StateReceiver.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"startId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"endId","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"root","type":"bytes32"}],"name":"NewCommitment","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"counter","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"},{"indexed":false,"internalType":"bytes","name":"message","type":"bytes"}],"name":"StateSyncResult","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[][]","name":"proofs","type":"bytes32[][]"},{"components":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"internalType":"struct StateReceiver.StateSync[]","name":"objs","type":"tuple[]"}],"name":"batchExecute","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"startId","type":"uint256"},{"internalType":"uint256","name":"endId","type":"uint256"},{"internalType":"bytes32","name":"root","type":"bytes32"}],"internalType":"struct StateReceiver.StateSyncCommitment","name":"commitment","type":"tuple"},{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"bytes","name":"bitmap","type":"bytes"}],"name":"commit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"commitmentCounter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"commitmentIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"commitments","outputs":[{"internalType":"uint256","name":"startId","type":"uint256"},{"internalType":"uint256","name":"endId","type":"uint256"},{"internalType":"bytes32","name":"root","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"},{"components":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"internalType":"struct StateReceiver.StateSync","name":"obj","type":"tuple"}],"name":"execute","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getCommitmentByStateSyncId","outputs":[{"components":[{"internalType":"uint256","name":"startId","type":"uint256"},{"internalType":"uint256","name":"endId","type":"uint256"},{"internalType":"bytes32","name":"root","type":"bytes32"}],"internalType":"struct StateReceiver.StateSyncCommitment","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getRootByStateSyncId","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lastCommittedId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"processedStateSyncs","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611244806100206000396000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c806355b01e4d116100ad578063ad240c2a11610071578063ad240c2a1461026a578063c59a18f714610273578063c6df461714610286578063e0563ab114610299578063eb70ef44146102a257600080fd5b806355b01e4d1461022d5780635ea5df791461023b5780639017c12714610244578063947287cf1461025757806397e5230d1461026057600080fd5b80633b878c22116100f45780633b878c221461018457806349ce89971461018d57806350d5b95b146101d757806351351d53146101ec578063544c5e0f146101fa57600080fd5b806307b3e25214610126578063196f1b2d1461015157806323e281cf14610172578063284017f51461017b575b600080fd5b6101346004600360981b0181565b6040516001600160a01b0390911681526020015b60405180910390f35b61016461015f366004610cd6565b6102d7565b604051908152602001610148565b61016460325481565b61013461202081565b61013461101081565b6101bc61019b366004610cd6565b60356020526000908152604090208054600182015460029092015490919083565b60408051938452602084019290925290820152606001610148565b6101ea6101e5366004610d3a565b610356565b005b6101346002600160a01b0381565b61021d610208366004610cd6565b60346020526000908152604090205460ff1681565b6040519015158152602001610148565b6101346004600160991b0181565b61016461138881565b6101ea610252366004610da9565b61041d565b61016461520881565b610164620249f081565b61016460335481565b610164610281366004610cd6565b6105bd565b6101ea610294366004610e55565b6105de565b61013461203081565b6102b56102b0366004610cd6565b6107c2565b6040805182518152602080840151908201529181015190820152606001610148565b6000806035816102e8603686610885565b81526020810191909152604001600020600201549050806103505760405162461bcd60e51b815260206004820152601d60248201527f537461746552656365697665723a204e4f5f524f4f545f464f525f494400000060448201526064015b60405180910390fd5b92915050565b600061036282356107c2565b80519091506103d290610376908435610ef3565b825160208401516103879190610ef3565b610392906001610f06565b83604001518787876040516020016103aa9190610f5e565b604051602081830303815290604052805190602001206109329095949392919063ffffffff16565b61040e5760405162461bcd60e51b815260206004820152600d60248201526c24a72b20a624a22fa82927a7a360991b6044820152606401610347565b61041782610995565b50505050565b828181146104805760405162461bcd60e51b815260206004820152602a60248201527f537461746552656365697665723a20554e4d4154434845445f4c454e4754485f604482015269504152414d455445525360b01b6064820152608401610347565b60005b818110156105b55760006104ba8585848181106104a2576104a2610ffa565b90506020028101906104b49190611010565b356107c2565b9050600061056e82600001518787868181106104d8576104d8610ffa565b90506020028101906104ea9190611010565b6104f5919035610ef3565b835160208501516105069190610ef3565b610511906001610f06565b84604001518b8b8881811061052857610528610ffa565b905060200281019061053a9190611030565b8b8b8a81811061054c5761054c610ffa565b905060200281019061055e9190611010565b6040516020016103aa9190610f5e565b90508061057f575050600101610483565b6105ab86868581811061059457610594610ffa565b90506020028101906105a69190611010565b610995565b5050600101610483565b505050505050565b603681815481106105cd57600080fd5b600091825260209091200154905081565b336002600160a01b03146106225760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610347565b603354610630906001610f06565b8535146106725760405162461bcd60e51b815260206004820152601060248201526f1253959053125117d4d510549517d25160821b6044820152606401610347565b8435602086013510156106b85760405162461bcd60e51b815260206004820152600e60248201526d1253959053125117d1539117d25160921b6044820152606401610347565b604080518635602080830191909152870135818301529086013560608201526106fd906080016040516020818303038152906040528051906020012085858585610bb0565b6032805486916035916000918261071383611079565b90915550815260208082019290925260409081016000208335815591830135600183015582013560028201555050603680546001810182556000919091526020868101357f4a11f94e20a93c79f6ec743a1954ec4fc2c08429ae2122118bf234b2185c81b89092018290556033829055604080519088013581528735917f11efd893530b26afc66d488ff54cb15df117cb6e0e4a08c6dcb166d766c3bf3b910160405180910390a35050505050565b60408051606081018252600080825260208201819052918101829052906107ea603684610885565b603654909150810361084a5760405162461bcd60e51b815260206004820152602360248201527f537461746552656365697665723a204e4f5f434f4d4d49544d454e545f464f5260448201526217d25160ea1b6064820152608401610347565b600090815260356020908152604091829020825160608101845281548152600182015492810192909252600201549181019190915292915050565b8154600090810361089857506000610350565b82546000905b808210156108e55760006108b28383610cb4565b600087815260209020909150859082015411156108d1578091506108df565b6108dc816001610f06565b92505b5061089e565b60008211801561091157508361090e86610900600186610ef3565b600091825260209091200190565b54145b1561092a57610921600183610ef3565b92505050610350565b509392505050565b60008115610971578160051b8301835b8760011660051b8981528135602082185250604060002098508760011c97506020810190508181106109425750505b85158488141660018084031b8611600180851b018710161690509695505050505050565b803560009081526034602052604090205460ff1615610a055760405162461bcd60e51b815260206004820152602660248201527f537461746552656365697665723a2053544154455f53594e435f49535f50524f60448201526510d154d4d15160d21b6064820152608401610347565b610a156060820160408301611092565b6001600160a01b03163b600003610a69576040805160208082526000908201819052918335917f31c652130602f3ce96ceaf8a4c2b8b49f049166c6fcf2eb31943a75ec7c936ae910160405180910390a350565b8035600090815260346020526040808220805460ff191660011790558190610a979060608501908501611092565b6001600160a01b03168335610ab26040860160208701611092565b610abf60608701876110ad565b604051602401610ad294939291906110f3565b60408051601f198184030181529181526020820180516001600160e01b031663eeb4994560e01b17905251610b07919061114c565b6000604051808303816000865af19150503d8060008114610b44576040519150601f19603f3d011682016040523d82523d6000602084013e610b49565b606091505b509150915081610b6c5782356000908152603460205260409020805460ff191690555b81151583600001357f31c652130602f3ce96ceaf8a4c2b8b49f049166c6fcf2eb31943a75ec7c936ae83604051610ba3919061115e565b60405180910390a3505050565b6000806120306001600160a01b0316620249f08888888888604051602001610bdc959493929190611191565b60408051601f1981840301815290829052610bf69161114c565b6000604051808303818686fa925050503d8060008114610c32576040519150601f19603f3d011682016040523d82523d6000602084013e610c37565b606091505b5091509150600081806020019051810190610c5291906111ca565b9050828015610c5e5750805b610caa5760405162461bcd60e51b815260206004820152601d60248201527f5349474e41545552455f564552494649434154494f4e5f4641494c45440000006044820152606401610347565b5050505050505050565b6000610cc360028484186111ec565b610ccf90848416610f06565b9392505050565b600060208284031215610ce857600080fd5b5035919050565b60008083601f840112610d0157600080fd5b5081356001600160401b03811115610d1857600080fd5b6020830191508360208260051b8501011115610d3357600080fd5b9250929050565b600080600060408486031215610d4f57600080fd5b83356001600160401b0380821115610d6657600080fd5b610d7287838801610cef565b90955093506020860135915080821115610d8b57600080fd5b50840160808187031215610d9e57600080fd5b809150509250925092565b60008060008060408587031215610dbf57600080fd5b84356001600160401b0380821115610dd657600080fd5b610de288838901610cef565b90965094506020870135915080821115610dfb57600080fd5b50610e0887828801610cef565b95989497509550505050565b60008083601f840112610e2657600080fd5b5081356001600160401b03811115610e3d57600080fd5b602083019150836020828501011115610d3357600080fd5b600080600080600085870360a0811215610e6e57600080fd5b6060811215610e7c57600080fd5b5085945060608601356001600160401b0380821115610e9a57600080fd5b610ea689838a01610e14565b90965094506080880135915080821115610ebf57600080fd5b50610ecc88828901610e14565b969995985093965092949392505050565b634e487b7160e01b600052601160045260246000fd5b8181038181111561035057610350610edd565b8082018082111561035057610350610edd565b80356001600160a01b0381168114610f3057600080fd5b919050565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b60208152813560208201526000610f7760208401610f19565b60018060a01b03808216604085015280610f9360408701610f19565b16606085015250506060830135601e19843603018112610fb257600080fd5b83016020810190356001600160401b03811115610fce57600080fd5b803603821315610fdd57600080fd5b608080850152610ff160a085018284610f35565b95945050505050565b634e487b7160e01b600052603260045260246000fd5b60008235607e1983360301811261102657600080fd5b9190910192915050565b6000808335601e1984360301811261104757600080fd5b8301803591506001600160401b0382111561106157600080fd5b6020019150600581901b3603821315610d3357600080fd5b60006001820161108b5761108b610edd565b5060010190565b6000602082840312156110a457600080fd5b610ccf82610f19565b6000808335601e198436030181126110c457600080fd5b8301803591506001600160401b038211156110de57600080fd5b602001915036819003821315610d3357600080fd5b8481526001600160a01b038416602082015260606040820181905260009061111e9083018486610f35565b9695505050505050565b60005b8381101561114357818101518382015260200161112b565b50506000910152565b60008251611026818460208701611128565b602081526000825180602084015261117d816040850160208701611128565b601f01601f19169190910160400192915050565b8581526060602082015260006111ab606083018688610f35565b82810360408401526111be818587610f35565b98975050505050505050565b6000602082840312156111dc57600080fd5b81518015158114610ccf57600080fd5b60008261120957634e487b7160e01b600052601260045260246000fd5b50049056fea26469706673582212205e465487d9414dfe77390f61a0c38958de52ee524ceeb4baa7548b12c5998a1564736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101215760003560e01c806355b01e4d116100ad578063ad240c2a11610071578063ad240c2a1461026a578063c59a18f714610273578063c6df461714610286578063e0563ab114610299578063eb70ef44146102a257600080fd5b806355b01e4d1461022d5780635ea5df791461023b5780639017c12714610244578063947287cf1461025757806397e5230d1461026057600080fd5b80633b878c22116100f45780633b878c221461018457806349ce89971461018d57806350d5b95b146101d757806351351d53146101ec578063544c5e0f146101fa57600080fd5b806307b3e25214610126578063196f1b2d1461015157806323e281cf14610172578063284017f51461017b575b600080fd5b6101346004600360981b0181565b6040516001600160a01b0390911681526020015b60405180910390f35b61016461015f366004610cd6565b6102d7565b604051908152602001610148565b61016460325481565b61013461202081565b61013461101081565b6101bc61019b366004610cd6565b60356020526000908152604090208054600182015460029092015490919083565b60408051938452602084019290925290820152606001610148565b6101ea6101e5366004610d3a565b610356565b005b6101346002600160a01b0381565b61021d610208366004610cd6565b60346020526000908152604090205460ff1681565b6040519015158152602001610148565b6101346004600160991b0181565b61016461138881565b6101ea610252366004610da9565b61041d565b61016461520881565b610164620249f081565b61016460335481565b610164610281366004610cd6565b6105bd565b6101ea610294366004610e55565b6105de565b61013461203081565b6102b56102b0366004610cd6565b6107c2565b6040805182518152602080840151908201529181015190820152606001610148565b6000806035816102e8603686610885565b81526020810191909152604001600020600201549050806103505760405162461bcd60e51b815260206004820152601d60248201527f537461746552656365697665723a204e4f5f524f4f545f464f525f494400000060448201526064015b60405180910390fd5b92915050565b600061036282356107c2565b80519091506103d290610376908435610ef3565b825160208401516103879190610ef3565b610392906001610f06565b83604001518787876040516020016103aa9190610f5e565b604051602081830303815290604052805190602001206109329095949392919063ffffffff16565b61040e5760405162461bcd60e51b815260206004820152600d60248201526c24a72b20a624a22fa82927a7a360991b6044820152606401610347565b61041782610995565b50505050565b828181146104805760405162461bcd60e51b815260206004820152602a60248201527f537461746552656365697665723a20554e4d4154434845445f4c454e4754485f604482015269504152414d455445525360b01b6064820152608401610347565b60005b818110156105b55760006104ba8585848181106104a2576104a2610ffa565b90506020028101906104b49190611010565b356107c2565b9050600061056e82600001518787868181106104d8576104d8610ffa565b90506020028101906104ea9190611010565b6104f5919035610ef3565b835160208501516105069190610ef3565b610511906001610f06565b84604001518b8b8881811061052857610528610ffa565b905060200281019061053a9190611030565b8b8b8a81811061054c5761054c610ffa565b905060200281019061055e9190611010565b6040516020016103aa9190610f5e565b90508061057f575050600101610483565b6105ab86868581811061059457610594610ffa565b90506020028101906105a69190611010565b610995565b5050600101610483565b505050505050565b603681815481106105cd57600080fd5b600091825260209091200154905081565b336002600160a01b03146106225760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610347565b603354610630906001610f06565b8535146106725760405162461bcd60e51b815260206004820152601060248201526f1253959053125117d4d510549517d25160821b6044820152606401610347565b8435602086013510156106b85760405162461bcd60e51b815260206004820152600e60248201526d1253959053125117d1539117d25160921b6044820152606401610347565b604080518635602080830191909152870135818301529086013560608201526106fd906080016040516020818303038152906040528051906020012085858585610bb0565b6032805486916035916000918261071383611079565b90915550815260208082019290925260409081016000208335815591830135600183015582013560028201555050603680546001810182556000919091526020868101357f4a11f94e20a93c79f6ec743a1954ec4fc2c08429ae2122118bf234b2185c81b89092018290556033829055604080519088013581528735917f11efd893530b26afc66d488ff54cb15df117cb6e0e4a08c6dcb166d766c3bf3b910160405180910390a35050505050565b60408051606081018252600080825260208201819052918101829052906107ea603684610885565b603654909150810361084a5760405162461bcd60e51b815260206004820152602360248201527f537461746552656365697665723a204e4f5f434f4d4d49544d454e545f464f5260448201526217d25160ea1b6064820152608401610347565b600090815260356020908152604091829020825160608101845281548152600182015492810192909252600201549181019190915292915050565b8154600090810361089857506000610350565b82546000905b808210156108e55760006108b28383610cb4565b600087815260209020909150859082015411156108d1578091506108df565b6108dc816001610f06565b92505b5061089e565b60008211801561091157508361090e86610900600186610ef3565b600091825260209091200190565b54145b1561092a57610921600183610ef3565b92505050610350565b509392505050565b60008115610971578160051b8301835b8760011660051b8981528135602082185250604060002098508760011c97506020810190508181106109425750505b85158488141660018084031b8611600180851b018710161690509695505050505050565b803560009081526034602052604090205460ff1615610a055760405162461bcd60e51b815260206004820152602660248201527f537461746552656365697665723a2053544154455f53594e435f49535f50524f60448201526510d154d4d15160d21b6064820152608401610347565b610a156060820160408301611092565b6001600160a01b03163b600003610a69576040805160208082526000908201819052918335917f31c652130602f3ce96ceaf8a4c2b8b49f049166c6fcf2eb31943a75ec7c936ae910160405180910390a350565b8035600090815260346020526040808220805460ff191660011790558190610a979060608501908501611092565b6001600160a01b03168335610ab26040860160208701611092565b610abf60608701876110ad565b604051602401610ad294939291906110f3565b60408051601f198184030181529181526020820180516001600160e01b031663eeb4994560e01b17905251610b07919061114c565b6000604051808303816000865af19150503d8060008114610b44576040519150601f19603f3d011682016040523d82523d6000602084013e610b49565b606091505b509150915081610b6c5782356000908152603460205260409020805460ff191690555b81151583600001357f31c652130602f3ce96ceaf8a4c2b8b49f049166c6fcf2eb31943a75ec7c936ae83604051610ba3919061115e565b60405180910390a3505050565b6000806120306001600160a01b0316620249f08888888888604051602001610bdc959493929190611191565b60408051601f1981840301815290829052610bf69161114c565b6000604051808303818686fa925050503d8060008114610c32576040519150601f19603f3d011682016040523d82523d6000602084013e610c37565b606091505b5091509150600081806020019051810190610c5291906111ca565b9050828015610c5e5750805b610caa5760405162461bcd60e51b815260206004820152601d60248201527f5349474e41545552455f564552494649434154494f4e5f4641494c45440000006044820152606401610347565b5050505050505050565b6000610cc360028484186111ec565b610ccf90848416610f06565b9392505050565b600060208284031215610ce857600080fd5b5035919050565b60008083601f840112610d0157600080fd5b5081356001600160401b03811115610d1857600080fd5b6020830191508360208260051b8501011115610d3357600080fd5b9250929050565b600080600060408486031215610d4f57600080fd5b83356001600160401b0380821115610d6657600080fd5b610d7287838801610cef565b90955093506020860135915080821115610d8b57600080fd5b50840160808187031215610d9e57600080fd5b809150509250925092565b60008060008060408587031215610dbf57600080fd5b84356001600160401b0380821115610dd657600080fd5b610de288838901610cef565b90965094506020870135915080821115610dfb57600080fd5b50610e0887828801610cef565b95989497509550505050565b60008083601f840112610e2657600080fd5b5081356001600160401b03811115610e3d57600080fd5b602083019150836020828501011115610d3357600080fd5b600080600080600085870360a0811215610e6e57600080fd5b6060811215610e7c57600080fd5b5085945060608601356001600160401b0380821115610e9a57600080fd5b610ea689838a01610e14565b90965094506080880135915080821115610ebf57600080fd5b50610ecc88828901610e14565b969995985093965092949392505050565b634e487b7160e01b600052601160045260246000fd5b8181038181111561035057610350610edd565b8082018082111561035057610350610edd565b80356001600160a01b0381168114610f3057600080fd5b919050565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b60208152813560208201526000610f7760208401610f19565b60018060a01b03808216604085015280610f9360408701610f19565b16606085015250506060830135601e19843603018112610fb257600080fd5b83016020810190356001600160401b03811115610fce57600080fd5b803603821315610fdd57600080fd5b608080850152610ff160a085018284610f35565b95945050505050565b634e487b7160e01b600052603260045260246000fd5b60008235607e1983360301811261102657600080fd5b9190910192915050565b6000808335601e1984360301811261104757600080fd5b8301803591506001600160401b0382111561106157600080fd5b6020019150600581901b3603821315610d3357600080fd5b60006001820161108b5761108b610edd565b5060010190565b6000602082840312156110a457600080fd5b610ccf82610f19565b6000808335601e198436030181126110c457600080fd5b8301803591506001600160401b038211156110de57600080fd5b602001915036819003821315610d3357600080fd5b8481526001600160a01b038416602082015260606040820181905260009061111e9083018486610f35565b9695505050505050565b60005b8381101561114357818101518382015260200161112b565b50506000910152565b60008251611026818460208701611128565b602081526000825180602084015261117d816040850160208701611128565b601f01601f19169190910160400192915050565b8581526060602082015260006111ab606083018688610f35565b82810360408401526111be818587610f35565b98975050505050505050565b6000602082840312156111dc57600080fd5b81518015158114610ccf57600080fd5b60008261120957634e487b7160e01b600052601260045260246000fd5b50049056fea26469706673582212205e465487d9414dfe77390f61a0c38958de52ee524ceeb4baa7548b12c5998a1564736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var NativeERC20Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"NativeERC20","sourceName":"contracts/child/NativeERC20.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"predicate_","type":"address"},{"internalType":"address","name":"rootToken_","type":"address"},{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"uint8","name":"decimals_","type":"uint8"},{"internalType":"uint256","name":"tokenSupply_","type":"uint256"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rootToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061121c806100206000396000f3fe608060405234801561001057600080fd5b50600436106101635760003560e01c806355b01e4d116100ce57806397e5230d1161008757806397e5230d146102b85780639dc29fac146102c2578063a457c2d7146102d5578063a9059cbb146102e8578063dd62ed3e146102fb578063e0563ab11461030e578063e61987051461031757600080fd5b806355b01e4d146102605780635ea5df791461026e57806370a0823114610277578063740b08dc14610292578063947287cf146102a757806395d89b41146102b057600080fd5b8063284017f511610120578063284017f514610205578063313ce5671461020e57806339509351146102235780633b878c221461023657806340c10f191461023f57806351351d531461025257600080fd5b806306fdde031461016857806307b3e25214610186578063095ea7b3146101ac57806318160ddd146101cf5780631f2d0065146101e157806323b872dd146101f2575b600080fd5b610170610328565b60405161017d9190610d4d565b60405180910390f35b6101946004600360981b0181565b6040516001600160a01b03909116815260200161017d565b6101bf6101ba366004610d9c565b6103ba565b604051901515815260200161017d565b6034545b60405190815260200161017d565b6036546001600160a01b0316610194565b6101bf610200366004610dc6565b6103d4565b61019461202081565b60395460405160ff909116815260200161017d565b6101bf610231366004610d9c565b6103f8565b61019461101081565b6101bf61024d366004610d9c565b61041a565b6101946002600160a01b0381565b6101946004600160991b0181565b6101d361138881565b6101d3610285366004610e02565b6001600160a01b03163190565b6102a56102a0366004610e6d565b610463565b005b6101d361520881565b610170610618565b6101d3620249f081565b6101bf6102d0366004610d9c565b610627565b6101bf6102e3366004610d9c565b61065e565b6101bf6102f6366004610d9c565b6106d9565b6101d3610309366004610f21565b6106e7565b61019461203081565b6035546001600160a01b0316610194565b60606037805461033790610f54565b80601f016020809104026020016040519081016040528092919081815260200182805461036390610f54565b80156103b05780601f10610385576101008083540402835291602001916103b0565b820191906000526020600020905b81548152906001019060200180831161039357829003601f168201915b5050505050905090565b6000336103c8818585610712565b60019150505b92915050565b6000336103e2858285610836565b6103ed8585856108b0565b506001949350505050565b6000336103c881858561040b83836106e7565b6104159190610fa4565b610712565b6035546000906001600160a01b031633146104505760405162461bcd60e51b815260040161044790610fb7565b60405180910390fd5b61045a8383610a75565b50600192915050565b600054610100900460ff16158080156104835750600054600160ff909116105b8061049d5750303b15801561049d575060005460ff166001145b6105005760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610447565b6000805460ff191660011790558015610523576000805461ff0019166101001790555b336002600160a01b03146105675760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610447565b603580546001600160a01b03808c166001600160a01b03199283161790925560368054928b169290911691909117905560376105a4878983611060565b5060386105b2858783611060565b506039805460ff191660ff85161790556034829055801561060d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050505050565b60606038805461033790610f54565b6035546000906001600160a01b031633146106545760405162461bcd60e51b815260040161044790610fb7565b61045a8383610bcf565b6000338161066c82866106e7565b9050838110156106cc5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610447565b6103ed8286868403610712565b6000336103c88185856108b0565b6001600160a01b03918216600090815260336020908152604080832093909416825291909152205490565b6001600160a01b0383166107745760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610447565b6001600160a01b0382166107d55760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610447565b6001600160a01b0383811660008181526033602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b600061084284846106e7565b905060001981146108aa578181101561089d5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610447565b6108aa8484848403610712565b50505050565b6001600160a01b0383166109145760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610447565b6001600160a01b0382166109765760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610447565b6000806120206001600160a01b031685858560405160200161099a93929190611121565b60408051601f19818403018152908290526109b491611145565b6000604051808303816000865af19150503d80600081146109f1576040519150601f19603f3d011682016040523d82523d6000602084013e6109f6565b606091505b5091509150818015610a17575080806020019051810190610a179190611161565b610a335760405162461bcd60e51b815260040161044790611183565b836001600160a01b0316856001600160a01b03166000805160206111c783398151915285604051610a6691815260200190565b60405180910390a35050505050565b6001600160a01b038216610acb5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610447565b8060346000828254610add9190610fa4565b9091555050604051600090819061202090610b0090839087908790602001611121565b60408051601f1981840301815290829052610b1a91611145565b6000604051808303816000865af19150503d8060008114610b57576040519150601f19603f3d011682016040523d82523d6000602084013e610b5c565b606091505b5091509150818015610b7d575080806020019051810190610b7d9190611161565b610b995760405162461bcd60e51b815260040161044790611183565b6040518381526001600160a01b038516906000906000805160206111c7833981519152906020015b60405180910390a350505050565b6001600160a01b038216610c2f5760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610447565b8060346000828254610c4191906111b3565b9091555050604051600090819061202090610c6490869084908790602001611121565b60408051601f1981840301815290829052610c7e91611145565b6000604051808303816000865af19150503d8060008114610cbb576040519150601f19603f3d011682016040523d82523d6000602084013e610cc0565b606091505b5091509150818015610ce1575080806020019051810190610ce19190611161565b610cfd5760405162461bcd60e51b815260040161044790611183565b6040518381526000906001600160a01b038616906000805160206111c783398151915290602001610bc1565b60005b83811015610d44578181015183820152602001610d2c565b50506000910152565b6020815260008251806020840152610d6c816040850160208701610d29565b601f01601f19169190910160400192915050565b80356001600160a01b0381168114610d9757600080fd5b919050565b60008060408385031215610daf57600080fd5b610db883610d80565b946020939093013593505050565b600080600060608486031215610ddb57600080fd5b610de484610d80565b9250610df260208501610d80565b9150604084013590509250925092565b600060208284031215610e1457600080fd5b610e1d82610d80565b9392505050565b60008083601f840112610e3657600080fd5b50813567ffffffffffffffff811115610e4e57600080fd5b602083019150836020828501011115610e6657600080fd5b9250929050565b60008060008060008060008060c0898b031215610e8957600080fd5b610e9289610d80565b9750610ea060208a01610d80565b9650604089013567ffffffffffffffff80821115610ebd57600080fd5b610ec98c838d01610e24565b909850965060608b0135915080821115610ee257600080fd5b50610eef8b828c01610e24565b909550935050608089013560ff81168114610f0957600080fd5b8092505060a089013590509295985092959890939650565b60008060408385031215610f3457600080fd5b610f3d83610d80565b9150610f4b60208401610d80565b90509250929050565b600181811c90821680610f6857607f821691505b602082108103610f8857634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b808201808211156103ce576103ce610f8e565b60208082526024908201527f4e617469766545524332303a204f6e6c79207072656469636174652063616e2060408201526318d85b1b60e21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f82111561105b57600081815260208120601f850160051c810160208610156110385750805b601f850160051c820191505b8181101561105757828155600101611044565b5050505b505050565b67ffffffffffffffff83111561107857611078610ffb565b61108c836110868354610f54565b83611011565b6000601f8411600181146110c057600085156110a85750838201355b600019600387901b1c1916600186901b17835561111a565b600083815260209020601f19861690835b828110156110f157868501358255602094850194600190920191016110d1565b508682101561110e5760001960f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008251611157818460208701610d29565b9190910192915050565b60006020828403121561117357600080fd5b81518015158114610e1d57600080fd5b60208082526016908201527514149150d3d35412531157d0d0531317d1905253115160521b604082015260600190565b818103818111156103ce576103ce610f8e56feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa26469706673582212203e253e3b3f3175f58563f905e4d35905dc8b894d96a80a43930b6a730edd9a2a64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101635760003560e01c806355b01e4d116100ce57806397e5230d1161008757806397e5230d146102b85780639dc29fac146102c2578063a457c2d7146102d5578063a9059cbb146102e8578063dd62ed3e146102fb578063e0563ab11461030e578063e61987051461031757600080fd5b806355b01e4d146102605780635ea5df791461026e57806370a0823114610277578063740b08dc14610292578063947287cf146102a757806395d89b41146102b057600080fd5b8063284017f511610120578063284017f514610205578063313ce5671461020e57806339509351146102235780633b878c221461023657806340c10f191461023f57806351351d531461025257600080fd5b806306fdde031461016857806307b3e25214610186578063095ea7b3146101ac57806318160ddd146101cf5780631f2d0065146101e157806323b872dd146101f2575b600080fd5b610170610328565b60405161017d9190610d4d565b60405180910390f35b6101946004600360981b0181565b6040516001600160a01b03909116815260200161017d565b6101bf6101ba366004610d9c565b6103ba565b604051901515815260200161017d565b6034545b60405190815260200161017d565b6036546001600160a01b0316610194565b6101bf610200366004610dc6565b6103d4565b61019461202081565b60395460405160ff909116815260200161017d565b6101bf610231366004610d9c565b6103f8565b61019461101081565b6101bf61024d366004610d9c565b61041a565b6101946002600160a01b0381565b6101946004600160991b0181565b6101d361138881565b6101d3610285366004610e02565b6001600160a01b03163190565b6102a56102a0366004610e6d565b610463565b005b6101d361520881565b610170610618565b6101d3620249f081565b6101bf6102d0366004610d9c565b610627565b6101bf6102e3366004610d9c565b61065e565b6101bf6102f6366004610d9c565b6106d9565b6101d3610309366004610f21565b6106e7565b61019461203081565b6035546001600160a01b0316610194565b60606037805461033790610f54565b80601f016020809104026020016040519081016040528092919081815260200182805461036390610f54565b80156103b05780601f10610385576101008083540402835291602001916103b0565b820191906000526020600020905b81548152906001019060200180831161039357829003601f168201915b5050505050905090565b6000336103c8818585610712565b60019150505b92915050565b6000336103e2858285610836565b6103ed8585856108b0565b506001949350505050565b6000336103c881858561040b83836106e7565b6104159190610fa4565b610712565b6035546000906001600160a01b031633146104505760405162461bcd60e51b815260040161044790610fb7565b60405180910390fd5b61045a8383610a75565b50600192915050565b600054610100900460ff16158080156104835750600054600160ff909116105b8061049d5750303b15801561049d575060005460ff166001145b6105005760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610447565b6000805460ff191660011790558015610523576000805461ff0019166101001790555b336002600160a01b03146105675760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610447565b603580546001600160a01b03808c166001600160a01b03199283161790925560368054928b169290911691909117905560376105a4878983611060565b5060386105b2858783611060565b506039805460ff191660ff85161790556034829055801561060d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050505050565b60606038805461033790610f54565b6035546000906001600160a01b031633146106545760405162461bcd60e51b815260040161044790610fb7565b61045a8383610bcf565b6000338161066c82866106e7565b9050838110156106cc5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610447565b6103ed8286868403610712565b6000336103c88185856108b0565b6001600160a01b03918216600090815260336020908152604080832093909416825291909152205490565b6001600160a01b0383166107745760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610447565b6001600160a01b0382166107d55760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610447565b6001600160a01b0383811660008181526033602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b600061084284846106e7565b905060001981146108aa578181101561089d5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610447565b6108aa8484848403610712565b50505050565b6001600160a01b0383166109145760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610447565b6001600160a01b0382166109765760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610447565b6000806120206001600160a01b031685858560405160200161099a93929190611121565b60408051601f19818403018152908290526109b491611145565b6000604051808303816000865af19150503d80600081146109f1576040519150601f19603f3d011682016040523d82523d6000602084013e6109f6565b606091505b5091509150818015610a17575080806020019051810190610a179190611161565b610a335760405162461bcd60e51b815260040161044790611183565b836001600160a01b0316856001600160a01b03166000805160206111c783398151915285604051610a6691815260200190565b60405180910390a35050505050565b6001600160a01b038216610acb5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610447565b8060346000828254610add9190610fa4565b9091555050604051600090819061202090610b0090839087908790602001611121565b60408051601f1981840301815290829052610b1a91611145565b6000604051808303816000865af19150503d8060008114610b57576040519150601f19603f3d011682016040523d82523d6000602084013e610b5c565b606091505b5091509150818015610b7d575080806020019051810190610b7d9190611161565b610b995760405162461bcd60e51b815260040161044790611183565b6040518381526001600160a01b038516906000906000805160206111c7833981519152906020015b60405180910390a350505050565b6001600160a01b038216610c2f5760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610447565b8060346000828254610c4191906111b3565b9091555050604051600090819061202090610c6490869084908790602001611121565b60408051601f1981840301815290829052610c7e91611145565b6000604051808303816000865af19150503d8060008114610cbb576040519150601f19603f3d011682016040523d82523d6000602084013e610cc0565b606091505b5091509150818015610ce1575080806020019051810190610ce19190611161565b610cfd5760405162461bcd60e51b815260040161044790611183565b6040518381526000906001600160a01b038616906000805160206111c783398151915290602001610bc1565b60005b83811015610d44578181015183820152602001610d2c565b50506000910152565b6020815260008251806020840152610d6c816040850160208701610d29565b601f01601f19169190910160400192915050565b80356001600160a01b0381168114610d9757600080fd5b919050565b60008060408385031215610daf57600080fd5b610db883610d80565b946020939093013593505050565b600080600060608486031215610ddb57600080fd5b610de484610d80565b9250610df260208501610d80565b9150604084013590509250925092565b600060208284031215610e1457600080fd5b610e1d82610d80565b9392505050565b60008083601f840112610e3657600080fd5b50813567ffffffffffffffff811115610e4e57600080fd5b602083019150836020828501011115610e6657600080fd5b9250929050565b60008060008060008060008060c0898b031215610e8957600080fd5b610e9289610d80565b9750610ea060208a01610d80565b9650604089013567ffffffffffffffff80821115610ebd57600080fd5b610ec98c838d01610e24565b909850965060608b0135915080821115610ee257600080fd5b50610eef8b828c01610e24565b909550935050608089013560ff81168114610f0957600080fd5b8092505060a089013590509295985092959890939650565b60008060408385031215610f3457600080fd5b610f3d83610d80565b9150610f4b60208401610d80565b90509250929050565b600181811c90821680610f6857607f821691505b602082108103610f8857634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b808201808211156103ce576103ce610f8e565b60208082526024908201527f4e617469766545524332303a204f6e6c79207072656469636174652063616e2060408201526318d85b1b60e21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f82111561105b57600081815260208120601f850160051c810160208610156110385750805b601f850160051c820191505b8181101561105757828155600101611044565b5050505b505050565b67ffffffffffffffff83111561107857611078610ffb565b61108c836110868354610f54565b83611011565b6000601f8411600181146110c057600085156110a85750838201355b600019600387901b1c1916600186901b17835561111a565b600083815260209020601f19861690835b828110156110f157868501358255602094850194600190920191016110d1565b508682101561110e5760001960f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008251611157818460208701610d29565b9190910192915050565b60006020828403121561117357600080fd5b81518015158114610e1d57600080fd5b60208082526016908201527514149150d3d35412531157d0d0531317d1905253115160521b604082015260600190565b818103818111156103ce576103ce610f8e56feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa26469706673582212203e253e3b3f3175f58563f905e4d35905dc8b894d96a80a43930b6a730edd9a2a64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var NativeERC20MintableArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"NativeERC20Mintable","sourceName":"contracts/child/NativeERC20Mintable.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"predicate_","type":"address"},{"internalType":"address","name":"owner_","type":"address"},{"internalType":"address","name":"rootToken_","type":"address"},{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"uint8","name":"decimals_","type":"uint8"},{"internalType":"uint256","name":"tokenSupply_","type":"uint256"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061001a3361001f565b61008d565b603480546001600160a01b03191690556100388161003b565b50565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b61150a8061009c6000396000f3fe608060405234801561001057600080fd5b506004361061019a5760003560e01c806370a08231116100e45780639dc29fac116100925780639dc29fac1461031a578063a457c2d71461032d578063a9059cbb14610340578063dd62ed3e14610353578063e0563ab114610366578063e30c39781461036f578063e619870514610380578063f2fde38b1461039157600080fd5b806370a08231146102c3578063715018a6146102de57806379ba5097146102e65780638da5cb5b146102ee578063947287cf146102ff57806395d89b411461030857806397e5230d1461031057600080fd5b8063313ce5671161014c578063313ce56714610245578063395093511461025a5780633b878c221461026d57806340c10f191461027657806351351d531461028957806355b01e4d146102975780635ea5df79146102a55780636091636b146102ae57600080fd5b806306fdde031461019f57806307b3e252146101bd578063095ea7b3146101e357806318160ddd146102065780631f2d00651461021857806323b872dd14610229578063284017f51461023c575b600080fd5b6101a76103a4565b6040516101b49190611022565b60405180910390f35b6101cb6004600360981b0181565b6040516001600160a01b0390911681526020016101b4565b6101f66101f1366004611071565b610436565b60405190151581526020016101b4565b6036545b6040519081526020016101b4565b6038546001600160a01b03166101cb565b6101f661023736600461109b565b610450565b6101cb61202081565b603b5460405160ff90911681526020016101b4565b6101f6610268366004611071565b610474565b6101cb61101081565b6101f6610284366004611071565b610496565b6101cb6002600160a01b0381565b6101cb6004600160991b0181565b61020a61138881565b6102c16102bc366004611120565b6104f4565b005b61020a6102d13660046111e4565b6001600160a01b03163190565b6102c1610714565b6102c1610728565b6033546001600160a01b03166101cb565b61020a61520881565b6101a76107a2565b61020a620249f081565b6101f6610328366004611071565b6107b1565b6101f661033b366004611071565b6107fd565b6101f661034e366004611071565b610878565b61020a610361366004611206565b610886565b6101cb61203081565b6034546001600160a01b03166101cb565b6037546001600160a01b03166101cb565b6102c161039f3660046111e4565b6108b1565b6060603980546103b390611239565b80601f01602080910402602001604051908101604052809291908181526020018280546103df90611239565b801561042c5780601f106104015761010080835404028352916020019161042c565b820191906000526020600020905b81548152906001019060200180831161040f57829003601f168201915b5050505050905090565b600033610444818585610922565b60019150505b92915050565b60003361045e858285610a46565b610469858585610ac0565b506001949350505050565b6000336104448185856104878383610886565b6104919190611289565b610922565b6037546000906001600160a01b03163314806104bc57506033546001600160a01b031633145b6104e15760405162461bcd60e51b81526004016104d89061129c565b60405180910390fd5b6104eb8383610c85565b50600192915050565b600054610100900460ff16158080156105145750600054600160ff909116105b8061052e5750303b15801561052e575060005460ff166001145b6105915760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104d8565b6000805460ff1916600117905580156105b4576000805461ff0019166101001790555b336002600160a01b03146105f85760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064016104d8565b6001600160a01b0389166106595760405162461bcd60e51b815260206004820152602260248201527f4e617469766545524332303a20496e76616c6964206f776e6572206164647265604482015261737360f01b60648201526084016104d8565b603780546001600160a01b03808d166001600160a01b03199283161790925560388054928b1692909116919091179055603961069687898361134e565b50603a6106a485878361134e565b50603b805460ff191660ff851617905560368290556106c289610ddf565b8015610708576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050505050565b61071c610df8565b6107266000610ddf565b565b60345433906001600160a01b031681146107965760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016104d8565b61079f81610ddf565b50565b6060603a80546103b390611239565b6037546000906001600160a01b03163314806107d757506033546001600160a01b031633145b6107f35760405162461bcd60e51b81526004016104d89061129c565b6104eb8383610e52565b6000338161080b8286610886565b90508381101561086b5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016104d8565b6104698286868403610922565b600033610444818585610ac0565b6001600160a01b03918216600090815260356020908152604080832093909416825291909152205490565b6108b9610df8565b603480546001600160a01b0383166001600160a01b031990911681179091556108ea6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b6001600160a01b0383166109845760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b60648201526084016104d8565b6001600160a01b0382166109e55760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b60648201526084016104d8565b6001600160a01b0383811660008181526035602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b6000610a528484610886565b90506000198114610aba5781811015610aad5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016104d8565b610aba8484848403610922565b50505050565b6001600160a01b038316610b245760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016104d8565b6001600160a01b038216610b865760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016104d8565b6000806120206001600160a01b0316858585604051602001610baa9392919061140f565b60408051601f1981840301815290829052610bc491611433565b6000604051808303816000865af19150503d8060008114610c01576040519150601f19603f3d011682016040523d82523d6000602084013e610c06565b606091505b5091509150818015610c27575080806020019051810190610c27919061144f565b610c435760405162461bcd60e51b81526004016104d890611471565b836001600160a01b0316856001600160a01b03166000805160206114b583398151915285604051610c7691815260200190565b60405180910390a35050505050565b6001600160a01b038216610cdb5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016104d8565b8060366000828254610ced9190611289565b9091555050604051600090819061202090610d109083908790879060200161140f565b60408051601f1981840301815290829052610d2a91611433565b6000604051808303816000865af19150503d8060008114610d67576040519150601f19603f3d011682016040523d82523d6000602084013e610d6c565b606091505b5091509150818015610d8d575080806020019051810190610d8d919061144f565b610da95760405162461bcd60e51b81526004016104d890611471565b6040518381526001600160a01b038516906000906000805160206114b5833981519152906020015b60405180910390a350505050565b603480546001600160a01b031916905561079f81610fac565b6033546001600160a01b031633146107265760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104d8565b6001600160a01b038216610eb25760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016104d8565b8060366000828254610ec491906114a1565b9091555050604051600090819061202090610ee79086908490879060200161140f565b60408051601f1981840301815290829052610f0191611433565b6000604051808303816000865af19150503d8060008114610f3e576040519150601f19603f3d011682016040523d82523d6000602084013e610f43565b606091505b5091509150818015610f64575080806020019051810190610f64919061144f565b610f805760405162461bcd60e51b81526004016104d890611471565b6040518381526000906001600160a01b038616906000805160206114b583398151915290602001610dd1565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60005b83811015611019578181015183820152602001611001565b50506000910152565b6020815260008251806020840152611041816040850160208701610ffe565b601f01601f19169190910160400192915050565b80356001600160a01b038116811461106c57600080fd5b919050565b6000806040838503121561108457600080fd5b61108d83611055565b946020939093013593505050565b6000806000606084860312156110b057600080fd5b6110b984611055565b92506110c760208501611055565b9150604084013590509250925092565b60008083601f8401126110e957600080fd5b50813567ffffffffffffffff81111561110157600080fd5b60208301915083602082850101111561111957600080fd5b9250929050565b600080600080600080600080600060e08a8c03121561113e57600080fd5b6111478a611055565b985061115560208b01611055565b975061116360408b01611055565b965060608a013567ffffffffffffffff8082111561118057600080fd5b61118c8d838e016110d7565b909850965060808c01359150808211156111a557600080fd5b506111b28c828d016110d7565b90955093505060a08a013560ff811681146111cc57600080fd5b8092505060c08a013590509295985092959850929598565b6000602082840312156111f657600080fd5b6111ff82611055565b9392505050565b6000806040838503121561121957600080fd5b61122283611055565b915061123060208401611055565b90509250929050565b600181811c9082168061124d57607f821691505b60208210810361126d57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b8082018082111561044a5761044a611273565b6020808252602d908201527f4e617469766545524332303a204f6e6c7920707265646963617465206f72206f60408201526c1ddb995c8818d85b8818d85b1b609a1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f82111561134957600081815260208120601f850160051c810160208610156113265750805b601f850160051c820191505b8181101561134557828155600101611332565b5050505b505050565b67ffffffffffffffff831115611366576113666112e9565b61137a836113748354611239565b836112ff565b6000601f8411600181146113ae57600085156113965750838201355b600019600387901b1c1916600186901b178355611408565b600083815260209020601f19861690835b828110156113df57868501358255602094850194600190920191016113bf565b50868210156113fc5760001960f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008251611445818460208701610ffe565b9190910192915050565b60006020828403121561146157600080fd5b815180151581146111ff57600080fd5b60208082526016908201527514149150d3d35412531157d0d0531317d1905253115160521b604082015260600190565b8181038181111561044a5761044a61127356feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220c841ea6b2ede0321e38158aa4ac46f255ea0caf34a5429d64b9287ce7df103b364736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061019a5760003560e01c806370a08231116100e45780639dc29fac116100925780639dc29fac1461031a578063a457c2d71461032d578063a9059cbb14610340578063dd62ed3e14610353578063e0563ab114610366578063e30c39781461036f578063e619870514610380578063f2fde38b1461039157600080fd5b806370a08231146102c3578063715018a6146102de57806379ba5097146102e65780638da5cb5b146102ee578063947287cf146102ff57806395d89b411461030857806397e5230d1461031057600080fd5b8063313ce5671161014c578063313ce56714610245578063395093511461025a5780633b878c221461026d57806340c10f191461027657806351351d531461028957806355b01e4d146102975780635ea5df79146102a55780636091636b146102ae57600080fd5b806306fdde031461019f57806307b3e252146101bd578063095ea7b3146101e357806318160ddd146102065780631f2d00651461021857806323b872dd14610229578063284017f51461023c575b600080fd5b6101a76103a4565b6040516101b49190611022565b60405180910390f35b6101cb6004600360981b0181565b6040516001600160a01b0390911681526020016101b4565b6101f66101f1366004611071565b610436565b60405190151581526020016101b4565b6036545b6040519081526020016101b4565b6038546001600160a01b03166101cb565b6101f661023736600461109b565b610450565b6101cb61202081565b603b5460405160ff90911681526020016101b4565b6101f6610268366004611071565b610474565b6101cb61101081565b6101f6610284366004611071565b610496565b6101cb6002600160a01b0381565b6101cb6004600160991b0181565b61020a61138881565b6102c16102bc366004611120565b6104f4565b005b61020a6102d13660046111e4565b6001600160a01b03163190565b6102c1610714565b6102c1610728565b6033546001600160a01b03166101cb565b61020a61520881565b6101a76107a2565b61020a620249f081565b6101f6610328366004611071565b6107b1565b6101f661033b366004611071565b6107fd565b6101f661034e366004611071565b610878565b61020a610361366004611206565b610886565b6101cb61203081565b6034546001600160a01b03166101cb565b6037546001600160a01b03166101cb565b6102c161039f3660046111e4565b6108b1565b6060603980546103b390611239565b80601f01602080910402602001604051908101604052809291908181526020018280546103df90611239565b801561042c5780601f106104015761010080835404028352916020019161042c565b820191906000526020600020905b81548152906001019060200180831161040f57829003601f168201915b5050505050905090565b600033610444818585610922565b60019150505b92915050565b60003361045e858285610a46565b610469858585610ac0565b506001949350505050565b6000336104448185856104878383610886565b6104919190611289565b610922565b6037546000906001600160a01b03163314806104bc57506033546001600160a01b031633145b6104e15760405162461bcd60e51b81526004016104d89061129c565b60405180910390fd5b6104eb8383610c85565b50600192915050565b600054610100900460ff16158080156105145750600054600160ff909116105b8061052e5750303b15801561052e575060005460ff166001145b6105915760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104d8565b6000805460ff1916600117905580156105b4576000805461ff0019166101001790555b336002600160a01b03146105f85760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064016104d8565b6001600160a01b0389166106595760405162461bcd60e51b815260206004820152602260248201527f4e617469766545524332303a20496e76616c6964206f776e6572206164647265604482015261737360f01b60648201526084016104d8565b603780546001600160a01b03808d166001600160a01b03199283161790925560388054928b1692909116919091179055603961069687898361134e565b50603a6106a485878361134e565b50603b805460ff191660ff851617905560368290556106c289610ddf565b8015610708576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050505050565b61071c610df8565b6107266000610ddf565b565b60345433906001600160a01b031681146107965760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016104d8565b61079f81610ddf565b50565b6060603a80546103b390611239565b6037546000906001600160a01b03163314806107d757506033546001600160a01b031633145b6107f35760405162461bcd60e51b81526004016104d89061129c565b6104eb8383610e52565b6000338161080b8286610886565b90508381101561086b5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016104d8565b6104698286868403610922565b600033610444818585610ac0565b6001600160a01b03918216600090815260356020908152604080832093909416825291909152205490565b6108b9610df8565b603480546001600160a01b0383166001600160a01b031990911681179091556108ea6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b6001600160a01b0383166109845760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b60648201526084016104d8565b6001600160a01b0382166109e55760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b60648201526084016104d8565b6001600160a01b0383811660008181526035602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b6000610a528484610886565b90506000198114610aba5781811015610aad5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016104d8565b610aba8484848403610922565b50505050565b6001600160a01b038316610b245760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016104d8565b6001600160a01b038216610b865760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016104d8565b6000806120206001600160a01b0316858585604051602001610baa9392919061140f565b60408051601f1981840301815290829052610bc491611433565b6000604051808303816000865af19150503d8060008114610c01576040519150601f19603f3d011682016040523d82523d6000602084013e610c06565b606091505b5091509150818015610c27575080806020019051810190610c27919061144f565b610c435760405162461bcd60e51b81526004016104d890611471565b836001600160a01b0316856001600160a01b03166000805160206114b583398151915285604051610c7691815260200190565b60405180910390a35050505050565b6001600160a01b038216610cdb5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016104d8565b8060366000828254610ced9190611289565b9091555050604051600090819061202090610d109083908790879060200161140f565b60408051601f1981840301815290829052610d2a91611433565b6000604051808303816000865af19150503d8060008114610d67576040519150601f19603f3d011682016040523d82523d6000602084013e610d6c565b606091505b5091509150818015610d8d575080806020019051810190610d8d919061144f565b610da95760405162461bcd60e51b81526004016104d890611471565b6040518381526001600160a01b038516906000906000805160206114b5833981519152906020015b60405180910390a350505050565b603480546001600160a01b031916905561079f81610fac565b6033546001600160a01b031633146107265760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104d8565b6001600160a01b038216610eb25760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016104d8565b8060366000828254610ec491906114a1565b9091555050604051600090819061202090610ee79086908490879060200161140f565b60408051601f1981840301815290829052610f0191611433565b6000604051808303816000865af19150503d8060008114610f3e576040519150601f19603f3d011682016040523d82523d6000602084013e610f43565b606091505b5091509150818015610f64575080806020019051810190610f64919061144f565b610f805760405162461bcd60e51b81526004016104d890611471565b6040518381526000906001600160a01b038616906000805160206114b583398151915290602001610dd1565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60005b83811015611019578181015183820152602001611001565b50506000910152565b6020815260008251806020840152611041816040850160208701610ffe565b601f01601f19169190910160400192915050565b80356001600160a01b038116811461106c57600080fd5b919050565b6000806040838503121561108457600080fd5b61108d83611055565b946020939093013593505050565b6000806000606084860312156110b057600080fd5b6110b984611055565b92506110c760208501611055565b9150604084013590509250925092565b60008083601f8401126110e957600080fd5b50813567ffffffffffffffff81111561110157600080fd5b60208301915083602082850101111561111957600080fd5b9250929050565b600080600080600080600080600060e08a8c03121561113e57600080fd5b6111478a611055565b985061115560208b01611055565b975061116360408b01611055565b965060608a013567ffffffffffffffff8082111561118057600080fd5b61118c8d838e016110d7565b909850965060808c01359150808211156111a557600080fd5b506111b28c828d016110d7565b90955093505060a08a013560ff811681146111cc57600080fd5b8092505060c08a013590509295985092959850929598565b6000602082840312156111f657600080fd5b6111ff82611055565b9392505050565b6000806040838503121561121957600080fd5b61122283611055565b915061123060208401611055565b90509250929050565b600181811c9082168061124d57607f821691505b60208210810361126d57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b8082018082111561044a5761044a611273565b6020808252602d908201527f4e617469766545524332303a204f6e6c7920707265646963617465206f72206f60408201526c1ddb995c8818d85b8818d85b1b609a1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f82111561134957600081815260208120601f850160051c810160208610156113265750805b601f850160051c820191505b8181101561134557828155600101611332565b5050505b505050565b67ffffffffffffffff831115611366576113666112e9565b61137a836113748354611239565b836112ff565b6000601f8411600181146113ae57600085156113965750838201355b600019600387901b1c1916600186901b178355611408565b600083815260209020601f19861690835b828110156113df57868501358255602094850194600190920191016113bf565b50868210156113fc5760001960f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008251611445818460208701610ffe565b9190910192915050565b60006020828403121561146157600080fd5b815180151581146111ff57600080fd5b60208082526016908201527514149150d3d35412531157d0d0531317d1905253115160521b604082015260600190565b8181038181111561044a5761044a61127356feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220c841ea6b2ede0321e38158aa4ac46f255ea0caf34a5429d64b9287ce7df103b364736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildERC20Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC20","sourceName":"contracts/child/ChildERC20.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"userAddress","type":"address"},{"indexed":false,"internalType":"address","name":"relayerAddress","type":"address"},{"indexed":false,"internalType":"bytes","name":"functionSignature","type":"bytes"}],"name":"MetaTransactionExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"userAddress","type":"address"},{"internalType":"bytes","name":"functionSignature","type":"bytes"},{"internalType":"bytes32","name":"sigR","type":"bytes32"},{"internalType":"bytes32","name":"sigS","type":"bytes32"},{"internalType":"uint8","name":"sigV","type":"uint8"}],"name":"executeMetaTransaction","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getNonce","outputs":[{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"rootToken_","type":"address"},{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"uint8","name":"decimals_","type":"uint8"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"offset","type":"uint256"}],"name":"invalidateNext","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rootToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611920806100206000396000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c806340c10f19116100ad578063a457c2d711610071578063a457c2d71461028b578063a9059cbb1461029e578063dd62ed3e146102b1578063e6198705146102c4578063f6d2ee86146102d557600080fd5b806340c10f191461021f57806370a082311461023257806395d89b411461025b5780639b77ef11146102635780639dc29fac1461027857600080fd5b80631f2d0065116100f45780631f2d00651461018c57806323b872dd146101b15780632d0335ab146101c4578063313ce567146101ed578063395093511461020c57600080fd5b806306fdde0314610126578063095ea7b3146101445780630c53c51c1461016757806318160ddd1461017a575b600080fd5b61012e6102e8565b60405161013b9190611395565b60405180910390f35b6101576101523660046113cb565b61037a565b604051901515815260200161013b565b61012e61017536600461144f565b61039e565b60a0545b60405190815260200161013b565b60d1546001600160a01b03165b6040516001600160a01b03909116815260200161013b565b6101576101bf3660046114c5565b610681565b61017e6101d2366004611501565b6001600160a01b031660009081526038602052604090205490565b60d154600160a01b900460ff1660405160ff909116815260200161013b565b61015761021a3660046113cb565b6106af565b61015761022d3660046113cb565b6106db565b61017e610240366004611501565b6001600160a01b03166000908152609e602052604090205490565b61012e61071b565b61027661027136600461151c565b61072a565b005b6101576102863660046113cb565b610751565b6101576102993660046113cb565b610788565b6101576102ac3660046113cb565b61080e565b61017e6102bf366004611535565b610826565b60d0546001600160a01b0316610199565b6102766102e3366004611568565b610851565b606060a180546102f7906115ec565b80601f0160208091040260200160405190810160405280929190818152602001828054610323906115ec565b80156103705780601f1061034557610100808354040283529160200191610370565b820191906000526020600020905b81548152906001019060200180831161035357829003601f168201915b5050505050905090565b600080610385610ad1565b9050610392818585610ae0565b60019150505b92915050565b606060006103e187878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610c0592505050565b90506001600160e01b031960003581169082160361046c5760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f6400000060648201526084015b60405180910390fd5b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506104dd8982888888610c20565b6105335760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b6064820152608401610463565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d60405160200161058893929190611626565b60408051601f19818403018152908290526105a29161164c565b6000604051808303816000865af19150503d80600081146105df576040519150601f19603f3d011682016040523d82523d6000602084013e6105e4565b606091505b5091509150816106365760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610463565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c60405161066b9493929190611668565b60405180910390a19a9950505050505050505050565b60008061068c610ad1565b9050610699858285610cfc565b6106a4858585610d76565b506001949350505050565b6000806106ba610ad1565b90506103928185856106cc8589610826565b6106d691906116b4565b610ae0565b60d0546000906001600160a01b031633146107085760405162461bcd60e51b8152600401610463906116d5565b6107128383610f0f565b50600192915050565b606060a280546102f7906115ec565b33600090815260386020526040812080548392906107499084906116b4565b909155505050565b60d0546000906001600160a01b0316331461077e5760405162461bcd60e51b8152600401610463906116d5565b6107128383610fbf565b600080610793610ad1565b905060006107a18286610826565b9050838110156108015760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610463565b6106a48286868403610ae0565b600080610819610ad1565b9050610392818585610d76565b6001600160a01b039182166000908152609f6020908152604080832093909416825291909152205490565b606b54610100900460ff16158080156108715750606b54600160ff909116105b8061088b5750303b15801561088b5750606b5460ff166001145b6108ee5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610463565b606b805460ff19166001179055801561091157606b805461ff0019166101001790555b6001600160a01b0387161580159061092857508415155b801561093357508215155b61097f5760405162461bcd60e51b815260206004820152601e60248201527f4368696c6445524332303a204241445f494e495449414c495a4154494f4e00006044820152606401610463565b60d1805460ff8416600160a01b026001600160a81b03199091166001600160a01b038a161717905560d080546001600160a01b03191633179055604080516020601f8801819004810282018101909252868152610a2a91889088908190840183828082843760009201919091525050604080516020601f8a0181900481028201810190925288815292508891508790819084018382808284376000920191909152506110de92505050565b610a8286868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805180820190915260018152603160f81b6020820152915061110f9050565b8015610ac857606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b6000610adb61117b565b905090565b6001600160a01b038316610b425760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610463565b6001600160a01b038216610ba35760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610463565b6001600160a01b038381166000818152609f602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b60008151600003610c1857506000919050565b506020015190565b6000806001610c36610c31886111d7565b611254565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa158015610c84573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610cdb5760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610463565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6000610d088484610826565b90506000198114610d705781811015610d635760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610463565b610d708484848403610ae0565b50505050565b6001600160a01b038316610dda5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610463565b6001600160a01b038216610e3c5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610463565b6001600160a01b0383166000908152609e602052604090205481811015610eb45760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610463565b6001600160a01b038085166000818152609e602052604080822086860390559286168082529083902080548601905591516000805160206118cb83398151915290610f029086815260200190565b60405180910390a3610d70565b6001600160a01b038216610f655760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610463565b8060a06000828254610f7791906116b4565b90915550506001600160a01b0382166000818152609e60209081526040808320805486019055518481526000805160206118cb833981519152910160405180910390a35b5050565b6001600160a01b03821661101f5760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610463565b6001600160a01b0382166000908152609e6020526040902054818110156110935760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610463565b6001600160a01b0383166000818152609e60209081526040808320868603905560a080548790039055518581529192916000805160206118cb8339815191529101610bf8565b505050565b606b54610100900460ff166111055760405162461bcd60e51b815260040161046390611718565b610fbb8282611281565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f61115d8184846112c1565b600055600280546001600160a01b0319163017905560055550505050565b60003033036111d157600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506111d49050565b50335b90565b60006040518060800160405280604381526020016118886043913980516020918201208351848301516040808701518051908601209051611237950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039861126161130a565b8360405161190160f01b8152600281019290925260228201526042902090565b606b54610100900460ff166112a85760405162461bcd60e51b815260040161046390611718565b60a16112b483826117c7565b5060a26110d982826117c7565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b6002546000906001600160a01b031630148015611328575060015446145b15611334575060005490565b610adb6005546003546004546112c1565b60005b83811015611360578181015183820152602001611348565b50506000910152565b60008151808452611381816020860160208601611345565b601f01601f19169290920160200192915050565b6020815260006113a86020830184611369565b9392505050565b80356001600160a01b03811681146113c657600080fd5b919050565b600080604083850312156113de57600080fd5b6113e7836113af565b946020939093013593505050565b60008083601f84011261140757600080fd5b50813567ffffffffffffffff81111561141f57600080fd5b60208301915083602082850101111561143757600080fd5b9250929050565b803560ff811681146113c657600080fd5b60008060008060008060a0878903121561146857600080fd5b611471876113af565b9550602087013567ffffffffffffffff81111561148d57600080fd5b61149989828a016113f5565b90965094505060408701359250606087013591506114b96080880161143e565b90509295509295509295565b6000806000606084860312156114da57600080fd5b6114e3846113af565b92506114f1602085016113af565b9150604084013590509250925092565b60006020828403121561151357600080fd5b6113a8826113af565b60006020828403121561152e57600080fd5b5035919050565b6000806040838503121561154857600080fd5b611551836113af565b915061155f602084016113af565b90509250929050565b6000806000806000806080878903121561158157600080fd5b61158a876113af565b9550602087013567ffffffffffffffff808211156115a757600080fd5b6115b38a838b016113f5565b909750955060408901359150808211156115cc57600080fd5b506115d989828a016113f5565b90945092506114b990506060880161143e565b600181811c9082168061160057607f821691505b60208210810361162057634e487b7160e01b600052602260045260246000fd5b50919050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b6000825161165e818460208701611345565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b8082018082111561039857634e487b7160e01b600052601160045260246000fd5b60208082526023908201527f4368696c6445524332303a204f6e6c79207072656469636174652063616e2063604082015262185b1b60ea1b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f8211156110d957600081815260208120601f850160051c810160208610156117a05750805b601f850160051c820191505b818110156117bf578281556001016117ac565b505050505050565b815167ffffffffffffffff8111156117e1576117e1611763565b6117f5816117ef84546115ec565b84611779565b602080601f83116001811461182a57600084156118125750858301515b600019600386901b1c1916600185901b1785556117bf565b600085815260208120601f198616915b828110156118595788860151825594840194600190910190840161183a565b50858210156118775787850151600019600388901b60f8161c191681555b5050505050600190811b0190555056fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220b322ab3a17e671324178982233e8fdd83f1d7487c05f56ee80ebf7cb64b9b2c964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101215760003560e01c806340c10f19116100ad578063a457c2d711610071578063a457c2d71461028b578063a9059cbb1461029e578063dd62ed3e146102b1578063e6198705146102c4578063f6d2ee86146102d557600080fd5b806340c10f191461021f57806370a082311461023257806395d89b411461025b5780639b77ef11146102635780639dc29fac1461027857600080fd5b80631f2d0065116100f45780631f2d00651461018c57806323b872dd146101b15780632d0335ab146101c4578063313ce567146101ed578063395093511461020c57600080fd5b806306fdde0314610126578063095ea7b3146101445780630c53c51c1461016757806318160ddd1461017a575b600080fd5b61012e6102e8565b60405161013b9190611395565b60405180910390f35b6101576101523660046113cb565b61037a565b604051901515815260200161013b565b61012e61017536600461144f565b61039e565b60a0545b60405190815260200161013b565b60d1546001600160a01b03165b6040516001600160a01b03909116815260200161013b565b6101576101bf3660046114c5565b610681565b61017e6101d2366004611501565b6001600160a01b031660009081526038602052604090205490565b60d154600160a01b900460ff1660405160ff909116815260200161013b565b61015761021a3660046113cb565b6106af565b61015761022d3660046113cb565b6106db565b61017e610240366004611501565b6001600160a01b03166000908152609e602052604090205490565b61012e61071b565b61027661027136600461151c565b61072a565b005b6101576102863660046113cb565b610751565b6101576102993660046113cb565b610788565b6101576102ac3660046113cb565b61080e565b61017e6102bf366004611535565b610826565b60d0546001600160a01b0316610199565b6102766102e3366004611568565b610851565b606060a180546102f7906115ec565b80601f0160208091040260200160405190810160405280929190818152602001828054610323906115ec565b80156103705780601f1061034557610100808354040283529160200191610370565b820191906000526020600020905b81548152906001019060200180831161035357829003601f168201915b5050505050905090565b600080610385610ad1565b9050610392818585610ae0565b60019150505b92915050565b606060006103e187878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610c0592505050565b90506001600160e01b031960003581169082160361046c5760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f6400000060648201526084015b60405180910390fd5b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506104dd8982888888610c20565b6105335760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b6064820152608401610463565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d60405160200161058893929190611626565b60408051601f19818403018152908290526105a29161164c565b6000604051808303816000865af19150503d80600081146105df576040519150601f19603f3d011682016040523d82523d6000602084013e6105e4565b606091505b5091509150816106365760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610463565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c60405161066b9493929190611668565b60405180910390a19a9950505050505050505050565b60008061068c610ad1565b9050610699858285610cfc565b6106a4858585610d76565b506001949350505050565b6000806106ba610ad1565b90506103928185856106cc8589610826565b6106d691906116b4565b610ae0565b60d0546000906001600160a01b031633146107085760405162461bcd60e51b8152600401610463906116d5565b6107128383610f0f565b50600192915050565b606060a280546102f7906115ec565b33600090815260386020526040812080548392906107499084906116b4565b909155505050565b60d0546000906001600160a01b0316331461077e5760405162461bcd60e51b8152600401610463906116d5565b6107128383610fbf565b600080610793610ad1565b905060006107a18286610826565b9050838110156108015760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610463565b6106a48286868403610ae0565b600080610819610ad1565b9050610392818585610d76565b6001600160a01b039182166000908152609f6020908152604080832093909416825291909152205490565b606b54610100900460ff16158080156108715750606b54600160ff909116105b8061088b5750303b15801561088b5750606b5460ff166001145b6108ee5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610463565b606b805460ff19166001179055801561091157606b805461ff0019166101001790555b6001600160a01b0387161580159061092857508415155b801561093357508215155b61097f5760405162461bcd60e51b815260206004820152601e60248201527f4368696c6445524332303a204241445f494e495449414c495a4154494f4e00006044820152606401610463565b60d1805460ff8416600160a01b026001600160a81b03199091166001600160a01b038a161717905560d080546001600160a01b03191633179055604080516020601f8801819004810282018101909252868152610a2a91889088908190840183828082843760009201919091525050604080516020601f8a0181900481028201810190925288815292508891508790819084018382808284376000920191909152506110de92505050565b610a8286868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805180820190915260018152603160f81b6020820152915061110f9050565b8015610ac857606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b6000610adb61117b565b905090565b6001600160a01b038316610b425760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610463565b6001600160a01b038216610ba35760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610463565b6001600160a01b038381166000818152609f602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b60008151600003610c1857506000919050565b506020015190565b6000806001610c36610c31886111d7565b611254565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa158015610c84573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610cdb5760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610463565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6000610d088484610826565b90506000198114610d705781811015610d635760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610463565b610d708484848403610ae0565b50505050565b6001600160a01b038316610dda5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610463565b6001600160a01b038216610e3c5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610463565b6001600160a01b0383166000908152609e602052604090205481811015610eb45760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610463565b6001600160a01b038085166000818152609e602052604080822086860390559286168082529083902080548601905591516000805160206118cb83398151915290610f029086815260200190565b60405180910390a3610d70565b6001600160a01b038216610f655760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610463565b8060a06000828254610f7791906116b4565b90915550506001600160a01b0382166000818152609e60209081526040808320805486019055518481526000805160206118cb833981519152910160405180910390a35b5050565b6001600160a01b03821661101f5760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610463565b6001600160a01b0382166000908152609e6020526040902054818110156110935760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610463565b6001600160a01b0383166000818152609e60209081526040808320868603905560a080548790039055518581529192916000805160206118cb8339815191529101610bf8565b505050565b606b54610100900460ff166111055760405162461bcd60e51b815260040161046390611718565b610fbb8282611281565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f61115d8184846112c1565b600055600280546001600160a01b0319163017905560055550505050565b60003033036111d157600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506111d49050565b50335b90565b60006040518060800160405280604381526020016118886043913980516020918201208351848301516040808701518051908601209051611237950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039861126161130a565b8360405161190160f01b8152600281019290925260228201526042902090565b606b54610100900460ff166112a85760405162461bcd60e51b815260040161046390611718565b60a16112b483826117c7565b5060a26110d982826117c7565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b6002546000906001600160a01b031630148015611328575060015446145b15611334575060005490565b610adb6005546003546004546112c1565b60005b83811015611360578181015183820152602001611348565b50506000910152565b60008151808452611381816020860160208601611345565b601f01601f19169290920160200192915050565b6020815260006113a86020830184611369565b9392505050565b80356001600160a01b03811681146113c657600080fd5b919050565b600080604083850312156113de57600080fd5b6113e7836113af565b946020939093013593505050565b60008083601f84011261140757600080fd5b50813567ffffffffffffffff81111561141f57600080fd5b60208301915083602082850101111561143757600080fd5b9250929050565b803560ff811681146113c657600080fd5b60008060008060008060a0878903121561146857600080fd5b611471876113af565b9550602087013567ffffffffffffffff81111561148d57600080fd5b61149989828a016113f5565b90965094505060408701359250606087013591506114b96080880161143e565b90509295509295509295565b6000806000606084860312156114da57600080fd5b6114e3846113af565b92506114f1602085016113af565b9150604084013590509250925092565b60006020828403121561151357600080fd5b6113a8826113af565b60006020828403121561152e57600080fd5b5035919050565b6000806040838503121561154857600080fd5b611551836113af565b915061155f602084016113af565b90509250929050565b6000806000806000806080878903121561158157600080fd5b61158a876113af565b9550602087013567ffffffffffffffff808211156115a757600080fd5b6115b38a838b016113f5565b909750955060408901359150808211156115cc57600080fd5b506115d989828a016113f5565b90945092506114b990506060880161143e565b600181811c9082168061160057607f821691505b60208210810361162057634e487b7160e01b600052602260045260246000fd5b50919050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b6000825161165e818460208701611345565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b8082018082111561039857634e487b7160e01b600052601160045260246000fd5b60208082526023908201527f4368696c6445524332303a204f6e6c79207072656469636174652063616e2063604082015262185b1b60ea1b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f8211156110d957600081815260208120601f850160051c810160208610156117a05750805b601f850160051c820191505b818110156117bf578281556001016117ac565b505050505050565b815167ffffffffffffffff8111156117e1576117e1611763565b6117f5816117ef84546115ec565b84611779565b602080601f83116001811461182a57600084156118125750858301515b600019600386901b1c1916600185901b1785556117bf565b600085815260208120601f198616915b828110156118595788860151825594840194600190910190840161183a565b50858210156118775787850151600019600388901b60f8161c191681555b5050505050600190811b0190555056fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220b322ab3a17e671324178982233e8fdd83f1d7487c05f56ee80ebf7cb64b9b2c964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildERC20PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC20Predicate","sourceName":"contracts/child/ChildERC20Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"address","name":"newNativeTokenRootAddress","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506114ea806100206000396000f3fe608060405234801561001057600080fd5b50600436106101375760003560e01c80637efab4f5116100b8578063c3b35a7e1161007c578063c3b35a7e14610270578063d41f177114610283578063e0563ab1146102aa578063eeb49945146102b3578063f3fef3a3146102c6578063f6451255146102d957600080fd5b80637efab4f5146101fa578063947287cf1461022357806397e5230d1461022c578063b176806514610236578063b68ad1e41461025d57600080fd5b80633b878c22116100ff5780633b878c22146101ab57806351351d53146101b457806355b01e4d146101c25780635ea5df79146101d057806371cf93b7146101e757600080fd5b806305dc2e8f1461013c57806307b3e2521461016c5780631459457a1461017a5780631bc114ba1461018f578063284017f5146101a2575b600080fd5b60345461014f906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61014f6004600360981b0181565b61018d610188366004610ff2565b610300565b005b60335461014f906001600160a01b031681565b61014f61202081565b61014f61101081565b61014f6002600160a01b0381565b61014f6004600160991b0181565b6101d961138881565b604051908152602001610163565b60355461014f906001600160a01b031681565b61014f610208366004611063565b6037602052600090815260409020546001600160a01b031681565b6101d961520881565b6101d9620249f081565b6101d97f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60365461014f906001600160a01b031681565b61018d61027e366004611087565b610464565b6101d97f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61014f61203081565b61018d6102c13660046110c8565b610474565b61018d6102d4366004611151565b610648565b6101d97f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b336002600160a01b03146103495760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064015b60405180910390fd5b600054610100900460ff16158080156103695750600054600160ff909116105b806103835750303b158015610383575060005460ff166001145b6103e65760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610340565b6000805460ff191660011790558015610409576000805461ff0019166101001790555b6104168686868686610657565b801561045c576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b61046f8383836107a7565b505050565b6034546001600160a01b031633146104df5760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f53544154455f6044820152672922a1a2a4ab22a960c11b6064820152608401610340565b6035546001600160a01b0384811691161461054d5760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f524f4f545f50604482015267524544494341544560c01b6064820152608401610340565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82161057c60206000848661117d565b610585916111a7565b036105a45761059f61059a826020818661117d565b610b1d565b610642565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6105d360206000848661117d565b6105dc916111a7565b036105eb5761059f8282610dc8565b60405162461bcd60e51b815260206004820152602660248201527f4368696c6445524332305072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b6064820152608401610340565b50505050565b6106538233836107a7565b5050565b6001600160a01b0385161580159061067757506001600160a01b03841615155b801561068b57506001600160a01b03831615155b801561069f57506001600160a01b03821615155b6106fb5760405162461bcd60e51b815260206004820152602760248201527f4368696c6445524332305072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b6064820152608401610340565b603380546001600160a01b03199081166001600160a01b0388811691909117909255603480548216878416179055603580548216868416179055603680549091168483161790558116156107a0576001600160a01b03811660008181526037602052604080822080546001600160a01b03191661101090811790915590519092917f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d91a35b5050505050565b826001600160a01b03163b60000361080b5760405162461bcd60e51b815260206004820152602160248201527f4368696c6445524332305072656469636174653a204e4f545f434f4e545241436044820152601560fa1b6064820152608401610340565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561084b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061086f91906111c5565b6001600160a01b038181166000908152603760205260409020549192508581169116146108ae5760405162461bcd60e51b8152600401610340906111e2565b6001600160a01b0381166108c4576108c4611225565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561090c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061093091906111c5565b6001600160a01b03161461094657610946611225565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610974903390869060040161123b565b6020604051808303816000875af1158015610993573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b79190611254565b610a035760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204255524e5f4641494c45446044820152606401610340565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610a8e9391169160c4016112bc565b600060405180830381600087803b158015610aa857600080fd5b505af1158015610abc573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167fa0923f060a16fc784558d43de424ffde7b01643de5e5d335851b9df94c76bb273386604051610b0f92919061123b565b60405180910390a450505050565b6000808080610b2e858701876112e8565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610b715760405162461bcd60e51b8152600401610340906111e2565b806001600160a01b03163b600003610b8b57610b8b611225565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610bcb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bef91906111c5565b9050856001600160a01b0316816001600160a01b031614610c1257610c12611225565b6001600160a01b038116610c2857610c28611225565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c70573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c9491906111c5565b6001600160a01b031614610caa57610caa611225565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610cd8908790879060040161123b565b6020604051808303816000875af1158015610cf7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d1b9190611254565b610d675760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204d494e545f4641494c45446044820152606401610340565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fdf34f3a3ed8bedc14a4b284ebaee5374d55b64bac6a84c270dabe8fd6b4cdafd8887604051610db692919061123b565b60405180910390a45050505050505050565b6000808080610dd9858701876113dc565b92975090955093509150506001600160a01b038416610dfa57610dfa611225565b6001600160a01b038481166000908152603760205260409020541615610e2257610e22611225565b6036546040516bffffffffffffffffffffffff19606087901b166020820152600091610e72916001600160a01b039091169060340160405160208183030381529060405280519060200120610f3d565b6001600160a01b038681166000908152603760205260409081902080546001600160a01b031916928416928317905551637b69774360e11b81529192509063f6d2ee8690610eca908890889088908890600401611469565b600060405180830381600087803b158015610ee457600080fd5b505af1158015610ef8573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a350505050505050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116610fd45760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610340565b92915050565b6001600160a01b0381168114610fef57600080fd5b50565b600080600080600060a0868803121561100a57600080fd5b853561101581610fda565b9450602086013561102581610fda565b9350604086013561103581610fda565b9250606086013561104581610fda565b9150608086013561105581610fda565b809150509295509295909350565b60006020828403121561107557600080fd5b813561108081610fda565b9392505050565b60008060006060848603121561109c57600080fd5b83356110a781610fda565b925060208401356110b781610fda565b929592945050506040919091013590565b600080600080606085870312156110de57600080fd5b8435935060208501356110f081610fda565b9250604085013567ffffffffffffffff8082111561110d57600080fd5b818701915087601f83011261112157600080fd5b81358181111561113057600080fd5b88602082850101111561114257600080fd5b95989497505060200194505050565b6000806040838503121561116457600080fd5b823561116f81610fda565b946020939093013593505050565b6000808585111561118d57600080fd5b8386111561119a57600080fd5b5050820193919092039150565b80356020831015610fd457600019602084900360031b1b1692915050565b6000602082840312156111d757600080fd5b815161108081610fda565b60208082526023908201527f4368696c6445524332305072656469636174653a20554e4d41505045445f544f60408201526225a2a760e91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60006020828403121561126657600080fd5b8151801515811461108057600080fd5b6000815180845260005b8181101561129c57602081850181015186830182015201611280565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b03831681526040602082018190526000906112e090830184611276565b949350505050565b600080600080608085870312156112fe57600080fd5b843561130981610fda565b9350602085013561131981610fda565b9250604085013561132981610fda565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261136057600080fd5b813567ffffffffffffffff8082111561137b5761137b611339565b604051601f8301601f19908116603f011681019082821181831017156113a3576113a3611339565b816040528381528660208588010111156113bc57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a086880312156113f457600080fd5b85359450602086013561140681610fda565b9350604086013567ffffffffffffffff8082111561142357600080fd5b61142f89838a0161134f565b9450606088013591508082111561144557600080fd5b506114528882890161134f565b925050608086013560ff8116811461105557600080fd5b6001600160a01b038516815260806020820181905260009061148d90830186611276565b828103604084015261149f8186611276565b91505060ff831660608301529594505050505056fea2646970667358221220e0f44ad7883c5cd2dbd85a60832f6c9874795bf975cefd366724cc91bbc22dcd64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101375760003560e01c80637efab4f5116100b8578063c3b35a7e1161007c578063c3b35a7e14610270578063d41f177114610283578063e0563ab1146102aa578063eeb49945146102b3578063f3fef3a3146102c6578063f6451255146102d957600080fd5b80637efab4f5146101fa578063947287cf1461022357806397e5230d1461022c578063b176806514610236578063b68ad1e41461025d57600080fd5b80633b878c22116100ff5780633b878c22146101ab57806351351d53146101b457806355b01e4d146101c25780635ea5df79146101d057806371cf93b7146101e757600080fd5b806305dc2e8f1461013c57806307b3e2521461016c5780631459457a1461017a5780631bc114ba1461018f578063284017f5146101a2575b600080fd5b60345461014f906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61014f6004600360981b0181565b61018d610188366004610ff2565b610300565b005b60335461014f906001600160a01b031681565b61014f61202081565b61014f61101081565b61014f6002600160a01b0381565b61014f6004600160991b0181565b6101d961138881565b604051908152602001610163565b60355461014f906001600160a01b031681565b61014f610208366004611063565b6037602052600090815260409020546001600160a01b031681565b6101d961520881565b6101d9620249f081565b6101d97f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60365461014f906001600160a01b031681565b61018d61027e366004611087565b610464565b6101d97f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61014f61203081565b61018d6102c13660046110c8565b610474565b61018d6102d4366004611151565b610648565b6101d97f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b336002600160a01b03146103495760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064015b60405180910390fd5b600054610100900460ff16158080156103695750600054600160ff909116105b806103835750303b158015610383575060005460ff166001145b6103e65760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610340565b6000805460ff191660011790558015610409576000805461ff0019166101001790555b6104168686868686610657565b801561045c576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b61046f8383836107a7565b505050565b6034546001600160a01b031633146104df5760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f53544154455f6044820152672922a1a2a4ab22a960c11b6064820152608401610340565b6035546001600160a01b0384811691161461054d5760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f524f4f545f50604482015267524544494341544560c01b6064820152608401610340565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82161057c60206000848661117d565b610585916111a7565b036105a45761059f61059a826020818661117d565b610b1d565b610642565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6105d360206000848661117d565b6105dc916111a7565b036105eb5761059f8282610dc8565b60405162461bcd60e51b815260206004820152602660248201527f4368696c6445524332305072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b6064820152608401610340565b50505050565b6106538233836107a7565b5050565b6001600160a01b0385161580159061067757506001600160a01b03841615155b801561068b57506001600160a01b03831615155b801561069f57506001600160a01b03821615155b6106fb5760405162461bcd60e51b815260206004820152602760248201527f4368696c6445524332305072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b6064820152608401610340565b603380546001600160a01b03199081166001600160a01b0388811691909117909255603480548216878416179055603580548216868416179055603680549091168483161790558116156107a0576001600160a01b03811660008181526037602052604080822080546001600160a01b03191661101090811790915590519092917f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d91a35b5050505050565b826001600160a01b03163b60000361080b5760405162461bcd60e51b815260206004820152602160248201527f4368696c6445524332305072656469636174653a204e4f545f434f4e545241436044820152601560fa1b6064820152608401610340565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561084b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061086f91906111c5565b6001600160a01b038181166000908152603760205260409020549192508581169116146108ae5760405162461bcd60e51b8152600401610340906111e2565b6001600160a01b0381166108c4576108c4611225565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561090c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061093091906111c5565b6001600160a01b03161461094657610946611225565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610974903390869060040161123b565b6020604051808303816000875af1158015610993573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b79190611254565b610a035760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204255524e5f4641494c45446044820152606401610340565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610a8e9391169160c4016112bc565b600060405180830381600087803b158015610aa857600080fd5b505af1158015610abc573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167fa0923f060a16fc784558d43de424ffde7b01643de5e5d335851b9df94c76bb273386604051610b0f92919061123b565b60405180910390a450505050565b6000808080610b2e858701876112e8565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610b715760405162461bcd60e51b8152600401610340906111e2565b806001600160a01b03163b600003610b8b57610b8b611225565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610bcb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bef91906111c5565b9050856001600160a01b0316816001600160a01b031614610c1257610c12611225565b6001600160a01b038116610c2857610c28611225565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c70573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c9491906111c5565b6001600160a01b031614610caa57610caa611225565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610cd8908790879060040161123b565b6020604051808303816000875af1158015610cf7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d1b9190611254565b610d675760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204d494e545f4641494c45446044820152606401610340565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fdf34f3a3ed8bedc14a4b284ebaee5374d55b64bac6a84c270dabe8fd6b4cdafd8887604051610db692919061123b565b60405180910390a45050505050505050565b6000808080610dd9858701876113dc565b92975090955093509150506001600160a01b038416610dfa57610dfa611225565b6001600160a01b038481166000908152603760205260409020541615610e2257610e22611225565b6036546040516bffffffffffffffffffffffff19606087901b166020820152600091610e72916001600160a01b039091169060340160405160208183030381529060405280519060200120610f3d565b6001600160a01b038681166000908152603760205260409081902080546001600160a01b031916928416928317905551637b69774360e11b81529192509063f6d2ee8690610eca908890889088908890600401611469565b600060405180830381600087803b158015610ee457600080fd5b505af1158015610ef8573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a350505050505050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116610fd45760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610340565b92915050565b6001600160a01b0381168114610fef57600080fd5b50565b600080600080600060a0868803121561100a57600080fd5b853561101581610fda565b9450602086013561102581610fda565b9350604086013561103581610fda565b9250606086013561104581610fda565b9150608086013561105581610fda565b809150509295509295909350565b60006020828403121561107557600080fd5b813561108081610fda565b9392505050565b60008060006060848603121561109c57600080fd5b83356110a781610fda565b925060208401356110b781610fda565b929592945050506040919091013590565b600080600080606085870312156110de57600080fd5b8435935060208501356110f081610fda565b9250604085013567ffffffffffffffff8082111561110d57600080fd5b818701915087601f83011261112157600080fd5b81358181111561113057600080fd5b88602082850101111561114257600080fd5b95989497505060200194505050565b6000806040838503121561116457600080fd5b823561116f81610fda565b946020939093013593505050565b6000808585111561118d57600080fd5b8386111561119a57600080fd5b5050820193919092039150565b80356020831015610fd457600019602084900360031b1b1692915050565b6000602082840312156111d757600080fd5b815161108081610fda565b60208082526023908201527f4368696c6445524332305072656469636174653a20554e4d41505045445f544f60408201526225a2a760e91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60006020828403121561126657600080fd5b8151801515811461108057600080fd5b6000815180845260005b8181101561129c57602081850181015186830182015201611280565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b03831681526040602082018190526000906112e090830184611276565b949350505050565b600080600080608085870312156112fe57600080fd5b843561130981610fda565b9350602085013561131981610fda565b9250604085013561132981610fda565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261136057600080fd5b813567ffffffffffffffff8082111561137b5761137b611339565b604051601f8301601f19908116603f011681019082821181831017156113a3576113a3611339565b816040528381528660208588010111156113bc57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a086880312156113f457600080fd5b85359450602086013561140681610fda565b9350604086013567ffffffffffffffff8082111561142357600080fd5b61142f89838a0161134f565b9450606088013591508082111561144557600080fd5b506114528882890161134f565b925050608086013560ff8116811461105557600080fd5b6001600160a01b038516815260806020820181905260009061148d90830186611276565b828103604084015261149f8186611276565b91505060ff831660608301529594505050505056fea2646970667358221220e0f44ad7883c5cd2dbd85a60832f6c9874795bf975cefd366724cc91bbc22dcd64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildERC20PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC20PredicateAccessList","sourceName":"contracts/child/ChildERC20PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"address","name":"newNativeTokenRootAddress","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"address","name":"newNativeTokenRootAddress","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","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":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611c8e806100206000396000f3fe608060405234801561001057600080fd5b506004361061018f5760003560e01c80638da5cb5b116100e4578063c5e4683a11610092578063c5e4683a14610323578063d41f177114610336578063e0563ab11461035d578063e30c397814610366578063eeb4994514610377578063f2fde38b1461038a578063f3fef3a31461039d578063f6451255146103b057600080fd5b80638da5cb5b1461029f578063947287cf146102b057806397e5230d146102b9578063b1768065146102c3578063b68ad1e4146102ea578063c1225a20146102fd578063c3b35a7e1461031057600080fd5b806354f8abad1161014157806354f8abad1461021a57806355b01e4d1461022d5780635ea5df791461023b578063715018a61461025257806371cf93b71461025a57806379ba50971461026d5780637efab4f51461027557600080fd5b806305dc2e8f1461019457806307b3e252146101c45780631459457a146101d25780631bc114ba146101e7578063284017f5146101fa5780633b878c221461020357806351351d531461020c575b600080fd5b60fd546101a7906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101a76004600360981b0181565b6101e56101e0366004611616565b6103d7565b005b60fc546101a7906001600160a01b031681565b6101a761202081565b6101a761101081565b6101a76002600160a01b0381565b6101e5610228366004611695565b6104db565b6101a76004600160991b0181565b61024461138881565b6040519081526020016101bb565b6101e56105fe565b60fe546101a7906001600160a01b031681565b6101e5610612565b6101a761028336600461173e565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101a7565b61024461520881565b610244620249f081565b6102447f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101a7906001600160a01b031681565b6101e561030b366004611762565b61068c565b6101e561031e36600461177f565b6106db565b6101e5610331366004611762565b6106f3565b6102447f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101a761203081565b6065546001600160a01b03166101a7565b6101e56103853660046117c0565b61073a565b6101e561039836600461173e565b61090e565b6101e56103ab366004611849565b61097f565b6102447f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b336002600160a01b03146104075760405163973d02cb60e01b81526004016103fe90611875565b60405180910390fd5b600054610100900460ff16158080156104275750600054600160ff909116105b806104415750303b158015610441575060005460ff166001145b61045d5760405162461bcd60e51b81526004016103fe90611899565b6000805460ff191660011790558015610480576000805461ff0019166101001790555b61048d8686868686610996565b80156104d3576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b336002600160a01b03146105025760405163973d02cb60e01b81526004016103fe90611875565b600054610100900460ff16158080156105225750600054600160ff909116105b8061053c5750303b15801561053c575060005460ff166001145b6105585760405162461bcd60e51b81526004016103fe90611899565b6000805460ff19166001179055801561057b576000805461ff0019166101001790555b6105888989898989610996565b60c9805461ffff191685151561ff00191617610100851515021790556105ad82610ae7565b80156105f3576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050505050565b610606610b00565b6106106000610ae7565b565b60655433906001600160a01b031681146106805760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016103fe565b61068981610ae7565b50565b610694610b00565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6106e3610b5a565b6106ee838383610b62565b505050565b6106fb610b00565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b60fd546001600160a01b031633146107a55760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f53544154455f6044820152672922a1a2a4ab22a960c11b60648201526084016103fe565b60fe546001600160a01b038481169116146108135760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f524f4f545f50604482015267524544494341544560c01b60648201526084016103fe565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216108426020600084866118e7565b61084b91611911565b0361086a5761086561086082602081866118e7565b610ed9565b610908565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6108996020600084866118e7565b6108a291611911565b036108b1576108658282611185565b60405162461bcd60e51b815260206004820152602660248201527f4368696c6445524332305072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b60648201526084016103fe565b50505050565b610916610b00565b606580546001600160a01b0383166001600160a01b031990911681179091556109476033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b610987610b5a565b610992823383610b62565b5050565b6001600160a01b038516158015906109b657506001600160a01b03841615155b80156109ca57506001600160a01b03831615155b80156109de57506001600160a01b03821615155b610a3a5760405162461bcd60e51b815260206004820152602760248201527f4368696c6445524332305072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b60648201526084016103fe565b60fc80546001600160a01b03199081166001600160a01b038881169190911790925560fd8054821687841617905560fe8054821686841617905560ff8054909116848316179055811615610ae0576001600160a01b0381166000818152610100602052604080822080546001600160a01b03191661101090811790915590519092917f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d91a35b5050505050565b606580546001600160a01b0319169055610689816112fc565b6033546001600160a01b031633146106105760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103fe565b61061061134e565b826001600160a01b03163b600003610bc65760405162461bcd60e51b815260206004820152602160248201527f4368696c6445524332305072656469636174653a204e4f545f434f4e545241436044820152601560fa1b60648201526084016103fe565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c06573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c2a919061192f565b6001600160a01b0381811660009081526101006020526040902054919250858116911614610c6a5760405162461bcd60e51b81526004016103fe9061194c565b6001600160a01b038116610c8057610c8061198f565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610cc8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cec919061192f565b6001600160a01b031614610d0257610d0261198f565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610d3090339086906004016119a5565b6020604051808303816000875af1158015610d4f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d7391906119be565b610dbf5760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204255524e5f4641494c454460448201526064016103fe565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610e4a9391169160c401611a2b565b600060405180830381600087803b158015610e6457600080fd5b505af1158015610e78573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167fa0923f060a16fc784558d43de424ffde7b01643de5e5d335851b9df94c76bb273386604051610ecb9291906119a5565b60405180910390a450505050565b6000808080610eea85870187611a57565b6001600160a01b038085166000908152610100602052604090205494985092965090945092501680610f2e5760405162461bcd60e51b81526004016103fe9061194c565b806001600160a01b03163b600003610f4857610f4861198f565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f88573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fac919061192f565b9050856001600160a01b0316816001600160a01b031614610fcf57610fcf61198f565b6001600160a01b038116610fe557610fe561198f565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561102d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611051919061192f565b6001600160a01b0316146110675761106761198f565b6040516340c10f1960e01b81526001600160a01b038316906340c10f199061109590879087906004016119a5565b6020604051808303816000875af11580156110b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d891906119be565b6111245760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204d494e545f4641494c454460448201526064016103fe565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fdf34f3a3ed8bedc14a4b284ebaee5374d55b64bac6a84c270dabe8fd6b4cdafd88876040516111739291906119a5565b60405180910390a45050505050505050565b600080808061119685870187611b4b565b92975090955093509150506001600160a01b0384166111b7576111b761198f565b6001600160a01b038481166000908152610100602052604090205416156111e0576111e061198f565b60ff546040516bffffffffffffffffffffffff19606087901b166020820152600091611230916001600160a01b039091169060340160405160208183030381529060405280519060200120611564565b6001600160a01b03868116600090815261010060205260409081902080546001600160a01b031916928416928317905551637b69774360e11b81529192509063f6d2ee8690611289908890889088908890600401611bd8565b600060405180830381600087803b1580156112a357600080fd5b505af11580156112b7573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a350505050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff161561145957604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b0191611388916113b09190611c23565b6000604051808303818686fa925050503d80600081146113ec576040519150601f19603f3d011682016040523d82523d6000602084013e6113f1565b606091505b509150915081801561141657506000818060200190518101906114149190611c3f565b115b6114565760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016103fe565b50505b60c954610100900460ff161561061057604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b0191611388916114c09190611c23565b6000604051808303818686fa925050503d80600081146114fc576040519150601f19603f3d011682016040523d82523d6000602084013e611501565b606091505b50915091508180156115275750808060200190518101906115229190611c3f565b600114155b6109925760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016103fe565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166115fb5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016103fe565b92915050565b6001600160a01b038116811461068957600080fd5b600080600080600060a0868803121561162e57600080fd5b853561163981611601565b9450602086013561164981611601565b9350604086013561165981611601565b9250606086013561166981611601565b9150608086013561167981611601565b809150509295509295909350565b801515811461068957600080fd5b600080600080600080600080610100898b0312156116b257600080fd5b88356116bd81611601565b975060208901356116cd81611601565b965060408901356116dd81611601565b955060608901356116ed81611601565b945060808901356116fd81611601565b935060a089013561170d81611687565b925060c089013561171d81611687565b915060e089013561172d81611601565b809150509295985092959890939650565b60006020828403121561175057600080fd5b813561175b81611601565b9392505050565b60006020828403121561177457600080fd5b813561175b81611687565b60008060006060848603121561179457600080fd5b833561179f81611601565b925060208401356117af81611601565b929592945050506040919091013590565b600080600080606085870312156117d657600080fd5b8435935060208501356117e881611601565b9250604085013567ffffffffffffffff8082111561180557600080fd5b818701915087601f83011261181957600080fd5b81358181111561182857600080fd5b88602082850101111561183a57600080fd5b95989497505060200194505050565b6000806040838503121561185c57600080fd5b823561186781611601565b946020939093013593505050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b600080858511156118f757600080fd5b8386111561190457600080fd5b5050820193919092039150565b803560208310156115fb57600019602084900360031b1b1692915050565b60006020828403121561194157600080fd5b815161175b81611601565b60208082526023908201527f4368696c6445524332305072656469636174653a20554e4d41505045445f544f60408201526225a2a760e91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b6000602082840312156119d057600080fd5b815161175b81611687565b60005b838110156119f65781810151838201526020016119de565b50506000910152565b60008151808452611a178160208601602086016119db565b601f01601f19169290920160200192915050565b6001600160a01b0383168152604060208201819052600090611a4f908301846119ff565b949350505050565b60008060008060808587031215611a6d57600080fd5b8435611a7881611601565b93506020850135611a8881611601565b92506040850135611a9881611601565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112611acf57600080fd5b813567ffffffffffffffff80821115611aea57611aea611aa8565b604051601f8301601f19908116603f01168101908282118183101715611b1257611b12611aa8565b81604052838152866020858801011115611b2b57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a08688031215611b6357600080fd5b853594506020860135611b7581611601565b9350604086013567ffffffffffffffff80821115611b9257600080fd5b611b9e89838a01611abe565b94506060880135915080821115611bb457600080fd5b50611bc188828901611abe565b925050608086013560ff8116811461167957600080fd5b6001600160a01b0385168152608060208201819052600090611bfc908301866119ff565b8281036040840152611c0e81866119ff565b91505060ff8316606083015295945050505050565b60008251611c358184602087016119db565b9190910192915050565b600060208284031215611c5157600080fd5b505191905056fea26469706673582212206ea7447ee1c5e059d53f0d5e7f2241d867a55a3968ed1a50039de2f2d55b996664736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061018f5760003560e01c80638da5cb5b116100e4578063c5e4683a11610092578063c5e4683a14610323578063d41f177114610336578063e0563ab11461035d578063e30c397814610366578063eeb4994514610377578063f2fde38b1461038a578063f3fef3a31461039d578063f6451255146103b057600080fd5b80638da5cb5b1461029f578063947287cf146102b057806397e5230d146102b9578063b1768065146102c3578063b68ad1e4146102ea578063c1225a20146102fd578063c3b35a7e1461031057600080fd5b806354f8abad1161014157806354f8abad1461021a57806355b01e4d1461022d5780635ea5df791461023b578063715018a61461025257806371cf93b71461025a57806379ba50971461026d5780637efab4f51461027557600080fd5b806305dc2e8f1461019457806307b3e252146101c45780631459457a146101d25780631bc114ba146101e7578063284017f5146101fa5780633b878c221461020357806351351d531461020c575b600080fd5b60fd546101a7906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101a76004600360981b0181565b6101e56101e0366004611616565b6103d7565b005b60fc546101a7906001600160a01b031681565b6101a761202081565b6101a761101081565b6101a76002600160a01b0381565b6101e5610228366004611695565b6104db565b6101a76004600160991b0181565b61024461138881565b6040519081526020016101bb565b6101e56105fe565b60fe546101a7906001600160a01b031681565b6101e5610612565b6101a761028336600461173e565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101a7565b61024461520881565b610244620249f081565b6102447f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101a7906001600160a01b031681565b6101e561030b366004611762565b61068c565b6101e561031e36600461177f565b6106db565b6101e5610331366004611762565b6106f3565b6102447f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101a761203081565b6065546001600160a01b03166101a7565b6101e56103853660046117c0565b61073a565b6101e561039836600461173e565b61090e565b6101e56103ab366004611849565b61097f565b6102447f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b336002600160a01b03146104075760405163973d02cb60e01b81526004016103fe90611875565b60405180910390fd5b600054610100900460ff16158080156104275750600054600160ff909116105b806104415750303b158015610441575060005460ff166001145b61045d5760405162461bcd60e51b81526004016103fe90611899565b6000805460ff191660011790558015610480576000805461ff0019166101001790555b61048d8686868686610996565b80156104d3576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b336002600160a01b03146105025760405163973d02cb60e01b81526004016103fe90611875565b600054610100900460ff16158080156105225750600054600160ff909116105b8061053c5750303b15801561053c575060005460ff166001145b6105585760405162461bcd60e51b81526004016103fe90611899565b6000805460ff19166001179055801561057b576000805461ff0019166101001790555b6105888989898989610996565b60c9805461ffff191685151561ff00191617610100851515021790556105ad82610ae7565b80156105f3576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050505050565b610606610b00565b6106106000610ae7565b565b60655433906001600160a01b031681146106805760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016103fe565b61068981610ae7565b50565b610694610b00565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6106e3610b5a565b6106ee838383610b62565b505050565b6106fb610b00565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b60fd546001600160a01b031633146107a55760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f53544154455f6044820152672922a1a2a4ab22a960c11b60648201526084016103fe565b60fe546001600160a01b038481169116146108135760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f524f4f545f50604482015267524544494341544560c01b60648201526084016103fe565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216108426020600084866118e7565b61084b91611911565b0361086a5761086561086082602081866118e7565b610ed9565b610908565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6108996020600084866118e7565b6108a291611911565b036108b1576108658282611185565b60405162461bcd60e51b815260206004820152602660248201527f4368696c6445524332305072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b60648201526084016103fe565b50505050565b610916610b00565b606580546001600160a01b0383166001600160a01b031990911681179091556109476033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b610987610b5a565b610992823383610b62565b5050565b6001600160a01b038516158015906109b657506001600160a01b03841615155b80156109ca57506001600160a01b03831615155b80156109de57506001600160a01b03821615155b610a3a5760405162461bcd60e51b815260206004820152602760248201527f4368696c6445524332305072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b60648201526084016103fe565b60fc80546001600160a01b03199081166001600160a01b038881169190911790925560fd8054821687841617905560fe8054821686841617905560ff8054909116848316179055811615610ae0576001600160a01b0381166000818152610100602052604080822080546001600160a01b03191661101090811790915590519092917f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d91a35b5050505050565b606580546001600160a01b0319169055610689816112fc565b6033546001600160a01b031633146106105760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103fe565b61061061134e565b826001600160a01b03163b600003610bc65760405162461bcd60e51b815260206004820152602160248201527f4368696c6445524332305072656469636174653a204e4f545f434f4e545241436044820152601560fa1b60648201526084016103fe565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c06573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c2a919061192f565b6001600160a01b0381811660009081526101006020526040902054919250858116911614610c6a5760405162461bcd60e51b81526004016103fe9061194c565b6001600160a01b038116610c8057610c8061198f565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610cc8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cec919061192f565b6001600160a01b031614610d0257610d0261198f565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610d3090339086906004016119a5565b6020604051808303816000875af1158015610d4f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d7391906119be565b610dbf5760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204255524e5f4641494c454460448201526064016103fe565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610e4a9391169160c401611a2b565b600060405180830381600087803b158015610e6457600080fd5b505af1158015610e78573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167fa0923f060a16fc784558d43de424ffde7b01643de5e5d335851b9df94c76bb273386604051610ecb9291906119a5565b60405180910390a450505050565b6000808080610eea85870187611a57565b6001600160a01b038085166000908152610100602052604090205494985092965090945092501680610f2e5760405162461bcd60e51b81526004016103fe9061194c565b806001600160a01b03163b600003610f4857610f4861198f565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f88573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fac919061192f565b9050856001600160a01b0316816001600160a01b031614610fcf57610fcf61198f565b6001600160a01b038116610fe557610fe561198f565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561102d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611051919061192f565b6001600160a01b0316146110675761106761198f565b6040516340c10f1960e01b81526001600160a01b038316906340c10f199061109590879087906004016119a5565b6020604051808303816000875af11580156110b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d891906119be565b6111245760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204d494e545f4641494c454460448201526064016103fe565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fdf34f3a3ed8bedc14a4b284ebaee5374d55b64bac6a84c270dabe8fd6b4cdafd88876040516111739291906119a5565b60405180910390a45050505050505050565b600080808061119685870187611b4b565b92975090955093509150506001600160a01b0384166111b7576111b761198f565b6001600160a01b038481166000908152610100602052604090205416156111e0576111e061198f565b60ff546040516bffffffffffffffffffffffff19606087901b166020820152600091611230916001600160a01b039091169060340160405160208183030381529060405280519060200120611564565b6001600160a01b03868116600090815261010060205260409081902080546001600160a01b031916928416928317905551637b69774360e11b81529192509063f6d2ee8690611289908890889088908890600401611bd8565b600060405180830381600087803b1580156112a357600080fd5b505af11580156112b7573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a350505050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff161561145957604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b0191611388916113b09190611c23565b6000604051808303818686fa925050503d80600081146113ec576040519150601f19603f3d011682016040523d82523d6000602084013e6113f1565b606091505b509150915081801561141657506000818060200190518101906114149190611c3f565b115b6114565760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016103fe565b50505b60c954610100900460ff161561061057604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b0191611388916114c09190611c23565b6000604051808303818686fa925050503d80600081146114fc576040519150601f19603f3d011682016040523d82523d6000602084013e611501565b606091505b50915091508180156115275750808060200190518101906115229190611c3f565b600114155b6109925760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016103fe565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166115fb5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016103fe565b92915050565b6001600160a01b038116811461068957600080fd5b600080600080600060a0868803121561162e57600080fd5b853561163981611601565b9450602086013561164981611601565b9350604086013561165981611601565b9250606086013561166981611601565b9150608086013561167981611601565b809150509295509295909350565b801515811461068957600080fd5b600080600080600080600080610100898b0312156116b257600080fd5b88356116bd81611601565b975060208901356116cd81611601565b965060408901356116dd81611601565b955060608901356116ed81611601565b945060808901356116fd81611601565b935060a089013561170d81611687565b925060c089013561171d81611687565b915060e089013561172d81611601565b809150509295985092959890939650565b60006020828403121561175057600080fd5b813561175b81611601565b9392505050565b60006020828403121561177457600080fd5b813561175b81611687565b60008060006060848603121561179457600080fd5b833561179f81611601565b925060208401356117af81611601565b929592945050506040919091013590565b600080600080606085870312156117d657600080fd5b8435935060208501356117e881611601565b9250604085013567ffffffffffffffff8082111561180557600080fd5b818701915087601f83011261181957600080fd5b81358181111561182857600080fd5b88602082850101111561183a57600080fd5b95989497505060200194505050565b6000806040838503121561185c57600080fd5b823561186781611601565b946020939093013593505050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b600080858511156118f757600080fd5b8386111561190457600080fd5b5050820193919092039150565b803560208310156115fb57600019602084900360031b1b1692915050565b60006020828403121561194157600080fd5b815161175b81611601565b60208082526023908201527f4368696c6445524332305072656469636174653a20554e4d41505045445f544f60408201526225a2a760e91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b6000602082840312156119d057600080fd5b815161175b81611687565b60005b838110156119f65781810151838201526020016119de565b50506000910152565b60008151808452611a178160208601602086016119db565b601f01601f19169290920160200192915050565b6001600160a01b0383168152604060208201819052600090611a4f908301846119ff565b949350505050565b60008060008060808587031215611a6d57600080fd5b8435611a7881611601565b93506020850135611a8881611601565b92506040850135611a9881611601565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112611acf57600080fd5b813567ffffffffffffffff80821115611aea57611aea611aa8565b604051601f8301601f19908116603f01168101908282118183101715611b1257611b12611aa8565b81604052838152866020858801011115611b2b57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a08688031215611b6357600080fd5b853594506020860135611b7581611601565b9350604086013567ffffffffffffffff80821115611b9257600080fd5b611b9e89838a01611abe565b94506060880135915080821115611bb457600080fd5b50611bc188828901611abe565b925050608086013560ff8116811461167957600080fd5b6001600160a01b0385168152608060208201819052600090611bfc908301866119ff565b8281036040840152611c0e81866119ff565b91505060ff8316606083015295945050505050565b60008251611c358184602087016119db565b9190910192915050565b600060208284031215611c5157600080fd5b505191905056fea26469706673582212206ea7447ee1c5e059d53f0d5e7f2241d867a55a3968ed1a50039de2f2d55b996664736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RootMintableERC20PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC20Predicate","sourceName":"contracts/child/RootMintableERC20Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061149f806100206000396000f3fe608060405234801561001057600080fd5b50600436106101425760003560e01c806397e5230d116100b8578063e0563ab11161007c578063e0563ab1146102a2578063eeb49945146102ab578063f213159c146102be578063f4a120f7146102d1578063f6451255146102e4578063f8c8765e1461030b57600080fd5b806397e5230d14610224578063b17680651461022e578063b68ad1e414610255578063d41f177114610268578063d57184e41461028f57600080fd5b806347e7ef241161010a57806347e7ef24146101aa57806351351d53146101bf57806355b01e4d146101cd5780635ea5df79146101db5780637efab4f5146101f2578063947287cf1461021b57600080fd5b806305dc2e8f1461014757806307b3e252146101775780631bc114ba14610185578063284017f5146101985780633b878c22146101a1575b600080fd5b60345461015a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61015a6004600360981b0181565b60335461015a906001600160a01b031681565b61015a61202081565b61015a61101081565b6101bd6101b8366004611038565b61031e565b005b61015a6002600160a01b0381565b61015a6004600160991b0181565b6101e461138881565b60405190815260200161016e565b61015a610200366004611064565b6037602052600090815260409020546001600160a01b031681565b6101e461520881565b6101e4620249f081565b6101e47f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60365461015a906001600160a01b031681565b6101e47f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60355461015a906001600160a01b031681565b61015a61203081565b6101bd6102b9366004611088565b61032d565b6101bd6102cc366004611111565b6104d5565b61015a6102df366004611064565b6104e5565b6101e47f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6101bd610319366004611152565b6108b1565b610329823383610a0e565b5050565b6034546001600160a01b031633146103a45760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526e2fa9aa20aa22afa922a1a2a4ab22a960891b60648201526084015b60405180910390fd5b6035546001600160a01b0384811691161461041a5760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526f5f4348494c445f50524544494341544560801b606482015260840161039b565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696104496020600084866111ae565b610452916111d8565b036104715761046c61046782602081866111ae565b610b7e565b6104cf565b60405162461bcd60e51b815260206004820152602d60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e564160448201526c4c49445f5349474e415455524560981b606482015260840161039b565b50505050565b6104e0838383610a0e565b505050565b60006001600160a01b03821661054f5760405162461bcd60e51b815260206004820152602960248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e56416044820152682624a22faa27a5a2a760b91b606482015260840161039b565b6001600160a01b0382811660009081526037602052604090205416156105ca5760405162461bcd60e51b815260206004820152602a60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20414c524560448201526910511657d3505414115160b21b606482015260840161039b565b6035546036546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261067892911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0385811660008181526037602052604080822080546001600160a01b03191686861617905560335481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610710573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526107389190810190611231565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610776573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261079e9190810190611231565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107dc573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061080091906112d3565b604051602001610814959493929190611322565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610840929190611374565b600060405180830381600087803b15801561085a57600080fd5b505af115801561086e573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b03146108f55760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b604482015260640161039b565b600054610100900460ff16158080156109155750600054600160ff909116105b8061092f5750303b15801561092f575060005460ff166001145b6109925760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161039b565b6000805460ff1916600117905580156109b5576000805461ff0019166101001790555b6109c185858585610c36565b8015610a07576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6001600160a01b038084166000908152603760205260409020541680610a3a57610a37846104e5565b90505b6001600160a01b038116610a5057610a50611398565b610a656001600160a01b038516333085610d31565b603354603554604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610af09391169160c401611374565b600060405180830381600087803b158015610b0a57600080fd5b505af1158015610b1e573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f1666a3f7b8a7494f2ebcebe646a5187ae55b1db3a068097377d90cd64a258ce93386604051610b719291906113ae565b60405180910390a46104cf565b6000808080610b8f858701876113c7565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610bc257610bc2611398565b610bd66001600160a01b0386168484610d9c565b826001600160a01b0316816001600160a01b0316866001600160a01b03167fb9f935478aae5b1da868de596dafe0a2b41eeb61311fdd60c6dbbe46a1debee88786604051610c259291906113ae565b60405180910390a450505050505050565b6001600160a01b03841615801590610c5657506001600160a01b03831615155b8015610c6a57506001600160a01b03821615155b8015610c7e57506001600160a01b03811615155b610ce15760405162461bcd60e51b815260206004820152602e60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204241445f60448201526d24a724aa24a0a624ad20aa24a7a760911b606482015260840161039b565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6040516001600160a01b03808516602483015283166044820152606481018290526104cf9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610dbb565b6104e08363a9059cbb60e01b8484604051602401610d659291906113ae565b6000610e10826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610e909092919063ffffffff16565b9050805160001480610e31575080806020019051810190610e319190611418565b6104e05760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b606482015260840161039b565b6060610e9f8484600085610ea7565b949350505050565b606082471015610f085760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b606482015260840161039b565b600080866001600160a01b03168587604051610f24919061143a565b60006040518083038185875af1925050503d8060008114610f61576040519150601f19603f3d011682016040523d82523d6000602084013e610f66565b606091505b5091509150610f7787838387610f82565b979650505050505050565b60608315610ff1578251600003610fea576001600160a01b0385163b610fea5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161039b565b5081610e9f565b610e9f83838151156110065781518083602001fd5b8060405162461bcd60e51b815260040161039b9190611456565b6001600160a01b038116811461103557600080fd5b50565b6000806040838503121561104b57600080fd5b823561105681611020565b946020939093013593505050565b60006020828403121561107657600080fd5b813561108181611020565b9392505050565b6000806000806060858703121561109e57600080fd5b8435935060208501356110b081611020565b9250604085013567ffffffffffffffff808211156110cd57600080fd5b818701915087601f8301126110e157600080fd5b8135818111156110f057600080fd5b88602082850101111561110257600080fd5b95989497505060200194505050565b60008060006060848603121561112657600080fd5b833561113181611020565b9250602084013561114181611020565b929592945050506040919091013590565b6000806000806080858703121561116857600080fd5b843561117381611020565b9350602085013561118381611020565b9250604085013561119381611020565b915060608501356111a381611020565b939692955090935050565b600080858511156111be57600080fd5b838611156111cb57600080fd5b5050820193919092039150565b803560208310156111f157600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b83811015611228578181015183820152602001611210565b50506000910152565b60006020828403121561124357600080fd5b815167ffffffffffffffff8082111561125b57600080fd5b818401915084601f83011261126f57600080fd5b815181811115611281576112816111f7565b604051601f8201601f19908116603f011681019083821181831017156112a9576112a96111f7565b816040528281528760208487010111156112c257600080fd5b610f7783602083016020880161120d565b6000602082840312156112e557600080fd5b815160ff8116811461108157600080fd5b6000815180845261130e81602086016020860161120d565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a06040820181905260009061134c908301866112f6565b828103606084015261135e81866112f6565b91505060ff831660808301529695505050505050565b6001600160a01b0383168152604060208201819052600090610e9f908301846112f6565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b600080600080608085870312156113dd57600080fd5b84356113e881611020565b935060208501356113f881611020565b9250604085013561140881611020565b9396929550929360600135925050565b60006020828403121561142a57600080fd5b8151801515811461108157600080fd5b6000825161144c81846020870161120d565b9190910192915050565b60208152600061108160208301846112f656fea264697066735822122084ec8ad36f0d03abcfc5bde4447836ff970764edfea496ff308f22046530682b64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101425760003560e01c806397e5230d116100b8578063e0563ab11161007c578063e0563ab1146102a2578063eeb49945146102ab578063f213159c146102be578063f4a120f7146102d1578063f6451255146102e4578063f8c8765e1461030b57600080fd5b806397e5230d14610224578063b17680651461022e578063b68ad1e414610255578063d41f177114610268578063d57184e41461028f57600080fd5b806347e7ef241161010a57806347e7ef24146101aa57806351351d53146101bf57806355b01e4d146101cd5780635ea5df79146101db5780637efab4f5146101f2578063947287cf1461021b57600080fd5b806305dc2e8f1461014757806307b3e252146101775780631bc114ba14610185578063284017f5146101985780633b878c22146101a1575b600080fd5b60345461015a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61015a6004600360981b0181565b60335461015a906001600160a01b031681565b61015a61202081565b61015a61101081565b6101bd6101b8366004611038565b61031e565b005b61015a6002600160a01b0381565b61015a6004600160991b0181565b6101e461138881565b60405190815260200161016e565b61015a610200366004611064565b6037602052600090815260409020546001600160a01b031681565b6101e461520881565b6101e4620249f081565b6101e47f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60365461015a906001600160a01b031681565b6101e47f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60355461015a906001600160a01b031681565b61015a61203081565b6101bd6102b9366004611088565b61032d565b6101bd6102cc366004611111565b6104d5565b61015a6102df366004611064565b6104e5565b6101e47f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6101bd610319366004611152565b6108b1565b610329823383610a0e565b5050565b6034546001600160a01b031633146103a45760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526e2fa9aa20aa22afa922a1a2a4ab22a960891b60648201526084015b60405180910390fd5b6035546001600160a01b0384811691161461041a5760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526f5f4348494c445f50524544494341544560801b606482015260840161039b565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696104496020600084866111ae565b610452916111d8565b036104715761046c61046782602081866111ae565b610b7e565b6104cf565b60405162461bcd60e51b815260206004820152602d60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e564160448201526c4c49445f5349474e415455524560981b606482015260840161039b565b50505050565b6104e0838383610a0e565b505050565b60006001600160a01b03821661054f5760405162461bcd60e51b815260206004820152602960248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e56416044820152682624a22faa27a5a2a760b91b606482015260840161039b565b6001600160a01b0382811660009081526037602052604090205416156105ca5760405162461bcd60e51b815260206004820152602a60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20414c524560448201526910511657d3505414115160b21b606482015260840161039b565b6035546036546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261067892911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0385811660008181526037602052604080822080546001600160a01b03191686861617905560335481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610710573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526107389190810190611231565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610776573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261079e9190810190611231565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107dc573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061080091906112d3565b604051602001610814959493929190611322565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610840929190611374565b600060405180830381600087803b15801561085a57600080fd5b505af115801561086e573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b03146108f55760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b604482015260640161039b565b600054610100900460ff16158080156109155750600054600160ff909116105b8061092f5750303b15801561092f575060005460ff166001145b6109925760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161039b565b6000805460ff1916600117905580156109b5576000805461ff0019166101001790555b6109c185858585610c36565b8015610a07576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6001600160a01b038084166000908152603760205260409020541680610a3a57610a37846104e5565b90505b6001600160a01b038116610a5057610a50611398565b610a656001600160a01b038516333085610d31565b603354603554604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610af09391169160c401611374565b600060405180830381600087803b158015610b0a57600080fd5b505af1158015610b1e573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f1666a3f7b8a7494f2ebcebe646a5187ae55b1db3a068097377d90cd64a258ce93386604051610b719291906113ae565b60405180910390a46104cf565b6000808080610b8f858701876113c7565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610bc257610bc2611398565b610bd66001600160a01b0386168484610d9c565b826001600160a01b0316816001600160a01b0316866001600160a01b03167fb9f935478aae5b1da868de596dafe0a2b41eeb61311fdd60c6dbbe46a1debee88786604051610c259291906113ae565b60405180910390a450505050505050565b6001600160a01b03841615801590610c5657506001600160a01b03831615155b8015610c6a57506001600160a01b03821615155b8015610c7e57506001600160a01b03811615155b610ce15760405162461bcd60e51b815260206004820152602e60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204241445f60448201526d24a724aa24a0a624ad20aa24a7a760911b606482015260840161039b565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6040516001600160a01b03808516602483015283166044820152606481018290526104cf9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610dbb565b6104e08363a9059cbb60e01b8484604051602401610d659291906113ae565b6000610e10826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610e909092919063ffffffff16565b9050805160001480610e31575080806020019051810190610e319190611418565b6104e05760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b606482015260840161039b565b6060610e9f8484600085610ea7565b949350505050565b606082471015610f085760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b606482015260840161039b565b600080866001600160a01b03168587604051610f24919061143a565b60006040518083038185875af1925050503d8060008114610f61576040519150601f19603f3d011682016040523d82523d6000602084013e610f66565b606091505b5091509150610f7787838387610f82565b979650505050505050565b60608315610ff1578251600003610fea576001600160a01b0385163b610fea5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161039b565b5081610e9f565b610e9f83838151156110065781518083602001fd5b8060405162461bcd60e51b815260040161039b9190611456565b6001600160a01b038116811461103557600080fd5b50565b6000806040838503121561104b57600080fd5b823561105681611020565b946020939093013593505050565b60006020828403121561107657600080fd5b813561108181611020565b9392505050565b6000806000806060858703121561109e57600080fd5b8435935060208501356110b081611020565b9250604085013567ffffffffffffffff808211156110cd57600080fd5b818701915087601f8301126110e157600080fd5b8135818111156110f057600080fd5b88602082850101111561110257600080fd5b95989497505060200194505050565b60008060006060848603121561112657600080fd5b833561113181611020565b9250602084013561114181611020565b929592945050506040919091013590565b6000806000806080858703121561116857600080fd5b843561117381611020565b9350602085013561118381611020565b9250604085013561119381611020565b915060608501356111a381611020565b939692955090935050565b600080858511156111be57600080fd5b838611156111cb57600080fd5b5050820193919092039150565b803560208310156111f157600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b83811015611228578181015183820152602001611210565b50506000910152565b60006020828403121561124357600080fd5b815167ffffffffffffffff8082111561125b57600080fd5b818401915084601f83011261126f57600080fd5b815181811115611281576112816111f7565b604051601f8201601f19908116603f011681019083821181831017156112a9576112a96111f7565b816040528281528760208487010111156112c257600080fd5b610f7783602083016020880161120d565b6000602082840312156112e557600080fd5b815160ff8116811461108157600080fd5b6000815180845261130e81602086016020860161120d565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a06040820181905260009061134c908301866112f6565b828103606084015261135e81866112f6565b91505060ff831660808301529695505050505050565b6001600160a01b0383168152604060208201819052600090610e9f908301846112f6565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b600080600080608085870312156113dd57600080fd5b84356113e881611020565b935060208501356113f881611020565b9250604085013561140881611020565b9396929550929360600135925050565b60006020828403121561142a57600080fd5b8151801515811461108157600080fd5b6000825161144c81846020870161120d565b9190910192915050565b60208152600061108160208301846112f656fea264697066735822122084ec8ad36f0d03abcfc5bde4447836ff970764edfea496ff308f22046530682b64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RootMintableERC20PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC20PredicateAccessList","sourceName":"contracts/child/RootMintableERC20PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611bfb806100206000396000f3fe608060405234801561001057600080fd5b506004361061019a5760003560e01c8063b1768065116100e4578063e0563ab111610092578063e0563ab114610355578063e30c39781461035e578063eeb499451461036f578063f213159c14610382578063f2fde38b14610395578063f4a120f7146103a8578063f6451255146103bb578063f8c8765e146103e257600080fd5b8063b1768065146102a8578063b68ad1e4146102cf578063c1225a20146102e2578063c5e4683a146102f5578063d41f177114610308578063d57184e41461032f578063d8dd17731461034257600080fd5b806355b01e4d1161014c57806355b01e4d146102255780635ea5df7914610233578063715018a61461024a57806379ba5097146102525780637efab4f51461025a5780638da5cb5b14610284578063947287cf1461029557806397e5230d1461029e57600080fd5b806305dc2e8f1461019f57806307b3e252146101cf5780631bc114ba146101dd578063284017f5146101f05780633b878c22146101f957806347e7ef241461020257806351351d5314610217575b600080fd5b60fd546101b2906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101b26004600360981b0181565b60fc546101b2906001600160a01b031681565b6101b261202081565b6101b261101081565b61021561021036600461164d565b6103f5565b005b6101b26002600160a01b0381565b6101b26004600160991b0181565b61023c61138881565b6040519081526020016101c6565b610215610404565b610215610418565b6101b2610268366004611679565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101b2565b61023c61520881565b61023c620249f081565b61023c7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101b2906001600160a01b031681565b6102156102f03660046116ab565b610497565b6102156103033660046116ab565b6104e6565b61023c7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60fe546101b2906001600160a01b031681565b6102156103503660046116c8565b61052d565b6101b261203081565b6065546001600160a01b03166101b2565b61021561037d36600461175e565b61064e565b6102156103903660046117e7565b6107f1565b6102156103a3366004611679565b610801565b6101b26103b6366004611679565b610872565b61023c7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102156103f0366004611828565b610c40565b610400823383610d39565b5050565b61040c610eb2565b6104166000610f0c565b565b60655433906001600160a01b0316811461048b5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61049481610f0c565b50565b61049f610eb2565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6104ee610eb2565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105545760405163973d02cb60e01b815260040161048290611884565b600054610100900460ff16158080156105745750600054600160ff909116105b8061058e5750303b15801561058e575060005460ff166001145b6105aa5760405162461bcd60e51b8152600401610482906118a8565b6000805460ff1916600117905580156105cd576000805461ff0019166101001790555b6105d988888888610f25565b60c9805461ffff191685151561ff00191617610100851515021790556105fe82610f0c565b8015610644576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146106c05760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526e2fa9aa20aa22afa922a1a2a4ab22a960891b6064820152608401610482565b60fe546001600160a01b038481169116146107365760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526f5f4348494c445f50524544494341544560801b6064820152608401610482565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696107656020600084866118f6565b61076e91611920565b0361078d5761078861078382602081866118f6565b611020565b6107eb565b60405162461bcd60e51b815260206004820152602d60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e564160448201526c4c49445f5349474e415455524560981b6064820152608401610482565b50505050565b6107fc838383610d39565b505050565b610809610eb2565b606580546001600160a01b0383166001600160a01b0319909116811790915561083a6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b0382166108dc5760405162461bcd60e51b815260206004820152602960248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e56416044820152682624a22faa27a5a2a760b91b6064820152608401610482565b6001600160a01b038281166000908152610100602052604090205416156109585760405162461bcd60e51b815260206004820152602a60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20414c524560448201526910511657d3505414115160b21b6064820152608401610482565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692600092610a0692911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b038581166000818152610100602052604080822080546001600160a01b03191686861617905560fc5481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610a9f573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ac79190810190611979565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610b05573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610b2d9190810190611979565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b6b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8f9190611a1b565b604051602001610ba3959493929190611a6a565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610bcf929190611abc565b600060405180830381600087803b158015610be957600080fd5b505af1158015610bfd573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b0314610c675760405163973d02cb60e01b815260040161048290611884565b600054610100900460ff1615808015610c875750600054600160ff909116105b80610ca15750303b158015610ca1575060005460ff166001145b610cbd5760405162461bcd60e51b8152600401610482906118a8565b6000805460ff191660011790558015610ce0576000805461ff0019166101001790555b610cec85858585610f25565b8015610d32576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b610d416110d9565b6001600160a01b03808416600090815261010060205260409020541680610d6e57610d6b84610872565b90505b6001600160a01b038116610d8457610d84611ae0565b610d996001600160a01b0385163330856110e1565b60fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610e249391169160c401611abc565b600060405180830381600087803b158015610e3e57600080fd5b505af1158015610e52573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f1666a3f7b8a7494f2ebcebe646a5187ae55b1db3a068097377d90cd64a258ce93386604051610ea5929190611af6565b60405180910390a46107eb565b6033546001600160a01b031633146104165760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610482565b606580546001600160a01b03191690556104948161114c565b6001600160a01b03841615801590610f4557506001600160a01b03831615155b8015610f5957506001600160a01b03821615155b8015610f6d57506001600160a01b03811615155b610fd05760405162461bcd60e51b815260206004820152602e60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204241445f60448201526d24a724aa24a0a624ad20aa24a7a760911b6064820152608401610482565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b600080808061103185870187611b0f565b6001600160a01b03808516600090815261010060205260409020549498509296509094509250168061106557611065611ae0565b6110796001600160a01b038616848461119e565b826001600160a01b0316816001600160a01b0316866001600160a01b03167fb9f935478aae5b1da868de596dafe0a2b41eeb61311fdd60c6dbbe46a1debee887866040516110c8929190611af6565b60405180910390a450505050505050565b6104166111bd565b6040516001600160a01b03808516602483015283166044820152606481018290526107eb9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b0319909316929092179091526113d3565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6107fc8363a9059cbb60e01b8484604051602401611115929190611af6565b60c95460ff16156112c857604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161121f9190611b60565b6000604051808303818686fa925050503d806000811461125b576040519150601f19603f3d011682016040523d82523d6000602084013e611260565b606091505b509150915081801561128557506000818060200190518101906112839190611b7c565b115b6112c55760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b6044820152606401610482565b50505b60c954610100900460ff161561041657604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161132f9190611b60565b6000604051808303818686fa925050503d806000811461136b576040519150601f19603f3d011682016040523d82523d6000602084013e611370565b606091505b50915091508180156113965750808060200190518101906113919190611b7c565b600114155b6104005760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b6044820152606401610482565b6000611428826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166114a89092919063ffffffff16565b90508051600014806114495750808060200190518101906114499190611b95565b6107fc5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610482565b60606114b784846000856114bf565b949350505050565b6060824710156115205760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610482565b600080866001600160a01b0316858760405161153c9190611b60565b60006040518083038185875af1925050503d8060008114611579576040519150601f19603f3d011682016040523d82523d6000602084013e61157e565b606091505b509150915061158f8783838761159a565b979650505050505050565b60608315611609578251600003611602576001600160a01b0385163b6116025760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610482565b50816114b7565b6114b7838381511561161e5781518083602001fd5b8060405162461bcd60e51b81526004016104829190611bb2565b6001600160a01b038116811461049457600080fd5b6000806040838503121561166057600080fd5b823561166b81611638565b946020939093013593505050565b60006020828403121561168b57600080fd5b813561169681611638565b9392505050565b801515811461049457600080fd5b6000602082840312156116bd57600080fd5b81356116968161169d565b600080600080600080600060e0888a0312156116e357600080fd5b87356116ee81611638565b965060208801356116fe81611638565b9550604088013561170e81611638565b9450606088013561171e81611638565b9350608088013561172e8161169d565b925060a088013561173e8161169d565b915060c088013561174e81611638565b8091505092959891949750929550565b6000806000806060858703121561177457600080fd5b84359350602085013561178681611638565b9250604085013567ffffffffffffffff808211156117a357600080fd5b818701915087601f8301126117b757600080fd5b8135818111156117c657600080fd5b8860208285010111156117d857600080fd5b95989497505060200194505050565b6000806000606084860312156117fc57600080fd5b833561180781611638565b9250602084013561181781611638565b929592945050506040919091013590565b6000806000806080858703121561183e57600080fd5b843561184981611638565b9350602085013561185981611638565b9250604085013561186981611638565b9150606085013561187981611638565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b6000808585111561190657600080fd5b8386111561191357600080fd5b5050820193919092039150565b8035602083101561193957600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b83811015611970578181015183820152602001611958565b50506000910152565b60006020828403121561198b57600080fd5b815167ffffffffffffffff808211156119a357600080fd5b818401915084601f8301126119b757600080fd5b8151818111156119c9576119c961193f565b604051601f8201601f19908116603f011681019083821181831017156119f1576119f161193f565b81604052828152876020848701011115611a0a57600080fd5b61158f836020830160208801611955565b600060208284031215611a2d57600080fd5b815160ff8116811461169657600080fd5b60008151808452611a56816020860160208601611955565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a060408201819052600090611a9490830186611a3e565b8281036060840152611aa68186611a3e565b91505060ff831660808301529695505050505050565b6001600160a01b03831681526040602082018190526000906114b790830184611a3e565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611b2557600080fd5b8435611b3081611638565b93506020850135611b4081611638565b92506040850135611b5081611638565b9396929550929360600135925050565b60008251611b72818460208701611955565b9190910192915050565b600060208284031215611b8e57600080fd5b5051919050565b600060208284031215611ba757600080fd5b81516116968161169d565b6020815260006116966020830184611a3e56fea2646970667358221220176d1307d83cd6036f83b91e4ae24d7832bdefc3a6d526f5cfd719424ef4671864736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061019a5760003560e01c8063b1768065116100e4578063e0563ab111610092578063e0563ab114610355578063e30c39781461035e578063eeb499451461036f578063f213159c14610382578063f2fde38b14610395578063f4a120f7146103a8578063f6451255146103bb578063f8c8765e146103e257600080fd5b8063b1768065146102a8578063b68ad1e4146102cf578063c1225a20146102e2578063c5e4683a146102f5578063d41f177114610308578063d57184e41461032f578063d8dd17731461034257600080fd5b806355b01e4d1161014c57806355b01e4d146102255780635ea5df7914610233578063715018a61461024a57806379ba5097146102525780637efab4f51461025a5780638da5cb5b14610284578063947287cf1461029557806397e5230d1461029e57600080fd5b806305dc2e8f1461019f57806307b3e252146101cf5780631bc114ba146101dd578063284017f5146101f05780633b878c22146101f957806347e7ef241461020257806351351d5314610217575b600080fd5b60fd546101b2906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101b26004600360981b0181565b60fc546101b2906001600160a01b031681565b6101b261202081565b6101b261101081565b61021561021036600461164d565b6103f5565b005b6101b26002600160a01b0381565b6101b26004600160991b0181565b61023c61138881565b6040519081526020016101c6565b610215610404565b610215610418565b6101b2610268366004611679565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101b2565b61023c61520881565b61023c620249f081565b61023c7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101b2906001600160a01b031681565b6102156102f03660046116ab565b610497565b6102156103033660046116ab565b6104e6565b61023c7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60fe546101b2906001600160a01b031681565b6102156103503660046116c8565b61052d565b6101b261203081565b6065546001600160a01b03166101b2565b61021561037d36600461175e565b61064e565b6102156103903660046117e7565b6107f1565b6102156103a3366004611679565b610801565b6101b26103b6366004611679565b610872565b61023c7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102156103f0366004611828565b610c40565b610400823383610d39565b5050565b61040c610eb2565b6104166000610f0c565b565b60655433906001600160a01b0316811461048b5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61049481610f0c565b50565b61049f610eb2565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6104ee610eb2565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105545760405163973d02cb60e01b815260040161048290611884565b600054610100900460ff16158080156105745750600054600160ff909116105b8061058e5750303b15801561058e575060005460ff166001145b6105aa5760405162461bcd60e51b8152600401610482906118a8565b6000805460ff1916600117905580156105cd576000805461ff0019166101001790555b6105d988888888610f25565b60c9805461ffff191685151561ff00191617610100851515021790556105fe82610f0c565b8015610644576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146106c05760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526e2fa9aa20aa22afa922a1a2a4ab22a960891b6064820152608401610482565b60fe546001600160a01b038481169116146107365760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526f5f4348494c445f50524544494341544560801b6064820152608401610482565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696107656020600084866118f6565b61076e91611920565b0361078d5761078861078382602081866118f6565b611020565b6107eb565b60405162461bcd60e51b815260206004820152602d60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e564160448201526c4c49445f5349474e415455524560981b6064820152608401610482565b50505050565b6107fc838383610d39565b505050565b610809610eb2565b606580546001600160a01b0383166001600160a01b0319909116811790915561083a6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b0382166108dc5760405162461bcd60e51b815260206004820152602960248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e56416044820152682624a22faa27a5a2a760b91b6064820152608401610482565b6001600160a01b038281166000908152610100602052604090205416156109585760405162461bcd60e51b815260206004820152602a60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20414c524560448201526910511657d3505414115160b21b6064820152608401610482565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692600092610a0692911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b038581166000818152610100602052604080822080546001600160a01b03191686861617905560fc5481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610a9f573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ac79190810190611979565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610b05573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610b2d9190810190611979565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b6b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8f9190611a1b565b604051602001610ba3959493929190611a6a565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610bcf929190611abc565b600060405180830381600087803b158015610be957600080fd5b505af1158015610bfd573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b0314610c675760405163973d02cb60e01b815260040161048290611884565b600054610100900460ff1615808015610c875750600054600160ff909116105b80610ca15750303b158015610ca1575060005460ff166001145b610cbd5760405162461bcd60e51b8152600401610482906118a8565b6000805460ff191660011790558015610ce0576000805461ff0019166101001790555b610cec85858585610f25565b8015610d32576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b610d416110d9565b6001600160a01b03808416600090815261010060205260409020541680610d6e57610d6b84610872565b90505b6001600160a01b038116610d8457610d84611ae0565b610d996001600160a01b0385163330856110e1565b60fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610e249391169160c401611abc565b600060405180830381600087803b158015610e3e57600080fd5b505af1158015610e52573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f1666a3f7b8a7494f2ebcebe646a5187ae55b1db3a068097377d90cd64a258ce93386604051610ea5929190611af6565b60405180910390a46107eb565b6033546001600160a01b031633146104165760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610482565b606580546001600160a01b03191690556104948161114c565b6001600160a01b03841615801590610f4557506001600160a01b03831615155b8015610f5957506001600160a01b03821615155b8015610f6d57506001600160a01b03811615155b610fd05760405162461bcd60e51b815260206004820152602e60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204241445f60448201526d24a724aa24a0a624ad20aa24a7a760911b6064820152608401610482565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b600080808061103185870187611b0f565b6001600160a01b03808516600090815261010060205260409020549498509296509094509250168061106557611065611ae0565b6110796001600160a01b038616848461119e565b826001600160a01b0316816001600160a01b0316866001600160a01b03167fb9f935478aae5b1da868de596dafe0a2b41eeb61311fdd60c6dbbe46a1debee887866040516110c8929190611af6565b60405180910390a450505050505050565b6104166111bd565b6040516001600160a01b03808516602483015283166044820152606481018290526107eb9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b0319909316929092179091526113d3565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6107fc8363a9059cbb60e01b8484604051602401611115929190611af6565b60c95460ff16156112c857604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161121f9190611b60565b6000604051808303818686fa925050503d806000811461125b576040519150601f19603f3d011682016040523d82523d6000602084013e611260565b606091505b509150915081801561128557506000818060200190518101906112839190611b7c565b115b6112c55760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b6044820152606401610482565b50505b60c954610100900460ff161561041657604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161132f9190611b60565b6000604051808303818686fa925050503d806000811461136b576040519150601f19603f3d011682016040523d82523d6000602084013e611370565b606091505b50915091508180156113965750808060200190518101906113919190611b7c565b600114155b6104005760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b6044820152606401610482565b6000611428826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166114a89092919063ffffffff16565b90508051600014806114495750808060200190518101906114499190611b95565b6107fc5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610482565b60606114b784846000856114bf565b949350505050565b6060824710156115205760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610482565b600080866001600160a01b0316858760405161153c9190611b60565b60006040518083038185875af1925050503d8060008114611579576040519150601f19603f3d011682016040523d82523d6000602084013e61157e565b606091505b509150915061158f8783838761159a565b979650505050505050565b60608315611609578251600003611602576001600160a01b0385163b6116025760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610482565b50816114b7565b6114b7838381511561161e5781518083602001fd5b8060405162461bcd60e51b81526004016104829190611bb2565b6001600160a01b038116811461049457600080fd5b6000806040838503121561166057600080fd5b823561166b81611638565b946020939093013593505050565b60006020828403121561168b57600080fd5b813561169681611638565b9392505050565b801515811461049457600080fd5b6000602082840312156116bd57600080fd5b81356116968161169d565b600080600080600080600060e0888a0312156116e357600080fd5b87356116ee81611638565b965060208801356116fe81611638565b9550604088013561170e81611638565b9450606088013561171e81611638565b9350608088013561172e8161169d565b925060a088013561173e8161169d565b915060c088013561174e81611638565b8091505092959891949750929550565b6000806000806060858703121561177457600080fd5b84359350602085013561178681611638565b9250604085013567ffffffffffffffff808211156117a357600080fd5b818701915087601f8301126117b757600080fd5b8135818111156117c657600080fd5b8860208285010111156117d857600080fd5b95989497505060200194505050565b6000806000606084860312156117fc57600080fd5b833561180781611638565b9250602084013561181781611638565b929592945050506040919091013590565b6000806000806080858703121561183e57600080fd5b843561184981611638565b9350602085013561185981611638565b9250604085013561186981611638565b9150606085013561187981611638565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b6000808585111561190657600080fd5b8386111561191357600080fd5b5050820193919092039150565b8035602083101561193957600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b83811015611970578181015183820152602001611958565b50506000910152565b60006020828403121561198b57600080fd5b815167ffffffffffffffff808211156119a357600080fd5b818401915084601f8301126119b757600080fd5b8151818111156119c9576119c961193f565b604051601f8201601f19908116603f011681019083821181831017156119f1576119f161193f565b81604052828152876020848701011115611a0a57600080fd5b61158f836020830160208801611955565b600060208284031215611a2d57600080fd5b815160ff8116811461169657600080fd5b60008151808452611a56816020860160208601611955565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a060408201819052600090611a9490830186611a3e565b8281036060840152611aa68186611a3e565b91505060ff831660808301529695505050505050565b6001600160a01b03831681526040602082018190526000906114b790830184611a3e565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611b2557600080fd5b8435611b3081611638565b93506020850135611b4081611638565b92506040850135611b5081611638565b9396929550929360600135925050565b60008251611b72818460208701611955565b9190910192915050565b600060208284031215611b8e57600080fd5b5051919050565b600060208284031215611ba757600080fd5b81516116968161169d565b6020815260006116966020830184611a3e56fea2646970667358221220176d1307d83cd6036f83b91e4ae24d7832bdefc3a6d526f5cfd719424ef4671864736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildERC721Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC721","sourceName":"contracts/child/ChildERC721.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"userAddress","type":"address"},{"indexed":false,"internalType":"address","name":"relayerAddress","type":"address"},{"indexed":false,"internalType":"bytes","name":"functionSignature","type":"bytes"}],"name":"MetaTransactionExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"burnBatch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"userAddress","type":"address"},{"internalType":"bytes","name":"functionSignature","type":"bytes"},{"internalType":"bytes32","name":"sigR","type":"bytes32"},{"internalType":"bytes32","name":"sigS","type":"bytes32"},{"internalType":"uint8","name":"sigV","type":"uint8"}],"name":"executeMetaTransaction","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getNonce","outputs":[{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"rootToken_","type":"address"},{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"offset","type":"uint256"}],"name":"invalidateNext","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"mintBatch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rootToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612488806100206000396000f3fe608060405234801561001057600080fd5b506004361061014d5760003560e01c806370a08231116100c3578063a22cb4651161007c578063a22cb465146102de578063b2dc5dc3146102f1578063b88d4fde14610304578063c87b56dd14610317578063e61987051461032a578063e985e9c51461033c57600080fd5b806370a08231146102775780637c88e3d91461028a578063906571471461029d57806395d89b41146102b05780639b77ef11146102b85780639dc29fac146102cb57600080fd5b80631f2d0065116101155780631f2d0065146101e257806323b872dd146101f45780632d0335ab1461020757806340c10f191461023e57806342842e0e146102515780636352211e1461026457600080fd5b806301ffc9a71461015257806306fdde031461017a578063081812fc1461018f578063095ea7b3146101ba5780630c53c51c146101cf575b600080fd5b610165610160366004611a73565b61034f565b60405190151581526020015b60405180910390f35b6101826103a1565b6040516101719190611ae0565b6101a261019d366004611af3565b610433565b6040516001600160a01b039091168152602001610171565b6101cd6101c8366004611b28565b61045a565b005b6101826101dd366004611b9a565b610586565b610103546001600160a01b03166101a2565b6101cd610202366004611c19565b610864565b610230610215366004611c55565b6001600160a01b031660009081526038602052604090205490565b604051908152602001610171565b61016561024c366004611b28565b61089c565b6101cd61025f366004611c19565b6108dd565b6101a2610272366004611af3565b6108f8565b610230610285366004611c55565b61092d565b610165610298366004611cb4565b6109b3565b6101cd6102ab366004611d1f565b610a9b565b610182610d0b565b6101cd6102c6366004611af3565b610d1a565b6101656102d9366004611b28565b610d41565b6101cd6102ec366004611d9f565b610db1565b6101656102ff366004611ddb565b610dc7565b6101cd610312366004611e43565b610e75565b610182610325366004611af3565b610eb4565b610102546001600160a01b03166101a2565b61016561034a366004611f1e565b610f28565b60006001600160e01b031982166380ac58cd60e01b148061038057506001600160e01b03198216635b5e139f60e01b145b8061039b57506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060d080546103b090611f51565b80601f01602080910402602001604051908101604052809291908181526020018280546103dc90611f51565b80156104295780601f106103fe57610100808354040283529160200191610429565b820191906000526020600020905b81548152906001019060200180831161040c57829003601f168201915b5050505050905090565b600061043e82610f56565b50600090815260d460205260409020546001600160a01b031690565b6000610465826108f8565b9050806001600160a01b0316836001600160a01b0316036104d75760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b806001600160a01b03166104e9610f7e565b6001600160a01b0316148061050557506105058161034a610f7e565b6105775760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c00000060648201526084016104ce565b6105818383610f8d565b505050565b606060006105c987878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610ffb92505050565b90506001600160e01b031960003581169082160361064f5760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f6400000060648201526084016104ce565b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506106c08982888888611016565b6107165760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b60648201526084016104ce565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d60405160200161076b93929190611f8b565b60408051601f198184030181529082905261078591611fb1565b6000604051808303816000865af19150503d80600081146107c2576040519150601f19603f3d011682016040523d82523d6000602084013e6107c7565b606091505b5091509150816108195760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c0000000060448201526064016104ce565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c60405161084e9493929190611fcd565b60405180910390a19a9950505050505050505050565b61087561086f610f7e565b826110f2565b6108915760405162461bcd60e51b81526004016104ce90612019565b610581838383611150565b610102546000906001600160a01b031633146108ca5760405162461bcd60e51b81526004016104ce90612066565b6108d483836112a2565b50600192915050565b61058183838360405180602001604052806000815250610e75565b600081815260d260205260408120546001600160a01b03168061039b5760405162461bcd60e51b81526004016104ce906120aa565b60006001600160a01b0382166109975760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016104ce565b506001600160a01b0316600090815260d3602052604090205490565b610102546000906001600160a01b031633146109e15760405162461bcd60e51b81526004016104ce90612066565b83828114610a315760405162461bcd60e51b815260206004820152601f60248201527f4368696c644552433732313a204172726179206c656e206d69736d617463680060448201526064016104ce565b60005b81811015610a8c57610a84878783818110610a5157610a516120dc565b9050602002016020810190610a669190611c55565b868684818110610a7857610a786120dc565b905060200201356112a2565b600101610a34565b5060019150505b949350505050565b606b54610100900460ff1615808015610abb5750606b54600160ff909116105b80610ad55750303b158015610ad55750606b5460ff166001145b610b385760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104ce565b606b805460ff191660011790558015610b5b57606b805461ff0019166101001790555b6001600160a01b03861615801590610b7257508315155b8015610b7d57508115155b610bc95760405162461bcd60e51b815260206004820152601f60248201527f4368696c644552433732313a2042616420696e697469616c697a6174696f6e0060448201526064016104ce565b61010380546001600160a01b0388166001600160a01b031991821617909155610102805490911633179055604080516020601f8701819004810282018101909252858152610c6591879087908190840183828082843760009201919091525050604080516020601f890181900481028201810190925287815292508791508690819084018382808284376000920191909152506112bc92505050565b610cbd85858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805180820190915260018152603160f81b602082015291506112ed9050565b8015610d0357606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b606060d180546103b090611f51565b3360009081526038602052604081208054839290610d399084906120f2565b909155505050565b610102546000906001600160a01b03163314610d6f5760405162461bcd60e51b81526004016104ce90612066565b610d78826108f8565b6001600160a01b0316836001600160a01b031614610da85760405162461bcd60e51b81526004016104ce90612113565b6108d482611359565b610dc3610dbc610f7e565b83836113dc565b5050565b610102546000906001600160a01b03163314610df55760405162461bcd60e51b81526004016104ce90612066565b8160005b81811015610e69576000858583818110610e1557610e156120dc565b905060200201359050610e27816108f8565b6001600160a01b0316876001600160a01b031614610e575760405162461bcd60e51b81526004016104ce90612113565b610e6081611359565b50600101610df9565b50600195945050505050565b610e86610e80610f7e565b836110f2565b610ea25760405162461bcd60e51b81526004016104ce90612019565b610eae848484846114a6565b50505050565b6060610ebf82610f56565b6000610ed660408051602081019091526000815290565b90506000815111610ef65760405180602001604052806000815250610f21565b80610f00846114d9565b604051602001610f11929190612148565b6040516020818303038152906040525b9392505050565b6001600160a01b03918216600090815260d56020908152604080832093909416825291909152205460ff1690565b610f5f8161156b565b610f7b5760405162461bcd60e51b81526004016104ce906120aa565b50565b6000610f88611588565b905090565b600081815260d46020526040902080546001600160a01b0319166001600160a01b0384169081179091558190610fc2826108f8565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000815160000361100e57506000919050565b506020015190565b600080600161102c611027886115e4565b611661565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa15801561107a573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166110d15760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b60448201526064016104ce565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6000806110fe836108f8565b9050806001600160a01b0316846001600160a01b0316148061112557506111258185610f28565b80610a935750836001600160a01b031661113e84610433565b6001600160a01b031614949350505050565b826001600160a01b0316611163826108f8565b6001600160a01b0316146111895760405162461bcd60e51b81526004016104ce90612177565b6001600160a01b0382166111eb5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016104ce565b826001600160a01b03166111fe826108f8565b6001600160a01b0316146112245760405162461bcd60e51b81526004016104ce90612177565b600081815260d46020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260d3855283862080546000190190559087168086528386208054600101905586865260d2909452828520805490921684179091559051849360008051602061243383398151915291a4505050565b610dc382826040518060200160405280600081525061168e565b606b54610100900460ff166112e35760405162461bcd60e51b81526004016104ce906121bc565b610dc382826116c1565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f61133b818484611701565b600055600280546001600160a01b0319163017905560055550505050565b6000611364826108f8565b905061136f826108f8565b600083815260d46020908152604080832080546001600160a01b03199081169091556001600160a01b03851680855260d38452828520805460001901905587855260d290935281842080549091169055519293508492600080516020612433833981519152908390a45050565b816001600160a01b0316836001600160a01b0316036114395760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b60448201526064016104ce565b6001600160a01b03838116600081815260d56020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6114b1848484611150565b6114bd8484848461174a565b610eae5760405162461bcd60e51b81526004016104ce90612207565b606060006114e68361184f565b60010190506000816001600160401b0381111561150557611505611e2d565b6040519080825280601f01601f19166020018201604052801561152f576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a850494508461153957509392505050565b600090815260d260205260409020546001600160a01b0316151590565b60003033036115de57600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506115e19050565b50335b90565b60006040518060800160405280604381526020016123f06043913980516020918201208351848301516040808701518051908601209051611644950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039b61166e611927565b8360405161190160f01b8152600281019290925260228201526042902090565b6116988383611962565b6116a5600084848461174a565b6105815760405162461bcd60e51b81526004016104ce90612207565b606b54610100900460ff166116e85760405162461bcd60e51b81526004016104ce906121bc565b60d06116f4838261229f565b5060d1610581828261229f565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b60006001600160a01b0384163b1561184757836001600160a01b031663150b7a02611773610f7e565b8786866040518563ffffffff1660e01b8152600401611795949392919061235e565b6020604051808303816000875af19250505080156117d0575060408051601f3d908101601f191682019092526117cd9181019061239b565b60015b61182d573d8080156117fe576040519150601f19603f3d011682016040523d82523d6000602084013e611803565b606091505b5080516000036118255760405162461bcd60e51b81526004016104ce90612207565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610a93565b506001610a93565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b831061188e5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef810000000083106118ba576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106118d857662386f26fc10000830492506010015b6305f5e10083106118f0576305f5e100830492506008015b612710831061190457612710830492506004015b60648310611916576064830492506002015b600a831061039b5760010192915050565b6002546000906001600160a01b031630148015611945575060015446145b15611951575060005490565b610f88600554600354600454611701565b6001600160a01b0382166119b85760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016104ce565b6119c18161156b565b156119de5760405162461bcd60e51b81526004016104ce906123b8565b6119e78161156b565b15611a045760405162461bcd60e51b81526004016104ce906123b8565b6001600160a01b038216600081815260d3602090815260408083208054600101905584835260d290915280822080546001600160a01b031916841790555183929190600080516020612433833981519152908290a45050565b6001600160e01b031981168114610f7b57600080fd5b600060208284031215611a8557600080fd5b8135610f2181611a5d565b60005b83811015611aab578181015183820152602001611a93565b50506000910152565b60008151808452611acc816020860160208601611a90565b601f01601f19169290920160200192915050565b602081526000610f216020830184611ab4565b600060208284031215611b0557600080fd5b5035919050565b80356001600160a01b0381168114611b2357600080fd5b919050565b60008060408385031215611b3b57600080fd5b611b4483611b0c565b946020939093013593505050565b60008083601f840112611b6457600080fd5b5081356001600160401b03811115611b7b57600080fd5b602083019150836020828501011115611b9357600080fd5b9250929050565b60008060008060008060a08789031215611bb357600080fd5b611bbc87611b0c565b955060208701356001600160401b03811115611bd757600080fd5b611be389828a01611b52565b9096509450506040870135925060608701359150608087013560ff81168114611c0b57600080fd5b809150509295509295509295565b600080600060608486031215611c2e57600080fd5b611c3784611b0c565b9250611c4560208501611b0c565b9150604084013590509250925092565b600060208284031215611c6757600080fd5b610f2182611b0c565b60008083601f840112611c8257600080fd5b5081356001600160401b03811115611c9957600080fd5b6020830191508360208260051b8501011115611b9357600080fd5b60008060008060408587031215611cca57600080fd5b84356001600160401b0380821115611ce157600080fd5b611ced88838901611c70565b90965094506020870135915080821115611d0657600080fd5b50611d1387828801611c70565b95989497509550505050565b600080600080600060608688031215611d3757600080fd5b611d4086611b0c565b945060208601356001600160401b0380821115611d5c57600080fd5b611d6889838a01611b52565b90965094506040880135915080821115611d8157600080fd5b50611d8e88828901611b52565b969995985093965092949392505050565b60008060408385031215611db257600080fd5b611dbb83611b0c565b915060208301358015158114611dd057600080fd5b809150509250929050565b600080600060408486031215611df057600080fd5b611df984611b0c565b925060208401356001600160401b03811115611e1457600080fd5b611e2086828701611c70565b9497909650939450505050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215611e5957600080fd5b611e6285611b0c565b9350611e7060208601611b0c565b92506040850135915060608501356001600160401b0380821115611e9357600080fd5b818701915087601f830112611ea757600080fd5b813581811115611eb957611eb9611e2d565b604051601f8201601f19908116603f01168101908382118183101715611ee157611ee1611e2d565b816040528281528a6020848701011115611efa57600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215611f3157600080fd5b611f3a83611b0c565b9150611f4860208401611b0c565b90509250929050565b600181811c90821680611f6557607f821691505b602082108103611f8557634e487b7160e01b600052602260045260246000fd5b50919050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60008251611fc3818460208701611a90565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b60208082526024908201527f4368696c644552433732313a204f6e6c79207072656469636174652063616e2060408201526318d85b1b60e21b606082015260800190565b602080825260189082015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b8082018082111561039b57634e487b7160e01b600052601160045260246000fd5b6020808252818101527f4368696c644552433732313a204f6e6c79206f776e65722063616e206275726e604082015260600190565b6000835161215a818460208801611a90565b83519083019061216e818360208801611a90565b01949350505050565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b601f82111561058157600081815260208120601f850160051c810160208610156122805750805b601f850160051c820191505b81811015610d035782815560010161228c565b81516001600160401b038111156122b8576122b8611e2d565b6122cc816122c68454611f51565b84612259565b602080601f83116001811461230157600084156122e95750858301515b600019600386901b1c1916600185901b178555610d03565b600085815260208120601f198616915b8281101561233057888601518255948401946001909101908401612311565b508582101561234e5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061239190830184611ab4565b9695505050505050565b6000602082840312156123ad57600080fd5b8151610f2181611a5d565b6020808252601c908201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060408201526060019056fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220bd40f4c587cb7d8ae1bc3b96cf69daefceacb0a939f4075b779cabc6e8e56d3964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061014d5760003560e01c806370a08231116100c3578063a22cb4651161007c578063a22cb465146102de578063b2dc5dc3146102f1578063b88d4fde14610304578063c87b56dd14610317578063e61987051461032a578063e985e9c51461033c57600080fd5b806370a08231146102775780637c88e3d91461028a578063906571471461029d57806395d89b41146102b05780639b77ef11146102b85780639dc29fac146102cb57600080fd5b80631f2d0065116101155780631f2d0065146101e257806323b872dd146101f45780632d0335ab1461020757806340c10f191461023e57806342842e0e146102515780636352211e1461026457600080fd5b806301ffc9a71461015257806306fdde031461017a578063081812fc1461018f578063095ea7b3146101ba5780630c53c51c146101cf575b600080fd5b610165610160366004611a73565b61034f565b60405190151581526020015b60405180910390f35b6101826103a1565b6040516101719190611ae0565b6101a261019d366004611af3565b610433565b6040516001600160a01b039091168152602001610171565b6101cd6101c8366004611b28565b61045a565b005b6101826101dd366004611b9a565b610586565b610103546001600160a01b03166101a2565b6101cd610202366004611c19565b610864565b610230610215366004611c55565b6001600160a01b031660009081526038602052604090205490565b604051908152602001610171565b61016561024c366004611b28565b61089c565b6101cd61025f366004611c19565b6108dd565b6101a2610272366004611af3565b6108f8565b610230610285366004611c55565b61092d565b610165610298366004611cb4565b6109b3565b6101cd6102ab366004611d1f565b610a9b565b610182610d0b565b6101cd6102c6366004611af3565b610d1a565b6101656102d9366004611b28565b610d41565b6101cd6102ec366004611d9f565b610db1565b6101656102ff366004611ddb565b610dc7565b6101cd610312366004611e43565b610e75565b610182610325366004611af3565b610eb4565b610102546001600160a01b03166101a2565b61016561034a366004611f1e565b610f28565b60006001600160e01b031982166380ac58cd60e01b148061038057506001600160e01b03198216635b5e139f60e01b145b8061039b57506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060d080546103b090611f51565b80601f01602080910402602001604051908101604052809291908181526020018280546103dc90611f51565b80156104295780601f106103fe57610100808354040283529160200191610429565b820191906000526020600020905b81548152906001019060200180831161040c57829003601f168201915b5050505050905090565b600061043e82610f56565b50600090815260d460205260409020546001600160a01b031690565b6000610465826108f8565b9050806001600160a01b0316836001600160a01b0316036104d75760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b806001600160a01b03166104e9610f7e565b6001600160a01b0316148061050557506105058161034a610f7e565b6105775760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c00000060648201526084016104ce565b6105818383610f8d565b505050565b606060006105c987878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610ffb92505050565b90506001600160e01b031960003581169082160361064f5760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f6400000060648201526084016104ce565b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506106c08982888888611016565b6107165760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b60648201526084016104ce565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d60405160200161076b93929190611f8b565b60408051601f198184030181529082905261078591611fb1565b6000604051808303816000865af19150503d80600081146107c2576040519150601f19603f3d011682016040523d82523d6000602084013e6107c7565b606091505b5091509150816108195760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c0000000060448201526064016104ce565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c60405161084e9493929190611fcd565b60405180910390a19a9950505050505050505050565b61087561086f610f7e565b826110f2565b6108915760405162461bcd60e51b81526004016104ce90612019565b610581838383611150565b610102546000906001600160a01b031633146108ca5760405162461bcd60e51b81526004016104ce90612066565b6108d483836112a2565b50600192915050565b61058183838360405180602001604052806000815250610e75565b600081815260d260205260408120546001600160a01b03168061039b5760405162461bcd60e51b81526004016104ce906120aa565b60006001600160a01b0382166109975760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016104ce565b506001600160a01b0316600090815260d3602052604090205490565b610102546000906001600160a01b031633146109e15760405162461bcd60e51b81526004016104ce90612066565b83828114610a315760405162461bcd60e51b815260206004820152601f60248201527f4368696c644552433732313a204172726179206c656e206d69736d617463680060448201526064016104ce565b60005b81811015610a8c57610a84878783818110610a5157610a516120dc565b9050602002016020810190610a669190611c55565b868684818110610a7857610a786120dc565b905060200201356112a2565b600101610a34565b5060019150505b949350505050565b606b54610100900460ff1615808015610abb5750606b54600160ff909116105b80610ad55750303b158015610ad55750606b5460ff166001145b610b385760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104ce565b606b805460ff191660011790558015610b5b57606b805461ff0019166101001790555b6001600160a01b03861615801590610b7257508315155b8015610b7d57508115155b610bc95760405162461bcd60e51b815260206004820152601f60248201527f4368696c644552433732313a2042616420696e697469616c697a6174696f6e0060448201526064016104ce565b61010380546001600160a01b0388166001600160a01b031991821617909155610102805490911633179055604080516020601f8701819004810282018101909252858152610c6591879087908190840183828082843760009201919091525050604080516020601f890181900481028201810190925287815292508791508690819084018382808284376000920191909152506112bc92505050565b610cbd85858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805180820190915260018152603160f81b602082015291506112ed9050565b8015610d0357606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b606060d180546103b090611f51565b3360009081526038602052604081208054839290610d399084906120f2565b909155505050565b610102546000906001600160a01b03163314610d6f5760405162461bcd60e51b81526004016104ce90612066565b610d78826108f8565b6001600160a01b0316836001600160a01b031614610da85760405162461bcd60e51b81526004016104ce90612113565b6108d482611359565b610dc3610dbc610f7e565b83836113dc565b5050565b610102546000906001600160a01b03163314610df55760405162461bcd60e51b81526004016104ce90612066565b8160005b81811015610e69576000858583818110610e1557610e156120dc565b905060200201359050610e27816108f8565b6001600160a01b0316876001600160a01b031614610e575760405162461bcd60e51b81526004016104ce90612113565b610e6081611359565b50600101610df9565b50600195945050505050565b610e86610e80610f7e565b836110f2565b610ea25760405162461bcd60e51b81526004016104ce90612019565b610eae848484846114a6565b50505050565b6060610ebf82610f56565b6000610ed660408051602081019091526000815290565b90506000815111610ef65760405180602001604052806000815250610f21565b80610f00846114d9565b604051602001610f11929190612148565b6040516020818303038152906040525b9392505050565b6001600160a01b03918216600090815260d56020908152604080832093909416825291909152205460ff1690565b610f5f8161156b565b610f7b5760405162461bcd60e51b81526004016104ce906120aa565b50565b6000610f88611588565b905090565b600081815260d46020526040902080546001600160a01b0319166001600160a01b0384169081179091558190610fc2826108f8565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000815160000361100e57506000919050565b506020015190565b600080600161102c611027886115e4565b611661565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa15801561107a573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166110d15760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b60448201526064016104ce565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6000806110fe836108f8565b9050806001600160a01b0316846001600160a01b0316148061112557506111258185610f28565b80610a935750836001600160a01b031661113e84610433565b6001600160a01b031614949350505050565b826001600160a01b0316611163826108f8565b6001600160a01b0316146111895760405162461bcd60e51b81526004016104ce90612177565b6001600160a01b0382166111eb5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016104ce565b826001600160a01b03166111fe826108f8565b6001600160a01b0316146112245760405162461bcd60e51b81526004016104ce90612177565b600081815260d46020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260d3855283862080546000190190559087168086528386208054600101905586865260d2909452828520805490921684179091559051849360008051602061243383398151915291a4505050565b610dc382826040518060200160405280600081525061168e565b606b54610100900460ff166112e35760405162461bcd60e51b81526004016104ce906121bc565b610dc382826116c1565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f61133b818484611701565b600055600280546001600160a01b0319163017905560055550505050565b6000611364826108f8565b905061136f826108f8565b600083815260d46020908152604080832080546001600160a01b03199081169091556001600160a01b03851680855260d38452828520805460001901905587855260d290935281842080549091169055519293508492600080516020612433833981519152908390a45050565b816001600160a01b0316836001600160a01b0316036114395760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b60448201526064016104ce565b6001600160a01b03838116600081815260d56020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6114b1848484611150565b6114bd8484848461174a565b610eae5760405162461bcd60e51b81526004016104ce90612207565b606060006114e68361184f565b60010190506000816001600160401b0381111561150557611505611e2d565b6040519080825280601f01601f19166020018201604052801561152f576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a850494508461153957509392505050565b600090815260d260205260409020546001600160a01b0316151590565b60003033036115de57600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506115e19050565b50335b90565b60006040518060800160405280604381526020016123f06043913980516020918201208351848301516040808701518051908601209051611644950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039b61166e611927565b8360405161190160f01b8152600281019290925260228201526042902090565b6116988383611962565b6116a5600084848461174a565b6105815760405162461bcd60e51b81526004016104ce90612207565b606b54610100900460ff166116e85760405162461bcd60e51b81526004016104ce906121bc565b60d06116f4838261229f565b5060d1610581828261229f565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b60006001600160a01b0384163b1561184757836001600160a01b031663150b7a02611773610f7e565b8786866040518563ffffffff1660e01b8152600401611795949392919061235e565b6020604051808303816000875af19250505080156117d0575060408051601f3d908101601f191682019092526117cd9181019061239b565b60015b61182d573d8080156117fe576040519150601f19603f3d011682016040523d82523d6000602084013e611803565b606091505b5080516000036118255760405162461bcd60e51b81526004016104ce90612207565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610a93565b506001610a93565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b831061188e5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef810000000083106118ba576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106118d857662386f26fc10000830492506010015b6305f5e10083106118f0576305f5e100830492506008015b612710831061190457612710830492506004015b60648310611916576064830492506002015b600a831061039b5760010192915050565b6002546000906001600160a01b031630148015611945575060015446145b15611951575060005490565b610f88600554600354600454611701565b6001600160a01b0382166119b85760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016104ce565b6119c18161156b565b156119de5760405162461bcd60e51b81526004016104ce906123b8565b6119e78161156b565b15611a045760405162461bcd60e51b81526004016104ce906123b8565b6001600160a01b038216600081815260d3602090815260408083208054600101905584835260d290915280822080546001600160a01b031916841790555183929190600080516020612433833981519152908290a45050565b6001600160e01b031981168114610f7b57600080fd5b600060208284031215611a8557600080fd5b8135610f2181611a5d565b60005b83811015611aab578181015183820152602001611a93565b50506000910152565b60008151808452611acc816020860160208601611a90565b601f01601f19169290920160200192915050565b602081526000610f216020830184611ab4565b600060208284031215611b0557600080fd5b5035919050565b80356001600160a01b0381168114611b2357600080fd5b919050565b60008060408385031215611b3b57600080fd5b611b4483611b0c565b946020939093013593505050565b60008083601f840112611b6457600080fd5b5081356001600160401b03811115611b7b57600080fd5b602083019150836020828501011115611b9357600080fd5b9250929050565b60008060008060008060a08789031215611bb357600080fd5b611bbc87611b0c565b955060208701356001600160401b03811115611bd757600080fd5b611be389828a01611b52565b9096509450506040870135925060608701359150608087013560ff81168114611c0b57600080fd5b809150509295509295509295565b600080600060608486031215611c2e57600080fd5b611c3784611b0c565b9250611c4560208501611b0c565b9150604084013590509250925092565b600060208284031215611c6757600080fd5b610f2182611b0c565b60008083601f840112611c8257600080fd5b5081356001600160401b03811115611c9957600080fd5b6020830191508360208260051b8501011115611b9357600080fd5b60008060008060408587031215611cca57600080fd5b84356001600160401b0380821115611ce157600080fd5b611ced88838901611c70565b90965094506020870135915080821115611d0657600080fd5b50611d1387828801611c70565b95989497509550505050565b600080600080600060608688031215611d3757600080fd5b611d4086611b0c565b945060208601356001600160401b0380821115611d5c57600080fd5b611d6889838a01611b52565b90965094506040880135915080821115611d8157600080fd5b50611d8e88828901611b52565b969995985093965092949392505050565b60008060408385031215611db257600080fd5b611dbb83611b0c565b915060208301358015158114611dd057600080fd5b809150509250929050565b600080600060408486031215611df057600080fd5b611df984611b0c565b925060208401356001600160401b03811115611e1457600080fd5b611e2086828701611c70565b9497909650939450505050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215611e5957600080fd5b611e6285611b0c565b9350611e7060208601611b0c565b92506040850135915060608501356001600160401b0380821115611e9357600080fd5b818701915087601f830112611ea757600080fd5b813581811115611eb957611eb9611e2d565b604051601f8201601f19908116603f01168101908382118183101715611ee157611ee1611e2d565b816040528281528a6020848701011115611efa57600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215611f3157600080fd5b611f3a83611b0c565b9150611f4860208401611b0c565b90509250929050565b600181811c90821680611f6557607f821691505b602082108103611f8557634e487b7160e01b600052602260045260246000fd5b50919050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60008251611fc3818460208701611a90565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b60208082526024908201527f4368696c644552433732313a204f6e6c79207072656469636174652063616e2060408201526318d85b1b60e21b606082015260800190565b602080825260189082015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b8082018082111561039b57634e487b7160e01b600052601160045260246000fd5b6020808252818101527f4368696c644552433732313a204f6e6c79206f776e65722063616e206275726e604082015260600190565b6000835161215a818460208801611a90565b83519083019061216e818360208801611a90565b01949350505050565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b601f82111561058157600081815260208120601f850160051c810160208610156122805750805b601f850160051c820191505b81811015610d035782815560010161228c565b81516001600160401b038111156122b8576122b8611e2d565b6122cc816122c68454611f51565b84612259565b602080601f83116001811461230157600084156122e95750858301515b600019600386901b1c1916600185901b178555610d03565b600085815260208120601f198616915b8281101561233057888601518255948401946001909101908401612311565b508582101561234e5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061239190830184611ab4565b9695505050505050565b6000602082840312156123ad57600080fd5b8151610f2181611a5d565b6020808252601c908201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060408201526060019056fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220bd40f4c587cb7d8ae1bc3b96cf69daefceacb0a939f4075b779cabc6e8e56d3964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildERC721PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC721Predicate","sourceName":"contracts/child/ChildERC721Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2ERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2ERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2ERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2ERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611fc4806100206000396000f3fe608060405234801561001057600080fd5b50600436106101585760003560e01c8063b1768065116100c3578063e0563ab11161007c578063e0563ab114610306578063eeb499451461030f578063f3fef3a314610322578063f645125514610335578063f691325c1461035c578063f8c8765e1461036f57600080fd5b8063b176806514610244578063b68ad1e41461026b578063c3b35a7e1461027e578063c5ac2b1c14610291578063d41f1771146102b8578063d7c9e3ec146102df57600080fd5b806355b01e4d1161011557806355b01e4d146101ce5780635ea5df79146101dc5780636f33e695146101f35780637efab4f514610208578063947287cf1461023157806397e5230d1461023a57600080fd5b806305dc2e8f1461015d57806307b3e2521461018d5780631bc114ba1461019b578063284017f5146101ae5780633b878c22146101b757806351351d53146101c0575b600080fd5b603454610170906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101706004600360981b0181565b603354610170906001600160a01b031681565b61017061202081565b61017061101081565b6101706002600160a01b0381565b6101706004600160991b0181565b6101e561138881565b604051908152602001610184565b61020661020136600461166f565b610382565b005b6101706102163660046116f1565b6037602052600090815260409020546001600160a01b031681565b6101e561520881565b6101e5620249f081565b6101e57f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b603654610170906001600160a01b031681565b61020661028c366004611715565b610396565b6101e57faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6101e57f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101e57f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61017061203081565b61020661031d366004611756565b6103a6565b6102066103303660046117de565b6105c9565b6101e57f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b603554610170906001600160a01b031681565b61020661037d36600461180a565b6105d8565b61038f8585858585610734565b5050505050565b6103a1838383610a98565b505050565b6034546001600160a01b031633146104175760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f53544154456044820152682fa922a1a2a4ab22a960b91b60648201526084015b60405180910390fd5b6035546001600160a01b038481169116146104865760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f524f4f545f60448201526850524544494341544560b81b606482015260840161040e565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216104b5602060008486611866565b6104be91611890565b036104dd576104d86104d38260208186611866565b610da1565b6105c3565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1861050c602060008486611866565b61051591611890565b03610524576104d88282611017565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad610553602060008486611866565b61055c91611890565b0361056b576104d8828261127d565b60405162461bcd60e51b815260206004820152602760248201527f4368696c644552433732315072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b606482015260840161040e565b50505050565b6105d4823383610a98565b5050565b336002600160a01b031461061c5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b604482015260640161040e565b600054610100900460ff161580801561063c5750600054600160ff909116105b806106565750303b158015610656575060005460ff166001145b6106b95760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161040e565b6000805460ff1916600117905580156106dc576000805461ff0019166101001790555b6106e8858585856113eb565b801561038f576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b8461073e816114e0565b61075a5760405162461bcd60e51b815260040161040e906118ae565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561079a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107be91906118f0565b6001600160a01b038181166000908152603760205260409020549192508881169116146107fd5760405162461bcd60e51b815260040161040e9061190d565b6001600160a01b03811661081357610813611951565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561085b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061087f91906118f0565b6001600160a01b03161461089557610895611951565b8483146108f05760405162461bcd60e51b8152602060048201526024808201527f4368696c644552433732315072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b606482015260840161040e565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc39061092090339088908890600401611999565b6020604051808303816000875af115801561093f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061096391906119c7565b61097f5760405162461bcd60e51b815260040161040e906119e9565b6033546035546040516001600160a01b03928316926316f198319216906109d6907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d90602001611a73565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610a02929190611b0d565b600060405180830381600087803b158015610a1c57600080fd5b505af1158015610a30573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167fa80bc76d6e1849a9088a9c00a2aeaa54eeb78f15565a18da3e8873438976f52289898989604051610a879493929190611b39565b60405180910390a450505050505050565b82610aa2816114e0565b610abe5760405162461bcd60e51b815260040161040e906118ae565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610afe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b2291906118f0565b6001600160a01b03818116600090815260376020526040902054919250868116911614610b615760405162461bcd60e51b815260040161040e9061190d565b6001600160a01b038116610b7757610b77611951565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610bbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610be391906118f0565b6001600160a01b031614610bf957610bf9611951565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610c279033908790600401611b6b565b6020604051808303816000875af1158015610c46573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c6a91906119c7565b610c865760405162461bcd60e51b815260040161040e906119e9565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610d119391169160c401611b0d565b600060405180830381600087803b158015610d2b57600080fd5b505af1158015610d3f573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f1e0ef6131232b1090efc3ec1cf7b53aa17f4b7cd8a4f9e033b49ee237379b0133387604051610d92929190611b6b565b60405180910390a45050505050565b6000808080610db285870187611b84565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610df55760405162461bcd60e51b815260040161040e9061190d565b610dfe816114e0565b610e0a57610e0a611951565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e4a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e6e91906118f0565b9050856001600160a01b0316816001600160a01b031614610e9157610e91611951565b6001600160a01b038116610ea757610ea7611951565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610eef573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1391906118f0565b6001600160a01b031614610f2957610f29611951565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610f579087908790600401611b6b565b6020604051808303816000875af1158015610f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f9a91906119c7565b610fb65760405162461bcd60e51b815260040161040e90611bd5565b836001600160a01b0316826001600160a01b0316876001600160a01b03167f37589fd8c906c19ea68eeb7e6b3e03efc06ff8aa4b1830588eba75f4375b16118887604051611005929190611b6b565b60405180910390a45050505050505050565b600080808061102885870187611cea565b6001600160a01b0380851660009081526037602052604090205494995092975090955093501690508061106d5760405162461bcd60e51b815260040161040e9061190d565b611076816114e0565b61108257611082611951565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110c2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110e691906118f0565b9050856001600160a01b0316816001600160a01b03161461110957611109611951565b6001600160a01b03811661111f5761111f611951565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611167573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061118b91906118f0565b6001600160a01b0316146111a1576111a1611951565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d9906111cf9087908790600401611ddc565b6020604051808303816000875af11580156111ee573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061121291906119c7565b61122e5760405162461bcd60e51b815260040161040e90611bd5565b846001600160a01b0316826001600160a01b0316876001600160a01b03167fc1b1a5c1b97cc8e5ac82b47496f5ebdadf9c7d119b30a116e2bdafd56f6ed4758787604051611005929190611ddc565b6000808061128d84860186611ecf565b91955093509150506001600160a01b0383166112ab576112ab611951565b6001600160a01b0383811660009081526037602052604090205416156112d3576112d3611951565b6036546040516bffffffffffffffffffffffff19606086901b166020820152600091611323916001600160a01b039091169060340160405160208183030381529060405280519060200120611575565b6001600160a01b038581166000908152603760205260409081902080546001600160a01b031916928416928317905551639065714760e01b81529192509063906571479061137990879087908790600401611f4e565b600060405180830381600087803b15801561139357600080fd5b505af11580156113a7573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a3505050505050565b6001600160a01b0384161580159061140b57506001600160a01b03831615155b801561141f57506001600160a01b03821615155b801561143357506001600160a01b03811615155b6114905760405162461bcd60e51b815260206004820152602860248201527f4368696c644552433732315072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b606482015260840161040e565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000816001600160a01b03163b6000036114fc57506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611563575060408051601f3d908101601f19168201909252611560918101906119c7565b60015b61156f57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b03811661156f5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b604482015260640161040e565b6001600160a01b038116811461162157600080fd5b50565b60008083601f84011261163657600080fd5b5081356001600160401b0381111561164d57600080fd5b6020830191508360208260051b850101111561166857600080fd5b9250929050565b60008060008060006060868803121561168757600080fd5b85356116928161160c565b945060208601356001600160401b03808211156116ae57600080fd5b6116ba89838a01611624565b909650945060408801359150808211156116d357600080fd5b506116e088828901611624565b969995985093965092949392505050565b60006020828403121561170357600080fd5b813561170e8161160c565b9392505050565b60008060006060848603121561172a57600080fd5b83356117358161160c565b925060208401356117458161160c565b929592945050506040919091013590565b6000806000806060858703121561176c57600080fd5b84359350602085013561177e8161160c565b925060408501356001600160401b038082111561179a57600080fd5b818701915087601f8301126117ae57600080fd5b8135818111156117bd57600080fd5b8860208285010111156117cf57600080fd5b95989497505060200194505050565b600080604083850312156117f157600080fd5b82356117fc8161160c565b946020939093013593505050565b6000806000806080858703121561182057600080fd5b843561182b8161160c565b9350602085013561183b8161160c565b9250604085013561184b8161160c565b9150606085013561185b8161160c565b939692955090935050565b6000808585111561187657600080fd5b8386111561188357600080fd5b5050820193919092039150565b8035602083101561156f57600019602084900360031b1b1692915050565b60208082526022908201527f4368696c644552433732315072656469636174653a204e4f545f434f4e54524160408201526110d560f21b606082015260800190565b60006020828403121561190257600080fd5b815161170e8161160c565b60208082526024908201527f4368696c644552433732315072656469636174653a20554e4d41505045445f5460408201526327a5a2a760e11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561198057600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b03841681526040602082018190526000906119be9083018486611967565b95945050505050565b6000602082840312156119d957600080fd5b8151801515811461170e57600080fd5b60208082526021908201527f4368696c644552433732315072656469636174653a204255524e5f4641494c456040820152601160fa1b606082015260800190565b8183526000602080850194508260005b85811015611a68578135611a4d8161160c565b6001600160a01b031687529582019590820190600101611a3a565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a060608201819052600090611aa69083018688611a2a565b8281036080840152611ab9818587611967565b9a9950505050505050505050565b6000815180845260005b81811015611aed57602081850181015186830182015201611ad1565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611b3190830184611ac7565b949350505050565b604081526000611b4d604083018688611a2a565b8281036020840152611b60818587611967565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611b9a57600080fd5b8435611ba58161160c565b93506020850135611bb58161160c565b92506040850135611bc58161160c565b9396929550929360600135925050565b60208082526021908201527f4368696c644552433732315072656469636174653a204d494e545f4641494c456040820152601160fa1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611c5457611c54611c16565b604052919050565b60006001600160401b03821115611c7557611c75611c16565b5060051b60200190565b600082601f830112611c9057600080fd5b81356020611ca5611ca083611c5c565b611c2c565b82815260059290921b84018101918181019086841115611cc457600080fd5b8286015b84811015611cdf5780358352918301918301611cc8565b509695505050505050565b600080600080600060a08688031215611d0257600080fd5b85359450602080870135611d158161160c565b94506040870135611d258161160c565b935060608701356001600160401b0380821115611d4157600080fd5b818901915089601f830112611d5557600080fd5b8135611d63611ca082611c5c565b81815260059190911b8301840190848101908c831115611d8257600080fd5b938501935b82851015611da9578435611d9a8161160c565b82529385019390850190611d87565b965050506080890135925080831115611dc157600080fd5b5050611dcf88828901611c7f565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b82811015611e1e5781516001600160a01b031684529284019290840190600101611df9565b5050508381038285015284518082528583019183019060005b81811015611e5357835183529284019291840191600101611e37565b5090979650505050505050565b600082601f830112611e7157600080fd5b81356001600160401b03811115611e8a57611e8a611c16565b611e9d601f8201601f1916602001611c2c565b818152846020838601011115611eb257600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611ee557600080fd5b843593506020850135611ef78161160c565b925060408501356001600160401b0380821115611f1357600080fd5b611f1f88838901611e60565b93506060870135915080821115611f3557600080fd5b50611f4287828801611e60565b91505092959194509250565b6001600160a01b0384168152606060208201819052600090611f7290830185611ac7565b8281036040840152611f848185611ac7565b969550505050505056fea264697066735822122081e46b99b49bcb8dea5f01175766e4aca327da04a0662d01672b6f776a5e701164736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101585760003560e01c8063b1768065116100c3578063e0563ab11161007c578063e0563ab114610306578063eeb499451461030f578063f3fef3a314610322578063f645125514610335578063f691325c1461035c578063f8c8765e1461036f57600080fd5b8063b176806514610244578063b68ad1e41461026b578063c3b35a7e1461027e578063c5ac2b1c14610291578063d41f1771146102b8578063d7c9e3ec146102df57600080fd5b806355b01e4d1161011557806355b01e4d146101ce5780635ea5df79146101dc5780636f33e695146101f35780637efab4f514610208578063947287cf1461023157806397e5230d1461023a57600080fd5b806305dc2e8f1461015d57806307b3e2521461018d5780631bc114ba1461019b578063284017f5146101ae5780633b878c22146101b757806351351d53146101c0575b600080fd5b603454610170906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101706004600360981b0181565b603354610170906001600160a01b031681565b61017061202081565b61017061101081565b6101706002600160a01b0381565b6101706004600160991b0181565b6101e561138881565b604051908152602001610184565b61020661020136600461166f565b610382565b005b6101706102163660046116f1565b6037602052600090815260409020546001600160a01b031681565b6101e561520881565b6101e5620249f081565b6101e57f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b603654610170906001600160a01b031681565b61020661028c366004611715565b610396565b6101e57faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6101e57f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101e57f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61017061203081565b61020661031d366004611756565b6103a6565b6102066103303660046117de565b6105c9565b6101e57f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b603554610170906001600160a01b031681565b61020661037d36600461180a565b6105d8565b61038f8585858585610734565b5050505050565b6103a1838383610a98565b505050565b6034546001600160a01b031633146104175760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f53544154456044820152682fa922a1a2a4ab22a960b91b60648201526084015b60405180910390fd5b6035546001600160a01b038481169116146104865760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f524f4f545f60448201526850524544494341544560b81b606482015260840161040e565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216104b5602060008486611866565b6104be91611890565b036104dd576104d86104d38260208186611866565b610da1565b6105c3565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1861050c602060008486611866565b61051591611890565b03610524576104d88282611017565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad610553602060008486611866565b61055c91611890565b0361056b576104d8828261127d565b60405162461bcd60e51b815260206004820152602760248201527f4368696c644552433732315072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b606482015260840161040e565b50505050565b6105d4823383610a98565b5050565b336002600160a01b031461061c5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b604482015260640161040e565b600054610100900460ff161580801561063c5750600054600160ff909116105b806106565750303b158015610656575060005460ff166001145b6106b95760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161040e565b6000805460ff1916600117905580156106dc576000805461ff0019166101001790555b6106e8858585856113eb565b801561038f576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b8461073e816114e0565b61075a5760405162461bcd60e51b815260040161040e906118ae565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561079a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107be91906118f0565b6001600160a01b038181166000908152603760205260409020549192508881169116146107fd5760405162461bcd60e51b815260040161040e9061190d565b6001600160a01b03811661081357610813611951565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561085b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061087f91906118f0565b6001600160a01b03161461089557610895611951565b8483146108f05760405162461bcd60e51b8152602060048201526024808201527f4368696c644552433732315072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b606482015260840161040e565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc39061092090339088908890600401611999565b6020604051808303816000875af115801561093f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061096391906119c7565b61097f5760405162461bcd60e51b815260040161040e906119e9565b6033546035546040516001600160a01b03928316926316f198319216906109d6907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d90602001611a73565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610a02929190611b0d565b600060405180830381600087803b158015610a1c57600080fd5b505af1158015610a30573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167fa80bc76d6e1849a9088a9c00a2aeaa54eeb78f15565a18da3e8873438976f52289898989604051610a879493929190611b39565b60405180910390a450505050505050565b82610aa2816114e0565b610abe5760405162461bcd60e51b815260040161040e906118ae565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610afe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b2291906118f0565b6001600160a01b03818116600090815260376020526040902054919250868116911614610b615760405162461bcd60e51b815260040161040e9061190d565b6001600160a01b038116610b7757610b77611951565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610bbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610be391906118f0565b6001600160a01b031614610bf957610bf9611951565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610c279033908790600401611b6b565b6020604051808303816000875af1158015610c46573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c6a91906119c7565b610c865760405162461bcd60e51b815260040161040e906119e9565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610d119391169160c401611b0d565b600060405180830381600087803b158015610d2b57600080fd5b505af1158015610d3f573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f1e0ef6131232b1090efc3ec1cf7b53aa17f4b7cd8a4f9e033b49ee237379b0133387604051610d92929190611b6b565b60405180910390a45050505050565b6000808080610db285870187611b84565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610df55760405162461bcd60e51b815260040161040e9061190d565b610dfe816114e0565b610e0a57610e0a611951565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e4a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e6e91906118f0565b9050856001600160a01b0316816001600160a01b031614610e9157610e91611951565b6001600160a01b038116610ea757610ea7611951565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610eef573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1391906118f0565b6001600160a01b031614610f2957610f29611951565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610f579087908790600401611b6b565b6020604051808303816000875af1158015610f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f9a91906119c7565b610fb65760405162461bcd60e51b815260040161040e90611bd5565b836001600160a01b0316826001600160a01b0316876001600160a01b03167f37589fd8c906c19ea68eeb7e6b3e03efc06ff8aa4b1830588eba75f4375b16118887604051611005929190611b6b565b60405180910390a45050505050505050565b600080808061102885870187611cea565b6001600160a01b0380851660009081526037602052604090205494995092975090955093501690508061106d5760405162461bcd60e51b815260040161040e9061190d565b611076816114e0565b61108257611082611951565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110c2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110e691906118f0565b9050856001600160a01b0316816001600160a01b03161461110957611109611951565b6001600160a01b03811661111f5761111f611951565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611167573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061118b91906118f0565b6001600160a01b0316146111a1576111a1611951565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d9906111cf9087908790600401611ddc565b6020604051808303816000875af11580156111ee573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061121291906119c7565b61122e5760405162461bcd60e51b815260040161040e90611bd5565b846001600160a01b0316826001600160a01b0316876001600160a01b03167fc1b1a5c1b97cc8e5ac82b47496f5ebdadf9c7d119b30a116e2bdafd56f6ed4758787604051611005929190611ddc565b6000808061128d84860186611ecf565b91955093509150506001600160a01b0383166112ab576112ab611951565b6001600160a01b0383811660009081526037602052604090205416156112d3576112d3611951565b6036546040516bffffffffffffffffffffffff19606086901b166020820152600091611323916001600160a01b039091169060340160405160208183030381529060405280519060200120611575565b6001600160a01b038581166000908152603760205260409081902080546001600160a01b031916928416928317905551639065714760e01b81529192509063906571479061137990879087908790600401611f4e565b600060405180830381600087803b15801561139357600080fd5b505af11580156113a7573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a3505050505050565b6001600160a01b0384161580159061140b57506001600160a01b03831615155b801561141f57506001600160a01b03821615155b801561143357506001600160a01b03811615155b6114905760405162461bcd60e51b815260206004820152602860248201527f4368696c644552433732315072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b606482015260840161040e565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000816001600160a01b03163b6000036114fc57506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611563575060408051601f3d908101601f19168201909252611560918101906119c7565b60015b61156f57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b03811661156f5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b604482015260640161040e565b6001600160a01b038116811461162157600080fd5b50565b60008083601f84011261163657600080fd5b5081356001600160401b0381111561164d57600080fd5b6020830191508360208260051b850101111561166857600080fd5b9250929050565b60008060008060006060868803121561168757600080fd5b85356116928161160c565b945060208601356001600160401b03808211156116ae57600080fd5b6116ba89838a01611624565b909650945060408801359150808211156116d357600080fd5b506116e088828901611624565b969995985093965092949392505050565b60006020828403121561170357600080fd5b813561170e8161160c565b9392505050565b60008060006060848603121561172a57600080fd5b83356117358161160c565b925060208401356117458161160c565b929592945050506040919091013590565b6000806000806060858703121561176c57600080fd5b84359350602085013561177e8161160c565b925060408501356001600160401b038082111561179a57600080fd5b818701915087601f8301126117ae57600080fd5b8135818111156117bd57600080fd5b8860208285010111156117cf57600080fd5b95989497505060200194505050565b600080604083850312156117f157600080fd5b82356117fc8161160c565b946020939093013593505050565b6000806000806080858703121561182057600080fd5b843561182b8161160c565b9350602085013561183b8161160c565b9250604085013561184b8161160c565b9150606085013561185b8161160c565b939692955090935050565b6000808585111561187657600080fd5b8386111561188357600080fd5b5050820193919092039150565b8035602083101561156f57600019602084900360031b1b1692915050565b60208082526022908201527f4368696c644552433732315072656469636174653a204e4f545f434f4e54524160408201526110d560f21b606082015260800190565b60006020828403121561190257600080fd5b815161170e8161160c565b60208082526024908201527f4368696c644552433732315072656469636174653a20554e4d41505045445f5460408201526327a5a2a760e11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561198057600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b03841681526040602082018190526000906119be9083018486611967565b95945050505050565b6000602082840312156119d957600080fd5b8151801515811461170e57600080fd5b60208082526021908201527f4368696c644552433732315072656469636174653a204255524e5f4641494c456040820152601160fa1b606082015260800190565b8183526000602080850194508260005b85811015611a68578135611a4d8161160c565b6001600160a01b031687529582019590820190600101611a3a565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a060608201819052600090611aa69083018688611a2a565b8281036080840152611ab9818587611967565b9a9950505050505050505050565b6000815180845260005b81811015611aed57602081850181015186830182015201611ad1565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611b3190830184611ac7565b949350505050565b604081526000611b4d604083018688611a2a565b8281036020840152611b60818587611967565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611b9a57600080fd5b8435611ba58161160c565b93506020850135611bb58161160c565b92506040850135611bc58161160c565b9396929550929360600135925050565b60208082526021908201527f4368696c644552433732315072656469636174653a204d494e545f4641494c456040820152601160fa1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611c5457611c54611c16565b604052919050565b60006001600160401b03821115611c7557611c75611c16565b5060051b60200190565b600082601f830112611c9057600080fd5b81356020611ca5611ca083611c5c565b611c2c565b82815260059290921b84018101918181019086841115611cc457600080fd5b8286015b84811015611cdf5780358352918301918301611cc8565b509695505050505050565b600080600080600060a08688031215611d0257600080fd5b85359450602080870135611d158161160c565b94506040870135611d258161160c565b935060608701356001600160401b0380821115611d4157600080fd5b818901915089601f830112611d5557600080fd5b8135611d63611ca082611c5c565b81815260059190911b8301840190848101908c831115611d8257600080fd5b938501935b82851015611da9578435611d9a8161160c565b82529385019390850190611d87565b965050506080890135925080831115611dc157600080fd5b5050611dcf88828901611c7f565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b82811015611e1e5781516001600160a01b031684529284019290840190600101611df9565b5050508381038285015284518082528583019183019060005b81811015611e5357835183529284019291840191600101611e37565b5090979650505050505050565b600082601f830112611e7157600080fd5b81356001600160401b03811115611e8a57611e8a611c16565b611e9d601f8201601f1916602001611c2c565b818152846020838601011115611eb257600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611ee557600080fd5b843593506020850135611ef78161160c565b925060408501356001600160401b0380821115611f1357600080fd5b611f1f88838901611e60565b93506060870135915080821115611f3557600080fd5b50611f4287828801611e60565b91505092959194509250565b6001600160a01b0384168152606060208201819052600090611f7290830185611ac7565b8281036040840152611f848185611ac7565b969550505050505056fea264697066735822122081e46b99b49bcb8dea5f01175766e4aca327da04a0662d01672b6f776a5e701164736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildERC721PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC721PredicateAccessList","sourceName":"contracts/child/ChildERC721PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2ERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2ERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2ERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2ERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","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":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612758806100206000396000f3fe608060405234801561001057600080fd5b50600436106101b05760003560e01c8063b68ad1e4116100ef578063e0563ab111610092578063e0563ab1146103b9578063e30c3978146103c2578063eeb49945146103d3578063f2fde38b146103e6578063f3fef3a3146103f9578063f64512551461040c578063f691325c14610433578063f8c8765e1461044657600080fd5b8063b68ad1e4146102e5578063c1225a20146102f8578063c3b35a7e1461030b578063c5ac2b1c1461031e578063c5e4683a14610345578063d41f177114610358578063d7c9e3ec1461037f578063d8dd1773146103a657600080fd5b80636f33e695116101575780636f33e6951461024b578063715018a61461026057806379ba5097146102685780637efab4f5146102705780638da5cb5b1461029a578063947287cf146102ab57806397e5230d146102b4578063b1768065146102be57600080fd5b806305dc2e8f146101b557806307b3e252146101e55780631bc114ba146101f3578063284017f5146102065780633b878c221461020f57806351351d531461021857806355b01e4d146102265780635ea5df7914610234575b600080fd5b60fd546101c8906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101c86004600360981b0181565b60fc546101c8906001600160a01b031681565b6101c861202081565b6101c861101081565b6101c86002600160a01b0381565b6101c86004600160991b0181565b61023d61138881565b6040519081526020016101dc565b61025e610259366004611c96565b610459565b005b61025e610475565b61025e610489565b6101c861027e366004611d18565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101c8565b61023d61520881565b61023d620249f081565b61023d7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101c8906001600160a01b031681565b61025e610306366004611d4a565b610508565b61025e610319366004611d67565b610557565b61023d7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b61025e610353366004611d4a565b61056f565b61023d7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61023d7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61025e6103b4366004611da8565b6105b6565b6101c861203081565b6065546001600160a01b03166101c8565b61025e6103e1366004611e3e565b6106d7565b61025e6103f4366004611d18565b6108f5565b61025e610407366004611ec6565b610966565b61023d7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b60fe546101c8906001600160a01b031681565b61025e610454366004611ef2565b61097d565b610461610a75565b61046e8585858585610a7d565b5050505050565b61047d610de2565b6104876000610e3c565b565b60655433906001600160a01b031681146104fc5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61050581610e3c565b50565b610510610de2565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b61055f610a75565b61056a838383610e55565b505050565b610577610de2565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105dd5760405163973d02cb60e01b81526004016104f390611f4e565b600054610100900460ff16158080156105fd5750600054600160ff909116105b806106175750303b158015610617575060005460ff166001145b6106335760405162461bcd60e51b81526004016104f390611f72565b6000805460ff191660011790558015610656576000805461ff0019166101001790555b6106628888888861115f565b60c9805461ffff191685151561ff001916176101008515150217905561068782610e3c565b80156106cd576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107435760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f53544154456044820152682fa922a1a2a4ab22a960b91b60648201526084016104f3565b60fe546001600160a01b038481169116146107b25760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f524f4f545f60448201526850524544494341544560b81b60648201526084016104f3565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216107e1602060008486611fc0565b6107ea91611fea565b03610809576108046107ff8260208186611fc0565b611254565b6108ef565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18610838602060008486611fc0565b61084191611fea565b036108505761080482826114cb565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61087f602060008486611fc0565b61088891611fea565b03610897576108048282611732565b60405162461bcd60e51b815260206004820152602760248201527f4368696c644552433732315072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b60648201526084016104f3565b50505050565b6108fd610de2565b606580546001600160a01b0383166001600160a01b0319909116811790915561092e6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b61096e610a75565b610979823383610e55565b5050565b336002600160a01b03146109a45760405163973d02cb60e01b81526004016104f390611f4e565b600054610100900460ff16158080156109c45750600054600160ff909116105b806109de5750303b1580156109de575060005460ff166001145b6109fa5760405162461bcd60e51b81526004016104f390611f72565b6000805460ff191660011790558015610a1d576000805461ff0019166101001790555b610a298585858561115f565b801561046e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b6104876118a2565b84610a8781611ab8565b610aa35760405162461bcd60e51b81526004016104f390612008565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ae3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b07919061204a565b6001600160a01b0381811660009081526101006020526040902054919250888116911614610b475760405162461bcd60e51b81526004016104f390612067565b6001600160a01b038116610b5d57610b5d6120ab565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ba5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bc9919061204a565b6001600160a01b031614610bdf57610bdf6120ab565b848314610c3a5760405162461bcd60e51b8152602060048201526024808201527f4368696c644552433732315072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b60648201526084016104f3565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc390610c6a903390889088906004016120f3565b6020604051808303816000875af1158015610c89573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cad9190612121565b610cc95760405162461bcd60e51b81526004016104f39061213e565b60fc5460fe546040516001600160a01b03928316926316f19831921690610d20907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d906020016121c8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d4c92919061226c565b600060405180830381600087803b158015610d6657600080fd5b505af1158015610d7a573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167fa80bc76d6e1849a9088a9c00a2aeaa54eeb78f15565a18da3e8873438976f52289898989604051610dd19493929190612298565b60405180910390a450505050505050565b6033546001600160a01b031633146104875760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104f3565b606580546001600160a01b031916905561050581611b4d565b82610e5f81611ab8565b610e7b5760405162461bcd60e51b81526004016104f390612008565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ebb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610edf919061204a565b6001600160a01b0381811660009081526101006020526040902054919250868116911614610f1f5760405162461bcd60e51b81526004016104f390612067565b6001600160a01b038116610f3557610f356120ab565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f7d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fa1919061204a565b6001600160a01b031614610fb757610fb76120ab565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610fe590339087906004016122ca565b6020604051808303816000875af1158015611004573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110289190612121565b6110445760405162461bcd60e51b81526004016104f39061213e565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352938416936316f19831936110cf9391169160c40161226c565b600060405180830381600087803b1580156110e957600080fd5b505af11580156110fd573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f1e0ef6131232b1090efc3ec1cf7b53aa17f4b7cd8a4f9e033b49ee237379b01333876040516111509291906122ca565b60405180910390a45050505050565b6001600160a01b0384161580159061117f57506001600160a01b03831615155b801561119357506001600160a01b03821615155b80156111a757506001600160a01b03811615155b6112045760405162461bcd60e51b815260206004820152602860248201527f4368696c644552433732315072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b60648201526084016104f3565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b6000808080611265858701876122e3565b6001600160a01b0380851660009081526101006020526040902054949850929650909450925016806112a95760405162461bcd60e51b81526004016104f390612067565b6112b281611ab8565b6112be576112be6120ab565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156112fe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611322919061204a565b9050856001600160a01b0316816001600160a01b031614611345576113456120ab565b6001600160a01b03811661135b5761135b6120ab565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113c7919061204a565b6001600160a01b0316146113dd576113dd6120ab565b6040516340c10f1960e01b81526001600160a01b038316906340c10f199061140b90879087906004016122ca565b6020604051808303816000875af115801561142a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061144e9190612121565b61146a5760405162461bcd60e51b81526004016104f390612334565b836001600160a01b0316826001600160a01b0316876001600160a01b03167f37589fd8c906c19ea68eeb7e6b3e03efc06ff8aa4b1830588eba75f4375b161188876040516114b99291906122ca565b60405180910390a45050505050505050565b60008080806114dc85870187612449565b6001600160a01b03808516600090815261010060205260409020549499509297509095509350169050806115225760405162461bcd60e51b81526004016104f390612067565b61152b81611ab8565b611537576115376120ab565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015611577573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061159b919061204a565b9050856001600160a01b0316816001600160a01b0316146115be576115be6120ab565b6001600160a01b0381166115d4576115d46120ab565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561161c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611640919061204a565b6001600160a01b031614611656576116566120ab565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d990611684908790879060040161253b565b6020604051808303816000875af11580156116a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116c79190612121565b6116e35760405162461bcd60e51b81526004016104f390612334565b846001600160a01b0316826001600160a01b0316876001600160a01b03167fc1b1a5c1b97cc8e5ac82b47496f5ebdadf9c7d119b30a116e2bdafd56f6ed47587876040516114b992919061253b565b600080806117428486018661262e565b91955093509150506001600160a01b038316611760576117606120ab565b6001600160a01b03838116600090815261010060205260409020541615611789576117896120ab565b60ff546040516bffffffffffffffffffffffff19606086901b1660208201526000916117d9916001600160a01b039091169060340160405160208183030381529060405280519060200120611b9f565b6001600160a01b03858116600090815261010060205260409081902080546001600160a01b031916928416928317905551639065714760e01b815291925090639065714790611830908790879087906004016126ad565b600060405180830381600087803b15801561184a57600080fd5b505af115801561185e573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a3505050505050565b60c95460ff16156119ad57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161190491906126ed565b6000604051808303818686fa925050503d8060008114611940576040519150601f19603f3d011682016040523d82523d6000602084013e611945565b606091505b509150915081801561196a57506000818060200190518101906119689190612709565b115b6119aa5760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016104f3565b50505b60c954610100900460ff161561048757604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b019161138891611a1491906126ed565b6000604051808303818686fa925050503d8060008114611a50576040519150601f19603f3d011682016040523d82523d6000602084013e611a55565b606091505b5091509150818015611a7b575080806020019051810190611a769190612709565b600114155b6109795760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016104f3565b6000816001600160a01b03163b600003611ad457506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611b3b575060408051601f3d908101601f19168201909252611b3891810190612121565b60015b611b4757506000919050565b92915050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116611b475760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016104f3565b6001600160a01b038116811461050557600080fd5b60008083601f840112611c5d57600080fd5b5081356001600160401b03811115611c7457600080fd5b6020830191508360208260051b8501011115611c8f57600080fd5b9250929050565b600080600080600060608688031215611cae57600080fd5b8535611cb981611c36565b945060208601356001600160401b0380821115611cd557600080fd5b611ce189838a01611c4b565b90965094506040880135915080821115611cfa57600080fd5b50611d0788828901611c4b565b969995985093965092949392505050565b600060208284031215611d2a57600080fd5b8135611d3581611c36565b9392505050565b801515811461050557600080fd5b600060208284031215611d5c57600080fd5b8135611d3581611d3c565b600080600060608486031215611d7c57600080fd5b8335611d8781611c36565b92506020840135611d9781611c36565b929592945050506040919091013590565b600080600080600080600060e0888a031215611dc357600080fd5b8735611dce81611c36565b96506020880135611dde81611c36565b95506040880135611dee81611c36565b94506060880135611dfe81611c36565b93506080880135611e0e81611d3c565b925060a0880135611e1e81611d3c565b915060c0880135611e2e81611c36565b8091505092959891949750929550565b60008060008060608587031215611e5457600080fd5b843593506020850135611e6681611c36565b925060408501356001600160401b0380821115611e8257600080fd5b818701915087601f830112611e9657600080fd5b813581811115611ea557600080fd5b886020828501011115611eb757600080fd5b95989497505060200194505050565b60008060408385031215611ed957600080fd5b8235611ee481611c36565b946020939093013593505050565b60008060008060808587031215611f0857600080fd5b8435611f1381611c36565b93506020850135611f2381611c36565b92506040850135611f3381611c36565b91506060850135611f4381611c36565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611fd057600080fd5b83861115611fdd57600080fd5b5050820193919092039150565b80356020831015611b4757600019602084900360031b1b1692915050565b60208082526022908201527f4368696c644552433732315072656469636174653a204e4f545f434f4e54524160408201526110d560f21b606082015260800190565b60006020828403121561205c57600080fd5b8151611d3581611c36565b60208082526024908201527f4368696c644552433732315072656469636174653a20554e4d41505045445f5460408201526327a5a2a760e11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156120da57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038416815260406020820181905260009061211890830184866120c1565b95945050505050565b60006020828403121561213357600080fd5b8151611d3581611d3c565b60208082526021908201527f4368696c644552433732315072656469636174653a204255524e5f4641494c456040820152601160fa1b606082015260800190565b8183526000602080850194508260005b858110156121bd5781356121a281611c36565b6001600160a01b03168752958201959082019060010161218f565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906121fb908301868861217f565b828103608084015261220e8185876120c1565b9a9950505050505050505050565b60005b8381101561223757818101518382015260200161221f565b50506000910152565b6000815180845261225881602086016020860161221c565b601f01601f19169290920160200192915050565b6001600160a01b038316815260406020820181905260009061229090830184612240565b949350505050565b6040815260006122ac60408301868861217f565b82810360208401526122bf8185876120c1565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b600080600080608085870312156122f957600080fd5b843561230481611c36565b9350602085013561231481611c36565b9250604085013561232481611c36565b9396929550929360600135925050565b60208082526021908201527f4368696c644552433732315072656469636174653a204d494e545f4641494c456040820152601160fa1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156123b3576123b3612375565b604052919050565b60006001600160401b038211156123d4576123d4612375565b5060051b60200190565b600082601f8301126123ef57600080fd5b813560206124046123ff836123bb565b61238b565b82815260059290921b8401810191818101908684111561242357600080fd5b8286015b8481101561243e5780358352918301918301612427565b509695505050505050565b600080600080600060a0868803121561246157600080fd5b8535945060208087013561247481611c36565b9450604087013561248481611c36565b935060608701356001600160401b03808211156124a057600080fd5b818901915089601f8301126124b457600080fd5b81356124c26123ff826123bb565b81815260059190911b8301840190848101908c8311156124e157600080fd5b938501935b828510156125085784356124f981611c36565b825293850193908501906124e6565b96505050608089013592508083111561252057600080fd5b505061252e888289016123de565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b8281101561257d5781516001600160a01b031684529284019290840190600101612558565b5050508381038285015284518082528583019183019060005b818110156125b257835183529284019291840191600101612596565b5090979650505050505050565b600082601f8301126125d057600080fd5b81356001600160401b038111156125e9576125e9612375565b6125fc601f8201601f191660200161238b565b81815284602083860101111561261157600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000806080858703121561264457600080fd5b84359350602085013561265681611c36565b925060408501356001600160401b038082111561267257600080fd5b61267e888389016125bf565b9350606087013591508082111561269457600080fd5b506126a1878288016125bf565b91505092959194509250565b6001600160a01b03841681526060602082018190526000906126d190830185612240565b82810360408401526126e38185612240565b9695505050505050565b600082516126ff81846020870161221c565b9190910192915050565b60006020828403121561271b57600080fd5b505191905056fea2646970667358221220d293b100fc5adddbb8fd0cb4e134ee7114418d77a3e89fc4f80cf959061a6cfc64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101b05760003560e01c8063b68ad1e4116100ef578063e0563ab111610092578063e0563ab1146103b9578063e30c3978146103c2578063eeb49945146103d3578063f2fde38b146103e6578063f3fef3a3146103f9578063f64512551461040c578063f691325c14610433578063f8c8765e1461044657600080fd5b8063b68ad1e4146102e5578063c1225a20146102f8578063c3b35a7e1461030b578063c5ac2b1c1461031e578063c5e4683a14610345578063d41f177114610358578063d7c9e3ec1461037f578063d8dd1773146103a657600080fd5b80636f33e695116101575780636f33e6951461024b578063715018a61461026057806379ba5097146102685780637efab4f5146102705780638da5cb5b1461029a578063947287cf146102ab57806397e5230d146102b4578063b1768065146102be57600080fd5b806305dc2e8f146101b557806307b3e252146101e55780631bc114ba146101f3578063284017f5146102065780633b878c221461020f57806351351d531461021857806355b01e4d146102265780635ea5df7914610234575b600080fd5b60fd546101c8906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101c86004600360981b0181565b60fc546101c8906001600160a01b031681565b6101c861202081565b6101c861101081565b6101c86002600160a01b0381565b6101c86004600160991b0181565b61023d61138881565b6040519081526020016101dc565b61025e610259366004611c96565b610459565b005b61025e610475565b61025e610489565b6101c861027e366004611d18565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101c8565b61023d61520881565b61023d620249f081565b61023d7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101c8906001600160a01b031681565b61025e610306366004611d4a565b610508565b61025e610319366004611d67565b610557565b61023d7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b61025e610353366004611d4a565b61056f565b61023d7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61023d7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61025e6103b4366004611da8565b6105b6565b6101c861203081565b6065546001600160a01b03166101c8565b61025e6103e1366004611e3e565b6106d7565b61025e6103f4366004611d18565b6108f5565b61025e610407366004611ec6565b610966565b61023d7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b60fe546101c8906001600160a01b031681565b61025e610454366004611ef2565b61097d565b610461610a75565b61046e8585858585610a7d565b5050505050565b61047d610de2565b6104876000610e3c565b565b60655433906001600160a01b031681146104fc5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61050581610e3c565b50565b610510610de2565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b61055f610a75565b61056a838383610e55565b505050565b610577610de2565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105dd5760405163973d02cb60e01b81526004016104f390611f4e565b600054610100900460ff16158080156105fd5750600054600160ff909116105b806106175750303b158015610617575060005460ff166001145b6106335760405162461bcd60e51b81526004016104f390611f72565b6000805460ff191660011790558015610656576000805461ff0019166101001790555b6106628888888861115f565b60c9805461ffff191685151561ff001916176101008515150217905561068782610e3c565b80156106cd576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107435760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f53544154456044820152682fa922a1a2a4ab22a960b91b60648201526084016104f3565b60fe546001600160a01b038481169116146107b25760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f524f4f545f60448201526850524544494341544560b81b60648201526084016104f3565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216107e1602060008486611fc0565b6107ea91611fea565b03610809576108046107ff8260208186611fc0565b611254565b6108ef565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18610838602060008486611fc0565b61084191611fea565b036108505761080482826114cb565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61087f602060008486611fc0565b61088891611fea565b03610897576108048282611732565b60405162461bcd60e51b815260206004820152602760248201527f4368696c644552433732315072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b60648201526084016104f3565b50505050565b6108fd610de2565b606580546001600160a01b0383166001600160a01b0319909116811790915561092e6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b61096e610a75565b610979823383610e55565b5050565b336002600160a01b03146109a45760405163973d02cb60e01b81526004016104f390611f4e565b600054610100900460ff16158080156109c45750600054600160ff909116105b806109de5750303b1580156109de575060005460ff166001145b6109fa5760405162461bcd60e51b81526004016104f390611f72565b6000805460ff191660011790558015610a1d576000805461ff0019166101001790555b610a298585858561115f565b801561046e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b6104876118a2565b84610a8781611ab8565b610aa35760405162461bcd60e51b81526004016104f390612008565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ae3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b07919061204a565b6001600160a01b0381811660009081526101006020526040902054919250888116911614610b475760405162461bcd60e51b81526004016104f390612067565b6001600160a01b038116610b5d57610b5d6120ab565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ba5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bc9919061204a565b6001600160a01b031614610bdf57610bdf6120ab565b848314610c3a5760405162461bcd60e51b8152602060048201526024808201527f4368696c644552433732315072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b60648201526084016104f3565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc390610c6a903390889088906004016120f3565b6020604051808303816000875af1158015610c89573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cad9190612121565b610cc95760405162461bcd60e51b81526004016104f39061213e565b60fc5460fe546040516001600160a01b03928316926316f19831921690610d20907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d906020016121c8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d4c92919061226c565b600060405180830381600087803b158015610d6657600080fd5b505af1158015610d7a573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167fa80bc76d6e1849a9088a9c00a2aeaa54eeb78f15565a18da3e8873438976f52289898989604051610dd19493929190612298565b60405180910390a450505050505050565b6033546001600160a01b031633146104875760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104f3565b606580546001600160a01b031916905561050581611b4d565b82610e5f81611ab8565b610e7b5760405162461bcd60e51b81526004016104f390612008565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ebb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610edf919061204a565b6001600160a01b0381811660009081526101006020526040902054919250868116911614610f1f5760405162461bcd60e51b81526004016104f390612067565b6001600160a01b038116610f3557610f356120ab565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f7d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fa1919061204a565b6001600160a01b031614610fb757610fb76120ab565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610fe590339087906004016122ca565b6020604051808303816000875af1158015611004573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110289190612121565b6110445760405162461bcd60e51b81526004016104f39061213e565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352938416936316f19831936110cf9391169160c40161226c565b600060405180830381600087803b1580156110e957600080fd5b505af11580156110fd573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f1e0ef6131232b1090efc3ec1cf7b53aa17f4b7cd8a4f9e033b49ee237379b01333876040516111509291906122ca565b60405180910390a45050505050565b6001600160a01b0384161580159061117f57506001600160a01b03831615155b801561119357506001600160a01b03821615155b80156111a757506001600160a01b03811615155b6112045760405162461bcd60e51b815260206004820152602860248201527f4368696c644552433732315072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b60648201526084016104f3565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b6000808080611265858701876122e3565b6001600160a01b0380851660009081526101006020526040902054949850929650909450925016806112a95760405162461bcd60e51b81526004016104f390612067565b6112b281611ab8565b6112be576112be6120ab565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156112fe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611322919061204a565b9050856001600160a01b0316816001600160a01b031614611345576113456120ab565b6001600160a01b03811661135b5761135b6120ab565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113c7919061204a565b6001600160a01b0316146113dd576113dd6120ab565b6040516340c10f1960e01b81526001600160a01b038316906340c10f199061140b90879087906004016122ca565b6020604051808303816000875af115801561142a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061144e9190612121565b61146a5760405162461bcd60e51b81526004016104f390612334565b836001600160a01b0316826001600160a01b0316876001600160a01b03167f37589fd8c906c19ea68eeb7e6b3e03efc06ff8aa4b1830588eba75f4375b161188876040516114b99291906122ca565b60405180910390a45050505050505050565b60008080806114dc85870187612449565b6001600160a01b03808516600090815261010060205260409020549499509297509095509350169050806115225760405162461bcd60e51b81526004016104f390612067565b61152b81611ab8565b611537576115376120ab565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015611577573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061159b919061204a565b9050856001600160a01b0316816001600160a01b0316146115be576115be6120ab565b6001600160a01b0381166115d4576115d46120ab565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561161c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611640919061204a565b6001600160a01b031614611656576116566120ab565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d990611684908790879060040161253b565b6020604051808303816000875af11580156116a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116c79190612121565b6116e35760405162461bcd60e51b81526004016104f390612334565b846001600160a01b0316826001600160a01b0316876001600160a01b03167fc1b1a5c1b97cc8e5ac82b47496f5ebdadf9c7d119b30a116e2bdafd56f6ed47587876040516114b992919061253b565b600080806117428486018661262e565b91955093509150506001600160a01b038316611760576117606120ab565b6001600160a01b03838116600090815261010060205260409020541615611789576117896120ab565b60ff546040516bffffffffffffffffffffffff19606086901b1660208201526000916117d9916001600160a01b039091169060340160405160208183030381529060405280519060200120611b9f565b6001600160a01b03858116600090815261010060205260409081902080546001600160a01b031916928416928317905551639065714760e01b815291925090639065714790611830908790879087906004016126ad565b600060405180830381600087803b15801561184a57600080fd5b505af115801561185e573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a3505050505050565b60c95460ff16156119ad57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161190491906126ed565b6000604051808303818686fa925050503d8060008114611940576040519150601f19603f3d011682016040523d82523d6000602084013e611945565b606091505b509150915081801561196a57506000818060200190518101906119689190612709565b115b6119aa5760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016104f3565b50505b60c954610100900460ff161561048757604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b019161138891611a1491906126ed565b6000604051808303818686fa925050503d8060008114611a50576040519150601f19603f3d011682016040523d82523d6000602084013e611a55565b606091505b5091509150818015611a7b575080806020019051810190611a769190612709565b600114155b6109795760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016104f3565b6000816001600160a01b03163b600003611ad457506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611b3b575060408051601f3d908101601f19168201909252611b3891810190612121565b60015b611b4757506000919050565b92915050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116611b475760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016104f3565b6001600160a01b038116811461050557600080fd5b60008083601f840112611c5d57600080fd5b5081356001600160401b03811115611c7457600080fd5b6020830191508360208260051b8501011115611c8f57600080fd5b9250929050565b600080600080600060608688031215611cae57600080fd5b8535611cb981611c36565b945060208601356001600160401b0380821115611cd557600080fd5b611ce189838a01611c4b565b90965094506040880135915080821115611cfa57600080fd5b50611d0788828901611c4b565b969995985093965092949392505050565b600060208284031215611d2a57600080fd5b8135611d3581611c36565b9392505050565b801515811461050557600080fd5b600060208284031215611d5c57600080fd5b8135611d3581611d3c565b600080600060608486031215611d7c57600080fd5b8335611d8781611c36565b92506020840135611d9781611c36565b929592945050506040919091013590565b600080600080600080600060e0888a031215611dc357600080fd5b8735611dce81611c36565b96506020880135611dde81611c36565b95506040880135611dee81611c36565b94506060880135611dfe81611c36565b93506080880135611e0e81611d3c565b925060a0880135611e1e81611d3c565b915060c0880135611e2e81611c36565b8091505092959891949750929550565b60008060008060608587031215611e5457600080fd5b843593506020850135611e6681611c36565b925060408501356001600160401b0380821115611e8257600080fd5b818701915087601f830112611e9657600080fd5b813581811115611ea557600080fd5b886020828501011115611eb757600080fd5b95989497505060200194505050565b60008060408385031215611ed957600080fd5b8235611ee481611c36565b946020939093013593505050565b60008060008060808587031215611f0857600080fd5b8435611f1381611c36565b93506020850135611f2381611c36565b92506040850135611f3381611c36565b91506060850135611f4381611c36565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611fd057600080fd5b83861115611fdd57600080fd5b5050820193919092039150565b80356020831015611b4757600019602084900360031b1b1692915050565b60208082526022908201527f4368696c644552433732315072656469636174653a204e4f545f434f4e54524160408201526110d560f21b606082015260800190565b60006020828403121561205c57600080fd5b8151611d3581611c36565b60208082526024908201527f4368696c644552433732315072656469636174653a20554e4d41505045445f5460408201526327a5a2a760e11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156120da57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038416815260406020820181905260009061211890830184866120c1565b95945050505050565b60006020828403121561213357600080fd5b8151611d3581611d3c565b60208082526021908201527f4368696c644552433732315072656469636174653a204255524e5f4641494c456040820152601160fa1b606082015260800190565b8183526000602080850194508260005b858110156121bd5781356121a281611c36565b6001600160a01b03168752958201959082019060010161218f565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906121fb908301868861217f565b828103608084015261220e8185876120c1565b9a9950505050505050505050565b60005b8381101561223757818101518382015260200161221f565b50506000910152565b6000815180845261225881602086016020860161221c565b601f01601f19169290920160200192915050565b6001600160a01b038316815260406020820181905260009061229090830184612240565b949350505050565b6040815260006122ac60408301868861217f565b82810360208401526122bf8185876120c1565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b600080600080608085870312156122f957600080fd5b843561230481611c36565b9350602085013561231481611c36565b9250604085013561232481611c36565b9396929550929360600135925050565b60208082526021908201527f4368696c644552433732315072656469636174653a204d494e545f4641494c456040820152601160fa1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156123b3576123b3612375565b604052919050565b60006001600160401b038211156123d4576123d4612375565b5060051b60200190565b600082601f8301126123ef57600080fd5b813560206124046123ff836123bb565b61238b565b82815260059290921b8401810191818101908684111561242357600080fd5b8286015b8481101561243e5780358352918301918301612427565b509695505050505050565b600080600080600060a0868803121561246157600080fd5b8535945060208087013561247481611c36565b9450604087013561248481611c36565b935060608701356001600160401b03808211156124a057600080fd5b818901915089601f8301126124b457600080fd5b81356124c26123ff826123bb565b81815260059190911b8301840190848101908c8311156124e157600080fd5b938501935b828510156125085784356124f981611c36565b825293850193908501906124e6565b96505050608089013592508083111561252057600080fd5b505061252e888289016123de565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b8281101561257d5781516001600160a01b031684529284019290840190600101612558565b5050508381038285015284518082528583019183019060005b818110156125b257835183529284019291840191600101612596565b5090979650505050505050565b600082601f8301126125d057600080fd5b81356001600160401b038111156125e9576125e9612375565b6125fc601f8201601f191660200161238b565b81815284602083860101111561261157600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000806080858703121561264457600080fd5b84359350602085013561265681611c36565b925060408501356001600160401b038082111561267257600080fd5b61267e888389016125bf565b9350606087013591508082111561269457600080fd5b506126a1878288016125bf565b91505092959194509250565b6001600160a01b03841681526060602082018190526000906126d190830185612240565b82810360408401526126e38185612240565b9695505050505050565b600082516126ff81846020870161221c565b9190910192915050565b60006020828403121561271b57600080fd5b505191905056fea2646970667358221220d293b100fc5adddbb8fd0cb4e134ee7114418d77a3e89fc4f80cf959061a6cfc64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RootMintableERC721PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC721Predicate","sourceName":"contracts/child/RootMintableERC721Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2MintableERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2MintableERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2MintableERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2MintableERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611a8f806100206000396000f3fe608060405234801561001057600080fd5b506004361061016e5760003560e01c806397e5230d116100ce578063e0563ab111610087578063e0563ab114610353578063eeb499451461035c578063f213159c1461036f578063f4a120f714610382578063f645125514610395578063f8c8765e146103bc578063ff6f870c146103cf57600080fd5b806397e5230d1461029a578063b1768065146102a4578063b68ad1e4146102cb578063c5ac2b1c146102de578063d41f177114610305578063d7c9e3ec1461032c57600080fd5b806347e7ef241161012b57806347e7ef241461020d5780634fdca69d1461022257806351351d531461023557806355b01e4d146102435780635ea5df79146102515780637efab4f514610268578063947287cf1461029157600080fd5b806305dc2e8f1461017357806307b3e252146101a3578063150b7a02146101b15780631bc114ba146101e8578063284017f5146101fb5780633b878c2214610204575b600080fd5b603454610186906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101866004600360981b0181565b6101cf6101bf366004611231565b630a85bd0160e11b949350505050565b6040516001600160e01b0319909116815260200161019a565b603354610186906001600160a01b031681565b61018661202081565b61018661101081565b61022061021b3660046112df565b6103e2565b005b603554610186906001600160a01b031681565b6101866002600160a01b0381565b6101866004600160991b0181565b61025a61138881565b60405190815260200161019a565b61018661027636600461130b565b6037602052600090815260409020546001600160a01b031681565b61025a61520881565b61025a620249f081565b61025a7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b603654610186906001600160a01b031681565b61025a7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b61025a7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61025a7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61018661203081565b61022061036a36600461132f565b6103f1565b61022061037d3660046113b7565b6105d1565b61018661039036600461130b565b6105e1565b61025a7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102206103ca3660046113f8565b61093a565b6102206103dd36600461149f565b610a97565b6103ed823383610af5565b5050565b6034546001600160a01b031633146104695760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b60648201526084015b60405180910390fd5b6035546001600160a01b038481169116146104e05760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c604482015270595f4348494c445f50524544494341544560781b6064820152608401610460565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961050f602060008486611521565b6105189161154b565b036105375761053261052d8260208186611521565b610c74565b6105cb565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed2610566602060008486611521565b61056f9161154b565b0361057e576105328282610d72565b60405162461bcd60e51b815260206004820152602e6024820152600080516020611a3a83398151915260448201526d414c49445f5349474e415455524560901b6064820152608401610460565b50505050565b6105dc838383610af5565b505050565b60006001600160a01b03821661063a5760405162461bcd60e51b815260206004820152602a6024820152600080516020611a3a83398151915260448201526920a624a22faa27a5a2a760b11b6064820152608401610460565b6001600160a01b0382811660009081526037602052604090205416156106b65760405162461bcd60e51b815260206004820152602b60248201527f526f6f744d696e7461626c654552433732315072656469636174653a20414c5260448201526a1150511657d3505414115160aa1b6064820152608401610460565b6035546036546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261076492911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0385811660008181526037602052604080822080546001600160a01b03191686861617905560335481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa1580156107fc573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610824919081019061158e565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610862573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261088a919081019061158e565b60405160200161089d9493929190611630565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108c9929190611677565b600060405180830381600087803b1580156108e357600080fd5b505af11580156108f7573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b031461097e5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610460565b600054610100900460ff161580801561099e5750600054600160ff909116105b806109b85750303b1580156109b8575060005460ff166001145b610a1b5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610460565b6000805460ff191660011790558015610a3e576000805461ff0019166101001790555b610a4a85858585610eb3565b8015610a90576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610ae85760405162461bcd60e51b815260206004820152602b6024820152600080516020611a3a83398151915260448201526a082989288be988a9c8ea8960ab1b6064820152608401610460565b610a908585858585610faf565b6000610b0084611165565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610b33903390309087906004016116a3565b600060405180830381600087803b158015610b4d57600080fd5b505af1158015610b61573d6000803e3d6000fd5b5050603354603554604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935293841695506316f198319450610bf1939092169160c401611677565b600060405180830381600087803b158015610c0b57600080fd5b505af1158015610c1f573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917fe3abb9ec195b50242582cc6cb7abc990ac26439b9ed7635ed72f7bd720e7477a910160405180910390a46105cb565b6000808080610c85858701876116c7565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610cb857610cb8611718565b604051632142170760e11b81526001600160a01b038616906342842e0e90610ce8903090879087906004016116a3565b600060405180830381600087803b158015610d0257600080fd5b505af1158015610d16573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f80afffd84aa825dd9b3c1ba262eb55eef58f78616634437a367a263f3c48fe3d91015b60405180910390a450505050505050565b6000808080610d83858701876117b7565b6001600160a01b03808516600090815260376020526040902054949950929750909550935016905080610db857610db8611718565b60005b8251811015610e6357856001600160a01b03166342842e0e30868481518110610de657610de66118a9565b6020026020010151868581518110610e0057610e006118a9565b60200260200101516040518463ffffffff1660e01b8152600401610e26939291906116a3565b600060405180830381600087803b158015610e4057600080fd5b505af1158015610e54573d6000803e3d6000fd5b50505050806001019050610dbb565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167ff64537485d843fa8a1f4354cb9937954c64282de0828be9f096355006222186b8686604051610d619291906118bf565b6001600160a01b03841615801590610ed357506001600160a01b03831615155b8015610ee757506001600160a01b03821615155b8015610efb57506001600160a01b03811615155b610f5f5760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c654552433732315072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b6064820152608401610460565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000610fba86611165565b905060005b8281101561104c57866001600160a01b03166342842e0e3330878786818110610fea57610fea6118a9565b905060200201356040518463ffffffff1660e01b815260040161100f939291906116a3565b600060405180830381600087803b15801561102957600080fd5b505af115801561103d573d6000803e3d6000fd5b50505050806001019050610fbf565b506033546035546040516001600160a01b03928316926316f198319216906110a4907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c906020016119be565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016110d0929190611677565b600060405180830381600087803b1580156110ea57600080fd5b505af11580156110fe573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f0ca5d99e0f7e7651c00c76347baa68a333790cbc9fb039a10843d1bd61f578c5888888886040516111559493929190611a12565b60405180910390a4505050505050565b6001600160a01b0380821660009081526037602052604090205416806111915761118e826105e1565b90505b6001600160a01b0381166111a7576111a7611718565b919050565b6001600160a01b03811681146111c157600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611202576112026111c4565b604052919050565b60006001600160401b03821115611223576112236111c4565b50601f01601f191660200190565b6000806000806080858703121561124757600080fd5b8435611252816111ac565b93506020850135611262816111ac565b92506040850135915060608501356001600160401b0381111561128457600080fd5b8501601f8101871361129557600080fd5b80356112a86112a38261120a565b6111da565b8181528860208385010111156112bd57600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b600080604083850312156112f257600080fd5b82356112fd816111ac565b946020939093013593505050565b60006020828403121561131d57600080fd5b8135611328816111ac565b9392505050565b6000806000806060858703121561134557600080fd5b843593506020850135611357816111ac565b925060408501356001600160401b038082111561137357600080fd5b818701915087601f83011261138757600080fd5b81358181111561139657600080fd5b8860208285010111156113a857600080fd5b95989497505060200194505050565b6000806000606084860312156113cc57600080fd5b83356113d7816111ac565b925060208401356113e7816111ac565b929592945050506040919091013590565b6000806000806080858703121561140e57600080fd5b8435611419816111ac565b93506020850135611429816111ac565b92506040850135611439816111ac565b91506060850135611449816111ac565b939692955090935050565b60008083601f84011261146657600080fd5b5081356001600160401b0381111561147d57600080fd5b6020830191508360208260051b850101111561149857600080fd5b9250929050565b6000806000806000606086880312156114b757600080fd5b85356114c2816111ac565b945060208601356001600160401b03808211156114de57600080fd5b6114ea89838a01611454565b9096509450604088013591508082111561150357600080fd5b5061151088828901611454565b969995985093965092949392505050565b6000808585111561153157600080fd5b8386111561153e57600080fd5b5050820193919092039150565b8035602083101561156457600019602084900360031b1b165b92915050565b60005b8381101561158557818101518382015260200161156d565b50506000910152565b6000602082840312156115a057600080fd5b81516001600160401b038111156115b657600080fd5b8201601f810184136115c757600080fd5b80516115d56112a38261120a565b8181528560208385010111156115ea57600080fd5b6115fb82602083016020860161156a565b95945050505050565b6000815180845261161c81602086016020860161156a565b601f01601f19169290920160200192915050565b8481526001600160a01b038416602082015260806040820181905260009061165a90830185611604565b828103606084015261166c8185611604565b979650505050505050565b6001600160a01b038316815260406020820181905260009061169b90830184611604565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600080600080608085870312156116dd57600080fd5b84356116e8816111ac565b935060208501356116f8816111ac565b92506040850135611708816111ac565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611747576117476111c4565b5060051b60200190565b600082601f83011261176257600080fd5b813560206117726112a38361172e565b82815260059290921b8401810191818101908684111561179157600080fd5b8286015b848110156117ac5780358352918301918301611795565b509695505050505050565b600080600080600060a086880312156117cf57600080fd5b853594506020808701356117e2816111ac565b945060408701356117f2816111ac565b935060608701356001600160401b038082111561180e57600080fd5b818901915089601f83011261182257600080fd5b81356118306112a38261172e565b81815260059190911b8301840190848101908c83111561184f57600080fd5b938501935b82851015611876578435611867816111ac565b82529385019390850190611854565b96505050608089013592508083111561188e57600080fd5b505061189c88828901611751565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b828110156119015781516001600160a01b0316845292840192908401906001016118dc565b5050508381038285015284518082528583019183019060005b818110156119365783518352928401929184019160010161191a565b5090979650505050505050565b8183526000602080850194508260005b85811015611981578135611966816111ac565b6001600160a01b031687529582019590820190600101611953565b509495945050505050565b81835260006001600160fb1b038311156119a557600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906119f19083018688611943565b8281036080840152611a0481858761198c565b9a9950505050505050505050565b604081526000611a26604083018688611943565b828103602084015261166c81858761198c56fe526f6f744d696e7461626c654552433732315072656469636174653a20494e56a2646970667358221220d56687504a65fbdf30d6fa40bc1481712f630a02ef2aa4dc136cf9be78742d2364736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061016e5760003560e01c806397e5230d116100ce578063e0563ab111610087578063e0563ab114610353578063eeb499451461035c578063f213159c1461036f578063f4a120f714610382578063f645125514610395578063f8c8765e146103bc578063ff6f870c146103cf57600080fd5b806397e5230d1461029a578063b1768065146102a4578063b68ad1e4146102cb578063c5ac2b1c146102de578063d41f177114610305578063d7c9e3ec1461032c57600080fd5b806347e7ef241161012b57806347e7ef241461020d5780634fdca69d1461022257806351351d531461023557806355b01e4d146102435780635ea5df79146102515780637efab4f514610268578063947287cf1461029157600080fd5b806305dc2e8f1461017357806307b3e252146101a3578063150b7a02146101b15780631bc114ba146101e8578063284017f5146101fb5780633b878c2214610204575b600080fd5b603454610186906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101866004600360981b0181565b6101cf6101bf366004611231565b630a85bd0160e11b949350505050565b6040516001600160e01b0319909116815260200161019a565b603354610186906001600160a01b031681565b61018661202081565b61018661101081565b61022061021b3660046112df565b6103e2565b005b603554610186906001600160a01b031681565b6101866002600160a01b0381565b6101866004600160991b0181565b61025a61138881565b60405190815260200161019a565b61018661027636600461130b565b6037602052600090815260409020546001600160a01b031681565b61025a61520881565b61025a620249f081565b61025a7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b603654610186906001600160a01b031681565b61025a7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b61025a7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61025a7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61018661203081565b61022061036a36600461132f565b6103f1565b61022061037d3660046113b7565b6105d1565b61018661039036600461130b565b6105e1565b61025a7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102206103ca3660046113f8565b61093a565b6102206103dd36600461149f565b610a97565b6103ed823383610af5565b5050565b6034546001600160a01b031633146104695760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b60648201526084015b60405180910390fd5b6035546001600160a01b038481169116146104e05760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c604482015270595f4348494c445f50524544494341544560781b6064820152608401610460565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961050f602060008486611521565b6105189161154b565b036105375761053261052d8260208186611521565b610c74565b6105cb565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed2610566602060008486611521565b61056f9161154b565b0361057e576105328282610d72565b60405162461bcd60e51b815260206004820152602e6024820152600080516020611a3a83398151915260448201526d414c49445f5349474e415455524560901b6064820152608401610460565b50505050565b6105dc838383610af5565b505050565b60006001600160a01b03821661063a5760405162461bcd60e51b815260206004820152602a6024820152600080516020611a3a83398151915260448201526920a624a22faa27a5a2a760b11b6064820152608401610460565b6001600160a01b0382811660009081526037602052604090205416156106b65760405162461bcd60e51b815260206004820152602b60248201527f526f6f744d696e7461626c654552433732315072656469636174653a20414c5260448201526a1150511657d3505414115160aa1b6064820152608401610460565b6035546036546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261076492911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0385811660008181526037602052604080822080546001600160a01b03191686861617905560335481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa1580156107fc573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610824919081019061158e565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610862573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261088a919081019061158e565b60405160200161089d9493929190611630565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108c9929190611677565b600060405180830381600087803b1580156108e357600080fd5b505af11580156108f7573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b031461097e5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610460565b600054610100900460ff161580801561099e5750600054600160ff909116105b806109b85750303b1580156109b8575060005460ff166001145b610a1b5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610460565b6000805460ff191660011790558015610a3e576000805461ff0019166101001790555b610a4a85858585610eb3565b8015610a90576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610ae85760405162461bcd60e51b815260206004820152602b6024820152600080516020611a3a83398151915260448201526a082989288be988a9c8ea8960ab1b6064820152608401610460565b610a908585858585610faf565b6000610b0084611165565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610b33903390309087906004016116a3565b600060405180830381600087803b158015610b4d57600080fd5b505af1158015610b61573d6000803e3d6000fd5b5050603354603554604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935293841695506316f198319450610bf1939092169160c401611677565b600060405180830381600087803b158015610c0b57600080fd5b505af1158015610c1f573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917fe3abb9ec195b50242582cc6cb7abc990ac26439b9ed7635ed72f7bd720e7477a910160405180910390a46105cb565b6000808080610c85858701876116c7565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610cb857610cb8611718565b604051632142170760e11b81526001600160a01b038616906342842e0e90610ce8903090879087906004016116a3565b600060405180830381600087803b158015610d0257600080fd5b505af1158015610d16573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f80afffd84aa825dd9b3c1ba262eb55eef58f78616634437a367a263f3c48fe3d91015b60405180910390a450505050505050565b6000808080610d83858701876117b7565b6001600160a01b03808516600090815260376020526040902054949950929750909550935016905080610db857610db8611718565b60005b8251811015610e6357856001600160a01b03166342842e0e30868481518110610de657610de66118a9565b6020026020010151868581518110610e0057610e006118a9565b60200260200101516040518463ffffffff1660e01b8152600401610e26939291906116a3565b600060405180830381600087803b158015610e4057600080fd5b505af1158015610e54573d6000803e3d6000fd5b50505050806001019050610dbb565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167ff64537485d843fa8a1f4354cb9937954c64282de0828be9f096355006222186b8686604051610d619291906118bf565b6001600160a01b03841615801590610ed357506001600160a01b03831615155b8015610ee757506001600160a01b03821615155b8015610efb57506001600160a01b03811615155b610f5f5760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c654552433732315072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b6064820152608401610460565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000610fba86611165565b905060005b8281101561104c57866001600160a01b03166342842e0e3330878786818110610fea57610fea6118a9565b905060200201356040518463ffffffff1660e01b815260040161100f939291906116a3565b600060405180830381600087803b15801561102957600080fd5b505af115801561103d573d6000803e3d6000fd5b50505050806001019050610fbf565b506033546035546040516001600160a01b03928316926316f198319216906110a4907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c906020016119be565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016110d0929190611677565b600060405180830381600087803b1580156110ea57600080fd5b505af11580156110fe573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f0ca5d99e0f7e7651c00c76347baa68a333790cbc9fb039a10843d1bd61f578c5888888886040516111559493929190611a12565b60405180910390a4505050505050565b6001600160a01b0380821660009081526037602052604090205416806111915761118e826105e1565b90505b6001600160a01b0381166111a7576111a7611718565b919050565b6001600160a01b03811681146111c157600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611202576112026111c4565b604052919050565b60006001600160401b03821115611223576112236111c4565b50601f01601f191660200190565b6000806000806080858703121561124757600080fd5b8435611252816111ac565b93506020850135611262816111ac565b92506040850135915060608501356001600160401b0381111561128457600080fd5b8501601f8101871361129557600080fd5b80356112a86112a38261120a565b6111da565b8181528860208385010111156112bd57600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b600080604083850312156112f257600080fd5b82356112fd816111ac565b946020939093013593505050565b60006020828403121561131d57600080fd5b8135611328816111ac565b9392505050565b6000806000806060858703121561134557600080fd5b843593506020850135611357816111ac565b925060408501356001600160401b038082111561137357600080fd5b818701915087601f83011261138757600080fd5b81358181111561139657600080fd5b8860208285010111156113a857600080fd5b95989497505060200194505050565b6000806000606084860312156113cc57600080fd5b83356113d7816111ac565b925060208401356113e7816111ac565b929592945050506040919091013590565b6000806000806080858703121561140e57600080fd5b8435611419816111ac565b93506020850135611429816111ac565b92506040850135611439816111ac565b91506060850135611449816111ac565b939692955090935050565b60008083601f84011261146657600080fd5b5081356001600160401b0381111561147d57600080fd5b6020830191508360208260051b850101111561149857600080fd5b9250929050565b6000806000806000606086880312156114b757600080fd5b85356114c2816111ac565b945060208601356001600160401b03808211156114de57600080fd5b6114ea89838a01611454565b9096509450604088013591508082111561150357600080fd5b5061151088828901611454565b969995985093965092949392505050565b6000808585111561153157600080fd5b8386111561153e57600080fd5b5050820193919092039150565b8035602083101561156457600019602084900360031b1b165b92915050565b60005b8381101561158557818101518382015260200161156d565b50506000910152565b6000602082840312156115a057600080fd5b81516001600160401b038111156115b657600080fd5b8201601f810184136115c757600080fd5b80516115d56112a38261120a565b8181528560208385010111156115ea57600080fd5b6115fb82602083016020860161156a565b95945050505050565b6000815180845261161c81602086016020860161156a565b601f01601f19169290920160200192915050565b8481526001600160a01b038416602082015260806040820181905260009061165a90830185611604565b828103606084015261166c8185611604565b979650505050505050565b6001600160a01b038316815260406020820181905260009061169b90830184611604565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600080600080608085870312156116dd57600080fd5b84356116e8816111ac565b935060208501356116f8816111ac565b92506040850135611708816111ac565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611747576117476111c4565b5060051b60200190565b600082601f83011261176257600080fd5b813560206117726112a38361172e565b82815260059290921b8401810191818101908684111561179157600080fd5b8286015b848110156117ac5780358352918301918301611795565b509695505050505050565b600080600080600060a086880312156117cf57600080fd5b853594506020808701356117e2816111ac565b945060408701356117f2816111ac565b935060608701356001600160401b038082111561180e57600080fd5b818901915089601f83011261182257600080fd5b81356118306112a38261172e565b81815260059190911b8301840190848101908c83111561184f57600080fd5b938501935b82851015611876578435611867816111ac565b82529385019390850190611854565b96505050608089013592508083111561188e57600080fd5b505061189c88828901611751565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b828110156119015781516001600160a01b0316845292840192908401906001016118dc565b5050508381038285015284518082528583019183019060005b818110156119365783518352928401929184019160010161191a565b5090979650505050505050565b8183526000602080850194508260005b85811015611981578135611966816111ac565b6001600160a01b031687529582019590820190600101611953565b509495945050505050565b81835260006001600160fb1b038311156119a557600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906119f19083018688611943565b8281036080840152611a0481858761198c565b9a9950505050505050505050565b604081526000611a26604083018688611943565b828103602084015261166c81858761198c56fe526f6f744d696e7461626c654552433732315072656469636174653a20494e56a2646970667358221220d56687504a65fbdf30d6fa40bc1481712f630a02ef2aa4dc136cf9be78742d2364736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RootMintableERC721PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC721PredicateAccessList","sourceName":"contracts/child/RootMintableERC721PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2MintableERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2MintableERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2MintableERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2MintableERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612231806100206000396000f3fe608060405234801561001057600080fd5b50600436106101e65760003560e01c8063b17680651161010a578063e0563ab1116100ad578063f2fde38b1161007c578063f2fde38b14610466578063f4a120f714610479578063f64512551461048c578063f8c8765e146104b3578063ff6f870c146104c657600080fd5b8063e0563ab114610426578063e30c39781461042f578063eeb4994514610440578063f213159c1461045357600080fd5b8063b17680651461033e578063b68ad1e414610365578063c1225a2014610378578063c5ac2b1c1461038b578063c5e4683a146103b2578063d41f1771146103c5578063d7c9e3ec146103ec578063d8dd17731461041357600080fd5b806351351d531161018d57806379ba50971161015c57806379ba5097146102e85780637efab4f5146102f05780638da5cb5b1461031a578063947287cf1461032b57806397e5230d1461033457600080fd5b806351351d53146102ad57806355b01e4d146102bb5780635ea5df79146102c9578063715018a6146102e057600080fd5b806305dc2e8f146101eb57806307b3e2521461021b578063150b7a02146102295780631bc114ba14610260578063284017f5146102735780633b878c221461027c57806347e7ef24146102855780634fdca69d1461029a575b600080fd5b60fd546101fe906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101fe6004600360981b0181565b61024761023736600461186f565b630a85bd0160e11b949350505050565b6040516001600160e01b03199091168152602001610212565b60fc546101fe906001600160a01b031681565b6101fe61202081565b6101fe61101081565b61029861029336600461191d565b6104d9565b005b60fe546101fe906001600160a01b031681565b6101fe6002600160a01b0381565b6101fe6004600160991b0181565b6102d261138881565b604051908152602001610212565b6102986104e8565b6102986104fc565b6101fe6102fe366004611949565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101fe565b6102d261520881565b6102d2620249f081565b6102d27f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101fe906001600160a01b031681565b61029861038636600461197d565b61057b565b6102d27faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6102986103c036600461197d565b6105ca565b6102d27f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102d27f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b610298610421366004611998565b610611565b6101fe61203081565b6065546001600160a01b03166101fe565b61029861044e366004611a2a565b610732565b610298610461366004611ab2565b61090d565b610298610474366004611949565b61091d565b6101fe610487366004611949565b61098e565b6102d27f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102986104c1366004611af3565b610ce9565b6102986104d4366004611b9a565b610de2565b6104e4823383610e40565b5050565b6104f0610fc7565b6104fa6000611021565b565b60655433906001600160a01b0316811461056f5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61057881611021565b50565b610583610fc7565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6105d2610fc7565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146106385760405163973d02cb60e01b815260040161056690611c1c565b600054610100900460ff16158080156106585750600054600160ff909116105b806106725750303b158015610672575060005460ff166001145b61068e5760405162461bcd60e51b815260040161056690611c40565b6000805460ff1916600117905580156106b1576000805461ff0019166101001790555b6106bd8888888861103a565b60c9805461ffff191685151561ff00191617610100851515021790556106e282611021565b8015610728576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107a55760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b6064820152608401610566565b60fe546001600160a01b0384811691161461081c5760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c604482015270595f4348494c445f50524544494341544560781b6064820152608401610566565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961084b602060008486611c8e565b61085491611cb8565b036108735761086e6108698260208186611c8e565b611136565b610907565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26108a2602060008486611c8e565b6108ab91611cb8565b036108ba5761086e8282611235565b60405162461bcd60e51b815260206004820152602e60248201526000805160206121dc83398151915260448201526d414c49445f5349474e415455524560901b6064820152608401610566565b50505050565b610918838383610e40565b505050565b610925610fc7565b606580546001600160a01b0383166001600160a01b031990911681179091556109566033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b0382166109e75760405162461bcd60e51b815260206004820152602a60248201526000805160206121dc83398151915260448201526920a624a22faa27a5a2a760b11b6064820152608401610566565b6001600160a01b03828116600090815261010060205260409020541615610a645760405162461bcd60e51b815260206004820152602b60248201527f526f6f744d696e7461626c654552433732315072656469636174653a20414c5260448201526a1150511657d3505414115160aa1b6064820152608401610566565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692600092610b1292911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b038581166000818152610100602052604080822080546001600160a01b03191686861617905560fc5481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610bab573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610bd39190810190611cfb565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610c11573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610c399190810190611cfb565b604051602001610c4c9493929190611d9d565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610c78929190611de4565b600060405180830381600087803b158015610c9257600080fd5b505af1158015610ca6573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b0314610d105760405163973d02cb60e01b815260040161056690611c1c565b600054610100900460ff1615808015610d305750600054600160ff909116105b80610d4a5750303b158015610d4a575060005460ff166001145b610d665760405162461bcd60e51b815260040161056690611c40565b6000805460ff191660011790558015610d89576000805461ff0019166101001790555b610d958585858561103a565b8015610ddb576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610e335760405162461bcd60e51b815260206004820152602b60248201526000805160206121dc83398151915260448201526a082989288be988a9c8ea8960ab1b6064820152608401610566565b610ddb8585858585611377565b610e48611535565b6000610e538461153d565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610e8690339030908790600401611e10565b600060405180830381600087803b158015610ea057600080fd5b505af1158015610eb4573d6000803e3d6000fd5b505060fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935293841695506316f198319450610f44939092169160c401611de4565b600060405180830381600087803b158015610f5e57600080fd5b505af1158015610f72573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917fe3abb9ec195b50242582cc6cb7abc990ac26439b9ed7635ed72f7bd720e7477a910160405180910390a4610907565b6033546001600160a01b031633146104fa5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610566565b606580546001600160a01b031916905561057881611585565b6001600160a01b0384161580159061105a57506001600160a01b03831615155b801561106e57506001600160a01b03821615155b801561108257506001600160a01b03811615155b6110e65760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c654552433732315072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b6064820152608401610566565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b600080808061114785870187611e34565b6001600160a01b03808516600090815261010060205260409020549498509296509094509250168061117b5761117b611e85565b604051632142170760e11b81526001600160a01b038616906342842e0e906111ab90309087908790600401611e10565b600060405180830381600087803b1580156111c557600080fd5b505af11580156111d9573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f80afffd84aa825dd9b3c1ba262eb55eef58f78616634437a367a263f3c48fe3d91015b60405180910390a450505050505050565b600080808061124685870187611f24565b6001600160a01b038085166000908152610100602052604090205494995092975090955093501690508061127c5761127c611e85565b60005b825181101561132757856001600160a01b03166342842e0e308684815181106112aa576112aa612016565b60200260200101518685815181106112c4576112c4612016565b60200260200101516040518463ffffffff1660e01b81526004016112ea93929190611e10565b600060405180830381600087803b15801561130457600080fd5b505af1158015611318573d6000803e3d6000fd5b5050505080600101905061127f565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167ff64537485d843fa8a1f4354cb9937954c64282de0828be9f096355006222186b868660405161122492919061202c565b61137f611535565b600061138a8661153d565b905060005b8281101561141c57866001600160a01b03166342842e0e33308787868181106113ba576113ba612016565b905060200201356040518463ffffffff1660e01b81526004016113df93929190611e10565b600060405180830381600087803b1580156113f957600080fd5b505af115801561140d573d6000803e3d6000fd5b5050505080600101905061138f565b5060fc5460fe546040516001600160a01b03928316926316f19831921690611474907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c9060200161212b565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016114a0929190611de4565b600060405180830381600087803b1580156114ba57600080fd5b505af11580156114ce573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f0ca5d99e0f7e7651c00c76347baa68a333790cbc9fb039a10843d1bd61f578c588888888604051611525949392919061217f565b60405180910390a4505050505050565b6104fa6115d7565b6001600160a01b0380821660009081526101006020526040902054168061156a576115678261098e565b90505b6001600160a01b03811661158057611580611e85565b919050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff16156116e257604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161163991906121a6565b6000604051808303818686fa925050503d8060008114611675576040519150601f19603f3d011682016040523d82523d6000602084013e61167a565b606091505b509150915081801561169f575060008180602001905181019061169d91906121c2565b115b6116df5760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b6044820152606401610566565b50505b60c954610100900460ff16156104fa57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161174991906121a6565b6000604051808303818686fa925050503d8060008114611785576040519150601f19603f3d011682016040523d82523d6000602084013e61178a565b606091505b50915091508180156117b05750808060200190518101906117ab91906121c2565b600114155b6104e45760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b6044820152606401610566565b6001600160a01b038116811461057857600080fd5b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171561184057611840611802565b604052919050565b60006001600160401b0382111561186157611861611802565b50601f01601f191660200190565b6000806000806080858703121561188557600080fd5b8435611890816117ed565b935060208501356118a0816117ed565b92506040850135915060608501356001600160401b038111156118c257600080fd5b8501601f810187136118d357600080fd5b80356118e66118e182611848565b611818565b8181528860208385010111156118fb57600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b6000806040838503121561193057600080fd5b823561193b816117ed565b946020939093013593505050565b60006020828403121561195b57600080fd5b8135611966816117ed565b9392505050565b8035801515811461158057600080fd5b60006020828403121561198f57600080fd5b6119668261196d565b600080600080600080600060e0888a0312156119b357600080fd5b87356119be816117ed565b965060208801356119ce816117ed565b955060408801356119de816117ed565b945060608801356119ee816117ed565b93506119fc6080890161196d565b9250611a0a60a0890161196d565b915060c0880135611a1a816117ed565b8091505092959891949750929550565b60008060008060608587031215611a4057600080fd5b843593506020850135611a52816117ed565b925060408501356001600160401b0380821115611a6e57600080fd5b818701915087601f830112611a8257600080fd5b813581811115611a9157600080fd5b886020828501011115611aa357600080fd5b95989497505060200194505050565b600080600060608486031215611ac757600080fd5b8335611ad2816117ed565b92506020840135611ae2816117ed565b929592945050506040919091013590565b60008060008060808587031215611b0957600080fd5b8435611b14816117ed565b93506020850135611b24816117ed565b92506040850135611b34816117ed565b91506060850135611b44816117ed565b939692955090935050565b60008083601f840112611b6157600080fd5b5081356001600160401b03811115611b7857600080fd5b6020830191508360208260051b8501011115611b9357600080fd5b9250929050565b600080600080600060608688031215611bb257600080fd5b8535611bbd816117ed565b945060208601356001600160401b0380821115611bd957600080fd5b611be589838a01611b4f565b90965094506040880135915080821115611bfe57600080fd5b50611c0b88828901611b4f565b969995985093965092949392505050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611c9e57600080fd5b83861115611cab57600080fd5b5050820193919092039150565b80356020831015611cd157600019602084900360031b1b165b92915050565b60005b83811015611cf2578181015183820152602001611cda565b50506000910152565b600060208284031215611d0d57600080fd5b81516001600160401b03811115611d2357600080fd5b8201601f81018413611d3457600080fd5b8051611d426118e182611848565b818152856020838501011115611d5757600080fd5b611d68826020830160208601611cd7565b95945050505050565b60008151808452611d89816020860160208601611cd7565b601f01601f19169290920160200192915050565b8481526001600160a01b0384166020820152608060408201819052600090611dc790830185611d71565b8281036060840152611dd98185611d71565b979650505050505050565b6001600160a01b0383168152604060208201819052600090611e0890830184611d71565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008060008060808587031215611e4a57600080fd5b8435611e55816117ed565b93506020850135611e65816117ed565b92506040850135611e75816117ed565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611eb457611eb4611802565b5060051b60200190565b600082601f830112611ecf57600080fd5b81356020611edf6118e183611e9b565b82815260059290921b84018101918181019086841115611efe57600080fd5b8286015b84811015611f195780358352918301918301611f02565b509695505050505050565b600080600080600060a08688031215611f3c57600080fd5b85359450602080870135611f4f816117ed565b94506040870135611f5f816117ed565b935060608701356001600160401b0380821115611f7b57600080fd5b818901915089601f830112611f8f57600080fd5b8135611f9d6118e182611e9b565b81815260059190911b8301840190848101908c831115611fbc57600080fd5b938501935b82851015611fe3578435611fd4816117ed565b82529385019390850190611fc1565b965050506080890135925080831115611ffb57600080fd5b505061200988828901611ebe565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b8281101561206e5781516001600160a01b031684529284019290840190600101612049565b5050508381038285015284518082528583019183019060005b818110156120a357835183529284019291840191600101612087565b5090979650505050505050565b8183526000602080850194508260005b858110156120ee5781356120d3816117ed565b6001600160a01b0316875295820195908201906001016120c0565b509495945050505050565b81835260006001600160fb1b0383111561211257600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a06060820181905260009061215e90830186886120b0565b82810360808401526121718185876120f9565b9a9950505050505050505050565b6040815260006121936040830186886120b0565b8281036020840152611dd98185876120f9565b600082516121b8818460208701611cd7565b9190910192915050565b6000602082840312156121d457600080fd5b505191905056fe526f6f744d696e7461626c654552433732315072656469636174653a20494e56a26469706673582212204063e808f9818c931a3cdbf2406d8b4f218ddd313bef99b78b2b8455373be0c864736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101e65760003560e01c8063b17680651161010a578063e0563ab1116100ad578063f2fde38b1161007c578063f2fde38b14610466578063f4a120f714610479578063f64512551461048c578063f8c8765e146104b3578063ff6f870c146104c657600080fd5b8063e0563ab114610426578063e30c39781461042f578063eeb4994514610440578063f213159c1461045357600080fd5b8063b17680651461033e578063b68ad1e414610365578063c1225a2014610378578063c5ac2b1c1461038b578063c5e4683a146103b2578063d41f1771146103c5578063d7c9e3ec146103ec578063d8dd17731461041357600080fd5b806351351d531161018d57806379ba50971161015c57806379ba5097146102e85780637efab4f5146102f05780638da5cb5b1461031a578063947287cf1461032b57806397e5230d1461033457600080fd5b806351351d53146102ad57806355b01e4d146102bb5780635ea5df79146102c9578063715018a6146102e057600080fd5b806305dc2e8f146101eb57806307b3e2521461021b578063150b7a02146102295780631bc114ba14610260578063284017f5146102735780633b878c221461027c57806347e7ef24146102855780634fdca69d1461029a575b600080fd5b60fd546101fe906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101fe6004600360981b0181565b61024761023736600461186f565b630a85bd0160e11b949350505050565b6040516001600160e01b03199091168152602001610212565b60fc546101fe906001600160a01b031681565b6101fe61202081565b6101fe61101081565b61029861029336600461191d565b6104d9565b005b60fe546101fe906001600160a01b031681565b6101fe6002600160a01b0381565b6101fe6004600160991b0181565b6102d261138881565b604051908152602001610212565b6102986104e8565b6102986104fc565b6101fe6102fe366004611949565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101fe565b6102d261520881565b6102d2620249f081565b6102d27f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101fe906001600160a01b031681565b61029861038636600461197d565b61057b565b6102d27faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6102986103c036600461197d565b6105ca565b6102d27f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102d27f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b610298610421366004611998565b610611565b6101fe61203081565b6065546001600160a01b03166101fe565b61029861044e366004611a2a565b610732565b610298610461366004611ab2565b61090d565b610298610474366004611949565b61091d565b6101fe610487366004611949565b61098e565b6102d27f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102986104c1366004611af3565b610ce9565b6102986104d4366004611b9a565b610de2565b6104e4823383610e40565b5050565b6104f0610fc7565b6104fa6000611021565b565b60655433906001600160a01b0316811461056f5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61057881611021565b50565b610583610fc7565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6105d2610fc7565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146106385760405163973d02cb60e01b815260040161056690611c1c565b600054610100900460ff16158080156106585750600054600160ff909116105b806106725750303b158015610672575060005460ff166001145b61068e5760405162461bcd60e51b815260040161056690611c40565b6000805460ff1916600117905580156106b1576000805461ff0019166101001790555b6106bd8888888861103a565b60c9805461ffff191685151561ff00191617610100851515021790556106e282611021565b8015610728576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107a55760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b6064820152608401610566565b60fe546001600160a01b0384811691161461081c5760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c604482015270595f4348494c445f50524544494341544560781b6064820152608401610566565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961084b602060008486611c8e565b61085491611cb8565b036108735761086e6108698260208186611c8e565b611136565b610907565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26108a2602060008486611c8e565b6108ab91611cb8565b036108ba5761086e8282611235565b60405162461bcd60e51b815260206004820152602e60248201526000805160206121dc83398151915260448201526d414c49445f5349474e415455524560901b6064820152608401610566565b50505050565b610918838383610e40565b505050565b610925610fc7565b606580546001600160a01b0383166001600160a01b031990911681179091556109566033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b0382166109e75760405162461bcd60e51b815260206004820152602a60248201526000805160206121dc83398151915260448201526920a624a22faa27a5a2a760b11b6064820152608401610566565b6001600160a01b03828116600090815261010060205260409020541615610a645760405162461bcd60e51b815260206004820152602b60248201527f526f6f744d696e7461626c654552433732315072656469636174653a20414c5260448201526a1150511657d3505414115160aa1b6064820152608401610566565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692600092610b1292911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b038581166000818152610100602052604080822080546001600160a01b03191686861617905560fc5481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610bab573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610bd39190810190611cfb565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610c11573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610c399190810190611cfb565b604051602001610c4c9493929190611d9d565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610c78929190611de4565b600060405180830381600087803b158015610c9257600080fd5b505af1158015610ca6573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b0314610d105760405163973d02cb60e01b815260040161056690611c1c565b600054610100900460ff1615808015610d305750600054600160ff909116105b80610d4a5750303b158015610d4a575060005460ff166001145b610d665760405162461bcd60e51b815260040161056690611c40565b6000805460ff191660011790558015610d89576000805461ff0019166101001790555b610d958585858561103a565b8015610ddb576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610e335760405162461bcd60e51b815260206004820152602b60248201526000805160206121dc83398151915260448201526a082989288be988a9c8ea8960ab1b6064820152608401610566565b610ddb8585858585611377565b610e48611535565b6000610e538461153d565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610e8690339030908790600401611e10565b600060405180830381600087803b158015610ea057600080fd5b505af1158015610eb4573d6000803e3d6000fd5b505060fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935293841695506316f198319450610f44939092169160c401611de4565b600060405180830381600087803b158015610f5e57600080fd5b505af1158015610f72573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917fe3abb9ec195b50242582cc6cb7abc990ac26439b9ed7635ed72f7bd720e7477a910160405180910390a4610907565b6033546001600160a01b031633146104fa5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610566565b606580546001600160a01b031916905561057881611585565b6001600160a01b0384161580159061105a57506001600160a01b03831615155b801561106e57506001600160a01b03821615155b801561108257506001600160a01b03811615155b6110e65760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c654552433732315072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b6064820152608401610566565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b600080808061114785870187611e34565b6001600160a01b03808516600090815261010060205260409020549498509296509094509250168061117b5761117b611e85565b604051632142170760e11b81526001600160a01b038616906342842e0e906111ab90309087908790600401611e10565b600060405180830381600087803b1580156111c557600080fd5b505af11580156111d9573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f80afffd84aa825dd9b3c1ba262eb55eef58f78616634437a367a263f3c48fe3d91015b60405180910390a450505050505050565b600080808061124685870187611f24565b6001600160a01b038085166000908152610100602052604090205494995092975090955093501690508061127c5761127c611e85565b60005b825181101561132757856001600160a01b03166342842e0e308684815181106112aa576112aa612016565b60200260200101518685815181106112c4576112c4612016565b60200260200101516040518463ffffffff1660e01b81526004016112ea93929190611e10565b600060405180830381600087803b15801561130457600080fd5b505af1158015611318573d6000803e3d6000fd5b5050505080600101905061127f565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167ff64537485d843fa8a1f4354cb9937954c64282de0828be9f096355006222186b868660405161122492919061202c565b61137f611535565b600061138a8661153d565b905060005b8281101561141c57866001600160a01b03166342842e0e33308787868181106113ba576113ba612016565b905060200201356040518463ffffffff1660e01b81526004016113df93929190611e10565b600060405180830381600087803b1580156113f957600080fd5b505af115801561140d573d6000803e3d6000fd5b5050505080600101905061138f565b5060fc5460fe546040516001600160a01b03928316926316f19831921690611474907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c9060200161212b565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016114a0929190611de4565b600060405180830381600087803b1580156114ba57600080fd5b505af11580156114ce573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f0ca5d99e0f7e7651c00c76347baa68a333790cbc9fb039a10843d1bd61f578c588888888604051611525949392919061217f565b60405180910390a4505050505050565b6104fa6115d7565b6001600160a01b0380821660009081526101006020526040902054168061156a576115678261098e565b90505b6001600160a01b03811661158057611580611e85565b919050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff16156116e257604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161163991906121a6565b6000604051808303818686fa925050503d8060008114611675576040519150601f19603f3d011682016040523d82523d6000602084013e61167a565b606091505b509150915081801561169f575060008180602001905181019061169d91906121c2565b115b6116df5760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b6044820152606401610566565b50505b60c954610100900460ff16156104fa57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161174991906121a6565b6000604051808303818686fa925050503d8060008114611785576040519150601f19603f3d011682016040523d82523d6000602084013e61178a565b606091505b50915091508180156117b05750808060200190518101906117ab91906121c2565b600114155b6104e45760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b6044820152606401610566565b6001600160a01b038116811461057857600080fd5b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171561184057611840611802565b604052919050565b60006001600160401b0382111561186157611861611802565b50601f01601f191660200190565b6000806000806080858703121561188557600080fd5b8435611890816117ed565b935060208501356118a0816117ed565b92506040850135915060608501356001600160401b038111156118c257600080fd5b8501601f810187136118d357600080fd5b80356118e66118e182611848565b611818565b8181528860208385010111156118fb57600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b6000806040838503121561193057600080fd5b823561193b816117ed565b946020939093013593505050565b60006020828403121561195b57600080fd5b8135611966816117ed565b9392505050565b8035801515811461158057600080fd5b60006020828403121561198f57600080fd5b6119668261196d565b600080600080600080600060e0888a0312156119b357600080fd5b87356119be816117ed565b965060208801356119ce816117ed565b955060408801356119de816117ed565b945060608801356119ee816117ed565b93506119fc6080890161196d565b9250611a0a60a0890161196d565b915060c0880135611a1a816117ed565b8091505092959891949750929550565b60008060008060608587031215611a4057600080fd5b843593506020850135611a52816117ed565b925060408501356001600160401b0380821115611a6e57600080fd5b818701915087601f830112611a8257600080fd5b813581811115611a9157600080fd5b886020828501011115611aa357600080fd5b95989497505060200194505050565b600080600060608486031215611ac757600080fd5b8335611ad2816117ed565b92506020840135611ae2816117ed565b929592945050506040919091013590565b60008060008060808587031215611b0957600080fd5b8435611b14816117ed565b93506020850135611b24816117ed565b92506040850135611b34816117ed565b91506060850135611b44816117ed565b939692955090935050565b60008083601f840112611b6157600080fd5b5081356001600160401b03811115611b7857600080fd5b6020830191508360208260051b8501011115611b9357600080fd5b9250929050565b600080600080600060608688031215611bb257600080fd5b8535611bbd816117ed565b945060208601356001600160401b0380821115611bd957600080fd5b611be589838a01611b4f565b90965094506040880135915080821115611bfe57600080fd5b50611c0b88828901611b4f565b969995985093965092949392505050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611c9e57600080fd5b83861115611cab57600080fd5b5050820193919092039150565b80356020831015611cd157600019602084900360031b1b165b92915050565b60005b83811015611cf2578181015183820152602001611cda565b50506000910152565b600060208284031215611d0d57600080fd5b81516001600160401b03811115611d2357600080fd5b8201601f81018413611d3457600080fd5b8051611d426118e182611848565b818152856020838501011115611d5757600080fd5b611d68826020830160208601611cd7565b95945050505050565b60008151808452611d89816020860160208601611cd7565b601f01601f19169290920160200192915050565b8481526001600160a01b0384166020820152608060408201819052600090611dc790830185611d71565b8281036060840152611dd98185611d71565b979650505050505050565b6001600160a01b0383168152604060208201819052600090611e0890830184611d71565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008060008060808587031215611e4a57600080fd5b8435611e55816117ed565b93506020850135611e65816117ed565b92506040850135611e75816117ed565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611eb457611eb4611802565b5060051b60200190565b600082601f830112611ecf57600080fd5b81356020611edf6118e183611e9b565b82815260059290921b84018101918181019086841115611efe57600080fd5b8286015b84811015611f195780358352918301918301611f02565b509695505050505050565b600080600080600060a08688031215611f3c57600080fd5b85359450602080870135611f4f816117ed565b94506040870135611f5f816117ed565b935060608701356001600160401b0380821115611f7b57600080fd5b818901915089601f830112611f8f57600080fd5b8135611f9d6118e182611e9b565b81815260059190911b8301840190848101908c831115611fbc57600080fd5b938501935b82851015611fe3578435611fd4816117ed565b82529385019390850190611fc1565b965050506080890135925080831115611ffb57600080fd5b505061200988828901611ebe565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b8281101561206e5781516001600160a01b031684529284019290840190600101612049565b5050508381038285015284518082528583019183019060005b818110156120a357835183529284019291840191600101612087565b5090979650505050505050565b8183526000602080850194508260005b858110156120ee5781356120d3816117ed565b6001600160a01b0316875295820195908201906001016120c0565b509495945050505050565b81835260006001600160fb1b0383111561211257600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a06060820181905260009061215e90830186886120b0565b82810360808401526121718185876120f9565b9a9950505050505050505050565b6040815260006121936040830186886120b0565b8281036020840152611dd98185876120f9565b600082516121b8818460208701611cd7565b9190910192915050565b6000602082840312156121d457600080fd5b505191905056fe526f6f744d696e7461626c654552433732315072656469636174653a20494e56a26469706673582212204063e808f9818c931a3cdbf2406d8b4f218ddd313bef99b78b2b8455373be0c864736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildERC1155Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC1155","sourceName":"contracts/child/ChildERC1155.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"userAddress","type":"address"},{"indexed":false,"internalType":"address","name":"relayerAddress","type":"address"},{"indexed":false,"internalType":"bytes","name":"functionSignature","type":"bytes"}],"name":"MetaTransactionExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"TransferBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferSingle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"value","type":"string"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"URI","type":"event"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"balanceOfBatch","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"burnBatch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"userAddress","type":"address"},{"internalType":"bytes","name":"functionSignature","type":"bytes"},{"internalType":"bytes32","name":"sigR","type":"bytes32"},{"internalType":"bytes32","name":"sigS","type":"bytes32"},{"internalType":"uint8","name":"sigV","type":"uint8"}],"name":"executeMetaTransaction","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getNonce","outputs":[{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"rootToken_","type":"address"},{"internalType":"string","name":"uri_","type":"string"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"offset","type":"uint256"}],"name":"invalidateNext","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"mintBatch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rootToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeBatchTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"uri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612b8b806100206000396000f3fe608060405234801561001057600080fd5b50600436106101155760003560e01c806357128683116100a2578063e619870511610071578063e619870514610279578063e985e9c51461028b578063f242432a146102c7578063f399e22e146102da578063f5298aca146102ed57600080fd5b8063571286831461022d5780636b20c454146102405780639b77ef1114610253578063a22cb4651461026657600080fd5b8063156e29f6116100e9578063156e29f6146101965780631f2d0065146101a95780632d0335ab146101cf5780632eb2c2d6146101f85780634e1273f41461020d57600080fd5b8062fdd58e1461011a57806301ffc9a7146101405780630c53c51c146101635780630e89341c14610183575b600080fd5b61012d610128366004611cd5565b610300565b6040519081526020015b60405180910390f35b61015361014e366004611d15565b61039b565b6040519015158152602001610137565b610176610171366004611d7a565b6103eb565b6040516101379190611e49565b610176610191366004611e5c565b6106c9565b6101536101a4366004611e75565b61075d565b610103546001600160a01b03165b6040516001600160a01b039091168152602001610137565b61012d6101dd366004611ea8565b6001600160a01b031660009081526038602052604090205490565b61020b61020636600461200c565b6107b0565b005b61022061021b3660046120b5565b61080e565b60405161013791906121ba565b61015361023b366004612211565b610937565b61015361024e3660046122aa565b610a53565b61020b610261366004611e5c565b610afb565b61020b61027436600461232a565b610b22565b610102546001600160a01b03166101b7565b610153610299366004612366565b6001600160a01b03918216600090815260d16020908152604080832093909416825291909152205460ff1690565b61020b6102d5366004612399565b610b38565b61020b6102e83660046123fd565b610b8f565b6101536102fb366004611e75565b610da5565b60006001600160a01b0383166103705760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b50600081815260d0602090815260408083206001600160a01b03861684529091529020545b92915050565b60006001600160e01b03198216636cdb3d1360e11b14806103cc57506001600160e01b031982166303a24d0760e21b145b8061039557506301ffc9a760e01b6001600160e01b0319831614610395565b6060600061042e87878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610dde92505050565b90506001600160e01b03196000358116908216036104b45760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f640000006064820152608401610367565b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506105258982888888610df9565b61057b5760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b6064820152608401610367565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d6040516020016105d09392919061244f565b60408051601f19818403018152908290526105ea91612475565b6000604051808303816000865af19150503d8060008114610627576040519150601f19603f3d011682016040523d82523d6000602084013e61062c565b606091505b50915091508161067e5760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610367565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c6040516106b39493929190612491565b60405180910390a19a9950505050505050505050565b606060d280546106d8906124dd565b80601f0160208091040260200160405190810160405280929190818152602001828054610704906124dd565b80156107515780601f1061072657610100808354040283529160200191610751565b820191906000526020600020905b81548152906001019060200180831161073457829003601f168201915b50505050509050919050565b610102546000906001600160a01b0316331461078b5760405162461bcd60e51b815260040161036790612517565b6107a684848460405180602001604052806000815250610ed5565b5060019392505050565b6107b8610fe4565b6001600160a01b0316856001600160a01b031614806107de57506107de85610299610fe4565b6107fa5760405162461bcd60e51b81526004016103679061255c565b6108078585858585610ff3565b5050505050565b606081518351146108735760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610367565b600083516001600160401b0381111561088e5761088e611ec3565b6040519080825280602002602001820160405280156108b7578160200160208202803683370190505b50905060005b845181101561092f576109028582815181106108db576108db6125aa565b60200260200101518583815181106108f5576108f56125aa565b6020026020010151610300565b828281518110610914576109146125aa565b6020908102919091010152610928816125d6565b90506108bd565b509392505050565b610102546000906001600160a01b031633146109655760405162461bcd60e51b815260040161036790612517565b85848114801561097457508083145b6109c05760405162461bcd60e51b815260206004820181905260248201527f4368696c64455243313135353a206172726179206c656e206d69736d617463686044820152606401610367565b60005b81811015610a4457610a3c8989838181106109e0576109e06125aa565b90506020020160208101906109f59190611ea8565b888884818110610a0757610a076125aa565b90506020020135878785818110610a2057610a206125aa565b9050602002013560405180602001604052806000815250610ed5565b6001016109c3565b50600198975050505050505050565b610102546000906001600160a01b03163314610a815760405162461bcd60e51b815260040161036790612517565b610aef8686868080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808a0282810182019093528982529093508992508891829185019084908082843760009201919091525061119d92505050565b50600195945050505050565b3360009081526038602052604081208054839290610b1a9084906125ef565b909155505050565b610b34610b2d610fe4565b8383611334565b5050565b610b40610fe4565b6001600160a01b0316856001600160a01b03161480610b665750610b6685610299610fe4565b610b825760405162461bcd60e51b81526004016103679061255c565b6108078585858585611414565b606b54610100900460ff1615808015610baf5750606b54600160ff909116105b80610bc95750303b158015610bc95750606b5460ff166001145b610c2c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610367565b606b805460ff191660011790558015610c4f57606b805461ff0019166101001790555b6001600160a01b038416610ca55760405162461bcd60e51b815260206004820181905260248201527f4368696c64455243313135353a204241445f494e495449414c495a4154494f4e6044820152606401610367565b61010380546001600160a01b0386166001600160a01b031991821617909155610102805490911633179055604080516020601f8501819004810282018101909252838152610d0d91859085908190840183828082843760009201919091525061153b92505050565b610d59610d22856001600160a01b031661156e565b604051602001610d329190612602565b60408051601f1981840301815282820190915260018252603160f81b602083015290611584565b8015610d9f57606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050565b610102546000906001600160a01b03163314610dd35760405162461bcd60e51b815260040161036790612517565b6107a68484846115f0565b60008151600003610df157506000919050565b506020015190565b6000806001610e0f610e0a886116f0565b61176d565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa158015610e5d573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610eb45760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610367565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6001600160a01b038416610f355760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610367565b6000610f3f610fe4565b90506000610f4c8561179a565b90506000610f598561179a565b9050600086815260d0602090815260408083206001600160a01b038b16845290915281208054879290610f8d9084906125ef565b909155505060408051878152602081018790526001600160a01b03808a169260009291871691600080516020612af3833981519152910160405180910390a4610fdb836000898989896117e5565b50505050505050565b6000610fee611940565b905090565b81518351146110145760405162461bcd60e51b815260040161036790612637565b6001600160a01b03841661103a5760405162461bcd60e51b81526004016103679061267f565b6000611044610fe4565b905060005b845181101561112f576000858281518110611066576110666125aa565b602002602001015190506000858381518110611084576110846125aa565b602090810291909101810151600084815260d0835260408082206001600160a01b038e1683529093529190912054909150818110156110d55760405162461bcd60e51b8152600401610367906126c4565b600083815260d0602090815260408083206001600160a01b038e8116855292528083208585039055908b168252812080548492906111149084906125ef565b9250508190555050505080611128906125d6565b9050611049565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb878760405161117f92919061270e565b60405180910390a461119581878787878761199c565b505050505050565b6001600160a01b0383166111c35760405162461bcd60e51b81526004016103679061273c565b80518251146111e45760405162461bcd60e51b815260040161036790612637565b60006111ee610fe4565b604080516020810190915260009052905060005b83518110156112c757600084828151811061121f5761121f6125aa565b60200260200101519050600084838151811061123d5761123d6125aa565b602090810291909101810151600084815260d0835260408082206001600160a01b038c16835290935291909120549091508181101561128e5760405162461bcd60e51b81526004016103679061277f565b600092835260d0602090815260408085206001600160a01b038b16865290915290922091039055806112bf816125d6565b915050611202565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb868660405161131892919061270e565b60405180910390a4604080516020810190915260009052610d9f565b816001600160a01b0316836001600160a01b0316036113a75760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610367565b6001600160a01b03838116600081815260d16020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b03841661143a5760405162461bcd60e51b81526004016103679061267f565b6000611444610fe4565b905060006114518561179a565b9050600061145e8561179a565b9050600086815260d0602090815260408083206001600160a01b038c168452909152902054858110156114a35760405162461bcd60e51b8152600401610367906126c4565b600087815260d0602090815260408083206001600160a01b038d8116855292528083208985039055908a168252812080548892906114e29084906125ef565b909155505060408051888152602081018890526001600160a01b03808b16928c82169291881691600080516020612af3833981519152910160405180910390a4611530848a8a8a8a8a6117e5565b505050505050505050565b606b54610100900460ff166115625760405162461bcd60e51b8152600401610367906127c3565b61156b81611a57565b50565b60606103956001600160a01b0383166014611a87565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6115d2818484611c29565b600055600280546001600160a01b0319163017905560055550505050565b6001600160a01b0383166116165760405162461bcd60e51b81526004016103679061273c565b6000611620610fe4565b9050600061162d8461179a565b9050600061163a8461179a565b604080516020808201835260009182905288825260d081528282206001600160a01b038b16835290522054909150848110156116885760405162461bcd60e51b81526004016103679061277f565b600086815260d0602090815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a9052909290881691600080516020612af3833981519152910160405180910390a4604080516020810190915260009052610fdb565b6000604051806080016040528060438152602001612b136043913980516020918201208351848301516040808701518051908601209051611750950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039561177a611c72565b8360405161190160f01b8152600281019290925260228201526042902090565b604080516001808252818301909252606091600091906020808301908036833701905050905082816000815181106117d4576117d46125aa565b602090810291909101015292915050565b6001600160a01b0384163b156111955760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190611829908990899088908890889060040161280e565b6020604051808303816000875af1925050508015611864575060408051601f3d908101601f1916820190925261186191810190612853565b60015b61191057611870612870565b806308c379a0036118a9575061188461288b565b8061188f57506118ab565b8060405162461bcd60e51b81526004016103679190611e49565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e2d455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610367565b6001600160e01b0319811663f23a6e6160e01b14610fdb5760405162461bcd60e51b815260040161036790612914565b600030330361199657600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506119999050565b50335b90565b6001600160a01b0384163b156111955760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906119e0908990899088908890889060040161295c565b6020604051808303816000875af1925050508015611a1b575060408051601f3d908101601f19168201909252611a1891810190612853565b60015b611a2757611870612870565b6001600160e01b0319811663bc197c8160e01b14610fdb5760405162461bcd60e51b815260040161036790612914565b606b54610100900460ff16611a7e5760405162461bcd60e51b8152600401610367906127c3565b61156b81611cad565b60606000611a968360026129ba565b611aa19060026125ef565b6001600160401b03811115611ab857611ab8611ec3565b6040519080825280601f01601f191660200182016040528015611ae2576020820181803683370190505b509050600360fc1b81600081518110611afd57611afd6125aa565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110611b2c57611b2c6125aa565b60200101906001600160f81b031916908160001a9053506000611b508460026129ba565b611b5b9060016125ef565b90505b6001811115611bd3576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110611b8f57611b8f6125aa565b1a60f81b828281518110611ba557611ba56125aa565b60200101906001600160f81b031916908160001a90535060049490941c93611bcc816129d1565b9050611b5e565b508315611c225760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610367565b9392505050565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b6002546000906001600160a01b031630148015611c90575060015446145b15611c9c575060005490565b610fee600554600354600454611c29565b60d2610b348282612a33565b80356001600160a01b0381168114611cd057600080fd5b919050565b60008060408385031215611ce857600080fd5b611cf183611cb9565b946020939093013593505050565b6001600160e01b03198116811461156b57600080fd5b600060208284031215611d2757600080fd5b8135611c2281611cff565b60008083601f840112611d4457600080fd5b5081356001600160401b03811115611d5b57600080fd5b602083019150836020828501011115611d7357600080fd5b9250929050565b60008060008060008060a08789031215611d9357600080fd5b611d9c87611cb9565b955060208701356001600160401b03811115611db757600080fd5b611dc389828a01611d32565b9096509450506040870135925060608701359150608087013560ff81168114611deb57600080fd5b809150509295509295509295565b60005b83811015611e14578181015183820152602001611dfc565b50506000910152565b60008151808452611e35816020860160208601611df9565b601f01601f19169290920160200192915050565b602081526000611c226020830184611e1d565b600060208284031215611e6e57600080fd5b5035919050565b600080600060608486031215611e8a57600080fd5b611e9384611cb9565b95602085013595506040909401359392505050565b600060208284031215611eba57600080fd5b611c2282611cb9565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b0381118282101715611efe57611efe611ec3565b6040525050565b60006001600160401b03821115611f1e57611f1e611ec3565b5060051b60200190565b600082601f830112611f3957600080fd5b81356020611f4682611f05565b604051611f538282611ed9565b83815260059390931b8501820192828101915086841115611f7357600080fd5b8286015b84811015611f8e5780358352918301918301611f77565b509695505050505050565b600082601f830112611faa57600080fd5b81356001600160401b03811115611fc357611fc3611ec3565b604051611fda601f8301601f191660200182611ed9565b818152846020838601011115611fef57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a0868803121561202457600080fd5b61202d86611cb9565b945061203b60208701611cb9565b935060408601356001600160401b038082111561205757600080fd5b61206389838a01611f28565b9450606088013591508082111561207957600080fd5b61208589838a01611f28565b9350608088013591508082111561209b57600080fd5b506120a888828901611f99565b9150509295509295909350565b600080604083850312156120c857600080fd5b82356001600160401b03808211156120df57600080fd5b818501915085601f8301126120f357600080fd5b8135602061210082611f05565b60405161210d8282611ed9565b83815260059390931b850182019282810191508984111561212d57600080fd5b948201945b838610156121525761214386611cb9565b82529482019490820190612132565b9650508601359250508082111561216857600080fd5b5061217585828601611f28565b9150509250929050565b600081518084526020808501945080840160005b838110156121af57815187529582019590820190600101612193565b509495945050505050565b602081526000611c22602083018461217f565b60008083601f8401126121df57600080fd5b5081356001600160401b038111156121f657600080fd5b6020830191508360208260051b8501011115611d7357600080fd5b6000806000806000806060878903121561222a57600080fd5b86356001600160401b038082111561224157600080fd5b61224d8a838b016121cd565b9098509650602089013591508082111561226657600080fd5b6122728a838b016121cd565b9096509450604089013591508082111561228b57600080fd5b5061229889828a016121cd565b979a9699509497509295939492505050565b6000806000806000606086880312156122c257600080fd5b6122cb86611cb9565b945060208601356001600160401b03808211156122e757600080fd5b6122f389838a016121cd565b9096509450604088013591508082111561230c57600080fd5b50612319888289016121cd565b969995985093965092949392505050565b6000806040838503121561233d57600080fd5b61234683611cb9565b91506020830135801515811461235b57600080fd5b809150509250929050565b6000806040838503121561237957600080fd5b61238283611cb9565b915061239060208401611cb9565b90509250929050565b600080600080600060a086880312156123b157600080fd5b6123ba86611cb9565b94506123c860208701611cb9565b9350604086013592506060860135915060808601356001600160401b038111156123f157600080fd5b6120a888828901611f99565b60008060006040848603121561241257600080fd5b61241b84611cb9565b925060208401356001600160401b0381111561243657600080fd5b61244286828701611d32565b9497909650939450505050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60008251612487818460208701611df9565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b600181811c908216806124f157607f821691505b60208210810361251157634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526025908201527f4368696c64455243313135353a204f6e6c79207072656469636174652063616e6040820152640818d85b1b60da1b606082015260800190565b6020808252602e908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526d195c881bdc88185c1c1c9bdd995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016125e8576125e86125c0565b5060010190565b80820180821115610395576103956125c0565b6c4368696c64455243313135352d60981b81526000825161262a81600d850160208701611df9565b91909101600d0192915050565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b604081526000612721604083018561217f565b8281036020840152612733818561217f565b95945050505050565b60208082526023908201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260408201526265737360e81b606082015260800190565b60208082526024908201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604082015263616e636560e01b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a06080820181905260009061284890830184611e1d565b979650505050505050565b60006020828403121561286557600080fd5b8151611c2281611cff565b600060033d11156119995760046000803e5060005160e01c90565b600060443d10156128995790565b6040516003193d81016004833e81513d6001600160401b0381602484011181841117156128c857505050505090565b82850191508151818111156128e05750505050505090565b843d87010160208285010111156128fa5750505050505090565b61290960208286010187611ed9565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b0386811682528516602082015260a0604082018190526000906129889083018661217f565b828103606084015261299a818661217f565b905082810360808401526129ae8185611e1d565b98975050505050505050565b8082028115828204841417610395576103956125c0565b6000816129e0576129e06125c0565b506000190190565b601f821115612a2e57600081815260208120601f850160051c81016020861015612a0f5750805b601f850160051c820191505b8181101561119557828155600101612a1b565b505050565b81516001600160401b03811115612a4c57612a4c611ec3565b612a6081612a5a84546124dd565b846129e8565b602080601f831160018114612a955760008415612a7d5750858301515b600019600386901b1c1916600185901b178555611195565b600085815260208120601f198616915b82811015612ac457888601518255948401946001909101908401612aa5565b5085821015612ae25787850151600019600388901b60f8161c191681555b5050505050600190811b0190555056fec3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f624d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529a2646970667358221220d48b6656ae2af8f39607add0ff4fc12029027806b1a7c756a64f97827803920c64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101155760003560e01c806357128683116100a2578063e619870511610071578063e619870514610279578063e985e9c51461028b578063f242432a146102c7578063f399e22e146102da578063f5298aca146102ed57600080fd5b8063571286831461022d5780636b20c454146102405780639b77ef1114610253578063a22cb4651461026657600080fd5b8063156e29f6116100e9578063156e29f6146101965780631f2d0065146101a95780632d0335ab146101cf5780632eb2c2d6146101f85780634e1273f41461020d57600080fd5b8062fdd58e1461011a57806301ffc9a7146101405780630c53c51c146101635780630e89341c14610183575b600080fd5b61012d610128366004611cd5565b610300565b6040519081526020015b60405180910390f35b61015361014e366004611d15565b61039b565b6040519015158152602001610137565b610176610171366004611d7a565b6103eb565b6040516101379190611e49565b610176610191366004611e5c565b6106c9565b6101536101a4366004611e75565b61075d565b610103546001600160a01b03165b6040516001600160a01b039091168152602001610137565b61012d6101dd366004611ea8565b6001600160a01b031660009081526038602052604090205490565b61020b61020636600461200c565b6107b0565b005b61022061021b3660046120b5565b61080e565b60405161013791906121ba565b61015361023b366004612211565b610937565b61015361024e3660046122aa565b610a53565b61020b610261366004611e5c565b610afb565b61020b61027436600461232a565b610b22565b610102546001600160a01b03166101b7565b610153610299366004612366565b6001600160a01b03918216600090815260d16020908152604080832093909416825291909152205460ff1690565b61020b6102d5366004612399565b610b38565b61020b6102e83660046123fd565b610b8f565b6101536102fb366004611e75565b610da5565b60006001600160a01b0383166103705760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b50600081815260d0602090815260408083206001600160a01b03861684529091529020545b92915050565b60006001600160e01b03198216636cdb3d1360e11b14806103cc57506001600160e01b031982166303a24d0760e21b145b8061039557506301ffc9a760e01b6001600160e01b0319831614610395565b6060600061042e87878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610dde92505050565b90506001600160e01b03196000358116908216036104b45760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f640000006064820152608401610367565b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506105258982888888610df9565b61057b5760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b6064820152608401610367565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d6040516020016105d09392919061244f565b60408051601f19818403018152908290526105ea91612475565b6000604051808303816000865af19150503d8060008114610627576040519150601f19603f3d011682016040523d82523d6000602084013e61062c565b606091505b50915091508161067e5760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610367565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c6040516106b39493929190612491565b60405180910390a19a9950505050505050505050565b606060d280546106d8906124dd565b80601f0160208091040260200160405190810160405280929190818152602001828054610704906124dd565b80156107515780601f1061072657610100808354040283529160200191610751565b820191906000526020600020905b81548152906001019060200180831161073457829003601f168201915b50505050509050919050565b610102546000906001600160a01b0316331461078b5760405162461bcd60e51b815260040161036790612517565b6107a684848460405180602001604052806000815250610ed5565b5060019392505050565b6107b8610fe4565b6001600160a01b0316856001600160a01b031614806107de57506107de85610299610fe4565b6107fa5760405162461bcd60e51b81526004016103679061255c565b6108078585858585610ff3565b5050505050565b606081518351146108735760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610367565b600083516001600160401b0381111561088e5761088e611ec3565b6040519080825280602002602001820160405280156108b7578160200160208202803683370190505b50905060005b845181101561092f576109028582815181106108db576108db6125aa565b60200260200101518583815181106108f5576108f56125aa565b6020026020010151610300565b828281518110610914576109146125aa565b6020908102919091010152610928816125d6565b90506108bd565b509392505050565b610102546000906001600160a01b031633146109655760405162461bcd60e51b815260040161036790612517565b85848114801561097457508083145b6109c05760405162461bcd60e51b815260206004820181905260248201527f4368696c64455243313135353a206172726179206c656e206d69736d617463686044820152606401610367565b60005b81811015610a4457610a3c8989838181106109e0576109e06125aa565b90506020020160208101906109f59190611ea8565b888884818110610a0757610a076125aa565b90506020020135878785818110610a2057610a206125aa565b9050602002013560405180602001604052806000815250610ed5565b6001016109c3565b50600198975050505050505050565b610102546000906001600160a01b03163314610a815760405162461bcd60e51b815260040161036790612517565b610aef8686868080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808a0282810182019093528982529093508992508891829185019084908082843760009201919091525061119d92505050565b50600195945050505050565b3360009081526038602052604081208054839290610b1a9084906125ef565b909155505050565b610b34610b2d610fe4565b8383611334565b5050565b610b40610fe4565b6001600160a01b0316856001600160a01b03161480610b665750610b6685610299610fe4565b610b825760405162461bcd60e51b81526004016103679061255c565b6108078585858585611414565b606b54610100900460ff1615808015610baf5750606b54600160ff909116105b80610bc95750303b158015610bc95750606b5460ff166001145b610c2c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610367565b606b805460ff191660011790558015610c4f57606b805461ff0019166101001790555b6001600160a01b038416610ca55760405162461bcd60e51b815260206004820181905260248201527f4368696c64455243313135353a204241445f494e495449414c495a4154494f4e6044820152606401610367565b61010380546001600160a01b0386166001600160a01b031991821617909155610102805490911633179055604080516020601f8501819004810282018101909252838152610d0d91859085908190840183828082843760009201919091525061153b92505050565b610d59610d22856001600160a01b031661156e565b604051602001610d329190612602565b60408051601f1981840301815282820190915260018252603160f81b602083015290611584565b8015610d9f57606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050565b610102546000906001600160a01b03163314610dd35760405162461bcd60e51b815260040161036790612517565b6107a68484846115f0565b60008151600003610df157506000919050565b506020015190565b6000806001610e0f610e0a886116f0565b61176d565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa158015610e5d573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610eb45760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610367565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6001600160a01b038416610f355760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610367565b6000610f3f610fe4565b90506000610f4c8561179a565b90506000610f598561179a565b9050600086815260d0602090815260408083206001600160a01b038b16845290915281208054879290610f8d9084906125ef565b909155505060408051878152602081018790526001600160a01b03808a169260009291871691600080516020612af3833981519152910160405180910390a4610fdb836000898989896117e5565b50505050505050565b6000610fee611940565b905090565b81518351146110145760405162461bcd60e51b815260040161036790612637565b6001600160a01b03841661103a5760405162461bcd60e51b81526004016103679061267f565b6000611044610fe4565b905060005b845181101561112f576000858281518110611066576110666125aa565b602002602001015190506000858381518110611084576110846125aa565b602090810291909101810151600084815260d0835260408082206001600160a01b038e1683529093529190912054909150818110156110d55760405162461bcd60e51b8152600401610367906126c4565b600083815260d0602090815260408083206001600160a01b038e8116855292528083208585039055908b168252812080548492906111149084906125ef565b9250508190555050505080611128906125d6565b9050611049565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb878760405161117f92919061270e565b60405180910390a461119581878787878761199c565b505050505050565b6001600160a01b0383166111c35760405162461bcd60e51b81526004016103679061273c565b80518251146111e45760405162461bcd60e51b815260040161036790612637565b60006111ee610fe4565b604080516020810190915260009052905060005b83518110156112c757600084828151811061121f5761121f6125aa565b60200260200101519050600084838151811061123d5761123d6125aa565b602090810291909101810151600084815260d0835260408082206001600160a01b038c16835290935291909120549091508181101561128e5760405162461bcd60e51b81526004016103679061277f565b600092835260d0602090815260408085206001600160a01b038b16865290915290922091039055806112bf816125d6565b915050611202565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb868660405161131892919061270e565b60405180910390a4604080516020810190915260009052610d9f565b816001600160a01b0316836001600160a01b0316036113a75760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610367565b6001600160a01b03838116600081815260d16020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b03841661143a5760405162461bcd60e51b81526004016103679061267f565b6000611444610fe4565b905060006114518561179a565b9050600061145e8561179a565b9050600086815260d0602090815260408083206001600160a01b038c168452909152902054858110156114a35760405162461bcd60e51b8152600401610367906126c4565b600087815260d0602090815260408083206001600160a01b038d8116855292528083208985039055908a168252812080548892906114e29084906125ef565b909155505060408051888152602081018890526001600160a01b03808b16928c82169291881691600080516020612af3833981519152910160405180910390a4611530848a8a8a8a8a6117e5565b505050505050505050565b606b54610100900460ff166115625760405162461bcd60e51b8152600401610367906127c3565b61156b81611a57565b50565b60606103956001600160a01b0383166014611a87565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6115d2818484611c29565b600055600280546001600160a01b0319163017905560055550505050565b6001600160a01b0383166116165760405162461bcd60e51b81526004016103679061273c565b6000611620610fe4565b9050600061162d8461179a565b9050600061163a8461179a565b604080516020808201835260009182905288825260d081528282206001600160a01b038b16835290522054909150848110156116885760405162461bcd60e51b81526004016103679061277f565b600086815260d0602090815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a9052909290881691600080516020612af3833981519152910160405180910390a4604080516020810190915260009052610fdb565b6000604051806080016040528060438152602001612b136043913980516020918201208351848301516040808701518051908601209051611750950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039561177a611c72565b8360405161190160f01b8152600281019290925260228201526042902090565b604080516001808252818301909252606091600091906020808301908036833701905050905082816000815181106117d4576117d46125aa565b602090810291909101015292915050565b6001600160a01b0384163b156111955760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190611829908990899088908890889060040161280e565b6020604051808303816000875af1925050508015611864575060408051601f3d908101601f1916820190925261186191810190612853565b60015b61191057611870612870565b806308c379a0036118a9575061188461288b565b8061188f57506118ab565b8060405162461bcd60e51b81526004016103679190611e49565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e2d455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610367565b6001600160e01b0319811663f23a6e6160e01b14610fdb5760405162461bcd60e51b815260040161036790612914565b600030330361199657600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506119999050565b50335b90565b6001600160a01b0384163b156111955760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906119e0908990899088908890889060040161295c565b6020604051808303816000875af1925050508015611a1b575060408051601f3d908101601f19168201909252611a1891810190612853565b60015b611a2757611870612870565b6001600160e01b0319811663bc197c8160e01b14610fdb5760405162461bcd60e51b815260040161036790612914565b606b54610100900460ff16611a7e5760405162461bcd60e51b8152600401610367906127c3565b61156b81611cad565b60606000611a968360026129ba565b611aa19060026125ef565b6001600160401b03811115611ab857611ab8611ec3565b6040519080825280601f01601f191660200182016040528015611ae2576020820181803683370190505b509050600360fc1b81600081518110611afd57611afd6125aa565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110611b2c57611b2c6125aa565b60200101906001600160f81b031916908160001a9053506000611b508460026129ba565b611b5b9060016125ef565b90505b6001811115611bd3576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110611b8f57611b8f6125aa565b1a60f81b828281518110611ba557611ba56125aa565b60200101906001600160f81b031916908160001a90535060049490941c93611bcc816129d1565b9050611b5e565b508315611c225760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610367565b9392505050565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b6002546000906001600160a01b031630148015611c90575060015446145b15611c9c575060005490565b610fee600554600354600454611c29565b60d2610b348282612a33565b80356001600160a01b0381168114611cd057600080fd5b919050565b60008060408385031215611ce857600080fd5b611cf183611cb9565b946020939093013593505050565b6001600160e01b03198116811461156b57600080fd5b600060208284031215611d2757600080fd5b8135611c2281611cff565b60008083601f840112611d4457600080fd5b5081356001600160401b03811115611d5b57600080fd5b602083019150836020828501011115611d7357600080fd5b9250929050565b60008060008060008060a08789031215611d9357600080fd5b611d9c87611cb9565b955060208701356001600160401b03811115611db757600080fd5b611dc389828a01611d32565b9096509450506040870135925060608701359150608087013560ff81168114611deb57600080fd5b809150509295509295509295565b60005b83811015611e14578181015183820152602001611dfc565b50506000910152565b60008151808452611e35816020860160208601611df9565b601f01601f19169290920160200192915050565b602081526000611c226020830184611e1d565b600060208284031215611e6e57600080fd5b5035919050565b600080600060608486031215611e8a57600080fd5b611e9384611cb9565b95602085013595506040909401359392505050565b600060208284031215611eba57600080fd5b611c2282611cb9565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b0381118282101715611efe57611efe611ec3565b6040525050565b60006001600160401b03821115611f1e57611f1e611ec3565b5060051b60200190565b600082601f830112611f3957600080fd5b81356020611f4682611f05565b604051611f538282611ed9565b83815260059390931b8501820192828101915086841115611f7357600080fd5b8286015b84811015611f8e5780358352918301918301611f77565b509695505050505050565b600082601f830112611faa57600080fd5b81356001600160401b03811115611fc357611fc3611ec3565b604051611fda601f8301601f191660200182611ed9565b818152846020838601011115611fef57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a0868803121561202457600080fd5b61202d86611cb9565b945061203b60208701611cb9565b935060408601356001600160401b038082111561205757600080fd5b61206389838a01611f28565b9450606088013591508082111561207957600080fd5b61208589838a01611f28565b9350608088013591508082111561209b57600080fd5b506120a888828901611f99565b9150509295509295909350565b600080604083850312156120c857600080fd5b82356001600160401b03808211156120df57600080fd5b818501915085601f8301126120f357600080fd5b8135602061210082611f05565b60405161210d8282611ed9565b83815260059390931b850182019282810191508984111561212d57600080fd5b948201945b838610156121525761214386611cb9565b82529482019490820190612132565b9650508601359250508082111561216857600080fd5b5061217585828601611f28565b9150509250929050565b600081518084526020808501945080840160005b838110156121af57815187529582019590820190600101612193565b509495945050505050565b602081526000611c22602083018461217f565b60008083601f8401126121df57600080fd5b5081356001600160401b038111156121f657600080fd5b6020830191508360208260051b8501011115611d7357600080fd5b6000806000806000806060878903121561222a57600080fd5b86356001600160401b038082111561224157600080fd5b61224d8a838b016121cd565b9098509650602089013591508082111561226657600080fd5b6122728a838b016121cd565b9096509450604089013591508082111561228b57600080fd5b5061229889828a016121cd565b979a9699509497509295939492505050565b6000806000806000606086880312156122c257600080fd5b6122cb86611cb9565b945060208601356001600160401b03808211156122e757600080fd5b6122f389838a016121cd565b9096509450604088013591508082111561230c57600080fd5b50612319888289016121cd565b969995985093965092949392505050565b6000806040838503121561233d57600080fd5b61234683611cb9565b91506020830135801515811461235b57600080fd5b809150509250929050565b6000806040838503121561237957600080fd5b61238283611cb9565b915061239060208401611cb9565b90509250929050565b600080600080600060a086880312156123b157600080fd5b6123ba86611cb9565b94506123c860208701611cb9565b9350604086013592506060860135915060808601356001600160401b038111156123f157600080fd5b6120a888828901611f99565b60008060006040848603121561241257600080fd5b61241b84611cb9565b925060208401356001600160401b0381111561243657600080fd5b61244286828701611d32565b9497909650939450505050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60008251612487818460208701611df9565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b600181811c908216806124f157607f821691505b60208210810361251157634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526025908201527f4368696c64455243313135353a204f6e6c79207072656469636174652063616e6040820152640818d85b1b60da1b606082015260800190565b6020808252602e908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526d195c881bdc88185c1c1c9bdd995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016125e8576125e86125c0565b5060010190565b80820180821115610395576103956125c0565b6c4368696c64455243313135352d60981b81526000825161262a81600d850160208701611df9565b91909101600d0192915050565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b604081526000612721604083018561217f565b8281036020840152612733818561217f565b95945050505050565b60208082526023908201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260408201526265737360e81b606082015260800190565b60208082526024908201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604082015263616e636560e01b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a06080820181905260009061284890830184611e1d565b979650505050505050565b60006020828403121561286557600080fd5b8151611c2281611cff565b600060033d11156119995760046000803e5060005160e01c90565b600060443d10156128995790565b6040516003193d81016004833e81513d6001600160401b0381602484011181841117156128c857505050505090565b82850191508151818111156128e05750505050505090565b843d87010160208285010111156128fa5750505050505090565b61290960208286010187611ed9565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b0386811682528516602082015260a0604082018190526000906129889083018661217f565b828103606084015261299a818661217f565b905082810360808401526129ae8185611e1d565b98975050505050505050565b8082028115828204841417610395576103956125c0565b6000816129e0576129e06125c0565b506000190190565b601f821115612a2e57600081815260208120601f850160051c81016020861015612a0f5750805b601f850160051c820191505b8181101561119557828155600101612a1b565b505050565b81516001600160401b03811115612a4c57612a4c611ec3565b612a6081612a5a84546124dd565b846129e8565b602080601f831160018114612a955760008415612a7d5750858301515b600019600386901b1c1916600185901b178555611195565b600085815260208120601f198616915b82811015612ac457888601518255948401946001909101908401612aa5565b5085821015612ae25787850151600019600388901b60f8161c191681555b5050505050600190811b0190555056fec3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f624d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529a2646970667358221220d48b6656ae2af8f39607add0ff4fc12029027806b1a7c756a64f97827803920c64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildERC1155PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC1155Predicate","sourceName":"contracts/child/ChildERC1155Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2ERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2ERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612040806100206000396000f3fe608060405234801561001057600080fd5b50600436106101585760003560e01c806397e5230d116100c3578063d41f17711161007c578063d41f1771146102de578063d7c9e3ec14610305578063e0563ab11461032c578063eeb4994514610335578063f645125514610348578063f8c8765e1461036f57600080fd5b806397e5230d1461024d578063b176806514610257578063b5c5f6721461027e578063b68ad1e414610291578063b8cd3ec0146102a4578063c5ac2b1c146102b757600080fd5b806351351d531161011557806351351d53146101d357806355b01e4d146101e15780635ea5df79146101ef5780637efab4f51461020657806386937eb41461022f578063947287cf1461024457600080fd5b8063051eb2e21461015d57806305dc2e8f1461018d57806307b3e252146101a05780631bc114ba146101ae578063284017f5146101c15780633b878c22146101ca575b600080fd5b603554610170906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b603454610170906001600160a01b031681565b6101706004600360981b0181565b603354610170906001600160a01b031681565b61017061202081565b61017061101081565b6101706002600160a01b0381565b6101706004600160991b0181565b6101f861138881565b604051908152602001610184565b610170610214366004611648565b6037602052600090815260409020546001600160a01b031681565b61024261023d3660046116b7565b610382565b005b6101f861520881565b6101f8620249f081565b6101f87f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b61024261028c366004611763565b61039a565b603654610170906001600160a01b031681565b6102426102b2366004611798565b6103ab565b6101f87faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6101f87f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101f87f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61017061203081565b6102426103433660046117de565b6103bd565b6101f87f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61024261037d366004611866565b6105dd565b6103918787878787878761073a565b50505050505050565b6103a683338484610ab9565b505050565b6103b784848484610ab9565b50505050565b6034546001600160a01b0316331461042f5760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f5354415460448201526922afa922a1a2a4ab22a960b11b60648201526084015b60405180910390fd5b6035546001600160a01b0384811691161461049f5760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f524f4f546044820152695f50524544494341544560b01b6064820152608401610426565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216104ce6020600084866118c2565b6104d7916118ec565b036104f6576104f16104ec82602081866118c2565b610dce565b6103b7565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d186105256020600084866118c2565b61052e916118ec565b0361053d576104f18282611039565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61056c6020600084866118c2565b610575916118ec565b03610584576104f182826112a6565b60405162461bcd60e51b815260206004820152602860248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f5360448201526749474e415455524560c01b6064820152608401610426565b336002600160a01b03146106215760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610426565b600054610100900460ff16158080156106415750600054600160ff909116105b8061065b5750303b15801561065b575060005460ff166001145b6106be5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610426565b6000805460ff1916600117905580156106e1576000805461ff0019166101001790555b6106ed8585858561140e565b8015610733576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b8661074481611504565b6107605760405162461bcd60e51b81526004016104269061190a565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107c4919061194d565b6001600160a01b038181166000908152603760205260409020549192508a81169116146108035760405162461bcd60e51b81526004016104269061196a565b6001600160a01b038116610819576108196119af565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610861573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610885919061194d565b6001600160a01b03161461089b5761089b6119af565b86851480156108a957508483145b6109035760405162461bcd60e51b815260206004820152602560248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f4c60448201526408a9c8ea8960db1b6064820152608401610426565b604051631ac8311560e21b81526001600160a01b038a1690636b20c454906109379033908a908a908a908a906004016119f7565b6020604051808303816000875af1158015610956573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061097a9190611a3b565b6109965760405162461bcd60e51b815260040161042690611a5d565b6033546035546040516001600160a01b03928316926316f198319216906109f1907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001611ae8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610a1d929190611b99565b600060405180830381600087803b158015610a3757600080fd5b505af1158015610a4b573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167f7a10660242ca367951ff3777cdb3c2a761e3ccad204bac118501e24693f3683d8b8b8b8b8b8b604051610aa696959493929190611bc5565b60405180910390a4505050505050505050565b83610ac381611504565b610adf5760405162461bcd60e51b81526004016104269061190a565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b1f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b43919061194d565b6001600160a01b03818116600090815260376020526040902054919250878116911614610b825760405162461bcd60e51b81526004016104269061196a565b6001600160a01b038116610b9857610b986119af565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610be0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c04919061194d565b6001600160a01b031614610c1a57610c1a6119af565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca90610c4a90339088908890600401611c0e565b6020604051808303816000875af1158015610c69573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c8d9190611a3b565b610ca95760405162461bcd60e51b815260040161042690611a5d565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352938416936316f1983193610d3b9391169160e401611b99565b600060405180830381600087803b158015610d5557600080fd5b505af1158015610d69573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167f2ca9093e8b5356801039806c6a08003e5b7013fb8ae48f720fc90fc1c1a8bec2338888604051610dbe93929190611c0e565b60405180910390a4505050505050565b600080808080610de086880188611c2f565b6001600160a01b03808616600090815260376020526040902054959a50939850919650945092501680610e255760405162461bcd60e51b81526004016104269061196a565b610e2e81611504565b610e3a57610e3a6119af565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e7a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e9e919061194d565b9050866001600160a01b0316816001600160a01b031614610ec157610ec16119af565b6001600160a01b038116610ed757610ed76119af565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f1f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f43919061194d565b6001600160a01b031614610f5957610f596119af565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f690610f8990889088908890600401611c0e565b6020604051808303816000875af1158015610fa8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fcc9190611a3b565b610fe85760405162461bcd60e51b815260040161042690611c8a565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f2930d932c1cccd6add2e0e2d706ede9015db8a194405f2a3e1783703515e104f898888604051610aa693929190611c0e565b60008080808061104b86880188611da0565b6001600160a01b03808616600090815260376020526040902054959b5093995091975095509350169050806110925760405162461bcd60e51b81526004016104269061196a565b61109b81611504565b6110a7576110a76119af565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110e7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061110b919061194d565b9050866001600160a01b0316816001600160a01b03161461112e5761112e6119af565b6001600160a01b038116611144576111446119af565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561118c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b0919061194d565b6001600160a01b0316146111c6576111c66119af565b604051635712868360e01b81526001600160a01b038316906357128683906111f690889088908890600401611ee5565b6020604051808303816000875af1158015611215573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112399190611a3b565b6112555760405162461bcd60e51b815260040161042690611c8a565b856001600160a01b0316826001600160a01b0316886001600160a01b03167f17304b99f8dfa5a2b8dd5695d82f9947c2abfbc9cb64bab610b9a1a0feadb9a0888888604051610aa693929190611ee5565b6000806112b583850185611f5a565b9093509150506001600160a01b0382166112d1576112d16119af565b6001600160a01b0382811660009081526037602052604090205416156112f9576112f96119af565b6036546040516bffffffffffffffffffffffff19606085901b166020820152600091611349916001600160a01b039091169060340160405160208183030381529060405280519060200120611599565b6001600160a01b038481166000908152603760205260409081902080546001600160a01b0319169284169283179055516379ccf11760e11b81529192509063f399e22e9061139d9086908690600401611b99565b600060405180830381600087803b1580156113b757600080fd5b505af11580156113cb573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a35050505050565b6001600160a01b0384161580159061142e57506001600160a01b03831615155b801561144257506001600160a01b03821615155b801561145657506001600160a01b03811615155b6114b45760405162461bcd60e51b815260206004820152602960248201527f4368696c64455243313135355072656469636174653a204241445f494e49544960448201526820a624ad20aa24a7a760b91b6064820152608401610426565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000816001600160a01b03163b60000361152057506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611587575060408051601f3d908101601f1916820190925261158491810190611a3b565b60015b61159357506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166115935760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610426565b6001600160a01b038116811461164557600080fd5b50565b60006020828403121561165a57600080fd5b813561166581611630565b9392505050565b60008083601f84011261167e57600080fd5b5081356001600160401b0381111561169557600080fd5b6020830191508360208260051b85010111156116b057600080fd5b9250929050565b60008060008060008060006080888a0312156116d257600080fd5b87356116dd81611630565b965060208801356001600160401b03808211156116f957600080fd5b6117058b838c0161166c565b909850965060408a013591508082111561171e57600080fd5b61172a8b838c0161166c565b909650945060608a013591508082111561174357600080fd5b506117508a828b0161166c565b989b979a50959850939692959293505050565b60008060006060848603121561177857600080fd5b833561178381611630565b95602085013595506040909401359392505050565b600080600080608085870312156117ae57600080fd5b84356117b981611630565b935060208501356117c981611630565b93969395505050506040820135916060013590565b600080600080606085870312156117f457600080fd5b84359350602085013561180681611630565b925060408501356001600160401b038082111561182257600080fd5b818701915087601f83011261183657600080fd5b81358181111561184557600080fd5b88602082850101111561185757600080fd5b95989497505060200194505050565b6000806000806080858703121561187c57600080fd5b843561188781611630565b9350602085013561189781611630565b925060408501356118a781611630565b915060608501356118b781611630565b939692955090935050565b600080858511156118d257600080fd5b838611156118df57600080fd5b5050820193919092039150565b8035602083101561159357600019602084900360031b1b1692915050565b60208082526023908201527f4368696c64455243313135355072656469636174653a204e4f545f434f4e54526040820152621050d560ea1b606082015260800190565b60006020828403121561195f57600080fd5b815161166581611630565b60208082526025908201527f4368696c64455243313135355072656469636174653a20554e4d41505045445f6040820152642a27a5a2a760d91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156119de57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b0386168152606060208201819052600090611a1c90830186886119c5565b8281036040840152611a2f8185876119c5565b98975050505050505050565b600060208284031215611a4d57600080fd5b8151801515811461166557600080fd5b60208082526022908201527f4368696c64455243313135355072656469636174653a204255524e5f4641494c604082015261115160f21b606082015260800190565b8183526000602080850194508260005b85811015611add578135611ac281611630565b6001600160a01b031687529582019590820190600101611aaf565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090611b1b908301888a611a9f565b8281036080840152611b2e8187896119c5565b905082810360a0840152611b438185876119c5565b9c9b505050505050505050505050565b6000815180845260005b81811015611b7957602081850181015186830182015201611b5d565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611bbd90830184611b53565b949350505050565b606081526000611bd960608301888a611a9f565b8281036020840152611bec8187896119c5565b90508281036040840152611c018185876119c5565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a08688031215611c4757600080fd5b8535611c5281611630565b94506020860135611c6281611630565b93506040860135611c7281611630565b94979396509394606081013594506080013592915050565b60208082526022908201527f4368696c64455243313135355072656469636174653a204d494e545f4641494c604082015261115160f21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611d0a57611d0a611ccc565b604052919050565b60006001600160401b03821115611d2b57611d2b611ccc565b5060051b60200190565b600082601f830112611d4657600080fd5b81356020611d5b611d5683611d12565b611ce2565b82815260059290921b84018101918181019086841115611d7a57600080fd5b8286015b84811015611d955780358352918301918301611d7e565b509695505050505050565b60008060008060008060c08789031215611db957600080fd5b86359550602080880135611dcc81611630565b95506040880135611ddc81611630565b945060608801356001600160401b0380821115611df857600080fd5b818a0191508a601f830112611e0c57600080fd5b8135611e1a611d5682611d12565b81815260059190911b8301840190848101908d831115611e3957600080fd5b938501935b82851015611e60578435611e5181611630565b82529385019390850190611e3e565b9750505060808a0135925080831115611e7857600080fd5b611e848b848c01611d35565b945060a08a0135925080831115611e9a57600080fd5b5050611ea889828a01611d35565b9150509295509295509295565b600081518084526020808501945080840160005b83811015611add57815187529582019590820190600101611ec9565b606080825284519082018190526000906020906080840190828801845b82811015611f275781516001600160a01b031684529284019290840190600101611f02565b50505083810382850152611f3b8187611eb5565b9150508281036040840152611f508185611eb5565b9695505050505050565b600080600060608486031215611f6f57600080fd5b83359250602080850135611f8281611630565b925060408501356001600160401b0380821115611f9e57600080fd5b818701915087601f830112611fb257600080fd5b813581811115611fc457611fc4611ccc565b611fd6601f8201601f19168501611ce2565b91508082528884828501011115611fec57600080fd5b8084840185840137600084828401015250809350505050925092509256fea2646970667358221220144e7d3687aae30c76d4672a727fea0faa7f80324ee0ce29478a172a7808516964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101585760003560e01c806397e5230d116100c3578063d41f17711161007c578063d41f1771146102de578063d7c9e3ec14610305578063e0563ab11461032c578063eeb4994514610335578063f645125514610348578063f8c8765e1461036f57600080fd5b806397e5230d1461024d578063b176806514610257578063b5c5f6721461027e578063b68ad1e414610291578063b8cd3ec0146102a4578063c5ac2b1c146102b757600080fd5b806351351d531161011557806351351d53146101d357806355b01e4d146101e15780635ea5df79146101ef5780637efab4f51461020657806386937eb41461022f578063947287cf1461024457600080fd5b8063051eb2e21461015d57806305dc2e8f1461018d57806307b3e252146101a05780631bc114ba146101ae578063284017f5146101c15780633b878c22146101ca575b600080fd5b603554610170906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b603454610170906001600160a01b031681565b6101706004600360981b0181565b603354610170906001600160a01b031681565b61017061202081565b61017061101081565b6101706002600160a01b0381565b6101706004600160991b0181565b6101f861138881565b604051908152602001610184565b610170610214366004611648565b6037602052600090815260409020546001600160a01b031681565b61024261023d3660046116b7565b610382565b005b6101f861520881565b6101f8620249f081565b6101f87f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b61024261028c366004611763565b61039a565b603654610170906001600160a01b031681565b6102426102b2366004611798565b6103ab565b6101f87faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6101f87f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101f87f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61017061203081565b6102426103433660046117de565b6103bd565b6101f87f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61024261037d366004611866565b6105dd565b6103918787878787878761073a565b50505050505050565b6103a683338484610ab9565b505050565b6103b784848484610ab9565b50505050565b6034546001600160a01b0316331461042f5760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f5354415460448201526922afa922a1a2a4ab22a960b11b60648201526084015b60405180910390fd5b6035546001600160a01b0384811691161461049f5760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f524f4f546044820152695f50524544494341544560b01b6064820152608401610426565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216104ce6020600084866118c2565b6104d7916118ec565b036104f6576104f16104ec82602081866118c2565b610dce565b6103b7565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d186105256020600084866118c2565b61052e916118ec565b0361053d576104f18282611039565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61056c6020600084866118c2565b610575916118ec565b03610584576104f182826112a6565b60405162461bcd60e51b815260206004820152602860248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f5360448201526749474e415455524560c01b6064820152608401610426565b336002600160a01b03146106215760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610426565b600054610100900460ff16158080156106415750600054600160ff909116105b8061065b5750303b15801561065b575060005460ff166001145b6106be5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610426565b6000805460ff1916600117905580156106e1576000805461ff0019166101001790555b6106ed8585858561140e565b8015610733576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b8661074481611504565b6107605760405162461bcd60e51b81526004016104269061190a565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107c4919061194d565b6001600160a01b038181166000908152603760205260409020549192508a81169116146108035760405162461bcd60e51b81526004016104269061196a565b6001600160a01b038116610819576108196119af565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610861573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610885919061194d565b6001600160a01b03161461089b5761089b6119af565b86851480156108a957508483145b6109035760405162461bcd60e51b815260206004820152602560248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f4c60448201526408a9c8ea8960db1b6064820152608401610426565b604051631ac8311560e21b81526001600160a01b038a1690636b20c454906109379033908a908a908a908a906004016119f7565b6020604051808303816000875af1158015610956573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061097a9190611a3b565b6109965760405162461bcd60e51b815260040161042690611a5d565b6033546035546040516001600160a01b03928316926316f198319216906109f1907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001611ae8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610a1d929190611b99565b600060405180830381600087803b158015610a3757600080fd5b505af1158015610a4b573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167f7a10660242ca367951ff3777cdb3c2a761e3ccad204bac118501e24693f3683d8b8b8b8b8b8b604051610aa696959493929190611bc5565b60405180910390a4505050505050505050565b83610ac381611504565b610adf5760405162461bcd60e51b81526004016104269061190a565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b1f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b43919061194d565b6001600160a01b03818116600090815260376020526040902054919250878116911614610b825760405162461bcd60e51b81526004016104269061196a565b6001600160a01b038116610b9857610b986119af565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610be0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c04919061194d565b6001600160a01b031614610c1a57610c1a6119af565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca90610c4a90339088908890600401611c0e565b6020604051808303816000875af1158015610c69573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c8d9190611a3b565b610ca95760405162461bcd60e51b815260040161042690611a5d565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352938416936316f1983193610d3b9391169160e401611b99565b600060405180830381600087803b158015610d5557600080fd5b505af1158015610d69573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167f2ca9093e8b5356801039806c6a08003e5b7013fb8ae48f720fc90fc1c1a8bec2338888604051610dbe93929190611c0e565b60405180910390a4505050505050565b600080808080610de086880188611c2f565b6001600160a01b03808616600090815260376020526040902054959a50939850919650945092501680610e255760405162461bcd60e51b81526004016104269061196a565b610e2e81611504565b610e3a57610e3a6119af565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e7a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e9e919061194d565b9050866001600160a01b0316816001600160a01b031614610ec157610ec16119af565b6001600160a01b038116610ed757610ed76119af565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f1f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f43919061194d565b6001600160a01b031614610f5957610f596119af565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f690610f8990889088908890600401611c0e565b6020604051808303816000875af1158015610fa8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fcc9190611a3b565b610fe85760405162461bcd60e51b815260040161042690611c8a565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f2930d932c1cccd6add2e0e2d706ede9015db8a194405f2a3e1783703515e104f898888604051610aa693929190611c0e565b60008080808061104b86880188611da0565b6001600160a01b03808616600090815260376020526040902054959b5093995091975095509350169050806110925760405162461bcd60e51b81526004016104269061196a565b61109b81611504565b6110a7576110a76119af565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110e7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061110b919061194d565b9050866001600160a01b0316816001600160a01b03161461112e5761112e6119af565b6001600160a01b038116611144576111446119af565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561118c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b0919061194d565b6001600160a01b0316146111c6576111c66119af565b604051635712868360e01b81526001600160a01b038316906357128683906111f690889088908890600401611ee5565b6020604051808303816000875af1158015611215573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112399190611a3b565b6112555760405162461bcd60e51b815260040161042690611c8a565b856001600160a01b0316826001600160a01b0316886001600160a01b03167f17304b99f8dfa5a2b8dd5695d82f9947c2abfbc9cb64bab610b9a1a0feadb9a0888888604051610aa693929190611ee5565b6000806112b583850185611f5a565b9093509150506001600160a01b0382166112d1576112d16119af565b6001600160a01b0382811660009081526037602052604090205416156112f9576112f96119af565b6036546040516bffffffffffffffffffffffff19606085901b166020820152600091611349916001600160a01b039091169060340160405160208183030381529060405280519060200120611599565b6001600160a01b038481166000908152603760205260409081902080546001600160a01b0319169284169283179055516379ccf11760e11b81529192509063f399e22e9061139d9086908690600401611b99565b600060405180830381600087803b1580156113b757600080fd5b505af11580156113cb573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a35050505050565b6001600160a01b0384161580159061142e57506001600160a01b03831615155b801561144257506001600160a01b03821615155b801561145657506001600160a01b03811615155b6114b45760405162461bcd60e51b815260206004820152602960248201527f4368696c64455243313135355072656469636174653a204241445f494e49544960448201526820a624ad20aa24a7a760b91b6064820152608401610426565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000816001600160a01b03163b60000361152057506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611587575060408051601f3d908101601f1916820190925261158491810190611a3b565b60015b61159357506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166115935760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610426565b6001600160a01b038116811461164557600080fd5b50565b60006020828403121561165a57600080fd5b813561166581611630565b9392505050565b60008083601f84011261167e57600080fd5b5081356001600160401b0381111561169557600080fd5b6020830191508360208260051b85010111156116b057600080fd5b9250929050565b60008060008060008060006080888a0312156116d257600080fd5b87356116dd81611630565b965060208801356001600160401b03808211156116f957600080fd5b6117058b838c0161166c565b909850965060408a013591508082111561171e57600080fd5b61172a8b838c0161166c565b909650945060608a013591508082111561174357600080fd5b506117508a828b0161166c565b989b979a50959850939692959293505050565b60008060006060848603121561177857600080fd5b833561178381611630565b95602085013595506040909401359392505050565b600080600080608085870312156117ae57600080fd5b84356117b981611630565b935060208501356117c981611630565b93969395505050506040820135916060013590565b600080600080606085870312156117f457600080fd5b84359350602085013561180681611630565b925060408501356001600160401b038082111561182257600080fd5b818701915087601f83011261183657600080fd5b81358181111561184557600080fd5b88602082850101111561185757600080fd5b95989497505060200194505050565b6000806000806080858703121561187c57600080fd5b843561188781611630565b9350602085013561189781611630565b925060408501356118a781611630565b915060608501356118b781611630565b939692955090935050565b600080858511156118d257600080fd5b838611156118df57600080fd5b5050820193919092039150565b8035602083101561159357600019602084900360031b1b1692915050565b60208082526023908201527f4368696c64455243313135355072656469636174653a204e4f545f434f4e54526040820152621050d560ea1b606082015260800190565b60006020828403121561195f57600080fd5b815161166581611630565b60208082526025908201527f4368696c64455243313135355072656469636174653a20554e4d41505045445f6040820152642a27a5a2a760d91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156119de57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b0386168152606060208201819052600090611a1c90830186886119c5565b8281036040840152611a2f8185876119c5565b98975050505050505050565b600060208284031215611a4d57600080fd5b8151801515811461166557600080fd5b60208082526022908201527f4368696c64455243313135355072656469636174653a204255524e5f4641494c604082015261115160f21b606082015260800190565b8183526000602080850194508260005b85811015611add578135611ac281611630565b6001600160a01b031687529582019590820190600101611aaf565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090611b1b908301888a611a9f565b8281036080840152611b2e8187896119c5565b905082810360a0840152611b438185876119c5565b9c9b505050505050505050505050565b6000815180845260005b81811015611b7957602081850181015186830182015201611b5d565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611bbd90830184611b53565b949350505050565b606081526000611bd960608301888a611a9f565b8281036020840152611bec8187896119c5565b90508281036040840152611c018185876119c5565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a08688031215611c4757600080fd5b8535611c5281611630565b94506020860135611c6281611630565b93506040860135611c7281611630565b94979396509394606081013594506080013592915050565b60208082526022908201527f4368696c64455243313135355072656469636174653a204d494e545f4641494c604082015261115160f21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611d0a57611d0a611ccc565b604052919050565b60006001600160401b03821115611d2b57611d2b611ccc565b5060051b60200190565b600082601f830112611d4657600080fd5b81356020611d5b611d5683611d12565b611ce2565b82815260059290921b84018101918181019086841115611d7a57600080fd5b8286015b84811015611d955780358352918301918301611d7e565b509695505050505050565b60008060008060008060c08789031215611db957600080fd5b86359550602080880135611dcc81611630565b95506040880135611ddc81611630565b945060608801356001600160401b0380821115611df857600080fd5b818a0191508a601f830112611e0c57600080fd5b8135611e1a611d5682611d12565b81815260059190911b8301840190848101908d831115611e3957600080fd5b938501935b82851015611e60578435611e5181611630565b82529385019390850190611e3e565b9750505060808a0135925080831115611e7857600080fd5b611e848b848c01611d35565b945060a08a0135925080831115611e9a57600080fd5b5050611ea889828a01611d35565b9150509295509295509295565b600081518084526020808501945080840160005b83811015611add57815187529582019590820190600101611ec9565b606080825284519082018190526000906020906080840190828801845b82811015611f275781516001600160a01b031684529284019290840190600101611f02565b50505083810382850152611f3b8187611eb5565b9150508281036040840152611f508185611eb5565b9695505050505050565b600080600060608486031215611f6f57600080fd5b83359250602080850135611f8281611630565b925060408501356001600160401b0380821115611f9e57600080fd5b818701915087601f830112611fb257600080fd5b813581811115611fc457611fc4611ccc565b611fd6601f8201601f19168501611ce2565b91508082528884828501011115611fec57600080fd5b8084840185840137600084828401015250809350505050925092509256fea2646970667358221220144e7d3687aae30c76d4672a727fea0faa7f80324ee0ce29478a172a7808516964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildERC1155PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC1155PredicateAccessList","sourceName":"contracts/child/ChildERC1155PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2ERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2ERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","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":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506127d8806100206000396000f3fe608060405234801561001057600080fd5b50600436106101b05760003560e01c8063b1768065116100ef578063d7c9e3ec11610092578063d7c9e3ec146103a5578063d8dd1773146103cc578063e0563ab1146103df578063e30c3978146103e8578063eeb49945146103f9578063f2fde38b1461040c578063f64512551461041f578063f8c8765e1461044657600080fd5b8063b1768065146102d1578063b5c5f672146102f8578063b68ad1e41461030b578063b8cd3ec01461031e578063c1225a2014610331578063c5ac2b1c14610344578063c5e4683a1461036b578063d41f17711461037e57600080fd5b80635ea5df79116101575780635ea5df7914610247578063715018a61461025e57806379ba5097146102685780637efab4f51461027057806386937eb41461029a5780638da5cb5b146102ad578063947287cf146102be57806397e5230d146102c757600080fd5b8063051eb2e2146101b557806305dc2e8f146101e557806307b3e252146101f85780631bc114ba14610206578063284017f5146102195780633b878c221461022257806351351d531461022b57806355b01e4d14610239575b600080fd5b60fe546101c8906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b60fd546101c8906001600160a01b031681565b6101c86004600360981b0181565b60fc546101c8906001600160a01b031681565b6101c861202081565b6101c861101081565b6101c86002600160a01b0381565b6101c86004600160991b0181565b61025061138881565b6040519081526020016101dc565b610266610459565b005b61026661046d565b6101c861027e366004611c73565b610100602052600090815260409020546001600160a01b031681565b6102666102a8366004611ce2565b6104ec565b6033546001600160a01b03166101c8565b61025061520881565b610250620249f081565b6102507f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b610266610306366004611d8e565b61050c565b60ff546101c8906001600160a01b031681565b61026661032c366004611dc3565b610525565b61026661033f366004611e17565b61053f565b6102507faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b610266610379366004611e17565b61058e565b6102507f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102507f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6102666103da366004611e34565b6105d5565b6101c861203081565b6065546001600160a01b03166101c8565b610266610407366004611eca565b6106f6565b61026661041a366004611c73565b610911565b6102507f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b610266610454366004611f52565b610982565b610461610a7b565b61046b6000610ad5565b565b60655433906001600160a01b031681146104e05760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b6104e981610ad5565b50565b6104f4610aee565b61050387878787878787610af6565b50505050505050565b610514610aee565b61052083338484610e76565b505050565b61052d610aee565b61053984848484610e76565b50505050565b610547610a7b565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b610596610a7b565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105fc5760405163973d02cb60e01b81526004016104d790611fae565b600054610100900460ff161580801561061c5750600054600160ff909116105b806106365750303b158015610636575060005460ff166001145b6106525760405162461bcd60e51b81526004016104d790611fd2565b6000805460ff191660011790558015610675576000805461ff0019166101001790555b6106818888888861118c565b60c9805461ffff191685151561ff00191617610100851515021790556106a682610ad5565b80156106ec576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107635760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f5354415460448201526922afa922a1a2a4ab22a960b11b60648201526084016104d7565b60fe546001600160a01b038481169116146107d35760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f524f4f546044820152695f50524544494341544560b01b60648201526084016104d7565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f821610802602060008486612020565b61080b9161204a565b0361082a576108256108208260208186612020565b611282565b610539565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18610859602060008486612020565b6108629161204a565b036108715761082582826114ee565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6108a0602060008486612020565b6108a99161204a565b036108b857610825828261175c565b60405162461bcd60e51b815260206004820152602860248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f5360448201526749474e415455524560c01b60648201526084016104d7565b610919610a7b565b606580546001600160a01b0383166001600160a01b0319909116811790915561094a6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b336002600160a01b03146109a95760405163973d02cb60e01b81526004016104d790611fae565b600054610100900460ff16158080156109c95750600054600160ff909116105b806109e35750303b1580156109e3575060005460ff166001145b6109ff5760405162461bcd60e51b81526004016104d790611fd2565b6000805460ff191660011790558015610a22576000805461ff0019166101001790555b610a2e8585858561118c565b8015610a74576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6033546001600160a01b0316331461046b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104d7565b606580546001600160a01b03191690556104e9816118c6565b61046b611918565b86610b0081611b32565b610b1c5760405162461bcd60e51b81526004016104d790612068565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b5c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8091906120ab565b6001600160a01b03818116600090815261010060205260409020549192508a8116911614610bc05760405162461bcd60e51b81526004016104d7906120c8565b6001600160a01b038116610bd657610bd661210d565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c1e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c4291906120ab565b6001600160a01b031614610c5857610c5861210d565b8685148015610c6657508483145b610cc05760405162461bcd60e51b815260206004820152602560248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f4c60448201526408a9c8ea8960db1b60648201526084016104d7565b604051631ac8311560e21b81526001600160a01b038a1690636b20c45490610cf49033908a908a908a908a90600401612155565b6020604051808303816000875af1158015610d13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d379190612199565b610d535760405162461bcd60e51b81526004016104d7906121b6565b60fc5460fe546040516001600160a01b03928316926316f19831921690610dae907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001612241565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610dda9291906122fc565b600060405180830381600087803b158015610df457600080fd5b505af1158015610e08573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167f7a10660242ca367951ff3777cdb3c2a761e3ccad204bac118501e24693f3683d8b8b8b8b8b8b604051610e6396959493929190612328565b60405180910390a4505050505050505050565b83610e8081611b32565b610e9c5760405162461bcd60e51b81526004016104d790612068565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610edc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f0091906120ab565b6001600160a01b0381811660009081526101006020526040902054919250878116911614610f405760405162461bcd60e51b81526004016104d7906120c8565b6001600160a01b038116610f5657610f5661210d565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f9e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fc291906120ab565b6001600160a01b031614610fd857610fd861210d565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca9061100890339088908890600401612371565b6020604051808303816000875af1158015611027573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061104b9190612199565b6110675760405162461bcd60e51b81526004016104d7906121b6565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352938416936316f19831936110f99391169160e4016122fc565b600060405180830381600087803b15801561111357600080fd5b505af1158015611127573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167f2ca9093e8b5356801039806c6a08003e5b7013fb8ae48f720fc90fc1c1a8bec233888860405161117c93929190612371565b60405180910390a4505050505050565b6001600160a01b038416158015906111ac57506001600160a01b03831615155b80156111c057506001600160a01b03821615155b80156111d457506001600160a01b03811615155b6112325760405162461bcd60e51b815260206004820152602960248201527f4368696c64455243313135355072656469636174653a204241445f494e49544960448201526820a624ad20aa24a7a760b91b60648201526084016104d7565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b60008080808061129486880188612392565b6001600160a01b0380861660009081526101006020526040902054959a509398509196509450925016806112da5760405162461bcd60e51b81526004016104d7906120c8565b6112e381611b32565b6112ef576112ef61210d565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561132f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061135391906120ab565b9050866001600160a01b0316816001600160a01b0316146113765761137661210d565b6001600160a01b03811661138c5761138c61210d565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113f891906120ab565b6001600160a01b03161461140e5761140e61210d565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f69061143e90889088908890600401612371565b6020604051808303816000875af115801561145d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114819190612199565b61149d5760405162461bcd60e51b81526004016104d7906123ed565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f2930d932c1cccd6add2e0e2d706ede9015db8a194405f2a3e1783703515e104f898888604051610e6393929190612371565b60008080808061150086880188612503565b6001600160a01b0380861660009081526101006020526040902054959b5093995091975095509350169050806115485760405162461bcd60e51b81526004016104d7906120c8565b61155181611b32565b61155d5761155d61210d565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561159d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115c191906120ab565b9050866001600160a01b0316816001600160a01b0316146115e4576115e461210d565b6001600160a01b0381166115fa576115fa61210d565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611642573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061166691906120ab565b6001600160a01b03161461167c5761167c61210d565b604051635712868360e01b81526001600160a01b038316906357128683906116ac90889088908890600401612648565b6020604051808303816000875af11580156116cb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116ef9190612199565b61170b5760405162461bcd60e51b81526004016104d7906123ed565b856001600160a01b0316826001600160a01b0316886001600160a01b03167f17304b99f8dfa5a2b8dd5695d82f9947c2abfbc9cb64bab610b9a1a0feadb9a0888888604051610e6393929190612648565b60008061176b838501856126bd565b9093509150506001600160a01b0382166117875761178761210d565b6001600160a01b038281166000908152610100602052604090205416156117b0576117b061210d565b60ff546040516bffffffffffffffffffffffff19606085901b166020820152600091611800916001600160a01b039091169060340160405160208183030381529060405280519060200120611bc7565b6001600160a01b03848116600090815261010060205260409081902080546001600160a01b0319169284169283179055516379ccf11760e11b81529192509063f399e22e9061185590869086906004016122fc565b600060405180830381600087803b15801561186f57600080fd5b505af1158015611883573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a35050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff1615611a2357604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161197a919061276d565b6000604051808303818686fa925050503d80600081146119b6576040519150601f19603f3d011682016040523d82523d6000602084013e6119bb565b606091505b50915091508180156119e057506000818060200190518101906119de9190612789565b115b611a205760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016104d7565b50505b60c954610100900460ff161561046b57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b019161138891611a8a919061276d565b6000604051808303818686fa925050503d8060008114611ac6576040519150601f19603f3d011682016040523d82523d6000602084013e611acb565b606091505b5091509150818015611af1575080806020019051810190611aec9190612789565b600114155b611b2e5760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016104d7565b5050565b6000816001600160a01b03163b600003611b4e57506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611bb5575060408051601f3d908101601f19168201909252611bb291810190612199565b60015b611bc157506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116611bc15760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016104d7565b6001600160a01b03811681146104e957600080fd5b600060208284031215611c8557600080fd5b8135611c9081611c5e565b9392505050565b60008083601f840112611ca957600080fd5b5081356001600160401b03811115611cc057600080fd5b6020830191508360208260051b8501011115611cdb57600080fd5b9250929050565b60008060008060008060006080888a031215611cfd57600080fd5b8735611d0881611c5e565b965060208801356001600160401b0380821115611d2457600080fd5b611d308b838c01611c97565b909850965060408a0135915080821115611d4957600080fd5b611d558b838c01611c97565b909650945060608a0135915080821115611d6e57600080fd5b50611d7b8a828b01611c97565b989b979a50959850939692959293505050565b600080600060608486031215611da357600080fd5b8335611dae81611c5e565b95602085013595506040909401359392505050565b60008060008060808587031215611dd957600080fd5b8435611de481611c5e565b93506020850135611df481611c5e565b93969395505050506040820135916060013590565b80151581146104e957600080fd5b600060208284031215611e2957600080fd5b8135611c9081611e09565b600080600080600080600060e0888a031215611e4f57600080fd5b8735611e5a81611c5e565b96506020880135611e6a81611c5e565b95506040880135611e7a81611c5e565b94506060880135611e8a81611c5e565b93506080880135611e9a81611e09565b925060a0880135611eaa81611e09565b915060c0880135611eba81611c5e565b8091505092959891949750929550565b60008060008060608587031215611ee057600080fd5b843593506020850135611ef281611c5e565b925060408501356001600160401b0380821115611f0e57600080fd5b818701915087601f830112611f2257600080fd5b813581811115611f3157600080fd5b886020828501011115611f4357600080fd5b95989497505060200194505050565b60008060008060808587031215611f6857600080fd5b8435611f7381611c5e565b93506020850135611f8381611c5e565b92506040850135611f9381611c5e565b91506060850135611fa381611c5e565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b6000808585111561203057600080fd5b8386111561203d57600080fd5b5050820193919092039150565b80356020831015611bc157600019602084900360031b1b1692915050565b60208082526023908201527f4368696c64455243313135355072656469636174653a204e4f545f434f4e54526040820152621050d560ea1b606082015260800190565b6000602082840312156120bd57600080fd5b8151611c9081611c5e565b60208082526025908201527f4368696c64455243313135355072656469636174653a20554e4d41505045445f6040820152642a27a5a2a760d91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561213c57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038616815260606020820181905260009061217a9083018688612123565b828103604084015261218d818587612123565b98975050505050505050565b6000602082840312156121ab57600080fd5b8151611c9081611e09565b60208082526022908201527f4368696c64455243313135355072656469636174653a204255524e5f4641494c604082015261115160f21b606082015260800190565b8183526000602080850194508260005b8581101561223657813561221b81611c5e565b6001600160a01b031687529582019590820190600101612208565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090612274908301888a6121f8565b8281036080840152612287818789612123565b905082810360a084015261229c818587612123565b9c9b505050505050505050505050565b60005b838110156122c75781810151838201526020016122af565b50506000910152565b600081518084526122e88160208601602086016122ac565b601f01601f19169290920160200192915050565b6001600160a01b0383168152604060208201819052600090612320908301846122d0565b949350505050565b60608152600061233c60608301888a6121f8565b828103602084015261234f818789612123565b90508281036040840152612364818587612123565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a086880312156123aa57600080fd5b85356123b581611c5e565b945060208601356123c581611c5e565b935060408601356123d581611c5e565b94979396509394606081013594506080013592915050565b60208082526022908201527f4368696c64455243313135355072656469636174653a204d494e545f4641494c604082015261115160f21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171561246d5761246d61242f565b604052919050565b60006001600160401b0382111561248e5761248e61242f565b5060051b60200190565b600082601f8301126124a957600080fd5b813560206124be6124b983612475565b612445565b82815260059290921b840181019181810190868411156124dd57600080fd5b8286015b848110156124f857803583529183019183016124e1565b509695505050505050565b60008060008060008060c0878903121561251c57600080fd5b8635955060208088013561252f81611c5e565b9550604088013561253f81611c5e565b945060608801356001600160401b038082111561255b57600080fd5b818a0191508a601f83011261256f57600080fd5b813561257d6124b982612475565b81815260059190911b8301840190848101908d83111561259c57600080fd5b938501935b828510156125c35784356125b481611c5e565b825293850193908501906125a1565b9750505060808a01359250808311156125db57600080fd5b6125e78b848c01612498565b945060a08a01359250808311156125fd57600080fd5b505061260b89828a01612498565b9150509295509295509295565b600081518084526020808501945080840160005b838110156122365781518752958201959082019060010161262c565b606080825284519082018190526000906020906080840190828801845b8281101561268a5781516001600160a01b031684529284019290840190600101612665565b5050508381038285015261269e8187612618565b91505082810360408401526126b38185612618565b9695505050505050565b6000806000606084860312156126d257600080fd5b833592506020808501356126e581611c5e565b925060408501356001600160401b038082111561270157600080fd5b818701915087601f83011261271557600080fd5b8135818111156127275761272761242f565b612739601f8201601f19168501612445565b9150808252888482850101111561274f57600080fd5b80848401858401376000848284010152508093505050509250925092565b6000825161277f8184602087016122ac565b9190910192915050565b60006020828403121561279b57600080fd5b505191905056fea26469706673582212205d35ced486c2210da22d8254dca762acf5687ec4e599a9e2dbab26a8777a105964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101b05760003560e01c8063b1768065116100ef578063d7c9e3ec11610092578063d7c9e3ec146103a5578063d8dd1773146103cc578063e0563ab1146103df578063e30c3978146103e8578063eeb49945146103f9578063f2fde38b1461040c578063f64512551461041f578063f8c8765e1461044657600080fd5b8063b1768065146102d1578063b5c5f672146102f8578063b68ad1e41461030b578063b8cd3ec01461031e578063c1225a2014610331578063c5ac2b1c14610344578063c5e4683a1461036b578063d41f17711461037e57600080fd5b80635ea5df79116101575780635ea5df7914610247578063715018a61461025e57806379ba5097146102685780637efab4f51461027057806386937eb41461029a5780638da5cb5b146102ad578063947287cf146102be57806397e5230d146102c757600080fd5b8063051eb2e2146101b557806305dc2e8f146101e557806307b3e252146101f85780631bc114ba14610206578063284017f5146102195780633b878c221461022257806351351d531461022b57806355b01e4d14610239575b600080fd5b60fe546101c8906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b60fd546101c8906001600160a01b031681565b6101c86004600360981b0181565b60fc546101c8906001600160a01b031681565b6101c861202081565b6101c861101081565b6101c86002600160a01b0381565b6101c86004600160991b0181565b61025061138881565b6040519081526020016101dc565b610266610459565b005b61026661046d565b6101c861027e366004611c73565b610100602052600090815260409020546001600160a01b031681565b6102666102a8366004611ce2565b6104ec565b6033546001600160a01b03166101c8565b61025061520881565b610250620249f081565b6102507f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b610266610306366004611d8e565b61050c565b60ff546101c8906001600160a01b031681565b61026661032c366004611dc3565b610525565b61026661033f366004611e17565b61053f565b6102507faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b610266610379366004611e17565b61058e565b6102507f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102507f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6102666103da366004611e34565b6105d5565b6101c861203081565b6065546001600160a01b03166101c8565b610266610407366004611eca565b6106f6565b61026661041a366004611c73565b610911565b6102507f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b610266610454366004611f52565b610982565b610461610a7b565b61046b6000610ad5565b565b60655433906001600160a01b031681146104e05760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b6104e981610ad5565b50565b6104f4610aee565b61050387878787878787610af6565b50505050505050565b610514610aee565b61052083338484610e76565b505050565b61052d610aee565b61053984848484610e76565b50505050565b610547610a7b565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b610596610a7b565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105fc5760405163973d02cb60e01b81526004016104d790611fae565b600054610100900460ff161580801561061c5750600054600160ff909116105b806106365750303b158015610636575060005460ff166001145b6106525760405162461bcd60e51b81526004016104d790611fd2565b6000805460ff191660011790558015610675576000805461ff0019166101001790555b6106818888888861118c565b60c9805461ffff191685151561ff00191617610100851515021790556106a682610ad5565b80156106ec576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107635760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f5354415460448201526922afa922a1a2a4ab22a960b11b60648201526084016104d7565b60fe546001600160a01b038481169116146107d35760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f524f4f546044820152695f50524544494341544560b01b60648201526084016104d7565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f821610802602060008486612020565b61080b9161204a565b0361082a576108256108208260208186612020565b611282565b610539565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18610859602060008486612020565b6108629161204a565b036108715761082582826114ee565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6108a0602060008486612020565b6108a99161204a565b036108b857610825828261175c565b60405162461bcd60e51b815260206004820152602860248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f5360448201526749474e415455524560c01b60648201526084016104d7565b610919610a7b565b606580546001600160a01b0383166001600160a01b0319909116811790915561094a6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b336002600160a01b03146109a95760405163973d02cb60e01b81526004016104d790611fae565b600054610100900460ff16158080156109c95750600054600160ff909116105b806109e35750303b1580156109e3575060005460ff166001145b6109ff5760405162461bcd60e51b81526004016104d790611fd2565b6000805460ff191660011790558015610a22576000805461ff0019166101001790555b610a2e8585858561118c565b8015610a74576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6033546001600160a01b0316331461046b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104d7565b606580546001600160a01b03191690556104e9816118c6565b61046b611918565b86610b0081611b32565b610b1c5760405162461bcd60e51b81526004016104d790612068565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b5c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8091906120ab565b6001600160a01b03818116600090815261010060205260409020549192508a8116911614610bc05760405162461bcd60e51b81526004016104d7906120c8565b6001600160a01b038116610bd657610bd661210d565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c1e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c4291906120ab565b6001600160a01b031614610c5857610c5861210d565b8685148015610c6657508483145b610cc05760405162461bcd60e51b815260206004820152602560248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f4c60448201526408a9c8ea8960db1b60648201526084016104d7565b604051631ac8311560e21b81526001600160a01b038a1690636b20c45490610cf49033908a908a908a908a90600401612155565b6020604051808303816000875af1158015610d13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d379190612199565b610d535760405162461bcd60e51b81526004016104d7906121b6565b60fc5460fe546040516001600160a01b03928316926316f19831921690610dae907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001612241565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610dda9291906122fc565b600060405180830381600087803b158015610df457600080fd5b505af1158015610e08573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167f7a10660242ca367951ff3777cdb3c2a761e3ccad204bac118501e24693f3683d8b8b8b8b8b8b604051610e6396959493929190612328565b60405180910390a4505050505050505050565b83610e8081611b32565b610e9c5760405162461bcd60e51b81526004016104d790612068565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610edc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f0091906120ab565b6001600160a01b0381811660009081526101006020526040902054919250878116911614610f405760405162461bcd60e51b81526004016104d7906120c8565b6001600160a01b038116610f5657610f5661210d565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f9e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fc291906120ab565b6001600160a01b031614610fd857610fd861210d565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca9061100890339088908890600401612371565b6020604051808303816000875af1158015611027573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061104b9190612199565b6110675760405162461bcd60e51b81526004016104d7906121b6565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352938416936316f19831936110f99391169160e4016122fc565b600060405180830381600087803b15801561111357600080fd5b505af1158015611127573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167f2ca9093e8b5356801039806c6a08003e5b7013fb8ae48f720fc90fc1c1a8bec233888860405161117c93929190612371565b60405180910390a4505050505050565b6001600160a01b038416158015906111ac57506001600160a01b03831615155b80156111c057506001600160a01b03821615155b80156111d457506001600160a01b03811615155b6112325760405162461bcd60e51b815260206004820152602960248201527f4368696c64455243313135355072656469636174653a204241445f494e49544960448201526820a624ad20aa24a7a760b91b60648201526084016104d7565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b60008080808061129486880188612392565b6001600160a01b0380861660009081526101006020526040902054959a509398509196509450925016806112da5760405162461bcd60e51b81526004016104d7906120c8565b6112e381611b32565b6112ef576112ef61210d565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561132f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061135391906120ab565b9050866001600160a01b0316816001600160a01b0316146113765761137661210d565b6001600160a01b03811661138c5761138c61210d565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113f891906120ab565b6001600160a01b03161461140e5761140e61210d565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f69061143e90889088908890600401612371565b6020604051808303816000875af115801561145d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114819190612199565b61149d5760405162461bcd60e51b81526004016104d7906123ed565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f2930d932c1cccd6add2e0e2d706ede9015db8a194405f2a3e1783703515e104f898888604051610e6393929190612371565b60008080808061150086880188612503565b6001600160a01b0380861660009081526101006020526040902054959b5093995091975095509350169050806115485760405162461bcd60e51b81526004016104d7906120c8565b61155181611b32565b61155d5761155d61210d565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561159d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115c191906120ab565b9050866001600160a01b0316816001600160a01b0316146115e4576115e461210d565b6001600160a01b0381166115fa576115fa61210d565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611642573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061166691906120ab565b6001600160a01b03161461167c5761167c61210d565b604051635712868360e01b81526001600160a01b038316906357128683906116ac90889088908890600401612648565b6020604051808303816000875af11580156116cb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116ef9190612199565b61170b5760405162461bcd60e51b81526004016104d7906123ed565b856001600160a01b0316826001600160a01b0316886001600160a01b03167f17304b99f8dfa5a2b8dd5695d82f9947c2abfbc9cb64bab610b9a1a0feadb9a0888888604051610e6393929190612648565b60008061176b838501856126bd565b9093509150506001600160a01b0382166117875761178761210d565b6001600160a01b038281166000908152610100602052604090205416156117b0576117b061210d565b60ff546040516bffffffffffffffffffffffff19606085901b166020820152600091611800916001600160a01b039091169060340160405160208183030381529060405280519060200120611bc7565b6001600160a01b03848116600090815261010060205260409081902080546001600160a01b0319169284169283179055516379ccf11760e11b81529192509063f399e22e9061185590869086906004016122fc565b600060405180830381600087803b15801561186f57600080fd5b505af1158015611883573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a35050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff1615611a2357604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161197a919061276d565b6000604051808303818686fa925050503d80600081146119b6576040519150601f19603f3d011682016040523d82523d6000602084013e6119bb565b606091505b50915091508180156119e057506000818060200190518101906119de9190612789565b115b611a205760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016104d7565b50505b60c954610100900460ff161561046b57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b019161138891611a8a919061276d565b6000604051808303818686fa925050503d8060008114611ac6576040519150601f19603f3d011682016040523d82523d6000602084013e611acb565b606091505b5091509150818015611af1575080806020019051810190611aec9190612789565b600114155b611b2e5760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016104d7565b5050565b6000816001600160a01b03163b600003611b4e57506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611bb5575060408051601f3d908101601f19168201909252611bb291810190612199565b60015b611bc157506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116611bc15760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016104d7565b6001600160a01b03811681146104e957600080fd5b600060208284031215611c8557600080fd5b8135611c9081611c5e565b9392505050565b60008083601f840112611ca957600080fd5b5081356001600160401b03811115611cc057600080fd5b6020830191508360208260051b8501011115611cdb57600080fd5b9250929050565b60008060008060008060006080888a031215611cfd57600080fd5b8735611d0881611c5e565b965060208801356001600160401b0380821115611d2457600080fd5b611d308b838c01611c97565b909850965060408a0135915080821115611d4957600080fd5b611d558b838c01611c97565b909650945060608a0135915080821115611d6e57600080fd5b50611d7b8a828b01611c97565b989b979a50959850939692959293505050565b600080600060608486031215611da357600080fd5b8335611dae81611c5e565b95602085013595506040909401359392505050565b60008060008060808587031215611dd957600080fd5b8435611de481611c5e565b93506020850135611df481611c5e565b93969395505050506040820135916060013590565b80151581146104e957600080fd5b600060208284031215611e2957600080fd5b8135611c9081611e09565b600080600080600080600060e0888a031215611e4f57600080fd5b8735611e5a81611c5e565b96506020880135611e6a81611c5e565b95506040880135611e7a81611c5e565b94506060880135611e8a81611c5e565b93506080880135611e9a81611e09565b925060a0880135611eaa81611e09565b915060c0880135611eba81611c5e565b8091505092959891949750929550565b60008060008060608587031215611ee057600080fd5b843593506020850135611ef281611c5e565b925060408501356001600160401b0380821115611f0e57600080fd5b818701915087601f830112611f2257600080fd5b813581811115611f3157600080fd5b886020828501011115611f4357600080fd5b95989497505060200194505050565b60008060008060808587031215611f6857600080fd5b8435611f7381611c5e565b93506020850135611f8381611c5e565b92506040850135611f9381611c5e565b91506060850135611fa381611c5e565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b6000808585111561203057600080fd5b8386111561203d57600080fd5b5050820193919092039150565b80356020831015611bc157600019602084900360031b1b1692915050565b60208082526023908201527f4368696c64455243313135355072656469636174653a204e4f545f434f4e54526040820152621050d560ea1b606082015260800190565b6000602082840312156120bd57600080fd5b8151611c9081611c5e565b60208082526025908201527f4368696c64455243313135355072656469636174653a20554e4d41505045445f6040820152642a27a5a2a760d91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561213c57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038616815260606020820181905260009061217a9083018688612123565b828103604084015261218d818587612123565b98975050505050505050565b6000602082840312156121ab57600080fd5b8151611c9081611e09565b60208082526022908201527f4368696c64455243313135355072656469636174653a204255524e5f4641494c604082015261115160f21b606082015260800190565b8183526000602080850194508260005b8581101561223657813561221b81611c5e565b6001600160a01b031687529582019590820190600101612208565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090612274908301888a6121f8565b8281036080840152612287818789612123565b905082810360a084015261229c818587612123565b9c9b505050505050505050505050565b60005b838110156122c75781810151838201526020016122af565b50506000910152565b600081518084526122e88160208601602086016122ac565b601f01601f19169290920160200192915050565b6001600160a01b0383168152604060208201819052600090612320908301846122d0565b949350505050565b60608152600061233c60608301888a6121f8565b828103602084015261234f818789612123565b90508281036040840152612364818587612123565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a086880312156123aa57600080fd5b85356123b581611c5e565b945060208601356123c581611c5e565b935060408601356123d581611c5e565b94979396509394606081013594506080013592915050565b60208082526022908201527f4368696c64455243313135355072656469636174653a204d494e545f4641494c604082015261115160f21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171561246d5761246d61242f565b604052919050565b60006001600160401b0382111561248e5761248e61242f565b5060051b60200190565b600082601f8301126124a957600080fd5b813560206124be6124b983612475565b612445565b82815260059290921b840181019181810190868411156124dd57600080fd5b8286015b848110156124f857803583529183019183016124e1565b509695505050505050565b60008060008060008060c0878903121561251c57600080fd5b8635955060208088013561252f81611c5e565b9550604088013561253f81611c5e565b945060608801356001600160401b038082111561255b57600080fd5b818a0191508a601f83011261256f57600080fd5b813561257d6124b982612475565b81815260059190911b8301840190848101908d83111561259c57600080fd5b938501935b828510156125c35784356125b481611c5e565b825293850193908501906125a1565b9750505060808a01359250808311156125db57600080fd5b6125e78b848c01612498565b945060a08a01359250808311156125fd57600080fd5b505061260b89828a01612498565b9150509295509295509295565b600081518084526020808501945080840160005b838110156122365781518752958201959082019060010161262c565b606080825284519082018190526000906020906080840190828801845b8281101561268a5781516001600160a01b031684529284019290840190600101612665565b5050508381038285015261269e8187612618565b91505082810360408401526126b38185612618565b9695505050505050565b6000806000606084860312156126d257600080fd5b833592506020808501356126e581611c5e565b925060408501356001600160401b038082111561270157600080fd5b818701915087601f83011261271557600080fd5b8135818111156127275761272761242f565b612739601f8201601f19168501612445565b9150808252888482850101111561274f57600080fd5b80848401858401376000848284010152508093505050509250925092565b6000825161277f8184602087016122ac565b9190910192915050565b60006020828403121561279b57600080fd5b505191905056fea26469706673582212205d35ced486c2210da22d8254dca762acf5687ec4e599a9e2dbab26a8777a105964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RootMintableERC1155PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC1155Predicate","sourceName":"contracts/child/RootMintableERC1155Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2MintableERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2MintableERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"childToken","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155BatchReceived","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611c01806100206000396000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c8063b68ad1e4116100ad578063eeb4994511610071578063eeb49945146102fe578063f23a6e6114610311578063f4a120f714610330578063f645125514610343578063f8c8765e1461036a57600080fd5b8063b68ad1e41461023e578063bc197c8114610251578063c5ac2b1c14610289578063d41f1771146102b0578063d7c9e3ec146102d757600080fd5b80634c4c45de116100f45780634c4c45de146101a7578063654715e6146101ba5780637efab4f5146101cd578063a78e111c146101f6578063b17680651461020957600080fd5b806301ffc9a71461012657806305dc2e8f1461014e5780630efe6a8b146101795780631bc114ba1461018e575b600080fd5b610139610134366004611182565b61037d565b60405190151581526020015b60405180910390f35b600154610161906001600160a01b031681565b6040516001600160a01b039091168152602001610145565b61018c6101873660046111cb565b6103b4565b005b600054610161906201000090046001600160a01b031681565b61018c6101b536600461124b565b6103c5565b600254610161906001600160a01b031681565b6101616101db3660046112f7565b6004602052600090815260409020546001600160a01b031681565b61018c610204366004611314565b61043f565b6102307f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610145565b600354610161906001600160a01b031681565b61027061025f3660046114a6565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610145565b6102307faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6102307f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102307f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61018c61030c366004611553565b610451565b61027061031f3660046115db565b63f23a6e6160e01b95945050505050565b61016161033e3660046112f7565b610629565b6102307f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61018c610378366004611643565b610944565b60006001600160e01b03198216630271189760e51b14806103ae57506301ffc9a760e01b6001600160e01b03198316145b92915050565b6103c083338484610a5d565b505050565b84831480156103d357508481145b6104275760405162461bcd60e51b815260206004820152602c6024820152600080516020611bac83398151915260448201526b0ac82989288be988a9c8ea8960a31b60648201526084015b60405180910390fd5b61043687878787878787610bf3565b50505050505050565b61044b84848484610a5d565b50505050565b6001546001600160a01b031633146104c55760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e604482015270262cafa9aa20aa22afa922a1a2a4ab22a960791b606482015260840161041e565b6002546001600160a01b0384811691161461053d5760405162461bcd60e51b815260206004820152603260248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e6044820152714c595f4348494c445f50524544494341544560701b606482015260840161041e565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961056c60206000848661169f565b610575916116c9565b036105945761058f61058a826020818661169f565b610dd3565b61044b565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26105c360206000848661169f565b6105cc916116c9565b036105db5761058f8282610ed2565b60405162461bcd60e51b815260206004820152602f6024820152600080516020611bac83398151915260448201526e56414c49445f5349474e415455524560881b606482015260840161041e565b60006001600160a01b0382166106835760405162461bcd60e51b815260206004820152602b6024820152600080516020611bac83398151915260448201526a2b20a624a22faa27a5a2a760a91b606482015260840161041e565b6001600160a01b0382811660009081526004602052604090205416156107005760405162461bcd60e51b815260206004820152602c60248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20414c60448201526b149150511657d3505414115160a21b606482015260840161041e565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b03928316926107aa921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03848116600081815260046020818152604080842080546001600160a01b031916968816969096179095558451908101855282815293516303a24d0760e21b8152908101919091529294509091630e89341c90602401600060405180830381865afa92505050801561084557506040513d6000823e601f3d908101601f19168201604052610842919081019061170b565b60015b1561084d5790505b600060029054906101000a90046001600160a01b03166001600160a01b03166316f19831837f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad87856040516020016108a7939291906117ad565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108d39291906117d7565b600060405180830381600087803b1580156108ed57600080fd5b505af1158015610901573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a35050919050565b600054610100900460ff16158080156109645750600054600160ff909116105b8061097e5750303b15801561097e575060005460ff166001145b6109e15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161041e565b6000805460ff191660011790558015610a04576000805461ff0019166101001790555b610a1085858585611033565b8015610a56576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6000610a688561113b565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610a9d903390309088908890600401611803565b600060405180830381600087803b158015610ab757600080fd5b505af1158015610acb573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935262010000909404841695506316f198319450610b68939092169160e4016117d7565b600060405180830381600087803b158015610b8257600080fd5b505af1158015610b96573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fe6f1fb6bb1930a5d4b997d56e0a4a8cb6f3f941f0d5391f63c1f6914ee01e0b89060600160405180910390a4610a56565b6000610bfe8861113b565b905060005b84811015610caa57886001600160a01b031663f242432a3330898986818110610c2e57610c2e61183b565b90506020020135888887818110610c4757610c4761183b565b905060200201356040518563ffffffff1660e01b8152600401610c6d9493929190611803565b600060405180830381600087803b158015610c8757600080fd5b505af1158015610c9b573d6000803e3d6000fd5b50505050806001019050610c03565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610d0c907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e906020016118cc565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d389291906117d7565b600060405180830381600087803b158015610d5257600080fd5b505af1158015610d66573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167fa7d9cd27143f817fe006011faf3c04351f70f75cd30e7b21405817f2f670041e8a8a8a8a8a8a604051610dc196959493929190611937565b60405180910390a45050505050505050565b600080808080610de586880188611980565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610e1a57610e1a6119db565b604051637921219560e11b81526001600160a01b0387169063f242432a90610e4c903090889088908890600401611803565b600060405180830381600087803b158015610e6657600080fd5b505af1158015610e7a573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907f52cdfbe452878311d3237a4c20a951600d8e3a4fe6691d967d33788dc12d19c690606001610dc1565b600080808080610ee4868801886119f1565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080610f1b57610f1b6119db565b60005b8351811015610fe157866001600160a01b031663f242432a30878481518110610f4957610f4961183b565b6020026020010151878581518110610f6357610f6361183b565b6020026020010151878681518110610f7d57610f7d61183b565b60200260200101516040518563ffffffff1660e01b8152600401610fa49493929190611803565b600060405180830381600087803b158015610fbe57600080fd5b505af1158015610fd2573d6000803e3d6000fd5b50505050806001019050610f1e565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167f52733a40a0466155541c2fc4044165dd37a3db116bc834bab2f020665e90fd20878787604051610dc193929190611b36565b6001600160a01b0384161580159061105357506001600160a01b03831615155b801561106757506001600160a01b03821615155b801561107b57506001600160a01b03811615155b6110e05760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b606482015260840161041e565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6001600160a01b0380821660009081526004602052604090205416806111675761116482610629565b90505b6001600160a01b03811661117d5761117d6119db565b919050565b60006020828403121561119457600080fd5b81356001600160e01b0319811681146111ac57600080fd5b9392505050565b6001600160a01b03811681146111c857600080fd5b50565b6000806000606084860312156111e057600080fd5b83356111eb816111b3565b95602085013595506040909401359392505050565b60008083601f84011261121257600080fd5b5081356001600160401b0381111561122957600080fd5b6020830191508360208260051b850101111561124457600080fd5b9250929050565b60008060008060008060006080888a03121561126657600080fd5b8735611271816111b3565b965060208801356001600160401b038082111561128d57600080fd5b6112998b838c01611200565b909850965060408a01359150808211156112b257600080fd5b6112be8b838c01611200565b909650945060608a01359150808211156112d757600080fd5b506112e48a828b01611200565b989b979a50959850939692959293505050565b60006020828403121561130957600080fd5b81356111ac816111b3565b6000806000806080858703121561132a57600080fd5b8435611335816111b3565b93506020850135611345816111b3565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156113985761139861135a565b604052919050565b60006001600160401b038211156113b9576113b961135a565b5060051b60200190565b600082601f8301126113d457600080fd5b813560206113e96113e4836113a0565b611370565b82815260059290921b8401810191818101908684111561140857600080fd5b8286015b84811015611423578035835291830191830161140c565b509695505050505050565b60006001600160401b038211156114475761144761135a565b50601f01601f191660200190565b600082601f83011261146657600080fd5b81356114746113e48261142e565b81815284602083860101111561148957600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156114be57600080fd5b85356114c9816111b3565b945060208601356114d9816111b3565b935060408601356001600160401b03808211156114f557600080fd5b61150189838a016113c3565b9450606088013591508082111561151757600080fd5b61152389838a016113c3565b9350608088013591508082111561153957600080fd5b5061154688828901611455565b9150509295509295909350565b6000806000806060858703121561156957600080fd5b84359350602085013561157b816111b3565b925060408501356001600160401b038082111561159757600080fd5b818701915087601f8301126115ab57600080fd5b8135818111156115ba57600080fd5b8860208285010111156115cc57600080fd5b95989497505060200194505050565b600080600080600060a086880312156115f357600080fd5b85356115fe816111b3565b9450602086013561160e816111b3565b9350604086013592506060860135915060808601356001600160401b0381111561163757600080fd5b61154688828901611455565b6000806000806080858703121561165957600080fd5b8435611664816111b3565b93506020850135611674816111b3565b92506040850135611684816111b3565b91506060850135611694816111b3565b939692955090935050565b600080858511156116af57600080fd5b838611156116bc57600080fd5b5050820193919092039150565b803560208310156103ae57600019602084900360031b1b1692915050565b60005b838110156117025781810151838201526020016116ea565b50506000910152565b60006020828403121561171d57600080fd5b81516001600160401b0381111561173357600080fd5b8201601f8101841361174457600080fd5b80516117526113e48261142e565b81815285602083850101111561176757600080fd5b6117788260208301602086016116e7565b95945050505050565b600081518084526117998160208601602086016116e7565b601f01601f19169290920160200192915050565b8381526001600160a01b038316602082015260606040820181905260009061177890830184611781565b6001600160a01b03831681526040602082018190526000906117fb90830184611781565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b8581101561188f578135611874816111b3565b6001600160a01b031687529582019590820190600101611861565b509495945050505050565b81835260006001600160fb1b038311156118b357600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c0606082018190526000906118ff908301888a611851565b828103608084015261191281878961189a565b905082810360a084015261192781858761189a565b9c9b505050505050505050505050565b60608152600061194b60608301888a611851565b828103602084015261195e81878961189a565b9050828103604084015261197381858761189a565b9998505050505050505050565b600080600080600060a0868803121561199857600080fd5b85356119a3816111b3565b945060208601356119b3816111b3565b935060408601356119c3816111b3565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c08789031215611a0a57600080fd5b86359550602080880135611a1d816111b3565b95506040880135611a2d816111b3565b945060608801356001600160401b0380821115611a4957600080fd5b818a0191508a601f830112611a5d57600080fd5b8135611a6b6113e4826113a0565b81815260059190911b8301840190848101908d831115611a8a57600080fd5b938501935b82851015611ab1578435611aa2816111b3565b82529385019390850190611a8f565b9750505060808a0135925080831115611ac957600080fd5b611ad58b848c016113c3565b945060a08a0135925080831115611aeb57600080fd5b5050611af989828a016113c3565b9150509295509295509295565b600081518084526020808501945080840160005b8381101561188f57815187529582019590820190600101611b1a565b606080825284519082018190526000906020906080840190828801845b82811015611b785781516001600160a01b031684529284019290840190600101611b53565b50505083810382850152611b8c8187611b06565b9150508281036040840152611ba18185611b06565b969550505050505056fe526f6f744d696e7461626c65455243313135355072656469636174653a20494ea2646970667358221220bac4157c867ef25ba423441a6f4177226bff4063bb665be9fb147719e7b08cc664736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101215760003560e01c8063b68ad1e4116100ad578063eeb4994511610071578063eeb49945146102fe578063f23a6e6114610311578063f4a120f714610330578063f645125514610343578063f8c8765e1461036a57600080fd5b8063b68ad1e41461023e578063bc197c8114610251578063c5ac2b1c14610289578063d41f1771146102b0578063d7c9e3ec146102d757600080fd5b80634c4c45de116100f45780634c4c45de146101a7578063654715e6146101ba5780637efab4f5146101cd578063a78e111c146101f6578063b17680651461020957600080fd5b806301ffc9a71461012657806305dc2e8f1461014e5780630efe6a8b146101795780631bc114ba1461018e575b600080fd5b610139610134366004611182565b61037d565b60405190151581526020015b60405180910390f35b600154610161906001600160a01b031681565b6040516001600160a01b039091168152602001610145565b61018c6101873660046111cb565b6103b4565b005b600054610161906201000090046001600160a01b031681565b61018c6101b536600461124b565b6103c5565b600254610161906001600160a01b031681565b6101616101db3660046112f7565b6004602052600090815260409020546001600160a01b031681565b61018c610204366004611314565b61043f565b6102307f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610145565b600354610161906001600160a01b031681565b61027061025f3660046114a6565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610145565b6102307faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6102307f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102307f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61018c61030c366004611553565b610451565b61027061031f3660046115db565b63f23a6e6160e01b95945050505050565b61016161033e3660046112f7565b610629565b6102307f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61018c610378366004611643565b610944565b60006001600160e01b03198216630271189760e51b14806103ae57506301ffc9a760e01b6001600160e01b03198316145b92915050565b6103c083338484610a5d565b505050565b84831480156103d357508481145b6104275760405162461bcd60e51b815260206004820152602c6024820152600080516020611bac83398151915260448201526b0ac82989288be988a9c8ea8960a31b60648201526084015b60405180910390fd5b61043687878787878787610bf3565b50505050505050565b61044b84848484610a5d565b50505050565b6001546001600160a01b031633146104c55760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e604482015270262cafa9aa20aa22afa922a1a2a4ab22a960791b606482015260840161041e565b6002546001600160a01b0384811691161461053d5760405162461bcd60e51b815260206004820152603260248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e6044820152714c595f4348494c445f50524544494341544560701b606482015260840161041e565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961056c60206000848661169f565b610575916116c9565b036105945761058f61058a826020818661169f565b610dd3565b61044b565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26105c360206000848661169f565b6105cc916116c9565b036105db5761058f8282610ed2565b60405162461bcd60e51b815260206004820152602f6024820152600080516020611bac83398151915260448201526e56414c49445f5349474e415455524560881b606482015260840161041e565b60006001600160a01b0382166106835760405162461bcd60e51b815260206004820152602b6024820152600080516020611bac83398151915260448201526a2b20a624a22faa27a5a2a760a91b606482015260840161041e565b6001600160a01b0382811660009081526004602052604090205416156107005760405162461bcd60e51b815260206004820152602c60248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20414c60448201526b149150511657d3505414115160a21b606482015260840161041e565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b03928316926107aa921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03848116600081815260046020818152604080842080546001600160a01b031916968816969096179095558451908101855282815293516303a24d0760e21b8152908101919091529294509091630e89341c90602401600060405180830381865afa92505050801561084557506040513d6000823e601f3d908101601f19168201604052610842919081019061170b565b60015b1561084d5790505b600060029054906101000a90046001600160a01b03166001600160a01b03166316f19831837f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad87856040516020016108a7939291906117ad565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108d39291906117d7565b600060405180830381600087803b1580156108ed57600080fd5b505af1158015610901573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a35050919050565b600054610100900460ff16158080156109645750600054600160ff909116105b8061097e5750303b15801561097e575060005460ff166001145b6109e15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161041e565b6000805460ff191660011790558015610a04576000805461ff0019166101001790555b610a1085858585611033565b8015610a56576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6000610a688561113b565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610a9d903390309088908890600401611803565b600060405180830381600087803b158015610ab757600080fd5b505af1158015610acb573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935262010000909404841695506316f198319450610b68939092169160e4016117d7565b600060405180830381600087803b158015610b8257600080fd5b505af1158015610b96573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fe6f1fb6bb1930a5d4b997d56e0a4a8cb6f3f941f0d5391f63c1f6914ee01e0b89060600160405180910390a4610a56565b6000610bfe8861113b565b905060005b84811015610caa57886001600160a01b031663f242432a3330898986818110610c2e57610c2e61183b565b90506020020135888887818110610c4757610c4761183b565b905060200201356040518563ffffffff1660e01b8152600401610c6d9493929190611803565b600060405180830381600087803b158015610c8757600080fd5b505af1158015610c9b573d6000803e3d6000fd5b50505050806001019050610c03565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610d0c907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e906020016118cc565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d389291906117d7565b600060405180830381600087803b158015610d5257600080fd5b505af1158015610d66573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167fa7d9cd27143f817fe006011faf3c04351f70f75cd30e7b21405817f2f670041e8a8a8a8a8a8a604051610dc196959493929190611937565b60405180910390a45050505050505050565b600080808080610de586880188611980565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610e1a57610e1a6119db565b604051637921219560e11b81526001600160a01b0387169063f242432a90610e4c903090889088908890600401611803565b600060405180830381600087803b158015610e6657600080fd5b505af1158015610e7a573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907f52cdfbe452878311d3237a4c20a951600d8e3a4fe6691d967d33788dc12d19c690606001610dc1565b600080808080610ee4868801886119f1565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080610f1b57610f1b6119db565b60005b8351811015610fe157866001600160a01b031663f242432a30878481518110610f4957610f4961183b565b6020026020010151878581518110610f6357610f6361183b565b6020026020010151878681518110610f7d57610f7d61183b565b60200260200101516040518563ffffffff1660e01b8152600401610fa49493929190611803565b600060405180830381600087803b158015610fbe57600080fd5b505af1158015610fd2573d6000803e3d6000fd5b50505050806001019050610f1e565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167f52733a40a0466155541c2fc4044165dd37a3db116bc834bab2f020665e90fd20878787604051610dc193929190611b36565b6001600160a01b0384161580159061105357506001600160a01b03831615155b801561106757506001600160a01b03821615155b801561107b57506001600160a01b03811615155b6110e05760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b606482015260840161041e565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6001600160a01b0380821660009081526004602052604090205416806111675761116482610629565b90505b6001600160a01b03811661117d5761117d6119db565b919050565b60006020828403121561119457600080fd5b81356001600160e01b0319811681146111ac57600080fd5b9392505050565b6001600160a01b03811681146111c857600080fd5b50565b6000806000606084860312156111e057600080fd5b83356111eb816111b3565b95602085013595506040909401359392505050565b60008083601f84011261121257600080fd5b5081356001600160401b0381111561122957600080fd5b6020830191508360208260051b850101111561124457600080fd5b9250929050565b60008060008060008060006080888a03121561126657600080fd5b8735611271816111b3565b965060208801356001600160401b038082111561128d57600080fd5b6112998b838c01611200565b909850965060408a01359150808211156112b257600080fd5b6112be8b838c01611200565b909650945060608a01359150808211156112d757600080fd5b506112e48a828b01611200565b989b979a50959850939692959293505050565b60006020828403121561130957600080fd5b81356111ac816111b3565b6000806000806080858703121561132a57600080fd5b8435611335816111b3565b93506020850135611345816111b3565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156113985761139861135a565b604052919050565b60006001600160401b038211156113b9576113b961135a565b5060051b60200190565b600082601f8301126113d457600080fd5b813560206113e96113e4836113a0565b611370565b82815260059290921b8401810191818101908684111561140857600080fd5b8286015b84811015611423578035835291830191830161140c565b509695505050505050565b60006001600160401b038211156114475761144761135a565b50601f01601f191660200190565b600082601f83011261146657600080fd5b81356114746113e48261142e565b81815284602083860101111561148957600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156114be57600080fd5b85356114c9816111b3565b945060208601356114d9816111b3565b935060408601356001600160401b03808211156114f557600080fd5b61150189838a016113c3565b9450606088013591508082111561151757600080fd5b61152389838a016113c3565b9350608088013591508082111561153957600080fd5b5061154688828901611455565b9150509295509295909350565b6000806000806060858703121561156957600080fd5b84359350602085013561157b816111b3565b925060408501356001600160401b038082111561159757600080fd5b818701915087601f8301126115ab57600080fd5b8135818111156115ba57600080fd5b8860208285010111156115cc57600080fd5b95989497505060200194505050565b600080600080600060a086880312156115f357600080fd5b85356115fe816111b3565b9450602086013561160e816111b3565b9350604086013592506060860135915060808601356001600160401b0381111561163757600080fd5b61154688828901611455565b6000806000806080858703121561165957600080fd5b8435611664816111b3565b93506020850135611674816111b3565b92506040850135611684816111b3565b91506060850135611694816111b3565b939692955090935050565b600080858511156116af57600080fd5b838611156116bc57600080fd5b5050820193919092039150565b803560208310156103ae57600019602084900360031b1b1692915050565b60005b838110156117025781810151838201526020016116ea565b50506000910152565b60006020828403121561171d57600080fd5b81516001600160401b0381111561173357600080fd5b8201601f8101841361174457600080fd5b80516117526113e48261142e565b81815285602083850101111561176757600080fd5b6117788260208301602086016116e7565b95945050505050565b600081518084526117998160208601602086016116e7565b601f01601f19169290920160200192915050565b8381526001600160a01b038316602082015260606040820181905260009061177890830184611781565b6001600160a01b03831681526040602082018190526000906117fb90830184611781565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b8581101561188f578135611874816111b3565b6001600160a01b031687529582019590820190600101611861565b509495945050505050565b81835260006001600160fb1b038311156118b357600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c0606082018190526000906118ff908301888a611851565b828103608084015261191281878961189a565b905082810360a084015261192781858761189a565b9c9b505050505050505050505050565b60608152600061194b60608301888a611851565b828103602084015261195e81878961189a565b9050828103604084015261197381858761189a565b9998505050505050505050565b600080600080600060a0868803121561199857600080fd5b85356119a3816111b3565b945060208601356119b3816111b3565b935060408601356119c3816111b3565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c08789031215611a0a57600080fd5b86359550602080880135611a1d816111b3565b95506040880135611a2d816111b3565b945060608801356001600160401b0380821115611a4957600080fd5b818a0191508a601f830112611a5d57600080fd5b8135611a6b6113e4826113a0565b81815260059190911b8301840190848101908d831115611a8a57600080fd5b938501935b82851015611ab1578435611aa2816111b3565b82529385019390850190611a8f565b9750505060808a0135925080831115611ac957600080fd5b611ad58b848c016113c3565b945060a08a0135925080831115611aeb57600080fd5b5050611af989828a016113c3565b9150509295509295509295565b600081518084526020808501945080840160005b8381101561188f57815187529582019590820190600101611b1a565b606080825284519082018190526000906020906080840190828801845b82811015611b785781516001600160a01b031684529284019290840190600101611b53565b50505083810382850152611b8c8187611b06565b9150508281036040840152611ba18185611b06565b969550505050505056fe526f6f744d696e7461626c65455243313135355072656469636174653a20494ea2646970667358221220bac4157c867ef25ba423441a6f4177226bff4063bb665be9fb147719e7b08cc664736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RootMintableERC1155PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC1155PredicateAccessList","sourceName":"contracts/child/RootMintableERC1155PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2MintableERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2MintableERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"childToken","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155BatchReceived","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612480806100206000396000f3fe608060405234801561001057600080fd5b506004361061021c5760003560e01c8063a78e111c11610125578063d8dd1773116100ad578063f23a6e611161007c578063f23a6e61146104d3578063f2fde38b146104f2578063f4a120f714610505578063f645125514610518578063f8c8765e1461053f57600080fd5b8063d8dd177314610493578063e0563ab1146104a6578063e30c3978146104af578063eeb49945146104c057600080fd5b8063c1225a20116100f4578063c1225a20146103f8578063c5ac2b1c1461040b578063c5e4683a14610432578063d41f177114610445578063d7c9e3ec1461046c57600080fd5b8063a78e111c14610373578063b176806514610386578063b68ad1e4146103ad578063bc197c81146103c057600080fd5b806355b01e4d116101a857806379ba50971161017757806379ba50971461031d5780637efab4f5146103255780638da5cb5b1461034f578063947287cf1461036057806397e5230d1461036957600080fd5b806355b01e4d146102dd5780635ea5df79146102eb578063654715e614610302578063715018a61461031557600080fd5b80631bc114ba116101ef5780631bc114ba14610297578063284017f5146102aa5780633b878c22146102b35780634c4c45de146102bc57806351351d53146102cf57600080fd5b806301ffc9a71461022157806305dc2e8f1461024957806307b3e252146102745780630efe6a8b14610282575b600080fd5b61023461022f3660046118c4565b610552565b60405190151581526020015b60405180910390f35b60fd5461025c906001600160a01b031681565b6040516001600160a01b039091168152602001610240565b61025c6004600360981b0181565b61029561029036600461190a565b610589565b005b60fc5461025c906001600160a01b031681565b61025c61202081565b61025c61101081565b6102956102ca36600461198a565b61059a565b61025c6002600160a01b0381565b61025c6004600160991b0181565b6102f461138881565b604051908152602001610240565b60fe5461025c906001600160a01b031681565b610295610614565b610295610628565b61025c610333366004611a36565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b031661025c565b6102f461520881565b6102f4620249f081565b610295610381366004611a53565b6106a2565b6102f47f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff5461025c906001600160a01b031681565b6103df6103ce366004611be5565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610240565b610295610406366004611ca2565b6106b4565b6102f47faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b610295610440366004611ca2565b610703565b6102f47f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102f47f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6102956104a1366004611cbd565b61074a565b61025c61203081565b6065546001600160a01b031661025c565b6102956104ce366004611d4f565b610888565b6103df6104e1366004611dd7565b63f23a6e6160e01b95945050505050565b610295610500366004611a36565b610a60565b61025c610513366004611a36565b610ad1565b6102f47f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61029561054d366004611e3f565b610de1565b60006001600160e01b03198216630271189760e51b148061058357506301ffc9a760e01b6001600160e01b03198316145b92915050565b61059583338484610eb3565b505050565b84831480156105a857508481145b6105fc5760405162461bcd60e51b815260206004820152602c602482015260008051602061242b83398151915260448201526b0ac82989288be988a9c8ea8960a31b60648201526084015b60405180910390fd5b61060b8787878787878761104b565b50505050505050565b61061c611228565b6106266000611282565b565b60655433906001600160a01b031681146106965760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016105f3565b61069f81611282565b50565b6106ae84848484610eb3565b50505050565b6106bc611228565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b61070b611228565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b031461078e5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064016105f3565b600054610100900460ff16158080156107ae5750600054600160ff909116105b806107c85750303b1580156107c8575060005460ff166001145b6107e45760405162461bcd60e51b81526004016105f390611e9b565b6000805460ff191660011790558015610807576000805461ff0019166101001790555b6108138888888861129b565b60c9805461ffff191685151561ff001916176101008515150217905561083882611282565b801561087e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146108fc5760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e604482015270262cafa9aa20aa22afa922a1a2a4ab22a960791b60648201526084016105f3565b60fe546001600160a01b038481169116146109745760405162461bcd60e51b815260206004820152603260248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e6044820152714c595f4348494c445f50524544494341544560701b60648201526084016105f3565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696109a3602060008486611ee9565b6109ac91611f13565b036109cb576109c66109c18260208186611ee9565b611398565b6106ae565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26109fa602060008486611ee9565b610a0391611f13565b03610a12576109c682826114a6565b60405162461bcd60e51b815260206004820152602f602482015260008051602061242b83398151915260448201526e56414c49445f5349474e415455524560881b60648201526084016105f3565b610a68611228565b606580546001600160a01b0383166001600160a01b03199091168117909155610a996033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b038216610b2b5760405162461bcd60e51b815260206004820152602b602482015260008051602061242b83398151915260448201526a2b20a624a22faa27a5a2a760a91b60648201526084016105f3565b6001600160a01b03828116600090815261010060205260409020541615610ba95760405162461bcd60e51b815260206004820152602c60248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20414c60448201526b149150511657d3505414115160a21b60648201526084016105f3565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692610c53921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0384811660008181526101006020908152604080832080546001600160a01b031916958716959095179094558351908101845281815292516303a24d0760e21b815260048101919091529294509091630e89341c90602401600060405180830381865afa925050508015610cf057506040513d6000823e601f3d908101601f19168201604052610ced9190810190611f55565b60015b15610cf85790505b60fc546040516001600160a01b03909116906316f19831908490610d44907f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad9089908790602001611ff7565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d70929190612021565b600060405180830381600087803b158015610d8a57600080fd5b505af1158015610d9e573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a35050919050565b600054610100900460ff1615808015610e015750600054600160ff909116105b80610e1b5750303b158015610e1b575060005460ff166001145b610e375760405162461bcd60e51b81526004016105f390611e9b565b6000805460ff191660011790558015610e5a576000805461ff0019166101001790555b610e668585858561129b565b8015610eac576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b610ebb611608565b6000610ec685611610565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610efb90339030908890889060040161204d565b600060405180830381600087803b158015610f1557600080fd5b505af1158015610f29573d6000803e3d6000fd5b505060fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935293841695506316f198319450610fc0939092169160e401612021565b600060405180830381600087803b158015610fda57600080fd5b505af1158015610fee573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fe6f1fb6bb1930a5d4b997d56e0a4a8cb6f3f941f0d5391f63c1f6914ee01e0b89060600160405180910390a4610eac565b611053611608565b600061105e88611610565b905060005b8481101561110a57886001600160a01b031663f242432a333089898681811061108e5761108e612085565b905060200201358888878181106110a7576110a7612085565b905060200201356040518563ffffffff1660e01b81526004016110cd949392919061204d565b600060405180830381600087803b1580156110e757600080fd5b505af11580156110fb573d6000803e3d6000fd5b50505050806001019050611063565b5060fc5460fe546040516001600160a01b03928316926316f19831921690611166907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e90602001612116565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401611192929190612021565b600060405180830381600087803b1580156111ac57600080fd5b505af11580156111c0573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167fa7d9cd27143f817fe006011faf3c04351f70f75cd30e7b21405817f2f670041e8a8a8a8a8a8a60405161121b96959493929190612181565b60405180910390a461087e565b6033546001600160a01b031633146106265760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016105f3565b606580546001600160a01b031916905561069f81611658565b6001600160a01b038416158015906112bb57506001600160a01b03831615155b80156112cf57506001600160a01b03821615155b80156112e357506001600160a01b03811615155b6113485760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b60648201526084016105f3565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b6000808080806113aa868801886121ca565b6001600160a01b0380861660009081526101006020526040902054959a509398509196509450925016806113e0576113e0612225565b604051637921219560e11b81526001600160a01b0387169063f242432a9061141290309088908890889060040161204d565b600060405180830381600087803b15801561142c57600080fd5b505af1158015611440573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907f52cdfbe452878311d3237a4c20a951600d8e3a4fe6691d967d33788dc12d19c6906060015b60405180910390a45050505050505050565b6000808080806114b88688018861223b565b6001600160a01b0380861660009081526101006020526040902054959b5093995091975095509350169050806114f0576114f0612225565b60005b83518110156115b657866001600160a01b031663f242432a3087848151811061151e5761151e612085565b602002602001015187858151811061153857611538612085565b602002602001015187868151811061155257611552612085565b60200260200101516040518563ffffffff1660e01b8152600401611579949392919061204d565b600060405180830381600087803b15801561159357600080fd5b505af11580156115a7573d6000803e3d6000fd5b505050508060010190506114f3565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167f52733a40a0466155541c2fc4044165dd37a3db116bc834bab2f020665e90fd2087878760405161149493929190612380565b6106266116aa565b6001600160a01b0380821660009081526101006020526040902054168061163d5761163a82610ad1565b90505b6001600160a01b03811661165357611653612225565b919050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff16156117b557604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161170c91906123f5565b6000604051808303818686fa925050503d8060008114611748576040519150601f19603f3d011682016040523d82523d6000602084013e61174d565b606091505b509150915081801561177257506000818060200190518101906117709190612411565b115b6117b25760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016105f3565b50505b60c954610100900460ff161561062657604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161181c91906123f5565b6000604051808303818686fa925050503d8060008114611858576040519150601f19603f3d011682016040523d82523d6000602084013e61185d565b606091505b509150915081801561188357508080602001905181019061187e9190612411565b600114155b6118c05760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016105f3565b5050565b6000602082840312156118d657600080fd5b81356001600160e01b0319811681146118ee57600080fd5b9392505050565b6001600160a01b038116811461069f57600080fd5b60008060006060848603121561191f57600080fd5b833561192a816118f5565b95602085013595506040909401359392505050565b60008083601f84011261195157600080fd5b5081356001600160401b0381111561196857600080fd5b6020830191508360208260051b850101111561198357600080fd5b9250929050565b60008060008060008060006080888a0312156119a557600080fd5b87356119b0816118f5565b965060208801356001600160401b03808211156119cc57600080fd5b6119d88b838c0161193f565b909850965060408a01359150808211156119f157600080fd5b6119fd8b838c0161193f565b909650945060608a0135915080821115611a1657600080fd5b50611a238a828b0161193f565b989b979a50959850939692959293505050565b600060208284031215611a4857600080fd5b81356118ee816118f5565b60008060008060808587031215611a6957600080fd5b8435611a74816118f5565b93506020850135611a84816118f5565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611ad757611ad7611a99565b604052919050565b60006001600160401b03821115611af857611af8611a99565b5060051b60200190565b600082601f830112611b1357600080fd5b81356020611b28611b2383611adf565b611aaf565b82815260059290921b84018101918181019086841115611b4757600080fd5b8286015b84811015611b625780358352918301918301611b4b565b509695505050505050565b60006001600160401b03821115611b8657611b86611a99565b50601f01601f191660200190565b600082601f830112611ba557600080fd5b8135611bb3611b2382611b6d565b818152846020838601011115611bc857600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a08688031215611bfd57600080fd5b8535611c08816118f5565b94506020860135611c18816118f5565b935060408601356001600160401b0380821115611c3457600080fd5b611c4089838a01611b02565b94506060880135915080821115611c5657600080fd5b611c6289838a01611b02565b93506080880135915080821115611c7857600080fd5b50611c8588828901611b94565b9150509295509295909350565b8035801515811461165357600080fd5b600060208284031215611cb457600080fd5b6118ee82611c92565b600080600080600080600060e0888a031215611cd857600080fd5b8735611ce3816118f5565b96506020880135611cf3816118f5565b95506040880135611d03816118f5565b94506060880135611d13816118f5565b9350611d2160808901611c92565b9250611d2f60a08901611c92565b915060c0880135611d3f816118f5565b8091505092959891949750929550565b60008060008060608587031215611d6557600080fd5b843593506020850135611d77816118f5565b925060408501356001600160401b0380821115611d9357600080fd5b818701915087601f830112611da757600080fd5b813581811115611db657600080fd5b886020828501011115611dc857600080fd5b95989497505060200194505050565b600080600080600060a08688031215611def57600080fd5b8535611dfa816118f5565b94506020860135611e0a816118f5565b9350604086013592506060860135915060808601356001600160401b03811115611e3357600080fd5b611c8588828901611b94565b60008060008060808587031215611e5557600080fd5b8435611e60816118f5565b93506020850135611e70816118f5565b92506040850135611e80816118f5565b91506060850135611e90816118f5565b939692955090935050565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611ef957600080fd5b83861115611f0657600080fd5b5050820193919092039150565b8035602083101561058357600019602084900360031b1b1692915050565b60005b83811015611f4c578181015183820152602001611f34565b50506000910152565b600060208284031215611f6757600080fd5b81516001600160401b03811115611f7d57600080fd5b8201601f81018413611f8e57600080fd5b8051611f9c611b2382611b6d565b818152856020838501011115611fb157600080fd5b611fc2826020830160208601611f31565b95945050505050565b60008151808452611fe3816020860160208601611f31565b601f01601f19169290920160200192915050565b8381526001600160a01b0383166020820152606060408201819052600090611fc290830184611fcb565b6001600160a01b038316815260406020820181905260009061204590830184611fcb565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b858110156120d95781356120be816118f5565b6001600160a01b0316875295820195908201906001016120ab565b509495945050505050565b81835260006001600160fb1b038311156120fd57600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090612149908301888a61209b565b828103608084015261215c8187896120e4565b905082810360a08401526121718185876120e4565b9c9b505050505050505050505050565b60608152600061219560608301888a61209b565b82810360208401526121a88187896120e4565b905082810360408401526121bd8185876120e4565b9998505050505050505050565b600080600080600060a086880312156121e257600080fd5b85356121ed816118f5565b945060208601356121fd816118f5565b9350604086013561220d816118f5565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c0878903121561225457600080fd5b86359550602080880135612267816118f5565b95506040880135612277816118f5565b945060608801356001600160401b038082111561229357600080fd5b818a0191508a601f8301126122a757600080fd5b81356122b5611b2382611adf565b81815260059190911b8301840190848101908d8311156122d457600080fd5b938501935b828510156122fb5784356122ec816118f5565b825293850193908501906122d9565b9750505060808a013592508083111561231357600080fd5b61231f8b848c01611b02565b945060a08a013592508083111561233557600080fd5b505061234389828a01611b02565b9150509295509295509295565b600081518084526020808501945080840160005b838110156120d957815187529582019590820190600101612364565b606080825284519082018190526000906020906080840190828801845b828110156123c25781516001600160a01b03168452928401929084019060010161239d565b505050838103828501526123d68187612350565b91505082810360408401526123eb8185612350565b9695505050505050565b60008251612407818460208701611f31565b9190910192915050565b60006020828403121561242357600080fd5b505191905056fe526f6f744d696e7461626c65455243313135355072656469636174653a20494ea26469706673582212207cc4d2e1fa811483449e50a585f2819503c945760fb6c93dc493fe7ad5264ad364736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061021c5760003560e01c8063a78e111c11610125578063d8dd1773116100ad578063f23a6e611161007c578063f23a6e61146104d3578063f2fde38b146104f2578063f4a120f714610505578063f645125514610518578063f8c8765e1461053f57600080fd5b8063d8dd177314610493578063e0563ab1146104a6578063e30c3978146104af578063eeb49945146104c057600080fd5b8063c1225a20116100f4578063c1225a20146103f8578063c5ac2b1c1461040b578063c5e4683a14610432578063d41f177114610445578063d7c9e3ec1461046c57600080fd5b8063a78e111c14610373578063b176806514610386578063b68ad1e4146103ad578063bc197c81146103c057600080fd5b806355b01e4d116101a857806379ba50971161017757806379ba50971461031d5780637efab4f5146103255780638da5cb5b1461034f578063947287cf1461036057806397e5230d1461036957600080fd5b806355b01e4d146102dd5780635ea5df79146102eb578063654715e614610302578063715018a61461031557600080fd5b80631bc114ba116101ef5780631bc114ba14610297578063284017f5146102aa5780633b878c22146102b35780634c4c45de146102bc57806351351d53146102cf57600080fd5b806301ffc9a71461022157806305dc2e8f1461024957806307b3e252146102745780630efe6a8b14610282575b600080fd5b61023461022f3660046118c4565b610552565b60405190151581526020015b60405180910390f35b60fd5461025c906001600160a01b031681565b6040516001600160a01b039091168152602001610240565b61025c6004600360981b0181565b61029561029036600461190a565b610589565b005b60fc5461025c906001600160a01b031681565b61025c61202081565b61025c61101081565b6102956102ca36600461198a565b61059a565b61025c6002600160a01b0381565b61025c6004600160991b0181565b6102f461138881565b604051908152602001610240565b60fe5461025c906001600160a01b031681565b610295610614565b610295610628565b61025c610333366004611a36565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b031661025c565b6102f461520881565b6102f4620249f081565b610295610381366004611a53565b6106a2565b6102f47f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff5461025c906001600160a01b031681565b6103df6103ce366004611be5565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610240565b610295610406366004611ca2565b6106b4565b6102f47faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b610295610440366004611ca2565b610703565b6102f47f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102f47f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6102956104a1366004611cbd565b61074a565b61025c61203081565b6065546001600160a01b031661025c565b6102956104ce366004611d4f565b610888565b6103df6104e1366004611dd7565b63f23a6e6160e01b95945050505050565b610295610500366004611a36565b610a60565b61025c610513366004611a36565b610ad1565b6102f47f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61029561054d366004611e3f565b610de1565b60006001600160e01b03198216630271189760e51b148061058357506301ffc9a760e01b6001600160e01b03198316145b92915050565b61059583338484610eb3565b505050565b84831480156105a857508481145b6105fc5760405162461bcd60e51b815260206004820152602c602482015260008051602061242b83398151915260448201526b0ac82989288be988a9c8ea8960a31b60648201526084015b60405180910390fd5b61060b8787878787878761104b565b50505050505050565b61061c611228565b6106266000611282565b565b60655433906001600160a01b031681146106965760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016105f3565b61069f81611282565b50565b6106ae84848484610eb3565b50505050565b6106bc611228565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b61070b611228565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b031461078e5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064016105f3565b600054610100900460ff16158080156107ae5750600054600160ff909116105b806107c85750303b1580156107c8575060005460ff166001145b6107e45760405162461bcd60e51b81526004016105f390611e9b565b6000805460ff191660011790558015610807576000805461ff0019166101001790555b6108138888888861129b565b60c9805461ffff191685151561ff001916176101008515150217905561083882611282565b801561087e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146108fc5760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e604482015270262cafa9aa20aa22afa922a1a2a4ab22a960791b60648201526084016105f3565b60fe546001600160a01b038481169116146109745760405162461bcd60e51b815260206004820152603260248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e6044820152714c595f4348494c445f50524544494341544560701b60648201526084016105f3565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696109a3602060008486611ee9565b6109ac91611f13565b036109cb576109c66109c18260208186611ee9565b611398565b6106ae565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26109fa602060008486611ee9565b610a0391611f13565b03610a12576109c682826114a6565b60405162461bcd60e51b815260206004820152602f602482015260008051602061242b83398151915260448201526e56414c49445f5349474e415455524560881b60648201526084016105f3565b610a68611228565b606580546001600160a01b0383166001600160a01b03199091168117909155610a996033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b038216610b2b5760405162461bcd60e51b815260206004820152602b602482015260008051602061242b83398151915260448201526a2b20a624a22faa27a5a2a760a91b60648201526084016105f3565b6001600160a01b03828116600090815261010060205260409020541615610ba95760405162461bcd60e51b815260206004820152602c60248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20414c60448201526b149150511657d3505414115160a21b60648201526084016105f3565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692610c53921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0384811660008181526101006020908152604080832080546001600160a01b031916958716959095179094558351908101845281815292516303a24d0760e21b815260048101919091529294509091630e89341c90602401600060405180830381865afa925050508015610cf057506040513d6000823e601f3d908101601f19168201604052610ced9190810190611f55565b60015b15610cf85790505b60fc546040516001600160a01b03909116906316f19831908490610d44907f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad9089908790602001611ff7565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d70929190612021565b600060405180830381600087803b158015610d8a57600080fd5b505af1158015610d9e573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a35050919050565b600054610100900460ff1615808015610e015750600054600160ff909116105b80610e1b5750303b158015610e1b575060005460ff166001145b610e375760405162461bcd60e51b81526004016105f390611e9b565b6000805460ff191660011790558015610e5a576000805461ff0019166101001790555b610e668585858561129b565b8015610eac576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b610ebb611608565b6000610ec685611610565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610efb90339030908890889060040161204d565b600060405180830381600087803b158015610f1557600080fd5b505af1158015610f29573d6000803e3d6000fd5b505060fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935293841695506316f198319450610fc0939092169160e401612021565b600060405180830381600087803b158015610fda57600080fd5b505af1158015610fee573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fe6f1fb6bb1930a5d4b997d56e0a4a8cb6f3f941f0d5391f63c1f6914ee01e0b89060600160405180910390a4610eac565b611053611608565b600061105e88611610565b905060005b8481101561110a57886001600160a01b031663f242432a333089898681811061108e5761108e612085565b905060200201358888878181106110a7576110a7612085565b905060200201356040518563ffffffff1660e01b81526004016110cd949392919061204d565b600060405180830381600087803b1580156110e757600080fd5b505af11580156110fb573d6000803e3d6000fd5b50505050806001019050611063565b5060fc5460fe546040516001600160a01b03928316926316f19831921690611166907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e90602001612116565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401611192929190612021565b600060405180830381600087803b1580156111ac57600080fd5b505af11580156111c0573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167fa7d9cd27143f817fe006011faf3c04351f70f75cd30e7b21405817f2f670041e8a8a8a8a8a8a60405161121b96959493929190612181565b60405180910390a461087e565b6033546001600160a01b031633146106265760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016105f3565b606580546001600160a01b031916905561069f81611658565b6001600160a01b038416158015906112bb57506001600160a01b03831615155b80156112cf57506001600160a01b03821615155b80156112e357506001600160a01b03811615155b6113485760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b60648201526084016105f3565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b6000808080806113aa868801886121ca565b6001600160a01b0380861660009081526101006020526040902054959a509398509196509450925016806113e0576113e0612225565b604051637921219560e11b81526001600160a01b0387169063f242432a9061141290309088908890889060040161204d565b600060405180830381600087803b15801561142c57600080fd5b505af1158015611440573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907f52cdfbe452878311d3237a4c20a951600d8e3a4fe6691d967d33788dc12d19c6906060015b60405180910390a45050505050505050565b6000808080806114b88688018861223b565b6001600160a01b0380861660009081526101006020526040902054959b5093995091975095509350169050806114f0576114f0612225565b60005b83518110156115b657866001600160a01b031663f242432a3087848151811061151e5761151e612085565b602002602001015187858151811061153857611538612085565b602002602001015187868151811061155257611552612085565b60200260200101516040518563ffffffff1660e01b8152600401611579949392919061204d565b600060405180830381600087803b15801561159357600080fd5b505af11580156115a7573d6000803e3d6000fd5b505050508060010190506114f3565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167f52733a40a0466155541c2fc4044165dd37a3db116bc834bab2f020665e90fd2087878760405161149493929190612380565b6106266116aa565b6001600160a01b0380821660009081526101006020526040902054168061163d5761163a82610ad1565b90505b6001600160a01b03811661165357611653612225565b919050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff16156117b557604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161170c91906123f5565b6000604051808303818686fa925050503d8060008114611748576040519150601f19603f3d011682016040523d82523d6000602084013e61174d565b606091505b509150915081801561177257506000818060200190518101906117709190612411565b115b6117b25760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016105f3565b50505b60c954610100900460ff161561062657604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161181c91906123f5565b6000604051808303818686fa925050503d8060008114611858576040519150601f19603f3d011682016040523d82523d6000602084013e61185d565b606091505b509150915081801561188357508080602001905181019061187e9190612411565b600114155b6118c05760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016105f3565b5050565b6000602082840312156118d657600080fd5b81356001600160e01b0319811681146118ee57600080fd5b9392505050565b6001600160a01b038116811461069f57600080fd5b60008060006060848603121561191f57600080fd5b833561192a816118f5565b95602085013595506040909401359392505050565b60008083601f84011261195157600080fd5b5081356001600160401b0381111561196857600080fd5b6020830191508360208260051b850101111561198357600080fd5b9250929050565b60008060008060008060006080888a0312156119a557600080fd5b87356119b0816118f5565b965060208801356001600160401b03808211156119cc57600080fd5b6119d88b838c0161193f565b909850965060408a01359150808211156119f157600080fd5b6119fd8b838c0161193f565b909650945060608a0135915080821115611a1657600080fd5b50611a238a828b0161193f565b989b979a50959850939692959293505050565b600060208284031215611a4857600080fd5b81356118ee816118f5565b60008060008060808587031215611a6957600080fd5b8435611a74816118f5565b93506020850135611a84816118f5565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611ad757611ad7611a99565b604052919050565b60006001600160401b03821115611af857611af8611a99565b5060051b60200190565b600082601f830112611b1357600080fd5b81356020611b28611b2383611adf565b611aaf565b82815260059290921b84018101918181019086841115611b4757600080fd5b8286015b84811015611b625780358352918301918301611b4b565b509695505050505050565b60006001600160401b03821115611b8657611b86611a99565b50601f01601f191660200190565b600082601f830112611ba557600080fd5b8135611bb3611b2382611b6d565b818152846020838601011115611bc857600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a08688031215611bfd57600080fd5b8535611c08816118f5565b94506020860135611c18816118f5565b935060408601356001600160401b0380821115611c3457600080fd5b611c4089838a01611b02565b94506060880135915080821115611c5657600080fd5b611c6289838a01611b02565b93506080880135915080821115611c7857600080fd5b50611c8588828901611b94565b9150509295509295909350565b8035801515811461165357600080fd5b600060208284031215611cb457600080fd5b6118ee82611c92565b600080600080600080600060e0888a031215611cd857600080fd5b8735611ce3816118f5565b96506020880135611cf3816118f5565b95506040880135611d03816118f5565b94506060880135611d13816118f5565b9350611d2160808901611c92565b9250611d2f60a08901611c92565b915060c0880135611d3f816118f5565b8091505092959891949750929550565b60008060008060608587031215611d6557600080fd5b843593506020850135611d77816118f5565b925060408501356001600160401b0380821115611d9357600080fd5b818701915087601f830112611da757600080fd5b813581811115611db657600080fd5b886020828501011115611dc857600080fd5b95989497505060200194505050565b600080600080600060a08688031215611def57600080fd5b8535611dfa816118f5565b94506020860135611e0a816118f5565b9350604086013592506060860135915060808601356001600160401b03811115611e3357600080fd5b611c8588828901611b94565b60008060008060808587031215611e5557600080fd5b8435611e60816118f5565b93506020850135611e70816118f5565b92506040850135611e80816118f5565b91506060850135611e90816118f5565b939692955090935050565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611ef957600080fd5b83861115611f0657600080fd5b5050820193919092039150565b8035602083101561058357600019602084900360031b1b1692915050565b60005b83811015611f4c578181015183820152602001611f34565b50506000910152565b600060208284031215611f6757600080fd5b81516001600160401b03811115611f7d57600080fd5b8201601f81018413611f8e57600080fd5b8051611f9c611b2382611b6d565b818152856020838501011115611fb157600080fd5b611fc2826020830160208601611f31565b95945050505050565b60008151808452611fe3816020860160208601611f31565b601f01601f19169290920160200192915050565b8381526001600160a01b0383166020820152606060408201819052600090611fc290830184611fcb565b6001600160a01b038316815260406020820181905260009061204590830184611fcb565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b858110156120d95781356120be816118f5565b6001600160a01b0316875295820195908201906001016120ab565b509495945050505050565b81835260006001600160fb1b038311156120fd57600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090612149908301888a61209b565b828103608084015261215c8187896120e4565b905082810360a08401526121718185876120e4565b9c9b505050505050505050505050565b60608152600061219560608301888a61209b565b82810360208401526121a88187896120e4565b905082810360408401526121bd8185876120e4565b9998505050505050505050565b600080600080600060a086880312156121e257600080fd5b85356121ed816118f5565b945060208601356121fd816118f5565b9350604086013561220d816118f5565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c0878903121561225457600080fd5b86359550602080880135612267816118f5565b95506040880135612277816118f5565b945060608801356001600160401b038082111561229357600080fd5b818a0191508a601f8301126122a757600080fd5b81356122b5611b2382611adf565b81815260059190911b8301840190848101908d8311156122d457600080fd5b938501935b828510156122fb5784356122ec816118f5565b825293850193908501906122d9565b9750505060808a013592508083111561231357600080fd5b61231f8b848c01611b02565b945060a08a013592508083111561233557600080fd5b505061234389828a01611b02565b9150509295509295509295565b600081518084526020808501945080840160005b838110156120d957815187529582019590820190600101612364565b606080825284519082018190526000906020906080840190828801845b828110156123c25781516001600160a01b03168452928401929084019060010161239d565b505050838103828501526123d68187612350565b91505082810360408401526123eb8185612350565b9695505050505050565b60008251612407818460208701611f31565b9190910192915050565b60006020828403121561242357600080fd5b505191905056fe526f6f744d696e7461626c65455243313135355072656469636174653a20494ea26469706673582212207cc4d2e1fa811483449e50a585f2819503c945760fb6c93dc493fe7ad5264ad364736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var SystemArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"System","sourceName":"contracts/child/System.sol","abi":[{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061015a806100206000396000f3fe608060405234801561001057600080fd5b50600436106100935760003560e01c806355b01e4d1161006657806355b01e4d146100e35780635ea5df79146100f1578063947287cf1461010857806397e5230d14610111578063e0563ab11461011b57600080fd5b806307b3e25214610098578063284017f5146100c35780633b878c22146100cc57806351351d53146100d5575b600080fd5b6100a66004600360981b0181565b6040516001600160a01b0390911681526020015b60405180910390f35b6100a661202081565b6100a661101081565b6100a66002600160a01b0381565b6100a66004600160991b0181565b6100fa61138881565b6040519081526020016100ba565b6100fa61520881565b6100fa620249f081565b6100a66120308156fea2646970667358221220cdc81f82626224fb8a04246ca1d1898f8b03c160e9b2f63cd0bc4b5d0b55c3f964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100935760003560e01c806355b01e4d1161006657806355b01e4d146100e35780635ea5df79146100f1578063947287cf1461010857806397e5230d14610111578063e0563ab11461011b57600080fd5b806307b3e25214610098578063284017f5146100c35780633b878c22146100cc57806351351d53146100d5575b600080fd5b6100a66004600360981b0181565b6040516001600160a01b0390911681526020015b60405180910390f35b6100a661202081565b6100a661101081565b6100a66002600160a01b0381565b6100a66004600160991b0181565b6100fa61138881565b6040519081526020016100ba565b6100fa61520881565b6100fa620249f081565b6100a66120308156fea2646970667358221220cdc81f82626224fb8a04246ca1d1898f8b03c160e9b2f63cd0bc4b5d0b55c3f964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var L2StateSenderArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"L2StateSender","sourceName":"contracts/blade/L2StateSender.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"bytes","name":"data","type":"bytes"}],"name":"L2StateSynced","type":"event"},{"inputs":[],"name":"MAX_LENGTH","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"counter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"syncState","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50610297806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806316f198311461004657806361bc221a1461005b578063a6f9885c14610076575b600080fd5b61005961005436600461017a565b61007f565b005b61006460005481565b60405190815260200160405180910390f35b61006461080081565b6001600160a01b0383166100cd5760405162461bcd60e51b815260206004820152601060248201526f24a72b20a624a22fa922a1a2a4ab22a960811b60448201526064015b60405180910390fd5b6108008111156101145760405162461bcd60e51b815260206004820152601260248201527108ab0868a8a88a6be9a82b0be988a9c8ea8960731b60448201526064016100c4565b826001600160a01b0316336001600160a01b031660008081546101369061020b565b9190508190557fedaf3c471ebd67d60c29efe34b639ede7d6a1d92eaeb3f503e784971e67118a5858560405161016d929190610232565b60405180910390a4505050565b60008060006040848603121561018f57600080fd5b83356001600160a01b03811681146101a657600080fd5b9250602084013567ffffffffffffffff808211156101c357600080fd5b818601915086601f8301126101d757600080fd5b8135818111156101e657600080fd5b8760208285010111156101f857600080fd5b6020830194508093505050509250925092565b60006001820161022b57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea2646970667358221220328e934bd386ef5d30a72d62e104182a16bcfd6af3e0ba82ff08b1eb8327c4ab64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100415760003560e01c806316f198311461004657806361bc221a1461005b578063a6f9885c14610076575b600080fd5b61005961005436600461017a565b61007f565b005b61006460005481565b60405190815260200160405180910390f35b61006461080081565b6001600160a01b0383166100cd5760405162461bcd60e51b815260206004820152601060248201526f24a72b20a624a22fa922a1a2a4ab22a960811b60448201526064015b60405180910390fd5b6108008111156101145760405162461bcd60e51b815260206004820152601260248201527108ab0868a8a88a6be9a82b0be988a9c8ea8960731b60448201526064016100c4565b826001600160a01b0316336001600160a01b031660008081546101369061020b565b9190508190557fedaf3c471ebd67d60c29efe34b639ede7d6a1d92eaeb3f503e784971e67118a5858560405161016d929190610232565b60405180910390a4505050565b60008060006040848603121561018f57600080fd5b83356001600160a01b03811681146101a657600080fd5b9250602084013567ffffffffffffffff808211156101c357600080fd5b818601915086601f8301126101d757600080fd5b8135818111156101e657600080fd5b8760208285010111156101f857600080fd5b6020830194508093505050509250925092565b60006001820161022b57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea2646970667358221220328e934bd386ef5d30a72d62e104182a16bcfd6af3e0ba82ff08b1eb8327c4ab64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var StateReceiverArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"StateReceiver","sourceName":"contracts/blade/StateReceiver.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"startId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"endId","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"root","type":"bytes32"}],"name":"NewCommitment","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"counter","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"},{"indexed":false,"internalType":"bytes","name":"message","type":"bytes"}],"name":"StateSyncResult","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[][]","name":"proofs","type":"bytes32[][]"},{"components":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"internalType":"struct StateReceiver.StateSync[]","name":"objs","type":"tuple[]"}],"name":"batchExecute","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"startId","type":"uint256"},{"internalType":"uint256","name":"endId","type":"uint256"},{"internalType":"bytes32","name":"root","type":"bytes32"}],"internalType":"struct StateReceiver.StateSyncCommitment","name":"commitment","type":"tuple"},{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"bytes","name":"bitmap","type":"bytes"}],"name":"commit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"commitmentCounter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"commitmentIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"commitments","outputs":[{"internalType":"uint256","name":"startId","type":"uint256"},{"internalType":"uint256","name":"endId","type":"uint256"},{"internalType":"bytes32","name":"root","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"},{"components":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"internalType":"struct StateReceiver.StateSync","name":"obj","type":"tuple"}],"name":"execute","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getCommitmentByStateSyncId","outputs":[{"components":[{"internalType":"uint256","name":"startId","type":"uint256"},{"internalType":"uint256","name":"endId","type":"uint256"},{"internalType":"bytes32","name":"root","type":"bytes32"}],"internalType":"struct StateReceiver.StateSyncCommitment","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getRootByStateSyncId","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lastCommittedId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"processedStateSyncs","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611244806100206000396000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c806355b01e4d116100ad578063ad240c2a11610071578063ad240c2a1461026a578063c59a18f714610273578063c6df461714610286578063e0563ab114610299578063eb70ef44146102a257600080fd5b806355b01e4d1461022d5780635ea5df791461023b5780639017c12714610244578063947287cf1461025757806397e5230d1461026057600080fd5b80633b878c22116100f45780633b878c221461018457806349ce89971461018d57806350d5b95b146101d757806351351d53146101ec578063544c5e0f146101fa57600080fd5b806307b3e25214610126578063196f1b2d1461015157806323e281cf14610172578063284017f51461017b575b600080fd5b6101346004600360981b0181565b6040516001600160a01b0390911681526020015b60405180910390f35b61016461015f366004610cd6565b6102d7565b604051908152602001610148565b61016460325481565b61013461202081565b61013461101081565b6101bc61019b366004610cd6565b60356020526000908152604090208054600182015460029092015490919083565b60408051938452602084019290925290820152606001610148565b6101ea6101e5366004610d3a565b610356565b005b6101346002600160a01b0381565b61021d610208366004610cd6565b60346020526000908152604090205460ff1681565b6040519015158152602001610148565b6101346004600160991b0181565b61016461138881565b6101ea610252366004610da9565b61041d565b61016461520881565b610164620249f081565b61016460335481565b610164610281366004610cd6565b6105bd565b6101ea610294366004610e55565b6105de565b61013461203081565b6102b56102b0366004610cd6565b6107c2565b6040805182518152602080840151908201529181015190820152606001610148565b6000806035816102e8603686610885565b81526020810191909152604001600020600201549050806103505760405162461bcd60e51b815260206004820152601d60248201527f537461746552656365697665723a204e4f5f524f4f545f464f525f494400000060448201526064015b60405180910390fd5b92915050565b600061036282356107c2565b80519091506103d290610376908435610ef3565b825160208401516103879190610ef3565b610392906001610f06565b83604001518787876040516020016103aa9190610f5e565b604051602081830303815290604052805190602001206109329095949392919063ffffffff16565b61040e5760405162461bcd60e51b815260206004820152600d60248201526c24a72b20a624a22fa82927a7a360991b6044820152606401610347565b61041782610995565b50505050565b828181146104805760405162461bcd60e51b815260206004820152602a60248201527f537461746552656365697665723a20554e4d4154434845445f4c454e4754485f604482015269504152414d455445525360b01b6064820152608401610347565b60005b818110156105b55760006104ba8585848181106104a2576104a2610ffa565b90506020028101906104b49190611010565b356107c2565b9050600061056e82600001518787868181106104d8576104d8610ffa565b90506020028101906104ea9190611010565b6104f5919035610ef3565b835160208501516105069190610ef3565b610511906001610f06565b84604001518b8b8881811061052857610528610ffa565b905060200281019061053a9190611030565b8b8b8a81811061054c5761054c610ffa565b905060200281019061055e9190611010565b6040516020016103aa9190610f5e565b90508061057f575050600101610483565b6105ab86868581811061059457610594610ffa565b90506020028101906105a69190611010565b610995565b5050600101610483565b505050505050565b603681815481106105cd57600080fd5b600091825260209091200154905081565b336002600160a01b03146106225760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610347565b603354610630906001610f06565b8535146106725760405162461bcd60e51b815260206004820152601060248201526f1253959053125117d4d510549517d25160821b6044820152606401610347565b8435602086013510156106b85760405162461bcd60e51b815260206004820152600e60248201526d1253959053125117d1539117d25160921b6044820152606401610347565b604080518635602080830191909152870135818301529086013560608201526106fd906080016040516020818303038152906040528051906020012085858585610bb0565b6032805486916035916000918261071383611079565b90915550815260208082019290925260409081016000208335815591830135600183015582013560028201555050603680546001810182556000919091526020868101357f4a11f94e20a93c79f6ec743a1954ec4fc2c08429ae2122118bf234b2185c81b89092018290556033829055604080519088013581528735917f11efd893530b26afc66d488ff54cb15df117cb6e0e4a08c6dcb166d766c3bf3b910160405180910390a35050505050565b60408051606081018252600080825260208201819052918101829052906107ea603684610885565b603654909150810361084a5760405162461bcd60e51b815260206004820152602360248201527f537461746552656365697665723a204e4f5f434f4d4d49544d454e545f464f5260448201526217d25160ea1b6064820152608401610347565b600090815260356020908152604091829020825160608101845281548152600182015492810192909252600201549181019190915292915050565b8154600090810361089857506000610350565b82546000905b808210156108e55760006108b28383610cb4565b600087815260209020909150859082015411156108d1578091506108df565b6108dc816001610f06565b92505b5061089e565b60008211801561091157508361090e86610900600186610ef3565b600091825260209091200190565b54145b1561092a57610921600183610ef3565b92505050610350565b509392505050565b60008115610971578160051b8301835b8760011660051b8981528135602082185250604060002098508760011c97506020810190508181106109425750505b85158488141660018084031b8611600180851b018710161690509695505050505050565b803560009081526034602052604090205460ff1615610a055760405162461bcd60e51b815260206004820152602660248201527f537461746552656365697665723a2053544154455f53594e435f49535f50524f60448201526510d154d4d15160d21b6064820152608401610347565b610a156060820160408301611092565b6001600160a01b03163b600003610a69576040805160208082526000908201819052918335917f31c652130602f3ce96ceaf8a4c2b8b49f049166c6fcf2eb31943a75ec7c936ae910160405180910390a350565b8035600090815260346020526040808220805460ff191660011790558190610a979060608501908501611092565b6001600160a01b03168335610ab26040860160208701611092565b610abf60608701876110ad565b604051602401610ad294939291906110f3565b60408051601f198184030181529181526020820180516001600160e01b031663eeb4994560e01b17905251610b07919061114c565b6000604051808303816000865af19150503d8060008114610b44576040519150601f19603f3d011682016040523d82523d6000602084013e610b49565b606091505b509150915081610b6c5782356000908152603460205260409020805460ff191690555b81151583600001357f31c652130602f3ce96ceaf8a4c2b8b49f049166c6fcf2eb31943a75ec7c936ae83604051610ba3919061115e565b60405180910390a3505050565b6000806120306001600160a01b0316620249f08888888888604051602001610bdc959493929190611191565b60408051601f1981840301815290829052610bf69161114c565b6000604051808303818686fa925050503d8060008114610c32576040519150601f19603f3d011682016040523d82523d6000602084013e610c37565b606091505b5091509150600081806020019051810190610c5291906111ca565b9050828015610c5e5750805b610caa5760405162461bcd60e51b815260206004820152601d60248201527f5349474e41545552455f564552494649434154494f4e5f4641494c45440000006044820152606401610347565b5050505050505050565b6000610cc360028484186111ec565b610ccf90848416610f06565b9392505050565b600060208284031215610ce857600080fd5b5035919050565b60008083601f840112610d0157600080fd5b5081356001600160401b03811115610d1857600080fd5b6020830191508360208260051b8501011115610d3357600080fd5b9250929050565b600080600060408486031215610d4f57600080fd5b83356001600160401b0380821115610d6657600080fd5b610d7287838801610cef565b90955093506020860135915080821115610d8b57600080fd5b50840160808187031215610d9e57600080fd5b809150509250925092565b60008060008060408587031215610dbf57600080fd5b84356001600160401b0380821115610dd657600080fd5b610de288838901610cef565b90965094506020870135915080821115610dfb57600080fd5b50610e0887828801610cef565b95989497509550505050565b60008083601f840112610e2657600080fd5b5081356001600160401b03811115610e3d57600080fd5b602083019150836020828501011115610d3357600080fd5b600080600080600085870360a0811215610e6e57600080fd5b6060811215610e7c57600080fd5b5085945060608601356001600160401b0380821115610e9a57600080fd5b610ea689838a01610e14565b90965094506080880135915080821115610ebf57600080fd5b50610ecc88828901610e14565b969995985093965092949392505050565b634e487b7160e01b600052601160045260246000fd5b8181038181111561035057610350610edd565b8082018082111561035057610350610edd565b80356001600160a01b0381168114610f3057600080fd5b919050565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b60208152813560208201526000610f7760208401610f19565b60018060a01b03808216604085015280610f9360408701610f19565b16606085015250506060830135601e19843603018112610fb257600080fd5b83016020810190356001600160401b03811115610fce57600080fd5b803603821315610fdd57600080fd5b608080850152610ff160a085018284610f35565b95945050505050565b634e487b7160e01b600052603260045260246000fd5b60008235607e1983360301811261102657600080fd5b9190910192915050565b6000808335601e1984360301811261104757600080fd5b8301803591506001600160401b0382111561106157600080fd5b6020019150600581901b3603821315610d3357600080fd5b60006001820161108b5761108b610edd565b5060010190565b6000602082840312156110a457600080fd5b610ccf82610f19565b6000808335601e198436030181126110c457600080fd5b8301803591506001600160401b038211156110de57600080fd5b602001915036819003821315610d3357600080fd5b8481526001600160a01b038416602082015260606040820181905260009061111e9083018486610f35565b9695505050505050565b60005b8381101561114357818101518382015260200161112b565b50506000910152565b60008251611026818460208701611128565b602081526000825180602084015261117d816040850160208701611128565b601f01601f19169190910160400192915050565b8581526060602082015260006111ab606083018688610f35565b82810360408401526111be818587610f35565b98975050505050505050565b6000602082840312156111dc57600080fd5b81518015158114610ccf57600080fd5b60008261120957634e487b7160e01b600052601260045260246000fd5b50049056fea2646970667358221220392ac2e72b0893936e6f32c4b119379007f503640aa0dd19cab5622e2438c24964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101215760003560e01c806355b01e4d116100ad578063ad240c2a11610071578063ad240c2a1461026a578063c59a18f714610273578063c6df461714610286578063e0563ab114610299578063eb70ef44146102a257600080fd5b806355b01e4d1461022d5780635ea5df791461023b5780639017c12714610244578063947287cf1461025757806397e5230d1461026057600080fd5b80633b878c22116100f45780633b878c221461018457806349ce89971461018d57806350d5b95b146101d757806351351d53146101ec578063544c5e0f146101fa57600080fd5b806307b3e25214610126578063196f1b2d1461015157806323e281cf14610172578063284017f51461017b575b600080fd5b6101346004600360981b0181565b6040516001600160a01b0390911681526020015b60405180910390f35b61016461015f366004610cd6565b6102d7565b604051908152602001610148565b61016460325481565b61013461202081565b61013461101081565b6101bc61019b366004610cd6565b60356020526000908152604090208054600182015460029092015490919083565b60408051938452602084019290925290820152606001610148565b6101ea6101e5366004610d3a565b610356565b005b6101346002600160a01b0381565b61021d610208366004610cd6565b60346020526000908152604090205460ff1681565b6040519015158152602001610148565b6101346004600160991b0181565b61016461138881565b6101ea610252366004610da9565b61041d565b61016461520881565b610164620249f081565b61016460335481565b610164610281366004610cd6565b6105bd565b6101ea610294366004610e55565b6105de565b61013461203081565b6102b56102b0366004610cd6565b6107c2565b6040805182518152602080840151908201529181015190820152606001610148565b6000806035816102e8603686610885565b81526020810191909152604001600020600201549050806103505760405162461bcd60e51b815260206004820152601d60248201527f537461746552656365697665723a204e4f5f524f4f545f464f525f494400000060448201526064015b60405180910390fd5b92915050565b600061036282356107c2565b80519091506103d290610376908435610ef3565b825160208401516103879190610ef3565b610392906001610f06565b83604001518787876040516020016103aa9190610f5e565b604051602081830303815290604052805190602001206109329095949392919063ffffffff16565b61040e5760405162461bcd60e51b815260206004820152600d60248201526c24a72b20a624a22fa82927a7a360991b6044820152606401610347565b61041782610995565b50505050565b828181146104805760405162461bcd60e51b815260206004820152602a60248201527f537461746552656365697665723a20554e4d4154434845445f4c454e4754485f604482015269504152414d455445525360b01b6064820152608401610347565b60005b818110156105b55760006104ba8585848181106104a2576104a2610ffa565b90506020028101906104b49190611010565b356107c2565b9050600061056e82600001518787868181106104d8576104d8610ffa565b90506020028101906104ea9190611010565b6104f5919035610ef3565b835160208501516105069190610ef3565b610511906001610f06565b84604001518b8b8881811061052857610528610ffa565b905060200281019061053a9190611030565b8b8b8a81811061054c5761054c610ffa565b905060200281019061055e9190611010565b6040516020016103aa9190610f5e565b90508061057f575050600101610483565b6105ab86868581811061059457610594610ffa565b90506020028101906105a69190611010565b610995565b5050600101610483565b505050505050565b603681815481106105cd57600080fd5b600091825260209091200154905081565b336002600160a01b03146106225760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610347565b603354610630906001610f06565b8535146106725760405162461bcd60e51b815260206004820152601060248201526f1253959053125117d4d510549517d25160821b6044820152606401610347565b8435602086013510156106b85760405162461bcd60e51b815260206004820152600e60248201526d1253959053125117d1539117d25160921b6044820152606401610347565b604080518635602080830191909152870135818301529086013560608201526106fd906080016040516020818303038152906040528051906020012085858585610bb0565b6032805486916035916000918261071383611079565b90915550815260208082019290925260409081016000208335815591830135600183015582013560028201555050603680546001810182556000919091526020868101357f4a11f94e20a93c79f6ec743a1954ec4fc2c08429ae2122118bf234b2185c81b89092018290556033829055604080519088013581528735917f11efd893530b26afc66d488ff54cb15df117cb6e0e4a08c6dcb166d766c3bf3b910160405180910390a35050505050565b60408051606081018252600080825260208201819052918101829052906107ea603684610885565b603654909150810361084a5760405162461bcd60e51b815260206004820152602360248201527f537461746552656365697665723a204e4f5f434f4d4d49544d454e545f464f5260448201526217d25160ea1b6064820152608401610347565b600090815260356020908152604091829020825160608101845281548152600182015492810192909252600201549181019190915292915050565b8154600090810361089857506000610350565b82546000905b808210156108e55760006108b28383610cb4565b600087815260209020909150859082015411156108d1578091506108df565b6108dc816001610f06565b92505b5061089e565b60008211801561091157508361090e86610900600186610ef3565b600091825260209091200190565b54145b1561092a57610921600183610ef3565b92505050610350565b509392505050565b60008115610971578160051b8301835b8760011660051b8981528135602082185250604060002098508760011c97506020810190508181106109425750505b85158488141660018084031b8611600180851b018710161690509695505050505050565b803560009081526034602052604090205460ff1615610a055760405162461bcd60e51b815260206004820152602660248201527f537461746552656365697665723a2053544154455f53594e435f49535f50524f60448201526510d154d4d15160d21b6064820152608401610347565b610a156060820160408301611092565b6001600160a01b03163b600003610a69576040805160208082526000908201819052918335917f31c652130602f3ce96ceaf8a4c2b8b49f049166c6fcf2eb31943a75ec7c936ae910160405180910390a350565b8035600090815260346020526040808220805460ff191660011790558190610a979060608501908501611092565b6001600160a01b03168335610ab26040860160208701611092565b610abf60608701876110ad565b604051602401610ad294939291906110f3565b60408051601f198184030181529181526020820180516001600160e01b031663eeb4994560e01b17905251610b07919061114c565b6000604051808303816000865af19150503d8060008114610b44576040519150601f19603f3d011682016040523d82523d6000602084013e610b49565b606091505b509150915081610b6c5782356000908152603460205260409020805460ff191690555b81151583600001357f31c652130602f3ce96ceaf8a4c2b8b49f049166c6fcf2eb31943a75ec7c936ae83604051610ba3919061115e565b60405180910390a3505050565b6000806120306001600160a01b0316620249f08888888888604051602001610bdc959493929190611191565b60408051601f1981840301815290829052610bf69161114c565b6000604051808303818686fa925050503d8060008114610c32576040519150601f19603f3d011682016040523d82523d6000602084013e610c37565b606091505b5091509150600081806020019051810190610c5291906111ca565b9050828015610c5e5750805b610caa5760405162461bcd60e51b815260206004820152601d60248201527f5349474e41545552455f564552494649434154494f4e5f4641494c45440000006044820152606401610347565b5050505050505050565b6000610cc360028484186111ec565b610ccf90848416610f06565b9392505050565b600060208284031215610ce857600080fd5b5035919050565b60008083601f840112610d0157600080fd5b5081356001600160401b03811115610d1857600080fd5b6020830191508360208260051b8501011115610d3357600080fd5b9250929050565b600080600060408486031215610d4f57600080fd5b83356001600160401b0380821115610d6657600080fd5b610d7287838801610cef565b90955093506020860135915080821115610d8b57600080fd5b50840160808187031215610d9e57600080fd5b809150509250925092565b60008060008060408587031215610dbf57600080fd5b84356001600160401b0380821115610dd657600080fd5b610de288838901610cef565b90965094506020870135915080821115610dfb57600080fd5b50610e0887828801610cef565b95989497509550505050565b60008083601f840112610e2657600080fd5b5081356001600160401b03811115610e3d57600080fd5b602083019150836020828501011115610d3357600080fd5b600080600080600085870360a0811215610e6e57600080fd5b6060811215610e7c57600080fd5b5085945060608601356001600160401b0380821115610e9a57600080fd5b610ea689838a01610e14565b90965094506080880135915080821115610ebf57600080fd5b50610ecc88828901610e14565b969995985093965092949392505050565b634e487b7160e01b600052601160045260246000fd5b8181038181111561035057610350610edd565b8082018082111561035057610350610edd565b80356001600160a01b0381168114610f3057600080fd5b919050565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b60208152813560208201526000610f7760208401610f19565b60018060a01b03808216604085015280610f9360408701610f19565b16606085015250506060830135601e19843603018112610fb257600080fd5b83016020810190356001600160401b03811115610fce57600080fd5b803603821315610fdd57600080fd5b608080850152610ff160a085018284610f35565b95945050505050565b634e487b7160e01b600052603260045260246000fd5b60008235607e1983360301811261102657600080fd5b9190910192915050565b6000808335601e1984360301811261104757600080fd5b8301803591506001600160401b0382111561106157600080fd5b6020019150600581901b3603821315610d3357600080fd5b60006001820161108b5761108b610edd565b5060010190565b6000602082840312156110a457600080fd5b610ccf82610f19565b6000808335601e198436030181126110c457600080fd5b8301803591506001600160401b038211156110de57600080fd5b602001915036819003821315610d3357600080fd5b8481526001600160a01b038416602082015260606040820181905260009061111e9083018486610f35565b9695505050505050565b60005b8381101561114357818101518382015260200161112b565b50506000910152565b60008251611026818460208701611128565b602081526000825180602084015261117d816040850160208701611128565b601f01601f19169190910160400192915050565b8581526060602082015260006111ab606083018688610f35565b82810360408401526111be818587610f35565b98975050505050505050565b6000602082840312156111dc57600080fd5b81518015158114610ccf57600080fd5b60008261120957634e487b7160e01b600052601260045260246000fd5b50049056fea2646970667358221220392ac2e72b0893936e6f32c4b119379007f503640aa0dd19cab5622e2438c24964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var NativeERC20Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"NativeERC20","sourceName":"contracts/blade/NativeERC20.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"predicate_","type":"address"},{"internalType":"address","name":"owner_","type":"address"},{"internalType":"address","name":"rootToken_","type":"address"},{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"uint8","name":"decimals_","type":"uint8"},{"internalType":"uint256","name":"tokenSupply_","type":"uint256"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061001a3361001f565b61008d565b603480546001600160a01b03191690556100388161003b565b50565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b61150a8061009c6000396000f3fe608060405234801561001057600080fd5b506004361061019a5760003560e01c806370a08231116100e45780639dc29fac116100925780639dc29fac1461031a578063a457c2d71461032d578063a9059cbb14610340578063dd62ed3e14610353578063e0563ab114610366578063e30c39781461036f578063e619870514610380578063f2fde38b1461039157600080fd5b806370a08231146102c3578063715018a6146102de57806379ba5097146102e65780638da5cb5b146102ee578063947287cf146102ff57806395d89b411461030857806397e5230d1461031057600080fd5b8063313ce5671161014c578063313ce56714610245578063395093511461025a5780633b878c221461026d57806340c10f191461027657806351351d531461028957806355b01e4d146102975780635ea5df79146102a55780636091636b146102ae57600080fd5b806306fdde031461019f57806307b3e252146101bd578063095ea7b3146101e357806318160ddd146102065780631f2d00651461021857806323b872dd14610229578063284017f51461023c575b600080fd5b6101a76103a4565b6040516101b49190611022565b60405180910390f35b6101cb6004600360981b0181565b6040516001600160a01b0390911681526020016101b4565b6101f66101f1366004611071565b610436565b60405190151581526020016101b4565b6036545b6040519081526020016101b4565b6038546001600160a01b03166101cb565b6101f661023736600461109b565b610450565b6101cb61202081565b603b5460405160ff90911681526020016101b4565b6101f6610268366004611071565b610474565b6101cb61101081565b6101f6610284366004611071565b610496565b6101cb6002600160a01b0381565b6101cb6004600160991b0181565b61020a61138881565b6102c16102bc366004611120565b6104f4565b005b61020a6102d13660046111e4565b6001600160a01b03163190565b6102c1610714565b6102c1610728565b6033546001600160a01b03166101cb565b61020a61520881565b6101a76107a2565b61020a620249f081565b6101f6610328366004611071565b6107b1565b6101f661033b366004611071565b6107fd565b6101f661034e366004611071565b610878565b61020a610361366004611206565b610886565b6101cb61203081565b6034546001600160a01b03166101cb565b6037546001600160a01b03166101cb565b6102c161039f3660046111e4565b6108b1565b6060603980546103b390611239565b80601f01602080910402602001604051908101604052809291908181526020018280546103df90611239565b801561042c5780601f106104015761010080835404028352916020019161042c565b820191906000526020600020905b81548152906001019060200180831161040f57829003601f168201915b5050505050905090565b600033610444818585610922565b60019150505b92915050565b60003361045e858285610a46565b610469858585610ac0565b506001949350505050565b6000336104448185856104878383610886565b6104919190611289565b610922565b6037546000906001600160a01b03163314806104bc57506033546001600160a01b031633145b6104e15760405162461bcd60e51b81526004016104d89061129c565b60405180910390fd5b6104eb8383610c85565b50600192915050565b600054610100900460ff16158080156105145750600054600160ff909116105b8061052e5750303b15801561052e575060005460ff166001145b6105915760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104d8565b6000805460ff1916600117905580156105b4576000805461ff0019166101001790555b336002600160a01b03146105f85760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064016104d8565b6001600160a01b0389166106595760405162461bcd60e51b815260206004820152602260248201527f4e617469766545524332303a20496e76616c6964206f776e6572206164647265604482015261737360f01b60648201526084016104d8565b603780546001600160a01b03808d166001600160a01b03199283161790925560388054928b1692909116919091179055603961069687898361134e565b50603a6106a485878361134e565b50603b805460ff191660ff851617905560368290556106c289610ddf565b8015610708576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050505050565b61071c610df8565b6107266000610ddf565b565b60345433906001600160a01b031681146107965760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016104d8565b61079f81610ddf565b50565b6060603a80546103b390611239565b6037546000906001600160a01b03163314806107d757506033546001600160a01b031633145b6107f35760405162461bcd60e51b81526004016104d89061129c565b6104eb8383610e52565b6000338161080b8286610886565b90508381101561086b5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016104d8565b6104698286868403610922565b600033610444818585610ac0565b6001600160a01b03918216600090815260356020908152604080832093909416825291909152205490565b6108b9610df8565b603480546001600160a01b0383166001600160a01b031990911681179091556108ea6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b6001600160a01b0383166109845760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b60648201526084016104d8565b6001600160a01b0382166109e55760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b60648201526084016104d8565b6001600160a01b0383811660008181526035602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b6000610a528484610886565b90506000198114610aba5781811015610aad5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016104d8565b610aba8484848403610922565b50505050565b6001600160a01b038316610b245760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016104d8565b6001600160a01b038216610b865760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016104d8565b6000806120206001600160a01b0316858585604051602001610baa9392919061140f565b60408051601f1981840301815290829052610bc491611433565b6000604051808303816000865af19150503d8060008114610c01576040519150601f19603f3d011682016040523d82523d6000602084013e610c06565b606091505b5091509150818015610c27575080806020019051810190610c27919061144f565b610c435760405162461bcd60e51b81526004016104d890611471565b836001600160a01b0316856001600160a01b03166000805160206114b583398151915285604051610c7691815260200190565b60405180910390a35050505050565b6001600160a01b038216610cdb5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016104d8565b8060366000828254610ced9190611289565b9091555050604051600090819061202090610d109083908790879060200161140f565b60408051601f1981840301815290829052610d2a91611433565b6000604051808303816000865af19150503d8060008114610d67576040519150601f19603f3d011682016040523d82523d6000602084013e610d6c565b606091505b5091509150818015610d8d575080806020019051810190610d8d919061144f565b610da95760405162461bcd60e51b81526004016104d890611471565b6040518381526001600160a01b038516906000906000805160206114b5833981519152906020015b60405180910390a350505050565b603480546001600160a01b031916905561079f81610fac565b6033546001600160a01b031633146107265760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104d8565b6001600160a01b038216610eb25760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016104d8565b8060366000828254610ec491906114a1565b9091555050604051600090819061202090610ee79086908490879060200161140f565b60408051601f1981840301815290829052610f0191611433565b6000604051808303816000865af19150503d8060008114610f3e576040519150601f19603f3d011682016040523d82523d6000602084013e610f43565b606091505b5091509150818015610f64575080806020019051810190610f64919061144f565b610f805760405162461bcd60e51b81526004016104d890611471565b6040518381526000906001600160a01b038616906000805160206114b583398151915290602001610dd1565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60005b83811015611019578181015183820152602001611001565b50506000910152565b6020815260008251806020840152611041816040850160208701610ffe565b601f01601f19169190910160400192915050565b80356001600160a01b038116811461106c57600080fd5b919050565b6000806040838503121561108457600080fd5b61108d83611055565b946020939093013593505050565b6000806000606084860312156110b057600080fd5b6110b984611055565b92506110c760208501611055565b9150604084013590509250925092565b60008083601f8401126110e957600080fd5b50813567ffffffffffffffff81111561110157600080fd5b60208301915083602082850101111561111957600080fd5b9250929050565b600080600080600080600080600060e08a8c03121561113e57600080fd5b6111478a611055565b985061115560208b01611055565b975061116360408b01611055565b965060608a013567ffffffffffffffff8082111561118057600080fd5b61118c8d838e016110d7565b909850965060808c01359150808211156111a557600080fd5b506111b28c828d016110d7565b90955093505060a08a013560ff811681146111cc57600080fd5b8092505060c08a013590509295985092959850929598565b6000602082840312156111f657600080fd5b6111ff82611055565b9392505050565b6000806040838503121561121957600080fd5b61122283611055565b915061123060208401611055565b90509250929050565b600181811c9082168061124d57607f821691505b60208210810361126d57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b8082018082111561044a5761044a611273565b6020808252602d908201527f4e617469766545524332303a204f6e6c7920707265646963617465206f72206f60408201526c1ddb995c8818d85b8818d85b1b609a1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f82111561134957600081815260208120601f850160051c810160208610156113265750805b601f850160051c820191505b8181101561134557828155600101611332565b5050505b505050565b67ffffffffffffffff831115611366576113666112e9565b61137a836113748354611239565b836112ff565b6000601f8411600181146113ae57600085156113965750838201355b600019600387901b1c1916600186901b178355611408565b600083815260209020601f19861690835b828110156113df57868501358255602094850194600190920191016113bf565b50868210156113fc5760001960f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008251611445818460208701610ffe565b9190910192915050565b60006020828403121561146157600080fd5b815180151581146111ff57600080fd5b60208082526016908201527514149150d3d35412531157d0d0531317d1905253115160521b604082015260600190565b8181038181111561044a5761044a61127356feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220eaa00abb0718aa894f058257d284ef40a7026a5937cff0d38612d893a34ec72464736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061019a5760003560e01c806370a08231116100e45780639dc29fac116100925780639dc29fac1461031a578063a457c2d71461032d578063a9059cbb14610340578063dd62ed3e14610353578063e0563ab114610366578063e30c39781461036f578063e619870514610380578063f2fde38b1461039157600080fd5b806370a08231146102c3578063715018a6146102de57806379ba5097146102e65780638da5cb5b146102ee578063947287cf146102ff57806395d89b411461030857806397e5230d1461031057600080fd5b8063313ce5671161014c578063313ce56714610245578063395093511461025a5780633b878c221461026d57806340c10f191461027657806351351d531461028957806355b01e4d146102975780635ea5df79146102a55780636091636b146102ae57600080fd5b806306fdde031461019f57806307b3e252146101bd578063095ea7b3146101e357806318160ddd146102065780631f2d00651461021857806323b872dd14610229578063284017f51461023c575b600080fd5b6101a76103a4565b6040516101b49190611022565b60405180910390f35b6101cb6004600360981b0181565b6040516001600160a01b0390911681526020016101b4565b6101f66101f1366004611071565b610436565b60405190151581526020016101b4565b6036545b6040519081526020016101b4565b6038546001600160a01b03166101cb565b6101f661023736600461109b565b610450565b6101cb61202081565b603b5460405160ff90911681526020016101b4565b6101f6610268366004611071565b610474565b6101cb61101081565b6101f6610284366004611071565b610496565b6101cb6002600160a01b0381565b6101cb6004600160991b0181565b61020a61138881565b6102c16102bc366004611120565b6104f4565b005b61020a6102d13660046111e4565b6001600160a01b03163190565b6102c1610714565b6102c1610728565b6033546001600160a01b03166101cb565b61020a61520881565b6101a76107a2565b61020a620249f081565b6101f6610328366004611071565b6107b1565b6101f661033b366004611071565b6107fd565b6101f661034e366004611071565b610878565b61020a610361366004611206565b610886565b6101cb61203081565b6034546001600160a01b03166101cb565b6037546001600160a01b03166101cb565b6102c161039f3660046111e4565b6108b1565b6060603980546103b390611239565b80601f01602080910402602001604051908101604052809291908181526020018280546103df90611239565b801561042c5780601f106104015761010080835404028352916020019161042c565b820191906000526020600020905b81548152906001019060200180831161040f57829003601f168201915b5050505050905090565b600033610444818585610922565b60019150505b92915050565b60003361045e858285610a46565b610469858585610ac0565b506001949350505050565b6000336104448185856104878383610886565b6104919190611289565b610922565b6037546000906001600160a01b03163314806104bc57506033546001600160a01b031633145b6104e15760405162461bcd60e51b81526004016104d89061129c565b60405180910390fd5b6104eb8383610c85565b50600192915050565b600054610100900460ff16158080156105145750600054600160ff909116105b8061052e5750303b15801561052e575060005460ff166001145b6105915760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104d8565b6000805460ff1916600117905580156105b4576000805461ff0019166101001790555b336002600160a01b03146105f85760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064016104d8565b6001600160a01b0389166106595760405162461bcd60e51b815260206004820152602260248201527f4e617469766545524332303a20496e76616c6964206f776e6572206164647265604482015261737360f01b60648201526084016104d8565b603780546001600160a01b03808d166001600160a01b03199283161790925560388054928b1692909116919091179055603961069687898361134e565b50603a6106a485878361134e565b50603b805460ff191660ff851617905560368290556106c289610ddf565b8015610708576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050505050565b61071c610df8565b6107266000610ddf565b565b60345433906001600160a01b031681146107965760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016104d8565b61079f81610ddf565b50565b6060603a80546103b390611239565b6037546000906001600160a01b03163314806107d757506033546001600160a01b031633145b6107f35760405162461bcd60e51b81526004016104d89061129c565b6104eb8383610e52565b6000338161080b8286610886565b90508381101561086b5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016104d8565b6104698286868403610922565b600033610444818585610ac0565b6001600160a01b03918216600090815260356020908152604080832093909416825291909152205490565b6108b9610df8565b603480546001600160a01b0383166001600160a01b031990911681179091556108ea6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b6001600160a01b0383166109845760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b60648201526084016104d8565b6001600160a01b0382166109e55760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b60648201526084016104d8565b6001600160a01b0383811660008181526035602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b6000610a528484610886565b90506000198114610aba5781811015610aad5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016104d8565b610aba8484848403610922565b50505050565b6001600160a01b038316610b245760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016104d8565b6001600160a01b038216610b865760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016104d8565b6000806120206001600160a01b0316858585604051602001610baa9392919061140f565b60408051601f1981840301815290829052610bc491611433565b6000604051808303816000865af19150503d8060008114610c01576040519150601f19603f3d011682016040523d82523d6000602084013e610c06565b606091505b5091509150818015610c27575080806020019051810190610c27919061144f565b610c435760405162461bcd60e51b81526004016104d890611471565b836001600160a01b0316856001600160a01b03166000805160206114b583398151915285604051610c7691815260200190565b60405180910390a35050505050565b6001600160a01b038216610cdb5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016104d8565b8060366000828254610ced9190611289565b9091555050604051600090819061202090610d109083908790879060200161140f565b60408051601f1981840301815290829052610d2a91611433565b6000604051808303816000865af19150503d8060008114610d67576040519150601f19603f3d011682016040523d82523d6000602084013e610d6c565b606091505b5091509150818015610d8d575080806020019051810190610d8d919061144f565b610da95760405162461bcd60e51b81526004016104d890611471565b6040518381526001600160a01b038516906000906000805160206114b5833981519152906020015b60405180910390a350505050565b603480546001600160a01b031916905561079f81610fac565b6033546001600160a01b031633146107265760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104d8565b6001600160a01b038216610eb25760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016104d8565b8060366000828254610ec491906114a1565b9091555050604051600090819061202090610ee79086908490879060200161140f565b60408051601f1981840301815290829052610f0191611433565b6000604051808303816000865af19150503d8060008114610f3e576040519150601f19603f3d011682016040523d82523d6000602084013e610f43565b606091505b5091509150818015610f64575080806020019051810190610f64919061144f565b610f805760405162461bcd60e51b81526004016104d890611471565b6040518381526000906001600160a01b038616906000805160206114b583398151915290602001610dd1565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60005b83811015611019578181015183820152602001611001565b50506000910152565b6020815260008251806020840152611041816040850160208701610ffe565b601f01601f19169190910160400192915050565b80356001600160a01b038116811461106c57600080fd5b919050565b6000806040838503121561108457600080fd5b61108d83611055565b946020939093013593505050565b6000806000606084860312156110b057600080fd5b6110b984611055565b92506110c760208501611055565b9150604084013590509250925092565b60008083601f8401126110e957600080fd5b50813567ffffffffffffffff81111561110157600080fd5b60208301915083602082850101111561111957600080fd5b9250929050565b600080600080600080600080600060e08a8c03121561113e57600080fd5b6111478a611055565b985061115560208b01611055565b975061116360408b01611055565b965060608a013567ffffffffffffffff8082111561118057600080fd5b61118c8d838e016110d7565b909850965060808c01359150808211156111a557600080fd5b506111b28c828d016110d7565b90955093505060a08a013560ff811681146111cc57600080fd5b8092505060c08a013590509295985092959850929598565b6000602082840312156111f657600080fd5b6111ff82611055565b9392505050565b6000806040838503121561121957600080fd5b61122283611055565b915061123060208401611055565b90509250929050565b600181811c9082168061124d57607f821691505b60208210810361126d57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b8082018082111561044a5761044a611273565b6020808252602d908201527f4e617469766545524332303a204f6e6c7920707265646963617465206f72206f60408201526c1ddb995c8818d85b8818d85b1b609a1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f82111561134957600081815260208120601f850160051c810160208610156113265750805b601f850160051c820191505b8181101561134557828155600101611332565b5050505b505050565b67ffffffffffffffff831115611366576113666112e9565b61137a836113748354611239565b836112ff565b6000601f8411600181146113ae57600085156113965750838201355b600019600387901b1c1916600186901b178355611408565b600083815260209020601f19861690835b828110156113df57868501358255602094850194600190920191016113bf565b50868210156113fc5760001960f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008251611445818460208701610ffe565b9190910192915050565b60006020828403121561146157600080fd5b815180151581146111ff57600080fd5b60208082526016908201527514149150d3d35412531157d0d0531317d1905253115160521b604082015260600190565b8181038181111561044a5761044a61127356feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220eaa00abb0718aa894f058257d284ef40a7026a5937cff0d38612d893a34ec72464736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildERC20Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC20","sourceName":"contracts/blade/ChildERC20.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"userAddress","type":"address"},{"indexed":false,"internalType":"address","name":"relayerAddress","type":"address"},{"indexed":false,"internalType":"bytes","name":"functionSignature","type":"bytes"}],"name":"MetaTransactionExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"userAddress","type":"address"},{"internalType":"bytes","name":"functionSignature","type":"bytes"},{"internalType":"bytes32","name":"sigR","type":"bytes32"},{"internalType":"bytes32","name":"sigS","type":"bytes32"},{"internalType":"uint8","name":"sigV","type":"uint8"}],"name":"executeMetaTransaction","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getNonce","outputs":[{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"rootToken_","type":"address"},{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"uint8","name":"decimals_","type":"uint8"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"offset","type":"uint256"}],"name":"invalidateNext","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rootToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611920806100206000396000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c806340c10f19116100ad578063a457c2d711610071578063a457c2d71461028b578063a9059cbb1461029e578063dd62ed3e146102b1578063e6198705146102c4578063f6d2ee86146102d557600080fd5b806340c10f191461021f57806370a082311461023257806395d89b411461025b5780639b77ef11146102635780639dc29fac1461027857600080fd5b80631f2d0065116100f45780631f2d00651461018c57806323b872dd146101b15780632d0335ab146101c4578063313ce567146101ed578063395093511461020c57600080fd5b806306fdde0314610126578063095ea7b3146101445780630c53c51c1461016757806318160ddd1461017a575b600080fd5b61012e6102e8565b60405161013b9190611395565b60405180910390f35b6101576101523660046113cb565b61037a565b604051901515815260200161013b565b61012e61017536600461144f565b61039e565b60a0545b60405190815260200161013b565b60d1546001600160a01b03165b6040516001600160a01b03909116815260200161013b565b6101576101bf3660046114c5565b610681565b61017e6101d2366004611501565b6001600160a01b031660009081526038602052604090205490565b60d154600160a01b900460ff1660405160ff909116815260200161013b565b61015761021a3660046113cb565b6106af565b61015761022d3660046113cb565b6106db565b61017e610240366004611501565b6001600160a01b03166000908152609e602052604090205490565b61012e61071b565b61027661027136600461151c565b61072a565b005b6101576102863660046113cb565b610751565b6101576102993660046113cb565b610788565b6101576102ac3660046113cb565b61080e565b61017e6102bf366004611535565b610826565b60d0546001600160a01b0316610199565b6102766102e3366004611568565b610851565b606060a180546102f7906115ec565b80601f0160208091040260200160405190810160405280929190818152602001828054610323906115ec565b80156103705780601f1061034557610100808354040283529160200191610370565b820191906000526020600020905b81548152906001019060200180831161035357829003601f168201915b5050505050905090565b600080610385610ad1565b9050610392818585610ae0565b60019150505b92915050565b606060006103e187878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610c0592505050565b90506001600160e01b031960003581169082160361046c5760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f6400000060648201526084015b60405180910390fd5b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506104dd8982888888610c20565b6105335760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b6064820152608401610463565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d60405160200161058893929190611626565b60408051601f19818403018152908290526105a29161164c565b6000604051808303816000865af19150503d80600081146105df576040519150601f19603f3d011682016040523d82523d6000602084013e6105e4565b606091505b5091509150816106365760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610463565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c60405161066b9493929190611668565b60405180910390a19a9950505050505050505050565b60008061068c610ad1565b9050610699858285610cfc565b6106a4858585610d76565b506001949350505050565b6000806106ba610ad1565b90506103928185856106cc8589610826565b6106d691906116b4565b610ae0565b60d0546000906001600160a01b031633146107085760405162461bcd60e51b8152600401610463906116d5565b6107128383610f0f565b50600192915050565b606060a280546102f7906115ec565b33600090815260386020526040812080548392906107499084906116b4565b909155505050565b60d0546000906001600160a01b0316331461077e5760405162461bcd60e51b8152600401610463906116d5565b6107128383610fbf565b600080610793610ad1565b905060006107a18286610826565b9050838110156108015760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610463565b6106a48286868403610ae0565b600080610819610ad1565b9050610392818585610d76565b6001600160a01b039182166000908152609f6020908152604080832093909416825291909152205490565b606b54610100900460ff16158080156108715750606b54600160ff909116105b8061088b5750303b15801561088b5750606b5460ff166001145b6108ee5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610463565b606b805460ff19166001179055801561091157606b805461ff0019166101001790555b6001600160a01b0387161580159061092857508415155b801561093357508215155b61097f5760405162461bcd60e51b815260206004820152601e60248201527f4368696c6445524332303a204241445f494e495449414c495a4154494f4e00006044820152606401610463565b60d1805460ff8416600160a01b026001600160a81b03199091166001600160a01b038a161717905560d080546001600160a01b03191633179055604080516020601f8801819004810282018101909252868152610a2a91889088908190840183828082843760009201919091525050604080516020601f8a0181900481028201810190925288815292508891508790819084018382808284376000920191909152506110de92505050565b610a8286868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805180820190915260018152603160f81b6020820152915061110f9050565b8015610ac857606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b6000610adb61117b565b905090565b6001600160a01b038316610b425760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610463565b6001600160a01b038216610ba35760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610463565b6001600160a01b038381166000818152609f602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b60008151600003610c1857506000919050565b506020015190565b6000806001610c36610c31886111d7565b611254565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa158015610c84573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610cdb5760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610463565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6000610d088484610826565b90506000198114610d705781811015610d635760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610463565b610d708484848403610ae0565b50505050565b6001600160a01b038316610dda5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610463565b6001600160a01b038216610e3c5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610463565b6001600160a01b0383166000908152609e602052604090205481811015610eb45760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610463565b6001600160a01b038085166000818152609e602052604080822086860390559286168082529083902080548601905591516000805160206118cb83398151915290610f029086815260200190565b60405180910390a3610d70565b6001600160a01b038216610f655760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610463565b8060a06000828254610f7791906116b4565b90915550506001600160a01b0382166000818152609e60209081526040808320805486019055518481526000805160206118cb833981519152910160405180910390a35b5050565b6001600160a01b03821661101f5760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610463565b6001600160a01b0382166000908152609e6020526040902054818110156110935760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610463565b6001600160a01b0383166000818152609e60209081526040808320868603905560a080548790039055518581529192916000805160206118cb8339815191529101610bf8565b505050565b606b54610100900460ff166111055760405162461bcd60e51b815260040161046390611718565b610fbb8282611281565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f61115d8184846112c1565b600055600280546001600160a01b0319163017905560055550505050565b60003033036111d157600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506111d49050565b50335b90565b60006040518060800160405280604381526020016118886043913980516020918201208351848301516040808701518051908601209051611237950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039861126161130a565b8360405161190160f01b8152600281019290925260228201526042902090565b606b54610100900460ff166112a85760405162461bcd60e51b815260040161046390611718565b60a16112b483826117c7565b5060a26110d982826117c7565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b6002546000906001600160a01b031630148015611328575060015446145b15611334575060005490565b610adb6005546003546004546112c1565b60005b83811015611360578181015183820152602001611348565b50506000910152565b60008151808452611381816020860160208601611345565b601f01601f19169290920160200192915050565b6020815260006113a86020830184611369565b9392505050565b80356001600160a01b03811681146113c657600080fd5b919050565b600080604083850312156113de57600080fd5b6113e7836113af565b946020939093013593505050565b60008083601f84011261140757600080fd5b50813567ffffffffffffffff81111561141f57600080fd5b60208301915083602082850101111561143757600080fd5b9250929050565b803560ff811681146113c657600080fd5b60008060008060008060a0878903121561146857600080fd5b611471876113af565b9550602087013567ffffffffffffffff81111561148d57600080fd5b61149989828a016113f5565b90965094505060408701359250606087013591506114b96080880161143e565b90509295509295509295565b6000806000606084860312156114da57600080fd5b6114e3846113af565b92506114f1602085016113af565b9150604084013590509250925092565b60006020828403121561151357600080fd5b6113a8826113af565b60006020828403121561152e57600080fd5b5035919050565b6000806040838503121561154857600080fd5b611551836113af565b915061155f602084016113af565b90509250929050565b6000806000806000806080878903121561158157600080fd5b61158a876113af565b9550602087013567ffffffffffffffff808211156115a757600080fd5b6115b38a838b016113f5565b909750955060408901359150808211156115cc57600080fd5b506115d989828a016113f5565b90945092506114b990506060880161143e565b600181811c9082168061160057607f821691505b60208210810361162057634e487b7160e01b600052602260045260246000fd5b50919050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b6000825161165e818460208701611345565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b8082018082111561039857634e487b7160e01b600052601160045260246000fd5b60208082526023908201527f4368696c6445524332303a204f6e6c79207072656469636174652063616e2063604082015262185b1b60ea1b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f8211156110d957600081815260208120601f850160051c810160208610156117a05750805b601f850160051c820191505b818110156117bf578281556001016117ac565b505050505050565b815167ffffffffffffffff8111156117e1576117e1611763565b6117f5816117ef84546115ec565b84611779565b602080601f83116001811461182a57600084156118125750858301515b600019600386901b1c1916600185901b1785556117bf565b600085815260208120601f198616915b828110156118595788860151825594840194600190910190840161183a565b50858210156118775787850151600019600388901b60f8161c191681555b5050505050600190811b0190555056fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa264697066735822122025382f2e5346073a2875deb90af71e629e8a47644d5cf7790f05f8e5b91544e164736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101215760003560e01c806340c10f19116100ad578063a457c2d711610071578063a457c2d71461028b578063a9059cbb1461029e578063dd62ed3e146102b1578063e6198705146102c4578063f6d2ee86146102d557600080fd5b806340c10f191461021f57806370a082311461023257806395d89b411461025b5780639b77ef11146102635780639dc29fac1461027857600080fd5b80631f2d0065116100f45780631f2d00651461018c57806323b872dd146101b15780632d0335ab146101c4578063313ce567146101ed578063395093511461020c57600080fd5b806306fdde0314610126578063095ea7b3146101445780630c53c51c1461016757806318160ddd1461017a575b600080fd5b61012e6102e8565b60405161013b9190611395565b60405180910390f35b6101576101523660046113cb565b61037a565b604051901515815260200161013b565b61012e61017536600461144f565b61039e565b60a0545b60405190815260200161013b565b60d1546001600160a01b03165b6040516001600160a01b03909116815260200161013b565b6101576101bf3660046114c5565b610681565b61017e6101d2366004611501565b6001600160a01b031660009081526038602052604090205490565b60d154600160a01b900460ff1660405160ff909116815260200161013b565b61015761021a3660046113cb565b6106af565b61015761022d3660046113cb565b6106db565b61017e610240366004611501565b6001600160a01b03166000908152609e602052604090205490565b61012e61071b565b61027661027136600461151c565b61072a565b005b6101576102863660046113cb565b610751565b6101576102993660046113cb565b610788565b6101576102ac3660046113cb565b61080e565b61017e6102bf366004611535565b610826565b60d0546001600160a01b0316610199565b6102766102e3366004611568565b610851565b606060a180546102f7906115ec565b80601f0160208091040260200160405190810160405280929190818152602001828054610323906115ec565b80156103705780601f1061034557610100808354040283529160200191610370565b820191906000526020600020905b81548152906001019060200180831161035357829003601f168201915b5050505050905090565b600080610385610ad1565b9050610392818585610ae0565b60019150505b92915050565b606060006103e187878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610c0592505050565b90506001600160e01b031960003581169082160361046c5760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f6400000060648201526084015b60405180910390fd5b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506104dd8982888888610c20565b6105335760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b6064820152608401610463565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d60405160200161058893929190611626565b60408051601f19818403018152908290526105a29161164c565b6000604051808303816000865af19150503d80600081146105df576040519150601f19603f3d011682016040523d82523d6000602084013e6105e4565b606091505b5091509150816106365760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610463565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c60405161066b9493929190611668565b60405180910390a19a9950505050505050505050565b60008061068c610ad1565b9050610699858285610cfc565b6106a4858585610d76565b506001949350505050565b6000806106ba610ad1565b90506103928185856106cc8589610826565b6106d691906116b4565b610ae0565b60d0546000906001600160a01b031633146107085760405162461bcd60e51b8152600401610463906116d5565b6107128383610f0f565b50600192915050565b606060a280546102f7906115ec565b33600090815260386020526040812080548392906107499084906116b4565b909155505050565b60d0546000906001600160a01b0316331461077e5760405162461bcd60e51b8152600401610463906116d5565b6107128383610fbf565b600080610793610ad1565b905060006107a18286610826565b9050838110156108015760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610463565b6106a48286868403610ae0565b600080610819610ad1565b9050610392818585610d76565b6001600160a01b039182166000908152609f6020908152604080832093909416825291909152205490565b606b54610100900460ff16158080156108715750606b54600160ff909116105b8061088b5750303b15801561088b5750606b5460ff166001145b6108ee5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610463565b606b805460ff19166001179055801561091157606b805461ff0019166101001790555b6001600160a01b0387161580159061092857508415155b801561093357508215155b61097f5760405162461bcd60e51b815260206004820152601e60248201527f4368696c6445524332303a204241445f494e495449414c495a4154494f4e00006044820152606401610463565b60d1805460ff8416600160a01b026001600160a81b03199091166001600160a01b038a161717905560d080546001600160a01b03191633179055604080516020601f8801819004810282018101909252868152610a2a91889088908190840183828082843760009201919091525050604080516020601f8a0181900481028201810190925288815292508891508790819084018382808284376000920191909152506110de92505050565b610a8286868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805180820190915260018152603160f81b6020820152915061110f9050565b8015610ac857606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b6000610adb61117b565b905090565b6001600160a01b038316610b425760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610463565b6001600160a01b038216610ba35760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610463565b6001600160a01b038381166000818152609f602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b60008151600003610c1857506000919050565b506020015190565b6000806001610c36610c31886111d7565b611254565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa158015610c84573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610cdb5760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610463565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6000610d088484610826565b90506000198114610d705781811015610d635760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610463565b610d708484848403610ae0565b50505050565b6001600160a01b038316610dda5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610463565b6001600160a01b038216610e3c5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610463565b6001600160a01b0383166000908152609e602052604090205481811015610eb45760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610463565b6001600160a01b038085166000818152609e602052604080822086860390559286168082529083902080548601905591516000805160206118cb83398151915290610f029086815260200190565b60405180910390a3610d70565b6001600160a01b038216610f655760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610463565b8060a06000828254610f7791906116b4565b90915550506001600160a01b0382166000818152609e60209081526040808320805486019055518481526000805160206118cb833981519152910160405180910390a35b5050565b6001600160a01b03821661101f5760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610463565b6001600160a01b0382166000908152609e6020526040902054818110156110935760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610463565b6001600160a01b0383166000818152609e60209081526040808320868603905560a080548790039055518581529192916000805160206118cb8339815191529101610bf8565b505050565b606b54610100900460ff166111055760405162461bcd60e51b815260040161046390611718565b610fbb8282611281565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f61115d8184846112c1565b600055600280546001600160a01b0319163017905560055550505050565b60003033036111d157600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506111d49050565b50335b90565b60006040518060800160405280604381526020016118886043913980516020918201208351848301516040808701518051908601209051611237950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039861126161130a565b8360405161190160f01b8152600281019290925260228201526042902090565b606b54610100900460ff166112a85760405162461bcd60e51b815260040161046390611718565b60a16112b483826117c7565b5060a26110d982826117c7565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b6002546000906001600160a01b031630148015611328575060015446145b15611334575060005490565b610adb6005546003546004546112c1565b60005b83811015611360578181015183820152602001611348565b50506000910152565b60008151808452611381816020860160208601611345565b601f01601f19169290920160200192915050565b6020815260006113a86020830184611369565b9392505050565b80356001600160a01b03811681146113c657600080fd5b919050565b600080604083850312156113de57600080fd5b6113e7836113af565b946020939093013593505050565b60008083601f84011261140757600080fd5b50813567ffffffffffffffff81111561141f57600080fd5b60208301915083602082850101111561143757600080fd5b9250929050565b803560ff811681146113c657600080fd5b60008060008060008060a0878903121561146857600080fd5b611471876113af565b9550602087013567ffffffffffffffff81111561148d57600080fd5b61149989828a016113f5565b90965094505060408701359250606087013591506114b96080880161143e565b90509295509295509295565b6000806000606084860312156114da57600080fd5b6114e3846113af565b92506114f1602085016113af565b9150604084013590509250925092565b60006020828403121561151357600080fd5b6113a8826113af565b60006020828403121561152e57600080fd5b5035919050565b6000806040838503121561154857600080fd5b611551836113af565b915061155f602084016113af565b90509250929050565b6000806000806000806080878903121561158157600080fd5b61158a876113af565b9550602087013567ffffffffffffffff808211156115a757600080fd5b6115b38a838b016113f5565b909750955060408901359150808211156115cc57600080fd5b506115d989828a016113f5565b90945092506114b990506060880161143e565b600181811c9082168061160057607f821691505b60208210810361162057634e487b7160e01b600052602260045260246000fd5b50919050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b6000825161165e818460208701611345565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b8082018082111561039857634e487b7160e01b600052601160045260246000fd5b60208082526023908201527f4368696c6445524332303a204f6e6c79207072656469636174652063616e2063604082015262185b1b60ea1b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b601f8211156110d957600081815260208120601f850160051c810160208610156117a05750805b601f850160051c820191505b818110156117bf578281556001016117ac565b505050505050565b815167ffffffffffffffff8111156117e1576117e1611763565b6117f5816117ef84546115ec565b84611779565b602080601f83116001811461182a57600084156118125750858301515b600019600386901b1c1916600185901b1785556117bf565b600085815260208120601f198616915b828110156118595788860151825594840194600190910190840161183a565b50858210156118775787850151600019600388901b60f8161c191681555b5050505050600190811b0190555056fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa264697066735822122025382f2e5346073a2875deb90af71e629e8a47644d5cf7790f05f8e5b91544e164736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildERC20PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC20Predicate","sourceName":"contracts/blade/ChildERC20Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"address","name":"newNativeTokenRootAddress","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506114ea806100206000396000f3fe608060405234801561001057600080fd5b50600436106101375760003560e01c80637efab4f5116100b8578063c3b35a7e1161007c578063c3b35a7e14610270578063d41f177114610283578063e0563ab1146102aa578063eeb49945146102b3578063f3fef3a3146102c6578063f6451255146102d957600080fd5b80637efab4f5146101fa578063947287cf1461022357806397e5230d1461022c578063b176806514610236578063b68ad1e41461025d57600080fd5b80633b878c22116100ff5780633b878c22146101ab57806351351d53146101b457806355b01e4d146101c25780635ea5df79146101d057806371cf93b7146101e757600080fd5b806305dc2e8f1461013c57806307b3e2521461016c5780631459457a1461017a5780631bc114ba1461018f578063284017f5146101a2575b600080fd5b60345461014f906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61014f6004600360981b0181565b61018d610188366004610ff2565b610300565b005b60335461014f906001600160a01b031681565b61014f61202081565b61014f61101081565b61014f6002600160a01b0381565b61014f6004600160991b0181565b6101d961138881565b604051908152602001610163565b60355461014f906001600160a01b031681565b61014f610208366004611063565b6037602052600090815260409020546001600160a01b031681565b6101d961520881565b6101d9620249f081565b6101d97f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60365461014f906001600160a01b031681565b61018d61027e366004611087565b610464565b6101d97f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61014f61203081565b61018d6102c13660046110c8565b610474565b61018d6102d4366004611151565b610648565b6101d97f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b336002600160a01b03146103495760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064015b60405180910390fd5b600054610100900460ff16158080156103695750600054600160ff909116105b806103835750303b158015610383575060005460ff166001145b6103e65760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610340565b6000805460ff191660011790558015610409576000805461ff0019166101001790555b6104168686868686610657565b801561045c576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b61046f8383836107a7565b505050565b6034546001600160a01b031633146104df5760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f53544154455f6044820152672922a1a2a4ab22a960c11b6064820152608401610340565b6035546001600160a01b0384811691161461054d5760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f524f4f545f50604482015267524544494341544560c01b6064820152608401610340565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82161057c60206000848661117d565b610585916111a7565b036105a45761059f61059a826020818661117d565b610b1d565b610642565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6105d360206000848661117d565b6105dc916111a7565b036105eb5761059f8282610dc8565b60405162461bcd60e51b815260206004820152602660248201527f4368696c6445524332305072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b6064820152608401610340565b50505050565b6106538233836107a7565b5050565b6001600160a01b0385161580159061067757506001600160a01b03841615155b801561068b57506001600160a01b03831615155b801561069f57506001600160a01b03821615155b6106fb5760405162461bcd60e51b815260206004820152602760248201527f4368696c6445524332305072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b6064820152608401610340565b603380546001600160a01b03199081166001600160a01b0388811691909117909255603480548216878416179055603580548216868416179055603680549091168483161790558116156107a0576001600160a01b03811660008181526037602052604080822080546001600160a01b03191661101090811790915590519092917f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d91a35b5050505050565b826001600160a01b03163b60000361080b5760405162461bcd60e51b815260206004820152602160248201527f4368696c6445524332305072656469636174653a204e4f545f434f4e545241436044820152601560fa1b6064820152608401610340565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561084b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061086f91906111c5565b6001600160a01b038181166000908152603760205260409020549192508581169116146108ae5760405162461bcd60e51b8152600401610340906111e2565b6001600160a01b0381166108c4576108c4611225565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561090c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061093091906111c5565b6001600160a01b03161461094657610946611225565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610974903390869060040161123b565b6020604051808303816000875af1158015610993573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b79190611254565b610a035760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204255524e5f4641494c45446044820152606401610340565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610a8e9391169160c4016112bc565b600060405180830381600087803b158015610aa857600080fd5b505af1158015610abc573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167fa0923f060a16fc784558d43de424ffde7b01643de5e5d335851b9df94c76bb273386604051610b0f92919061123b565b60405180910390a450505050565b6000808080610b2e858701876112e8565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610b715760405162461bcd60e51b8152600401610340906111e2565b806001600160a01b03163b600003610b8b57610b8b611225565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610bcb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bef91906111c5565b9050856001600160a01b0316816001600160a01b031614610c1257610c12611225565b6001600160a01b038116610c2857610c28611225565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c70573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c9491906111c5565b6001600160a01b031614610caa57610caa611225565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610cd8908790879060040161123b565b6020604051808303816000875af1158015610cf7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d1b9190611254565b610d675760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204d494e545f4641494c45446044820152606401610340565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fdf34f3a3ed8bedc14a4b284ebaee5374d55b64bac6a84c270dabe8fd6b4cdafd8887604051610db692919061123b565b60405180910390a45050505050505050565b6000808080610dd9858701876113dc565b92975090955093509150506001600160a01b038416610dfa57610dfa611225565b6001600160a01b038481166000908152603760205260409020541615610e2257610e22611225565b6036546040516bffffffffffffffffffffffff19606087901b166020820152600091610e72916001600160a01b039091169060340160405160208183030381529060405280519060200120610f3d565b6001600160a01b038681166000908152603760205260409081902080546001600160a01b031916928416928317905551637b69774360e11b81529192509063f6d2ee8690610eca908890889088908890600401611469565b600060405180830381600087803b158015610ee457600080fd5b505af1158015610ef8573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a350505050505050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116610fd45760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610340565b92915050565b6001600160a01b0381168114610fef57600080fd5b50565b600080600080600060a0868803121561100a57600080fd5b853561101581610fda565b9450602086013561102581610fda565b9350604086013561103581610fda565b9250606086013561104581610fda565b9150608086013561105581610fda565b809150509295509295909350565b60006020828403121561107557600080fd5b813561108081610fda565b9392505050565b60008060006060848603121561109c57600080fd5b83356110a781610fda565b925060208401356110b781610fda565b929592945050506040919091013590565b600080600080606085870312156110de57600080fd5b8435935060208501356110f081610fda565b9250604085013567ffffffffffffffff8082111561110d57600080fd5b818701915087601f83011261112157600080fd5b81358181111561113057600080fd5b88602082850101111561114257600080fd5b95989497505060200194505050565b6000806040838503121561116457600080fd5b823561116f81610fda565b946020939093013593505050565b6000808585111561118d57600080fd5b8386111561119a57600080fd5b5050820193919092039150565b80356020831015610fd457600019602084900360031b1b1692915050565b6000602082840312156111d757600080fd5b815161108081610fda565b60208082526023908201527f4368696c6445524332305072656469636174653a20554e4d41505045445f544f60408201526225a2a760e91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60006020828403121561126657600080fd5b8151801515811461108057600080fd5b6000815180845260005b8181101561129c57602081850181015186830182015201611280565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b03831681526040602082018190526000906112e090830184611276565b949350505050565b600080600080608085870312156112fe57600080fd5b843561130981610fda565b9350602085013561131981610fda565b9250604085013561132981610fda565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261136057600080fd5b813567ffffffffffffffff8082111561137b5761137b611339565b604051601f8301601f19908116603f011681019082821181831017156113a3576113a3611339565b816040528381528660208588010111156113bc57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a086880312156113f457600080fd5b85359450602086013561140681610fda565b9350604086013567ffffffffffffffff8082111561142357600080fd5b61142f89838a0161134f565b9450606088013591508082111561144557600080fd5b506114528882890161134f565b925050608086013560ff8116811461105557600080fd5b6001600160a01b038516815260806020820181905260009061148d90830186611276565b828103604084015261149f8186611276565b91505060ff831660608301529594505050505056fea2646970667358221220bd41dd13b54e29c0816d212372e16cd26df9c5264370fd910d08d3a513cb26d964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101375760003560e01c80637efab4f5116100b8578063c3b35a7e1161007c578063c3b35a7e14610270578063d41f177114610283578063e0563ab1146102aa578063eeb49945146102b3578063f3fef3a3146102c6578063f6451255146102d957600080fd5b80637efab4f5146101fa578063947287cf1461022357806397e5230d1461022c578063b176806514610236578063b68ad1e41461025d57600080fd5b80633b878c22116100ff5780633b878c22146101ab57806351351d53146101b457806355b01e4d146101c25780635ea5df79146101d057806371cf93b7146101e757600080fd5b806305dc2e8f1461013c57806307b3e2521461016c5780631459457a1461017a5780631bc114ba1461018f578063284017f5146101a2575b600080fd5b60345461014f906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61014f6004600360981b0181565b61018d610188366004610ff2565b610300565b005b60335461014f906001600160a01b031681565b61014f61202081565b61014f61101081565b61014f6002600160a01b0381565b61014f6004600160991b0181565b6101d961138881565b604051908152602001610163565b60355461014f906001600160a01b031681565b61014f610208366004611063565b6037602052600090815260409020546001600160a01b031681565b6101d961520881565b6101d9620249f081565b6101d97f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60365461014f906001600160a01b031681565b61018d61027e366004611087565b610464565b6101d97f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61014f61203081565b61018d6102c13660046110c8565b610474565b61018d6102d4366004611151565b610648565b6101d97f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b336002600160a01b03146103495760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064015b60405180910390fd5b600054610100900460ff16158080156103695750600054600160ff909116105b806103835750303b158015610383575060005460ff166001145b6103e65760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610340565b6000805460ff191660011790558015610409576000805461ff0019166101001790555b6104168686868686610657565b801561045c576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b61046f8383836107a7565b505050565b6034546001600160a01b031633146104df5760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f53544154455f6044820152672922a1a2a4ab22a960c11b6064820152608401610340565b6035546001600160a01b0384811691161461054d5760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f524f4f545f50604482015267524544494341544560c01b6064820152608401610340565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82161057c60206000848661117d565b610585916111a7565b036105a45761059f61059a826020818661117d565b610b1d565b610642565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6105d360206000848661117d565b6105dc916111a7565b036105eb5761059f8282610dc8565b60405162461bcd60e51b815260206004820152602660248201527f4368696c6445524332305072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b6064820152608401610340565b50505050565b6106538233836107a7565b5050565b6001600160a01b0385161580159061067757506001600160a01b03841615155b801561068b57506001600160a01b03831615155b801561069f57506001600160a01b03821615155b6106fb5760405162461bcd60e51b815260206004820152602760248201527f4368696c6445524332305072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b6064820152608401610340565b603380546001600160a01b03199081166001600160a01b0388811691909117909255603480548216878416179055603580548216868416179055603680549091168483161790558116156107a0576001600160a01b03811660008181526037602052604080822080546001600160a01b03191661101090811790915590519092917f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d91a35b5050505050565b826001600160a01b03163b60000361080b5760405162461bcd60e51b815260206004820152602160248201527f4368696c6445524332305072656469636174653a204e4f545f434f4e545241436044820152601560fa1b6064820152608401610340565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561084b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061086f91906111c5565b6001600160a01b038181166000908152603760205260409020549192508581169116146108ae5760405162461bcd60e51b8152600401610340906111e2565b6001600160a01b0381166108c4576108c4611225565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561090c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061093091906111c5565b6001600160a01b03161461094657610946611225565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610974903390869060040161123b565b6020604051808303816000875af1158015610993573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b79190611254565b610a035760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204255524e5f4641494c45446044820152606401610340565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610a8e9391169160c4016112bc565b600060405180830381600087803b158015610aa857600080fd5b505af1158015610abc573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167fa0923f060a16fc784558d43de424ffde7b01643de5e5d335851b9df94c76bb273386604051610b0f92919061123b565b60405180910390a450505050565b6000808080610b2e858701876112e8565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610b715760405162461bcd60e51b8152600401610340906111e2565b806001600160a01b03163b600003610b8b57610b8b611225565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610bcb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bef91906111c5565b9050856001600160a01b0316816001600160a01b031614610c1257610c12611225565b6001600160a01b038116610c2857610c28611225565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c70573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c9491906111c5565b6001600160a01b031614610caa57610caa611225565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610cd8908790879060040161123b565b6020604051808303816000875af1158015610cf7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d1b9190611254565b610d675760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204d494e545f4641494c45446044820152606401610340565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fdf34f3a3ed8bedc14a4b284ebaee5374d55b64bac6a84c270dabe8fd6b4cdafd8887604051610db692919061123b565b60405180910390a45050505050505050565b6000808080610dd9858701876113dc565b92975090955093509150506001600160a01b038416610dfa57610dfa611225565b6001600160a01b038481166000908152603760205260409020541615610e2257610e22611225565b6036546040516bffffffffffffffffffffffff19606087901b166020820152600091610e72916001600160a01b039091169060340160405160208183030381529060405280519060200120610f3d565b6001600160a01b038681166000908152603760205260409081902080546001600160a01b031916928416928317905551637b69774360e11b81529192509063f6d2ee8690610eca908890889088908890600401611469565b600060405180830381600087803b158015610ee457600080fd5b505af1158015610ef8573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a350505050505050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116610fd45760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610340565b92915050565b6001600160a01b0381168114610fef57600080fd5b50565b600080600080600060a0868803121561100a57600080fd5b853561101581610fda565b9450602086013561102581610fda565b9350604086013561103581610fda565b9250606086013561104581610fda565b9150608086013561105581610fda565b809150509295509295909350565b60006020828403121561107557600080fd5b813561108081610fda565b9392505050565b60008060006060848603121561109c57600080fd5b83356110a781610fda565b925060208401356110b781610fda565b929592945050506040919091013590565b600080600080606085870312156110de57600080fd5b8435935060208501356110f081610fda565b9250604085013567ffffffffffffffff8082111561110d57600080fd5b818701915087601f83011261112157600080fd5b81358181111561113057600080fd5b88602082850101111561114257600080fd5b95989497505060200194505050565b6000806040838503121561116457600080fd5b823561116f81610fda565b946020939093013593505050565b6000808585111561118d57600080fd5b8386111561119a57600080fd5b5050820193919092039150565b80356020831015610fd457600019602084900360031b1b1692915050565b6000602082840312156111d757600080fd5b815161108081610fda565b60208082526023908201527f4368696c6445524332305072656469636174653a20554e4d41505045445f544f60408201526225a2a760e91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60006020828403121561126657600080fd5b8151801515811461108057600080fd5b6000815180845260005b8181101561129c57602081850181015186830182015201611280565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b03831681526040602082018190526000906112e090830184611276565b949350505050565b600080600080608085870312156112fe57600080fd5b843561130981610fda565b9350602085013561131981610fda565b9250604085013561132981610fda565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261136057600080fd5b813567ffffffffffffffff8082111561137b5761137b611339565b604051601f8301601f19908116603f011681019082821181831017156113a3576113a3611339565b816040528381528660208588010111156113bc57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a086880312156113f457600080fd5b85359450602086013561140681610fda565b9350604086013567ffffffffffffffff8082111561142357600080fd5b61142f89838a0161134f565b9450606088013591508082111561144557600080fd5b506114528882890161134f565b925050608086013560ff8116811461105557600080fd5b6001600160a01b038516815260806020820181905260009061148d90830186611276565b828103604084015261149f8186611276565b91505060ff831660608301529594505050505056fea2646970667358221220bd41dd13b54e29c0816d212372e16cd26df9c5264370fd910d08d3a513cb26d964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildERC20PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC20PredicateAccessList","sourceName":"contracts/blade/ChildERC20PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"address","name":"newNativeTokenRootAddress","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"address","name":"newNativeTokenRootAddress","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","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":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611c8e806100206000396000f3fe608060405234801561001057600080fd5b506004361061018f5760003560e01c80638da5cb5b116100e4578063c5e4683a11610092578063c5e4683a14610323578063d41f177114610336578063e0563ab11461035d578063e30c397814610366578063eeb4994514610377578063f2fde38b1461038a578063f3fef3a31461039d578063f6451255146103b057600080fd5b80638da5cb5b1461029f578063947287cf146102b057806397e5230d146102b9578063b1768065146102c3578063b68ad1e4146102ea578063c1225a20146102fd578063c3b35a7e1461031057600080fd5b806354f8abad1161014157806354f8abad1461021a57806355b01e4d1461022d5780635ea5df791461023b578063715018a61461025257806371cf93b71461025a57806379ba50971461026d5780637efab4f51461027557600080fd5b806305dc2e8f1461019457806307b3e252146101c45780631459457a146101d25780631bc114ba146101e7578063284017f5146101fa5780633b878c221461020357806351351d531461020c575b600080fd5b60fd546101a7906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101a76004600360981b0181565b6101e56101e0366004611616565b6103d7565b005b60fc546101a7906001600160a01b031681565b6101a761202081565b6101a761101081565b6101a76002600160a01b0381565b6101e5610228366004611695565b6104db565b6101a76004600160991b0181565b61024461138881565b6040519081526020016101bb565b6101e56105fe565b60fe546101a7906001600160a01b031681565b6101e5610612565b6101a761028336600461173e565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101a7565b61024461520881565b610244620249f081565b6102447f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101a7906001600160a01b031681565b6101e561030b366004611762565b61068c565b6101e561031e36600461177f565b6106db565b6101e5610331366004611762565b6106f3565b6102447f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101a761203081565b6065546001600160a01b03166101a7565b6101e56103853660046117c0565b61073a565b6101e561039836600461173e565b61090e565b6101e56103ab366004611849565b61097f565b6102447f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b336002600160a01b03146104075760405163973d02cb60e01b81526004016103fe90611875565b60405180910390fd5b600054610100900460ff16158080156104275750600054600160ff909116105b806104415750303b158015610441575060005460ff166001145b61045d5760405162461bcd60e51b81526004016103fe90611899565b6000805460ff191660011790558015610480576000805461ff0019166101001790555b61048d8686868686610996565b80156104d3576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b336002600160a01b03146105025760405163973d02cb60e01b81526004016103fe90611875565b600054610100900460ff16158080156105225750600054600160ff909116105b8061053c5750303b15801561053c575060005460ff166001145b6105585760405162461bcd60e51b81526004016103fe90611899565b6000805460ff19166001179055801561057b576000805461ff0019166101001790555b6105888989898989610996565b60c9805461ffff191685151561ff00191617610100851515021790556105ad82610ae7565b80156105f3576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050505050565b610606610b00565b6106106000610ae7565b565b60655433906001600160a01b031681146106805760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016103fe565b61068981610ae7565b50565b610694610b00565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6106e3610b5a565b6106ee838383610b62565b505050565b6106fb610b00565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b60fd546001600160a01b031633146107a55760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f53544154455f6044820152672922a1a2a4ab22a960c11b60648201526084016103fe565b60fe546001600160a01b038481169116146108135760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f524f4f545f50604482015267524544494341544560c01b60648201526084016103fe565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216108426020600084866118e7565b61084b91611911565b0361086a5761086561086082602081866118e7565b610ed9565b610908565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6108996020600084866118e7565b6108a291611911565b036108b1576108658282611185565b60405162461bcd60e51b815260206004820152602660248201527f4368696c6445524332305072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b60648201526084016103fe565b50505050565b610916610b00565b606580546001600160a01b0383166001600160a01b031990911681179091556109476033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b610987610b5a565b610992823383610b62565b5050565b6001600160a01b038516158015906109b657506001600160a01b03841615155b80156109ca57506001600160a01b03831615155b80156109de57506001600160a01b03821615155b610a3a5760405162461bcd60e51b815260206004820152602760248201527f4368696c6445524332305072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b60648201526084016103fe565b60fc80546001600160a01b03199081166001600160a01b038881169190911790925560fd8054821687841617905560fe8054821686841617905560ff8054909116848316179055811615610ae0576001600160a01b0381166000818152610100602052604080822080546001600160a01b03191661101090811790915590519092917f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d91a35b5050505050565b606580546001600160a01b0319169055610689816112fc565b6033546001600160a01b031633146106105760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103fe565b61061061134e565b826001600160a01b03163b600003610bc65760405162461bcd60e51b815260206004820152602160248201527f4368696c6445524332305072656469636174653a204e4f545f434f4e545241436044820152601560fa1b60648201526084016103fe565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c06573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c2a919061192f565b6001600160a01b0381811660009081526101006020526040902054919250858116911614610c6a5760405162461bcd60e51b81526004016103fe9061194c565b6001600160a01b038116610c8057610c8061198f565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610cc8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cec919061192f565b6001600160a01b031614610d0257610d0261198f565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610d3090339086906004016119a5565b6020604051808303816000875af1158015610d4f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d7391906119be565b610dbf5760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204255524e5f4641494c454460448201526064016103fe565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610e4a9391169160c401611a2b565b600060405180830381600087803b158015610e6457600080fd5b505af1158015610e78573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167fa0923f060a16fc784558d43de424ffde7b01643de5e5d335851b9df94c76bb273386604051610ecb9291906119a5565b60405180910390a450505050565b6000808080610eea85870187611a57565b6001600160a01b038085166000908152610100602052604090205494985092965090945092501680610f2e5760405162461bcd60e51b81526004016103fe9061194c565b806001600160a01b03163b600003610f4857610f4861198f565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f88573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fac919061192f565b9050856001600160a01b0316816001600160a01b031614610fcf57610fcf61198f565b6001600160a01b038116610fe557610fe561198f565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561102d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611051919061192f565b6001600160a01b0316146110675761106761198f565b6040516340c10f1960e01b81526001600160a01b038316906340c10f199061109590879087906004016119a5565b6020604051808303816000875af11580156110b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d891906119be565b6111245760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204d494e545f4641494c454460448201526064016103fe565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fdf34f3a3ed8bedc14a4b284ebaee5374d55b64bac6a84c270dabe8fd6b4cdafd88876040516111739291906119a5565b60405180910390a45050505050505050565b600080808061119685870187611b4b565b92975090955093509150506001600160a01b0384166111b7576111b761198f565b6001600160a01b038481166000908152610100602052604090205416156111e0576111e061198f565b60ff546040516bffffffffffffffffffffffff19606087901b166020820152600091611230916001600160a01b039091169060340160405160208183030381529060405280519060200120611564565b6001600160a01b03868116600090815261010060205260409081902080546001600160a01b031916928416928317905551637b69774360e11b81529192509063f6d2ee8690611289908890889088908890600401611bd8565b600060405180830381600087803b1580156112a357600080fd5b505af11580156112b7573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a350505050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff161561145957604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b0191611388916113b09190611c23565b6000604051808303818686fa925050503d80600081146113ec576040519150601f19603f3d011682016040523d82523d6000602084013e6113f1565b606091505b509150915081801561141657506000818060200190518101906114149190611c3f565b115b6114565760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016103fe565b50505b60c954610100900460ff161561061057604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b0191611388916114c09190611c23565b6000604051808303818686fa925050503d80600081146114fc576040519150601f19603f3d011682016040523d82523d6000602084013e611501565b606091505b50915091508180156115275750808060200190518101906115229190611c3f565b600114155b6109925760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016103fe565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166115fb5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016103fe565b92915050565b6001600160a01b038116811461068957600080fd5b600080600080600060a0868803121561162e57600080fd5b853561163981611601565b9450602086013561164981611601565b9350604086013561165981611601565b9250606086013561166981611601565b9150608086013561167981611601565b809150509295509295909350565b801515811461068957600080fd5b600080600080600080600080610100898b0312156116b257600080fd5b88356116bd81611601565b975060208901356116cd81611601565b965060408901356116dd81611601565b955060608901356116ed81611601565b945060808901356116fd81611601565b935060a089013561170d81611687565b925060c089013561171d81611687565b915060e089013561172d81611601565b809150509295985092959890939650565b60006020828403121561175057600080fd5b813561175b81611601565b9392505050565b60006020828403121561177457600080fd5b813561175b81611687565b60008060006060848603121561179457600080fd5b833561179f81611601565b925060208401356117af81611601565b929592945050506040919091013590565b600080600080606085870312156117d657600080fd5b8435935060208501356117e881611601565b9250604085013567ffffffffffffffff8082111561180557600080fd5b818701915087601f83011261181957600080fd5b81358181111561182857600080fd5b88602082850101111561183a57600080fd5b95989497505060200194505050565b6000806040838503121561185c57600080fd5b823561186781611601565b946020939093013593505050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b600080858511156118f757600080fd5b8386111561190457600080fd5b5050820193919092039150565b803560208310156115fb57600019602084900360031b1b1692915050565b60006020828403121561194157600080fd5b815161175b81611601565b60208082526023908201527f4368696c6445524332305072656469636174653a20554e4d41505045445f544f60408201526225a2a760e91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b6000602082840312156119d057600080fd5b815161175b81611687565b60005b838110156119f65781810151838201526020016119de565b50506000910152565b60008151808452611a178160208601602086016119db565b601f01601f19169290920160200192915050565b6001600160a01b0383168152604060208201819052600090611a4f908301846119ff565b949350505050565b60008060008060808587031215611a6d57600080fd5b8435611a7881611601565b93506020850135611a8881611601565b92506040850135611a9881611601565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112611acf57600080fd5b813567ffffffffffffffff80821115611aea57611aea611aa8565b604051601f8301601f19908116603f01168101908282118183101715611b1257611b12611aa8565b81604052838152866020858801011115611b2b57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a08688031215611b6357600080fd5b853594506020860135611b7581611601565b9350604086013567ffffffffffffffff80821115611b9257600080fd5b611b9e89838a01611abe565b94506060880135915080821115611bb457600080fd5b50611bc188828901611abe565b925050608086013560ff8116811461167957600080fd5b6001600160a01b0385168152608060208201819052600090611bfc908301866119ff565b8281036040840152611c0e81866119ff565b91505060ff8316606083015295945050505050565b60008251611c358184602087016119db565b9190910192915050565b600060208284031215611c5157600080fd5b505191905056fea2646970667358221220dc69d4ed666c48fc4b8a9d7d1daa320adc4e6f03f6db49608ee97279bc64db2d64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061018f5760003560e01c80638da5cb5b116100e4578063c5e4683a11610092578063c5e4683a14610323578063d41f177114610336578063e0563ab11461035d578063e30c397814610366578063eeb4994514610377578063f2fde38b1461038a578063f3fef3a31461039d578063f6451255146103b057600080fd5b80638da5cb5b1461029f578063947287cf146102b057806397e5230d146102b9578063b1768065146102c3578063b68ad1e4146102ea578063c1225a20146102fd578063c3b35a7e1461031057600080fd5b806354f8abad1161014157806354f8abad1461021a57806355b01e4d1461022d5780635ea5df791461023b578063715018a61461025257806371cf93b71461025a57806379ba50971461026d5780637efab4f51461027557600080fd5b806305dc2e8f1461019457806307b3e252146101c45780631459457a146101d25780631bc114ba146101e7578063284017f5146101fa5780633b878c221461020357806351351d531461020c575b600080fd5b60fd546101a7906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101a76004600360981b0181565b6101e56101e0366004611616565b6103d7565b005b60fc546101a7906001600160a01b031681565b6101a761202081565b6101a761101081565b6101a76002600160a01b0381565b6101e5610228366004611695565b6104db565b6101a76004600160991b0181565b61024461138881565b6040519081526020016101bb565b6101e56105fe565b60fe546101a7906001600160a01b031681565b6101e5610612565b6101a761028336600461173e565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101a7565b61024461520881565b610244620249f081565b6102447f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101a7906001600160a01b031681565b6101e561030b366004611762565b61068c565b6101e561031e36600461177f565b6106db565b6101e5610331366004611762565b6106f3565b6102447f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101a761203081565b6065546001600160a01b03166101a7565b6101e56103853660046117c0565b61073a565b6101e561039836600461173e565b61090e565b6101e56103ab366004611849565b61097f565b6102447f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b336002600160a01b03146104075760405163973d02cb60e01b81526004016103fe90611875565b60405180910390fd5b600054610100900460ff16158080156104275750600054600160ff909116105b806104415750303b158015610441575060005460ff166001145b61045d5760405162461bcd60e51b81526004016103fe90611899565b6000805460ff191660011790558015610480576000805461ff0019166101001790555b61048d8686868686610996565b80156104d3576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b336002600160a01b03146105025760405163973d02cb60e01b81526004016103fe90611875565b600054610100900460ff16158080156105225750600054600160ff909116105b8061053c5750303b15801561053c575060005460ff166001145b6105585760405162461bcd60e51b81526004016103fe90611899565b6000805460ff19166001179055801561057b576000805461ff0019166101001790555b6105888989898989610996565b60c9805461ffff191685151561ff00191617610100851515021790556105ad82610ae7565b80156105f3576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050505050565b610606610b00565b6106106000610ae7565b565b60655433906001600160a01b031681146106805760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016103fe565b61068981610ae7565b50565b610694610b00565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6106e3610b5a565b6106ee838383610b62565b505050565b6106fb610b00565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b60fd546001600160a01b031633146107a55760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f53544154455f6044820152672922a1a2a4ab22a960c11b60648201526084016103fe565b60fe546001600160a01b038481169116146108135760405162461bcd60e51b815260206004820152602860248201527f4368696c6445524332305072656469636174653a204f4e4c595f524f4f545f50604482015267524544494341544560c01b60648201526084016103fe565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216108426020600084866118e7565b61084b91611911565b0361086a5761086561086082602081866118e7565b610ed9565b610908565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6108996020600084866118e7565b6108a291611911565b036108b1576108658282611185565b60405162461bcd60e51b815260206004820152602660248201527f4368696c6445524332305072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b60648201526084016103fe565b50505050565b610916610b00565b606580546001600160a01b0383166001600160a01b031990911681179091556109476033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b610987610b5a565b610992823383610b62565b5050565b6001600160a01b038516158015906109b657506001600160a01b03841615155b80156109ca57506001600160a01b03831615155b80156109de57506001600160a01b03821615155b610a3a5760405162461bcd60e51b815260206004820152602760248201527f4368696c6445524332305072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b60648201526084016103fe565b60fc80546001600160a01b03199081166001600160a01b038881169190911790925560fd8054821687841617905560fe8054821686841617905560ff8054909116848316179055811615610ae0576001600160a01b0381166000818152610100602052604080822080546001600160a01b03191661101090811790915590519092917f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d91a35b5050505050565b606580546001600160a01b0319169055610689816112fc565b6033546001600160a01b031633146106105760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103fe565b61061061134e565b826001600160a01b03163b600003610bc65760405162461bcd60e51b815260206004820152602160248201527f4368696c6445524332305072656469636174653a204e4f545f434f4e545241436044820152601560fa1b60648201526084016103fe565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c06573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c2a919061192f565b6001600160a01b0381811660009081526101006020526040902054919250858116911614610c6a5760405162461bcd60e51b81526004016103fe9061194c565b6001600160a01b038116610c8057610c8061198f565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610cc8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cec919061192f565b6001600160a01b031614610d0257610d0261198f565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610d3090339086906004016119a5565b6020604051808303816000875af1158015610d4f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d7391906119be565b610dbf5760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204255524e5f4641494c454460448201526064016103fe565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610e4a9391169160c401611a2b565b600060405180830381600087803b158015610e6457600080fd5b505af1158015610e78573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167fa0923f060a16fc784558d43de424ffde7b01643de5e5d335851b9df94c76bb273386604051610ecb9291906119a5565b60405180910390a450505050565b6000808080610eea85870187611a57565b6001600160a01b038085166000908152610100602052604090205494985092965090945092501680610f2e5760405162461bcd60e51b81526004016103fe9061194c565b806001600160a01b03163b600003610f4857610f4861198f565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f88573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fac919061192f565b9050856001600160a01b0316816001600160a01b031614610fcf57610fcf61198f565b6001600160a01b038116610fe557610fe561198f565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561102d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611051919061192f565b6001600160a01b0316146110675761106761198f565b6040516340c10f1960e01b81526001600160a01b038316906340c10f199061109590879087906004016119a5565b6020604051808303816000875af11580156110b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d891906119be565b6111245760405162461bcd60e51b815260206004820181905260248201527f4368696c6445524332305072656469636174653a204d494e545f4641494c454460448201526064016103fe565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fdf34f3a3ed8bedc14a4b284ebaee5374d55b64bac6a84c270dabe8fd6b4cdafd88876040516111739291906119a5565b60405180910390a45050505050505050565b600080808061119685870187611b4b565b92975090955093509150506001600160a01b0384166111b7576111b761198f565b6001600160a01b038481166000908152610100602052604090205416156111e0576111e061198f565b60ff546040516bffffffffffffffffffffffff19606087901b166020820152600091611230916001600160a01b039091169060340160405160208183030381529060405280519060200120611564565b6001600160a01b03868116600090815261010060205260409081902080546001600160a01b031916928416928317905551637b69774360e11b81529192509063f6d2ee8690611289908890889088908890600401611bd8565b600060405180830381600087803b1580156112a357600080fd5b505af11580156112b7573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a350505050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff161561145957604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b0191611388916113b09190611c23565b6000604051808303818686fa925050503d80600081146113ec576040519150601f19603f3d011682016040523d82523d6000602084013e6113f1565b606091505b509150915081801561141657506000818060200190518101906114149190611c3f565b115b6114565760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016103fe565b50505b60c954610100900460ff161561061057604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b0191611388916114c09190611c23565b6000604051808303818686fa925050503d80600081146114fc576040519150601f19603f3d011682016040523d82523d6000602084013e611501565b606091505b50915091508180156115275750808060200190518101906115229190611c3f565b600114155b6109925760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016103fe565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166115fb5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016103fe565b92915050565b6001600160a01b038116811461068957600080fd5b600080600080600060a0868803121561162e57600080fd5b853561163981611601565b9450602086013561164981611601565b9350604086013561165981611601565b9250606086013561166981611601565b9150608086013561167981611601565b809150509295509295909350565b801515811461068957600080fd5b600080600080600080600080610100898b0312156116b257600080fd5b88356116bd81611601565b975060208901356116cd81611601565b965060408901356116dd81611601565b955060608901356116ed81611601565b945060808901356116fd81611601565b935060a089013561170d81611687565b925060c089013561171d81611687565b915060e089013561172d81611601565b809150509295985092959890939650565b60006020828403121561175057600080fd5b813561175b81611601565b9392505050565b60006020828403121561177457600080fd5b813561175b81611687565b60008060006060848603121561179457600080fd5b833561179f81611601565b925060208401356117af81611601565b929592945050506040919091013590565b600080600080606085870312156117d657600080fd5b8435935060208501356117e881611601565b9250604085013567ffffffffffffffff8082111561180557600080fd5b818701915087601f83011261181957600080fd5b81358181111561182857600080fd5b88602082850101111561183a57600080fd5b95989497505060200194505050565b6000806040838503121561185c57600080fd5b823561186781611601565b946020939093013593505050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b600080858511156118f757600080fd5b8386111561190457600080fd5b5050820193919092039150565b803560208310156115fb57600019602084900360031b1b1692915050565b60006020828403121561194157600080fd5b815161175b81611601565b60208082526023908201527f4368696c6445524332305072656469636174653a20554e4d41505045445f544f60408201526225a2a760e91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b6000602082840312156119d057600080fd5b815161175b81611687565b60005b838110156119f65781810151838201526020016119de565b50506000910152565b60008151808452611a178160208601602086016119db565b601f01601f19169290920160200192915050565b6001600160a01b0383168152604060208201819052600090611a4f908301846119ff565b949350505050565b60008060008060808587031215611a6d57600080fd5b8435611a7881611601565b93506020850135611a8881611601565b92506040850135611a9881611601565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112611acf57600080fd5b813567ffffffffffffffff80821115611aea57611aea611aa8565b604051601f8301601f19908116603f01168101908282118183101715611b1257611b12611aa8565b81604052838152866020858801011115611b2b57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a08688031215611b6357600080fd5b853594506020860135611b7581611601565b9350604086013567ffffffffffffffff80821115611b9257600080fd5b611b9e89838a01611abe565b94506060880135915080821115611bb457600080fd5b50611bc188828901611abe565b925050608086013560ff8116811461167957600080fd5b6001600160a01b0385168152608060208201819052600090611bfc908301866119ff565b8281036040840152611c0e81866119ff565b91505060ff8316606083015295945050505050565b60008251611c358184602087016119db565b9190910192915050565b600060208284031215611c5157600080fd5b505191905056fea2646970667358221220dc69d4ed666c48fc4b8a9d7d1daa320adc4e6f03f6db49608ee97279bc64db2d64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var RootMintableERC20PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC20Predicate","sourceName":"contracts/blade/RootMintableERC20Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061149f806100206000396000f3fe608060405234801561001057600080fd5b50600436106101425760003560e01c806397e5230d116100b8578063e0563ab11161007c578063e0563ab1146102a2578063eeb49945146102ab578063f213159c146102be578063f4a120f7146102d1578063f6451255146102e4578063f8c8765e1461030b57600080fd5b806397e5230d14610224578063b17680651461022e578063b68ad1e414610255578063d41f177114610268578063d57184e41461028f57600080fd5b806347e7ef241161010a57806347e7ef24146101aa57806351351d53146101bf57806355b01e4d146101cd5780635ea5df79146101db5780637efab4f5146101f2578063947287cf1461021b57600080fd5b806305dc2e8f1461014757806307b3e252146101775780631bc114ba14610185578063284017f5146101985780633b878c22146101a1575b600080fd5b60345461015a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61015a6004600360981b0181565b60335461015a906001600160a01b031681565b61015a61202081565b61015a61101081565b6101bd6101b8366004611038565b61031e565b005b61015a6002600160a01b0381565b61015a6004600160991b0181565b6101e461138881565b60405190815260200161016e565b61015a610200366004611064565b6037602052600090815260409020546001600160a01b031681565b6101e461520881565b6101e4620249f081565b6101e47f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60365461015a906001600160a01b031681565b6101e47f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60355461015a906001600160a01b031681565b61015a61203081565b6101bd6102b9366004611088565b61032d565b6101bd6102cc366004611111565b6104d5565b61015a6102df366004611064565b6104e5565b6101e47f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6101bd610319366004611152565b6108b1565b610329823383610a0e565b5050565b6034546001600160a01b031633146103a45760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526e2fa9aa20aa22afa922a1a2a4ab22a960891b60648201526084015b60405180910390fd5b6035546001600160a01b0384811691161461041a5760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526f5f4348494c445f50524544494341544560801b606482015260840161039b565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696104496020600084866111ae565b610452916111d8565b036104715761046c61046782602081866111ae565b610b7e565b6104cf565b60405162461bcd60e51b815260206004820152602d60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e564160448201526c4c49445f5349474e415455524560981b606482015260840161039b565b50505050565b6104e0838383610a0e565b505050565b60006001600160a01b03821661054f5760405162461bcd60e51b815260206004820152602960248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e56416044820152682624a22faa27a5a2a760b91b606482015260840161039b565b6001600160a01b0382811660009081526037602052604090205416156105ca5760405162461bcd60e51b815260206004820152602a60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20414c524560448201526910511657d3505414115160b21b606482015260840161039b565b6035546036546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261067892911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0385811660008181526037602052604080822080546001600160a01b03191686861617905560335481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610710573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526107389190810190611231565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610776573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261079e9190810190611231565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107dc573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061080091906112d3565b604051602001610814959493929190611322565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610840929190611374565b600060405180830381600087803b15801561085a57600080fd5b505af115801561086e573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b03146108f55760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b604482015260640161039b565b600054610100900460ff16158080156109155750600054600160ff909116105b8061092f5750303b15801561092f575060005460ff166001145b6109925760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161039b565b6000805460ff1916600117905580156109b5576000805461ff0019166101001790555b6109c185858585610c36565b8015610a07576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6001600160a01b038084166000908152603760205260409020541680610a3a57610a37846104e5565b90505b6001600160a01b038116610a5057610a50611398565b610a656001600160a01b038516333085610d31565b603354603554604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610af09391169160c401611374565b600060405180830381600087803b158015610b0a57600080fd5b505af1158015610b1e573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f1666a3f7b8a7494f2ebcebe646a5187ae55b1db3a068097377d90cd64a258ce93386604051610b719291906113ae565b60405180910390a46104cf565b6000808080610b8f858701876113c7565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610bc257610bc2611398565b610bd66001600160a01b0386168484610d9c565b826001600160a01b0316816001600160a01b0316866001600160a01b03167fb9f935478aae5b1da868de596dafe0a2b41eeb61311fdd60c6dbbe46a1debee88786604051610c259291906113ae565b60405180910390a450505050505050565b6001600160a01b03841615801590610c5657506001600160a01b03831615155b8015610c6a57506001600160a01b03821615155b8015610c7e57506001600160a01b03811615155b610ce15760405162461bcd60e51b815260206004820152602e60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204241445f60448201526d24a724aa24a0a624ad20aa24a7a760911b606482015260840161039b565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6040516001600160a01b03808516602483015283166044820152606481018290526104cf9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610dbb565b6104e08363a9059cbb60e01b8484604051602401610d659291906113ae565b6000610e10826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610e909092919063ffffffff16565b9050805160001480610e31575080806020019051810190610e319190611418565b6104e05760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b606482015260840161039b565b6060610e9f8484600085610ea7565b949350505050565b606082471015610f085760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b606482015260840161039b565b600080866001600160a01b03168587604051610f24919061143a565b60006040518083038185875af1925050503d8060008114610f61576040519150601f19603f3d011682016040523d82523d6000602084013e610f66565b606091505b5091509150610f7787838387610f82565b979650505050505050565b60608315610ff1578251600003610fea576001600160a01b0385163b610fea5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161039b565b5081610e9f565b610e9f83838151156110065781518083602001fd5b8060405162461bcd60e51b815260040161039b9190611456565b6001600160a01b038116811461103557600080fd5b50565b6000806040838503121561104b57600080fd5b823561105681611020565b946020939093013593505050565b60006020828403121561107657600080fd5b813561108181611020565b9392505050565b6000806000806060858703121561109e57600080fd5b8435935060208501356110b081611020565b9250604085013567ffffffffffffffff808211156110cd57600080fd5b818701915087601f8301126110e157600080fd5b8135818111156110f057600080fd5b88602082850101111561110257600080fd5b95989497505060200194505050565b60008060006060848603121561112657600080fd5b833561113181611020565b9250602084013561114181611020565b929592945050506040919091013590565b6000806000806080858703121561116857600080fd5b843561117381611020565b9350602085013561118381611020565b9250604085013561119381611020565b915060608501356111a381611020565b939692955090935050565b600080858511156111be57600080fd5b838611156111cb57600080fd5b5050820193919092039150565b803560208310156111f157600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b83811015611228578181015183820152602001611210565b50506000910152565b60006020828403121561124357600080fd5b815167ffffffffffffffff8082111561125b57600080fd5b818401915084601f83011261126f57600080fd5b815181811115611281576112816111f7565b604051601f8201601f19908116603f011681019083821181831017156112a9576112a96111f7565b816040528281528760208487010111156112c257600080fd5b610f7783602083016020880161120d565b6000602082840312156112e557600080fd5b815160ff8116811461108157600080fd5b6000815180845261130e81602086016020860161120d565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a06040820181905260009061134c908301866112f6565b828103606084015261135e81866112f6565b91505060ff831660808301529695505050505050565b6001600160a01b0383168152604060208201819052600090610e9f908301846112f6565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b600080600080608085870312156113dd57600080fd5b84356113e881611020565b935060208501356113f881611020565b9250604085013561140881611020565b9396929550929360600135925050565b60006020828403121561142a57600080fd5b8151801515811461108157600080fd5b6000825161144c81846020870161120d565b9190910192915050565b60208152600061108160208301846112f656fea2646970667358221220d80b757cc67caa5c50e62e69140cecbb6c6dd71e9cc2847c11a56f2365701d0564736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101425760003560e01c806397e5230d116100b8578063e0563ab11161007c578063e0563ab1146102a2578063eeb49945146102ab578063f213159c146102be578063f4a120f7146102d1578063f6451255146102e4578063f8c8765e1461030b57600080fd5b806397e5230d14610224578063b17680651461022e578063b68ad1e414610255578063d41f177114610268578063d57184e41461028f57600080fd5b806347e7ef241161010a57806347e7ef24146101aa57806351351d53146101bf57806355b01e4d146101cd5780635ea5df79146101db5780637efab4f5146101f2578063947287cf1461021b57600080fd5b806305dc2e8f1461014757806307b3e252146101775780631bc114ba14610185578063284017f5146101985780633b878c22146101a1575b600080fd5b60345461015a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61015a6004600360981b0181565b60335461015a906001600160a01b031681565b61015a61202081565b61015a61101081565b6101bd6101b8366004611038565b61031e565b005b61015a6002600160a01b0381565b61015a6004600160991b0181565b6101e461138881565b60405190815260200161016e565b61015a610200366004611064565b6037602052600090815260409020546001600160a01b031681565b6101e461520881565b6101e4620249f081565b6101e47f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60365461015a906001600160a01b031681565b6101e47f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60355461015a906001600160a01b031681565b61015a61203081565b6101bd6102b9366004611088565b61032d565b6101bd6102cc366004611111565b6104d5565b61015a6102df366004611064565b6104e5565b6101e47f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6101bd610319366004611152565b6108b1565b610329823383610a0e565b5050565b6034546001600160a01b031633146103a45760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526e2fa9aa20aa22afa922a1a2a4ab22a960891b60648201526084015b60405180910390fd5b6035546001600160a01b0384811691161461041a5760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526f5f4348494c445f50524544494341544560801b606482015260840161039b565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696104496020600084866111ae565b610452916111d8565b036104715761046c61046782602081866111ae565b610b7e565b6104cf565b60405162461bcd60e51b815260206004820152602d60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e564160448201526c4c49445f5349474e415455524560981b606482015260840161039b565b50505050565b6104e0838383610a0e565b505050565b60006001600160a01b03821661054f5760405162461bcd60e51b815260206004820152602960248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e56416044820152682624a22faa27a5a2a760b91b606482015260840161039b565b6001600160a01b0382811660009081526037602052604090205416156105ca5760405162461bcd60e51b815260206004820152602a60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20414c524560448201526910511657d3505414115160b21b606482015260840161039b565b6035546036546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261067892911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0385811660008181526037602052604080822080546001600160a01b03191686861617905560335481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610710573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526107389190810190611231565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610776573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261079e9190810190611231565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107dc573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061080091906112d3565b604051602001610814959493929190611322565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610840929190611374565b600060405180830381600087803b15801561085a57600080fd5b505af115801561086e573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b03146108f55760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b604482015260640161039b565b600054610100900460ff16158080156109155750600054600160ff909116105b8061092f5750303b15801561092f575060005460ff166001145b6109925760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161039b565b6000805460ff1916600117905580156109b5576000805461ff0019166101001790555b6109c185858585610c36565b8015610a07576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6001600160a01b038084166000908152603760205260409020541680610a3a57610a37846104e5565b90505b6001600160a01b038116610a5057610a50611398565b610a656001600160a01b038516333085610d31565b603354603554604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610af09391169160c401611374565b600060405180830381600087803b158015610b0a57600080fd5b505af1158015610b1e573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f1666a3f7b8a7494f2ebcebe646a5187ae55b1db3a068097377d90cd64a258ce93386604051610b719291906113ae565b60405180910390a46104cf565b6000808080610b8f858701876113c7565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610bc257610bc2611398565b610bd66001600160a01b0386168484610d9c565b826001600160a01b0316816001600160a01b0316866001600160a01b03167fb9f935478aae5b1da868de596dafe0a2b41eeb61311fdd60c6dbbe46a1debee88786604051610c259291906113ae565b60405180910390a450505050505050565b6001600160a01b03841615801590610c5657506001600160a01b03831615155b8015610c6a57506001600160a01b03821615155b8015610c7e57506001600160a01b03811615155b610ce15760405162461bcd60e51b815260206004820152602e60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204241445f60448201526d24a724aa24a0a624ad20aa24a7a760911b606482015260840161039b565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6040516001600160a01b03808516602483015283166044820152606481018290526104cf9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610dbb565b6104e08363a9059cbb60e01b8484604051602401610d659291906113ae565b6000610e10826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610e909092919063ffffffff16565b9050805160001480610e31575080806020019051810190610e319190611418565b6104e05760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b606482015260840161039b565b6060610e9f8484600085610ea7565b949350505050565b606082471015610f085760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b606482015260840161039b565b600080866001600160a01b03168587604051610f24919061143a565b60006040518083038185875af1925050503d8060008114610f61576040519150601f19603f3d011682016040523d82523d6000602084013e610f66565b606091505b5091509150610f7787838387610f82565b979650505050505050565b60608315610ff1578251600003610fea576001600160a01b0385163b610fea5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161039b565b5081610e9f565b610e9f83838151156110065781518083602001fd5b8060405162461bcd60e51b815260040161039b9190611456565b6001600160a01b038116811461103557600080fd5b50565b6000806040838503121561104b57600080fd5b823561105681611020565b946020939093013593505050565b60006020828403121561107657600080fd5b813561108181611020565b9392505050565b6000806000806060858703121561109e57600080fd5b8435935060208501356110b081611020565b9250604085013567ffffffffffffffff808211156110cd57600080fd5b818701915087601f8301126110e157600080fd5b8135818111156110f057600080fd5b88602082850101111561110257600080fd5b95989497505060200194505050565b60008060006060848603121561112657600080fd5b833561113181611020565b9250602084013561114181611020565b929592945050506040919091013590565b6000806000806080858703121561116857600080fd5b843561117381611020565b9350602085013561118381611020565b9250604085013561119381611020565b915060608501356111a381611020565b939692955090935050565b600080858511156111be57600080fd5b838611156111cb57600080fd5b5050820193919092039150565b803560208310156111f157600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b83811015611228578181015183820152602001611210565b50506000910152565b60006020828403121561124357600080fd5b815167ffffffffffffffff8082111561125b57600080fd5b818401915084601f83011261126f57600080fd5b815181811115611281576112816111f7565b604051601f8201601f19908116603f011681019083821181831017156112a9576112a96111f7565b816040528281528760208487010111156112c257600080fd5b610f7783602083016020880161120d565b6000602082840312156112e557600080fd5b815160ff8116811461108157600080fd5b6000815180845261130e81602086016020860161120d565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a06040820181905260009061134c908301866112f6565b828103606084015261135e81866112f6565b91505060ff831660808301529695505050505050565b6001600160a01b0383168152604060208201819052600090610e9f908301846112f6565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b600080600080608085870312156113dd57600080fd5b84356113e881611020565b935060208501356113f881611020565b9250604085013561140881611020565b9396929550929360600135925050565b60006020828403121561142a57600080fd5b8151801515811461108157600080fd5b6000825161144c81846020870161120d565b9190910192915050565b60208152600061108160208301846112f656fea2646970667358221220d80b757cc67caa5c50e62e69140cecbb6c6dd71e9cc2847c11a56f2365701d0564736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var RootMintableERC20PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC20PredicateAccessList","sourceName":"contracts/blade/RootMintableERC20PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611bfb806100206000396000f3fe608060405234801561001057600080fd5b506004361061019a5760003560e01c8063b1768065116100e4578063e0563ab111610092578063e0563ab114610355578063e30c39781461035e578063eeb499451461036f578063f213159c14610382578063f2fde38b14610395578063f4a120f7146103a8578063f6451255146103bb578063f8c8765e146103e257600080fd5b8063b1768065146102a8578063b68ad1e4146102cf578063c1225a20146102e2578063c5e4683a146102f5578063d41f177114610308578063d57184e41461032f578063d8dd17731461034257600080fd5b806355b01e4d1161014c57806355b01e4d146102255780635ea5df7914610233578063715018a61461024a57806379ba5097146102525780637efab4f51461025a5780638da5cb5b14610284578063947287cf1461029557806397e5230d1461029e57600080fd5b806305dc2e8f1461019f57806307b3e252146101cf5780631bc114ba146101dd578063284017f5146101f05780633b878c22146101f957806347e7ef241461020257806351351d5314610217575b600080fd5b60fd546101b2906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101b26004600360981b0181565b60fc546101b2906001600160a01b031681565b6101b261202081565b6101b261101081565b61021561021036600461164d565b6103f5565b005b6101b26002600160a01b0381565b6101b26004600160991b0181565b61023c61138881565b6040519081526020016101c6565b610215610404565b610215610418565b6101b2610268366004611679565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101b2565b61023c61520881565b61023c620249f081565b61023c7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101b2906001600160a01b031681565b6102156102f03660046116ab565b610497565b6102156103033660046116ab565b6104e6565b61023c7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60fe546101b2906001600160a01b031681565b6102156103503660046116c8565b61052d565b6101b261203081565b6065546001600160a01b03166101b2565b61021561037d36600461175e565b61064e565b6102156103903660046117e7565b6107f1565b6102156103a3366004611679565b610801565b6101b26103b6366004611679565b610872565b61023c7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102156103f0366004611828565b610c40565b610400823383610d39565b5050565b61040c610eb2565b6104166000610f0c565b565b60655433906001600160a01b0316811461048b5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61049481610f0c565b50565b61049f610eb2565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6104ee610eb2565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105545760405163973d02cb60e01b815260040161048290611884565b600054610100900460ff16158080156105745750600054600160ff909116105b8061058e5750303b15801561058e575060005460ff166001145b6105aa5760405162461bcd60e51b8152600401610482906118a8565b6000805460ff1916600117905580156105cd576000805461ff0019166101001790555b6105d988888888610f25565b60c9805461ffff191685151561ff00191617610100851515021790556105fe82610f0c565b8015610644576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146106c05760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526e2fa9aa20aa22afa922a1a2a4ab22a960891b6064820152608401610482565b60fe546001600160a01b038481169116146107365760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526f5f4348494c445f50524544494341544560801b6064820152608401610482565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696107656020600084866118f6565b61076e91611920565b0361078d5761078861078382602081866118f6565b611020565b6107eb565b60405162461bcd60e51b815260206004820152602d60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e564160448201526c4c49445f5349474e415455524560981b6064820152608401610482565b50505050565b6107fc838383610d39565b505050565b610809610eb2565b606580546001600160a01b0383166001600160a01b0319909116811790915561083a6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b0382166108dc5760405162461bcd60e51b815260206004820152602960248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e56416044820152682624a22faa27a5a2a760b91b6064820152608401610482565b6001600160a01b038281166000908152610100602052604090205416156109585760405162461bcd60e51b815260206004820152602a60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20414c524560448201526910511657d3505414115160b21b6064820152608401610482565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692600092610a0692911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b038581166000818152610100602052604080822080546001600160a01b03191686861617905560fc5481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610a9f573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ac79190810190611979565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610b05573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610b2d9190810190611979565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b6b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8f9190611a1b565b604051602001610ba3959493929190611a6a565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610bcf929190611abc565b600060405180830381600087803b158015610be957600080fd5b505af1158015610bfd573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b0314610c675760405163973d02cb60e01b815260040161048290611884565b600054610100900460ff1615808015610c875750600054600160ff909116105b80610ca15750303b158015610ca1575060005460ff166001145b610cbd5760405162461bcd60e51b8152600401610482906118a8565b6000805460ff191660011790558015610ce0576000805461ff0019166101001790555b610cec85858585610f25565b8015610d32576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b610d416110d9565b6001600160a01b03808416600090815261010060205260409020541680610d6e57610d6b84610872565b90505b6001600160a01b038116610d8457610d84611ae0565b610d996001600160a01b0385163330856110e1565b60fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610e249391169160c401611abc565b600060405180830381600087803b158015610e3e57600080fd5b505af1158015610e52573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f1666a3f7b8a7494f2ebcebe646a5187ae55b1db3a068097377d90cd64a258ce93386604051610ea5929190611af6565b60405180910390a46107eb565b6033546001600160a01b031633146104165760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610482565b606580546001600160a01b03191690556104948161114c565b6001600160a01b03841615801590610f4557506001600160a01b03831615155b8015610f5957506001600160a01b03821615155b8015610f6d57506001600160a01b03811615155b610fd05760405162461bcd60e51b815260206004820152602e60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204241445f60448201526d24a724aa24a0a624ad20aa24a7a760911b6064820152608401610482565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b600080808061103185870187611b0f565b6001600160a01b03808516600090815261010060205260409020549498509296509094509250168061106557611065611ae0565b6110796001600160a01b038616848461119e565b826001600160a01b0316816001600160a01b0316866001600160a01b03167fb9f935478aae5b1da868de596dafe0a2b41eeb61311fdd60c6dbbe46a1debee887866040516110c8929190611af6565b60405180910390a450505050505050565b6104166111bd565b6040516001600160a01b03808516602483015283166044820152606481018290526107eb9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b0319909316929092179091526113d3565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6107fc8363a9059cbb60e01b8484604051602401611115929190611af6565b60c95460ff16156112c857604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161121f9190611b60565b6000604051808303818686fa925050503d806000811461125b576040519150601f19603f3d011682016040523d82523d6000602084013e611260565b606091505b509150915081801561128557506000818060200190518101906112839190611b7c565b115b6112c55760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b6044820152606401610482565b50505b60c954610100900460ff161561041657604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161132f9190611b60565b6000604051808303818686fa925050503d806000811461136b576040519150601f19603f3d011682016040523d82523d6000602084013e611370565b606091505b50915091508180156113965750808060200190518101906113919190611b7c565b600114155b6104005760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b6044820152606401610482565b6000611428826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166114a89092919063ffffffff16565b90508051600014806114495750808060200190518101906114499190611b95565b6107fc5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610482565b60606114b784846000856114bf565b949350505050565b6060824710156115205760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610482565b600080866001600160a01b0316858760405161153c9190611b60565b60006040518083038185875af1925050503d8060008114611579576040519150601f19603f3d011682016040523d82523d6000602084013e61157e565b606091505b509150915061158f8783838761159a565b979650505050505050565b60608315611609578251600003611602576001600160a01b0385163b6116025760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610482565b50816114b7565b6114b7838381511561161e5781518083602001fd5b8060405162461bcd60e51b81526004016104829190611bb2565b6001600160a01b038116811461049457600080fd5b6000806040838503121561166057600080fd5b823561166b81611638565b946020939093013593505050565b60006020828403121561168b57600080fd5b813561169681611638565b9392505050565b801515811461049457600080fd5b6000602082840312156116bd57600080fd5b81356116968161169d565b600080600080600080600060e0888a0312156116e357600080fd5b87356116ee81611638565b965060208801356116fe81611638565b9550604088013561170e81611638565b9450606088013561171e81611638565b9350608088013561172e8161169d565b925060a088013561173e8161169d565b915060c088013561174e81611638565b8091505092959891949750929550565b6000806000806060858703121561177457600080fd5b84359350602085013561178681611638565b9250604085013567ffffffffffffffff808211156117a357600080fd5b818701915087601f8301126117b757600080fd5b8135818111156117c657600080fd5b8860208285010111156117d857600080fd5b95989497505060200194505050565b6000806000606084860312156117fc57600080fd5b833561180781611638565b9250602084013561181781611638565b929592945050506040919091013590565b6000806000806080858703121561183e57600080fd5b843561184981611638565b9350602085013561185981611638565b9250604085013561186981611638565b9150606085013561187981611638565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b6000808585111561190657600080fd5b8386111561191357600080fd5b5050820193919092039150565b8035602083101561193957600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b83811015611970578181015183820152602001611958565b50506000910152565b60006020828403121561198b57600080fd5b815167ffffffffffffffff808211156119a357600080fd5b818401915084601f8301126119b757600080fd5b8151818111156119c9576119c961193f565b604051601f8201601f19908116603f011681019083821181831017156119f1576119f161193f565b81604052828152876020848701011115611a0a57600080fd5b61158f836020830160208801611955565b600060208284031215611a2d57600080fd5b815160ff8116811461169657600080fd5b60008151808452611a56816020860160208601611955565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a060408201819052600090611a9490830186611a3e565b8281036060840152611aa68186611a3e565b91505060ff831660808301529695505050505050565b6001600160a01b03831681526040602082018190526000906114b790830184611a3e565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611b2557600080fd5b8435611b3081611638565b93506020850135611b4081611638565b92506040850135611b5081611638565b9396929550929360600135925050565b60008251611b72818460208701611955565b9190910192915050565b600060208284031215611b8e57600080fd5b5051919050565b600060208284031215611ba757600080fd5b81516116968161169d565b6020815260006116966020830184611a3e56fea2646970667358221220ae01c5b3680c729d0c4e84a602e5e804c4507f2164d89b8ff5416b6c4e07ffef64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061019a5760003560e01c8063b1768065116100e4578063e0563ab111610092578063e0563ab114610355578063e30c39781461035e578063eeb499451461036f578063f213159c14610382578063f2fde38b14610395578063f4a120f7146103a8578063f6451255146103bb578063f8c8765e146103e257600080fd5b8063b1768065146102a8578063b68ad1e4146102cf578063c1225a20146102e2578063c5e4683a146102f5578063d41f177114610308578063d57184e41461032f578063d8dd17731461034257600080fd5b806355b01e4d1161014c57806355b01e4d146102255780635ea5df7914610233578063715018a61461024a57806379ba5097146102525780637efab4f51461025a5780638da5cb5b14610284578063947287cf1461029557806397e5230d1461029e57600080fd5b806305dc2e8f1461019f57806307b3e252146101cf5780631bc114ba146101dd578063284017f5146101f05780633b878c22146101f957806347e7ef241461020257806351351d5314610217575b600080fd5b60fd546101b2906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101b26004600360981b0181565b60fc546101b2906001600160a01b031681565b6101b261202081565b6101b261101081565b61021561021036600461164d565b6103f5565b005b6101b26002600160a01b0381565b6101b26004600160991b0181565b61023c61138881565b6040519081526020016101c6565b610215610404565b610215610418565b6101b2610268366004611679565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101b2565b61023c61520881565b61023c620249f081565b61023c7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101b2906001600160a01b031681565b6102156102f03660046116ab565b610497565b6102156103033660046116ab565b6104e6565b61023c7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60fe546101b2906001600160a01b031681565b6102156103503660046116c8565b61052d565b6101b261203081565b6065546001600160a01b03166101b2565b61021561037d36600461175e565b61064e565b6102156103903660046117e7565b6107f1565b6102156103a3366004611679565b610801565b6101b26103b6366004611679565b610872565b61023c7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102156103f0366004611828565b610c40565b610400823383610d39565b5050565b61040c610eb2565b6104166000610f0c565b565b60655433906001600160a01b0316811461048b5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61049481610f0c565b50565b61049f610eb2565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6104ee610eb2565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105545760405163973d02cb60e01b815260040161048290611884565b600054610100900460ff16158080156105745750600054600160ff909116105b8061058e5750303b15801561058e575060005460ff166001145b6105aa5760405162461bcd60e51b8152600401610482906118a8565b6000805460ff1916600117905580156105cd576000805461ff0019166101001790555b6105d988888888610f25565b60c9805461ffff191685151561ff00191617610100851515021790556105fe82610f0c565b8015610644576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146106c05760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526e2fa9aa20aa22afa922a1a2a4ab22a960891b6064820152608401610482565b60fe546001600160a01b038481169116146107365760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c6545524332305072656469636174653a204f4e4c5960448201526f5f4348494c445f50524544494341544560801b6064820152608401610482565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696107656020600084866118f6565b61076e91611920565b0361078d5761078861078382602081866118f6565b611020565b6107eb565b60405162461bcd60e51b815260206004820152602d60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e564160448201526c4c49445f5349474e415455524560981b6064820152608401610482565b50505050565b6107fc838383610d39565b505050565b610809610eb2565b606580546001600160a01b0383166001600160a01b0319909116811790915561083a6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b0382166108dc5760405162461bcd60e51b815260206004820152602960248201527f526f6f744d696e7461626c6545524332305072656469636174653a20494e56416044820152682624a22faa27a5a2a760b91b6064820152608401610482565b6001600160a01b038281166000908152610100602052604090205416156109585760405162461bcd60e51b815260206004820152602a60248201527f526f6f744d696e7461626c6545524332305072656469636174653a20414c524560448201526910511657d3505414115160b21b6064820152608401610482565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692600092610a0692911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b038581166000818152610100602052604080822080546001600160a01b03191686861617905560fc5481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610a9f573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ac79190810190611979565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610b05573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610b2d9190810190611979565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b6b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8f9190611a1b565b604051602001610ba3959493929190611a6a565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610bcf929190611abc565b600060405180830381600087803b158015610be957600080fd5b505af1158015610bfd573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b0314610c675760405163973d02cb60e01b815260040161048290611884565b600054610100900460ff1615808015610c875750600054600160ff909116105b80610ca15750303b158015610ca1575060005460ff166001145b610cbd5760405162461bcd60e51b8152600401610482906118a8565b6000805460ff191660011790558015610ce0576000805461ff0019166101001790555b610cec85858585610f25565b8015610d32576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b610d416110d9565b6001600160a01b03808416600090815261010060205260409020541680610d6e57610d6b84610872565b90505b6001600160a01b038116610d8457610d84611ae0565b610d996001600160a01b0385163330856110e1565b60fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610e249391169160c401611abc565b600060405180830381600087803b158015610e3e57600080fd5b505af1158015610e52573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f1666a3f7b8a7494f2ebcebe646a5187ae55b1db3a068097377d90cd64a258ce93386604051610ea5929190611af6565b60405180910390a46107eb565b6033546001600160a01b031633146104165760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610482565b606580546001600160a01b03191690556104948161114c565b6001600160a01b03841615801590610f4557506001600160a01b03831615155b8015610f5957506001600160a01b03821615155b8015610f6d57506001600160a01b03811615155b610fd05760405162461bcd60e51b815260206004820152602e60248201527f526f6f744d696e7461626c6545524332305072656469636174653a204241445f60448201526d24a724aa24a0a624ad20aa24a7a760911b6064820152608401610482565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b600080808061103185870187611b0f565b6001600160a01b03808516600090815261010060205260409020549498509296509094509250168061106557611065611ae0565b6110796001600160a01b038616848461119e565b826001600160a01b0316816001600160a01b0316866001600160a01b03167fb9f935478aae5b1da868de596dafe0a2b41eeb61311fdd60c6dbbe46a1debee887866040516110c8929190611af6565b60405180910390a450505050505050565b6104166111bd565b6040516001600160a01b03808516602483015283166044820152606481018290526107eb9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b0319909316929092179091526113d3565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6107fc8363a9059cbb60e01b8484604051602401611115929190611af6565b60c95460ff16156112c857604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161121f9190611b60565b6000604051808303818686fa925050503d806000811461125b576040519150601f19603f3d011682016040523d82523d6000602084013e611260565b606091505b509150915081801561128557506000818060200190518101906112839190611b7c565b115b6112c55760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b6044820152606401610482565b50505b60c954610100900460ff161561041657604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161132f9190611b60565b6000604051808303818686fa925050503d806000811461136b576040519150601f19603f3d011682016040523d82523d6000602084013e611370565b606091505b50915091508180156113965750808060200190518101906113919190611b7c565b600114155b6104005760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b6044820152606401610482565b6000611428826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166114a89092919063ffffffff16565b90508051600014806114495750808060200190518101906114499190611b95565b6107fc5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610482565b60606114b784846000856114bf565b949350505050565b6060824710156115205760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610482565b600080866001600160a01b0316858760405161153c9190611b60565b60006040518083038185875af1925050503d8060008114611579576040519150601f19603f3d011682016040523d82523d6000602084013e61157e565b606091505b509150915061158f8783838761159a565b979650505050505050565b60608315611609578251600003611602576001600160a01b0385163b6116025760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610482565b50816114b7565b6114b7838381511561161e5781518083602001fd5b8060405162461bcd60e51b81526004016104829190611bb2565b6001600160a01b038116811461049457600080fd5b6000806040838503121561166057600080fd5b823561166b81611638565b946020939093013593505050565b60006020828403121561168b57600080fd5b813561169681611638565b9392505050565b801515811461049457600080fd5b6000602082840312156116bd57600080fd5b81356116968161169d565b600080600080600080600060e0888a0312156116e357600080fd5b87356116ee81611638565b965060208801356116fe81611638565b9550604088013561170e81611638565b9450606088013561171e81611638565b9350608088013561172e8161169d565b925060a088013561173e8161169d565b915060c088013561174e81611638565b8091505092959891949750929550565b6000806000806060858703121561177457600080fd5b84359350602085013561178681611638565b9250604085013567ffffffffffffffff808211156117a357600080fd5b818701915087601f8301126117b757600080fd5b8135818111156117c657600080fd5b8860208285010111156117d857600080fd5b95989497505060200194505050565b6000806000606084860312156117fc57600080fd5b833561180781611638565b9250602084013561181781611638565b929592945050506040919091013590565b6000806000806080858703121561183e57600080fd5b843561184981611638565b9350602085013561185981611638565b9250604085013561186981611638565b9150606085013561187981611638565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b6000808585111561190657600080fd5b8386111561191357600080fd5b5050820193919092039150565b8035602083101561193957600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b83811015611970578181015183820152602001611958565b50506000910152565b60006020828403121561198b57600080fd5b815167ffffffffffffffff808211156119a357600080fd5b818401915084601f8301126119b757600080fd5b8151818111156119c9576119c961193f565b604051601f8201601f19908116603f011681019083821181831017156119f1576119f161193f565b81604052828152876020848701011115611a0a57600080fd5b61158f836020830160208801611955565b600060208284031215611a2d57600080fd5b815160ff8116811461169657600080fd5b60008151808452611a56816020860160208601611955565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a060408201819052600090611a9490830186611a3e565b8281036060840152611aa68186611a3e565b91505060ff831660808301529695505050505050565b6001600160a01b03831681526040602082018190526000906114b790830184611a3e565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611b2557600080fd5b8435611b3081611638565b93506020850135611b4081611638565b92506040850135611b5081611638565b9396929550929360600135925050565b60008251611b72818460208701611955565b9190910192915050565b600060208284031215611b8e57600080fd5b5051919050565b600060208284031215611ba757600080fd5b81516116968161169d565b6020815260006116966020830184611a3e56fea2646970667358221220ae01c5b3680c729d0c4e84a602e5e804c4507f2164d89b8ff5416b6c4e07ffef64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildERC721Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC721","sourceName":"contracts/blade/ChildERC721.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"userAddress","type":"address"},{"indexed":false,"internalType":"address","name":"relayerAddress","type":"address"},{"indexed":false,"internalType":"bytes","name":"functionSignature","type":"bytes"}],"name":"MetaTransactionExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"burnBatch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"userAddress","type":"address"},{"internalType":"bytes","name":"functionSignature","type":"bytes"},{"internalType":"bytes32","name":"sigR","type":"bytes32"},{"internalType":"bytes32","name":"sigS","type":"bytes32"},{"internalType":"uint8","name":"sigV","type":"uint8"}],"name":"executeMetaTransaction","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getNonce","outputs":[{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"rootToken_","type":"address"},{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"offset","type":"uint256"}],"name":"invalidateNext","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"mintBatch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rootToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612488806100206000396000f3fe608060405234801561001057600080fd5b506004361061014d5760003560e01c806370a08231116100c3578063a22cb4651161007c578063a22cb465146102de578063b2dc5dc3146102f1578063b88d4fde14610304578063c87b56dd14610317578063e61987051461032a578063e985e9c51461033c57600080fd5b806370a08231146102775780637c88e3d91461028a578063906571471461029d57806395d89b41146102b05780639b77ef11146102b85780639dc29fac146102cb57600080fd5b80631f2d0065116101155780631f2d0065146101e257806323b872dd146101f45780632d0335ab1461020757806340c10f191461023e57806342842e0e146102515780636352211e1461026457600080fd5b806301ffc9a71461015257806306fdde031461017a578063081812fc1461018f578063095ea7b3146101ba5780630c53c51c146101cf575b600080fd5b610165610160366004611a73565b61034f565b60405190151581526020015b60405180910390f35b6101826103a1565b6040516101719190611ae0565b6101a261019d366004611af3565b610433565b6040516001600160a01b039091168152602001610171565b6101cd6101c8366004611b28565b61045a565b005b6101826101dd366004611b9a565b610586565b610103546001600160a01b03166101a2565b6101cd610202366004611c19565b610864565b610230610215366004611c55565b6001600160a01b031660009081526038602052604090205490565b604051908152602001610171565b61016561024c366004611b28565b61089c565b6101cd61025f366004611c19565b6108dd565b6101a2610272366004611af3565b6108f8565b610230610285366004611c55565b61092d565b610165610298366004611cb4565b6109b3565b6101cd6102ab366004611d1f565b610a9b565b610182610d0b565b6101cd6102c6366004611af3565b610d1a565b6101656102d9366004611b28565b610d41565b6101cd6102ec366004611d9f565b610db1565b6101656102ff366004611ddb565b610dc7565b6101cd610312366004611e43565b610e75565b610182610325366004611af3565b610eb4565b610102546001600160a01b03166101a2565b61016561034a366004611f1e565b610f28565b60006001600160e01b031982166380ac58cd60e01b148061038057506001600160e01b03198216635b5e139f60e01b145b8061039b57506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060d080546103b090611f51565b80601f01602080910402602001604051908101604052809291908181526020018280546103dc90611f51565b80156104295780601f106103fe57610100808354040283529160200191610429565b820191906000526020600020905b81548152906001019060200180831161040c57829003601f168201915b5050505050905090565b600061043e82610f56565b50600090815260d460205260409020546001600160a01b031690565b6000610465826108f8565b9050806001600160a01b0316836001600160a01b0316036104d75760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b806001600160a01b03166104e9610f7e565b6001600160a01b0316148061050557506105058161034a610f7e565b6105775760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c00000060648201526084016104ce565b6105818383610f8d565b505050565b606060006105c987878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610ffb92505050565b90506001600160e01b031960003581169082160361064f5760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f6400000060648201526084016104ce565b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506106c08982888888611016565b6107165760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b60648201526084016104ce565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d60405160200161076b93929190611f8b565b60408051601f198184030181529082905261078591611fb1565b6000604051808303816000865af19150503d80600081146107c2576040519150601f19603f3d011682016040523d82523d6000602084013e6107c7565b606091505b5091509150816108195760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c0000000060448201526064016104ce565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c60405161084e9493929190611fcd565b60405180910390a19a9950505050505050505050565b61087561086f610f7e565b826110f2565b6108915760405162461bcd60e51b81526004016104ce90612019565b610581838383611150565b610102546000906001600160a01b031633146108ca5760405162461bcd60e51b81526004016104ce90612066565b6108d483836112a2565b50600192915050565b61058183838360405180602001604052806000815250610e75565b600081815260d260205260408120546001600160a01b03168061039b5760405162461bcd60e51b81526004016104ce906120aa565b60006001600160a01b0382166109975760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016104ce565b506001600160a01b0316600090815260d3602052604090205490565b610102546000906001600160a01b031633146109e15760405162461bcd60e51b81526004016104ce90612066565b83828114610a315760405162461bcd60e51b815260206004820152601f60248201527f4368696c644552433732313a204172726179206c656e206d69736d617463680060448201526064016104ce565b60005b81811015610a8c57610a84878783818110610a5157610a516120dc565b9050602002016020810190610a669190611c55565b868684818110610a7857610a786120dc565b905060200201356112a2565b600101610a34565b5060019150505b949350505050565b606b54610100900460ff1615808015610abb5750606b54600160ff909116105b80610ad55750303b158015610ad55750606b5460ff166001145b610b385760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104ce565b606b805460ff191660011790558015610b5b57606b805461ff0019166101001790555b6001600160a01b03861615801590610b7257508315155b8015610b7d57508115155b610bc95760405162461bcd60e51b815260206004820152601f60248201527f4368696c644552433732313a2042616420696e697469616c697a6174696f6e0060448201526064016104ce565b61010380546001600160a01b0388166001600160a01b031991821617909155610102805490911633179055604080516020601f8701819004810282018101909252858152610c6591879087908190840183828082843760009201919091525050604080516020601f890181900481028201810190925287815292508791508690819084018382808284376000920191909152506112bc92505050565b610cbd85858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805180820190915260018152603160f81b602082015291506112ed9050565b8015610d0357606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b606060d180546103b090611f51565b3360009081526038602052604081208054839290610d399084906120f2565b909155505050565b610102546000906001600160a01b03163314610d6f5760405162461bcd60e51b81526004016104ce90612066565b610d78826108f8565b6001600160a01b0316836001600160a01b031614610da85760405162461bcd60e51b81526004016104ce90612113565b6108d482611359565b610dc3610dbc610f7e565b83836113dc565b5050565b610102546000906001600160a01b03163314610df55760405162461bcd60e51b81526004016104ce90612066565b8160005b81811015610e69576000858583818110610e1557610e156120dc565b905060200201359050610e27816108f8565b6001600160a01b0316876001600160a01b031614610e575760405162461bcd60e51b81526004016104ce90612113565b610e6081611359565b50600101610df9565b50600195945050505050565b610e86610e80610f7e565b836110f2565b610ea25760405162461bcd60e51b81526004016104ce90612019565b610eae848484846114a6565b50505050565b6060610ebf82610f56565b6000610ed660408051602081019091526000815290565b90506000815111610ef65760405180602001604052806000815250610f21565b80610f00846114d9565b604051602001610f11929190612148565b6040516020818303038152906040525b9392505050565b6001600160a01b03918216600090815260d56020908152604080832093909416825291909152205460ff1690565b610f5f8161156b565b610f7b5760405162461bcd60e51b81526004016104ce906120aa565b50565b6000610f88611588565b905090565b600081815260d46020526040902080546001600160a01b0319166001600160a01b0384169081179091558190610fc2826108f8565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000815160000361100e57506000919050565b506020015190565b600080600161102c611027886115e4565b611661565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa15801561107a573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166110d15760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b60448201526064016104ce565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6000806110fe836108f8565b9050806001600160a01b0316846001600160a01b0316148061112557506111258185610f28565b80610a935750836001600160a01b031661113e84610433565b6001600160a01b031614949350505050565b826001600160a01b0316611163826108f8565b6001600160a01b0316146111895760405162461bcd60e51b81526004016104ce90612177565b6001600160a01b0382166111eb5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016104ce565b826001600160a01b03166111fe826108f8565b6001600160a01b0316146112245760405162461bcd60e51b81526004016104ce90612177565b600081815260d46020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260d3855283862080546000190190559087168086528386208054600101905586865260d2909452828520805490921684179091559051849360008051602061243383398151915291a4505050565b610dc382826040518060200160405280600081525061168e565b606b54610100900460ff166112e35760405162461bcd60e51b81526004016104ce906121bc565b610dc382826116c1565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f61133b818484611701565b600055600280546001600160a01b0319163017905560055550505050565b6000611364826108f8565b905061136f826108f8565b600083815260d46020908152604080832080546001600160a01b03199081169091556001600160a01b03851680855260d38452828520805460001901905587855260d290935281842080549091169055519293508492600080516020612433833981519152908390a45050565b816001600160a01b0316836001600160a01b0316036114395760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b60448201526064016104ce565b6001600160a01b03838116600081815260d56020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6114b1848484611150565b6114bd8484848461174a565b610eae5760405162461bcd60e51b81526004016104ce90612207565b606060006114e68361184f565b60010190506000816001600160401b0381111561150557611505611e2d565b6040519080825280601f01601f19166020018201604052801561152f576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a850494508461153957509392505050565b600090815260d260205260409020546001600160a01b0316151590565b60003033036115de57600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506115e19050565b50335b90565b60006040518060800160405280604381526020016123f06043913980516020918201208351848301516040808701518051908601209051611644950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039b61166e611927565b8360405161190160f01b8152600281019290925260228201526042902090565b6116988383611962565b6116a5600084848461174a565b6105815760405162461bcd60e51b81526004016104ce90612207565b606b54610100900460ff166116e85760405162461bcd60e51b81526004016104ce906121bc565b60d06116f4838261229f565b5060d1610581828261229f565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b60006001600160a01b0384163b1561184757836001600160a01b031663150b7a02611773610f7e565b8786866040518563ffffffff1660e01b8152600401611795949392919061235e565b6020604051808303816000875af19250505080156117d0575060408051601f3d908101601f191682019092526117cd9181019061239b565b60015b61182d573d8080156117fe576040519150601f19603f3d011682016040523d82523d6000602084013e611803565b606091505b5080516000036118255760405162461bcd60e51b81526004016104ce90612207565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610a93565b506001610a93565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b831061188e5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef810000000083106118ba576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106118d857662386f26fc10000830492506010015b6305f5e10083106118f0576305f5e100830492506008015b612710831061190457612710830492506004015b60648310611916576064830492506002015b600a831061039b5760010192915050565b6002546000906001600160a01b031630148015611945575060015446145b15611951575060005490565b610f88600554600354600454611701565b6001600160a01b0382166119b85760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016104ce565b6119c18161156b565b156119de5760405162461bcd60e51b81526004016104ce906123b8565b6119e78161156b565b15611a045760405162461bcd60e51b81526004016104ce906123b8565b6001600160a01b038216600081815260d3602090815260408083208054600101905584835260d290915280822080546001600160a01b031916841790555183929190600080516020612433833981519152908290a45050565b6001600160e01b031981168114610f7b57600080fd5b600060208284031215611a8557600080fd5b8135610f2181611a5d565b60005b83811015611aab578181015183820152602001611a93565b50506000910152565b60008151808452611acc816020860160208601611a90565b601f01601f19169290920160200192915050565b602081526000610f216020830184611ab4565b600060208284031215611b0557600080fd5b5035919050565b80356001600160a01b0381168114611b2357600080fd5b919050565b60008060408385031215611b3b57600080fd5b611b4483611b0c565b946020939093013593505050565b60008083601f840112611b6457600080fd5b5081356001600160401b03811115611b7b57600080fd5b602083019150836020828501011115611b9357600080fd5b9250929050565b60008060008060008060a08789031215611bb357600080fd5b611bbc87611b0c565b955060208701356001600160401b03811115611bd757600080fd5b611be389828a01611b52565b9096509450506040870135925060608701359150608087013560ff81168114611c0b57600080fd5b809150509295509295509295565b600080600060608486031215611c2e57600080fd5b611c3784611b0c565b9250611c4560208501611b0c565b9150604084013590509250925092565b600060208284031215611c6757600080fd5b610f2182611b0c565b60008083601f840112611c8257600080fd5b5081356001600160401b03811115611c9957600080fd5b6020830191508360208260051b8501011115611b9357600080fd5b60008060008060408587031215611cca57600080fd5b84356001600160401b0380821115611ce157600080fd5b611ced88838901611c70565b90965094506020870135915080821115611d0657600080fd5b50611d1387828801611c70565b95989497509550505050565b600080600080600060608688031215611d3757600080fd5b611d4086611b0c565b945060208601356001600160401b0380821115611d5c57600080fd5b611d6889838a01611b52565b90965094506040880135915080821115611d8157600080fd5b50611d8e88828901611b52565b969995985093965092949392505050565b60008060408385031215611db257600080fd5b611dbb83611b0c565b915060208301358015158114611dd057600080fd5b809150509250929050565b600080600060408486031215611df057600080fd5b611df984611b0c565b925060208401356001600160401b03811115611e1457600080fd5b611e2086828701611c70565b9497909650939450505050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215611e5957600080fd5b611e6285611b0c565b9350611e7060208601611b0c565b92506040850135915060608501356001600160401b0380821115611e9357600080fd5b818701915087601f830112611ea757600080fd5b813581811115611eb957611eb9611e2d565b604051601f8201601f19908116603f01168101908382118183101715611ee157611ee1611e2d565b816040528281528a6020848701011115611efa57600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215611f3157600080fd5b611f3a83611b0c565b9150611f4860208401611b0c565b90509250929050565b600181811c90821680611f6557607f821691505b602082108103611f8557634e487b7160e01b600052602260045260246000fd5b50919050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60008251611fc3818460208701611a90565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b60208082526024908201527f4368696c644552433732313a204f6e6c79207072656469636174652063616e2060408201526318d85b1b60e21b606082015260800190565b602080825260189082015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b8082018082111561039b57634e487b7160e01b600052601160045260246000fd5b6020808252818101527f4368696c644552433732313a204f6e6c79206f776e65722063616e206275726e604082015260600190565b6000835161215a818460208801611a90565b83519083019061216e818360208801611a90565b01949350505050565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b601f82111561058157600081815260208120601f850160051c810160208610156122805750805b601f850160051c820191505b81811015610d035782815560010161228c565b81516001600160401b038111156122b8576122b8611e2d565b6122cc816122c68454611f51565b84612259565b602080601f83116001811461230157600084156122e95750858301515b600019600386901b1c1916600185901b178555610d03565b600085815260208120601f198616915b8281101561233057888601518255948401946001909101908401612311565b508582101561234e5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061239190830184611ab4565b9695505050505050565b6000602082840312156123ad57600080fd5b8151610f2181611a5d565b6020808252601c908201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060408201526060019056fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220667d3c30bcd6799bcd5d1501bea0d3a68235675f8ae26bea6b04951c37765f7164736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061014d5760003560e01c806370a08231116100c3578063a22cb4651161007c578063a22cb465146102de578063b2dc5dc3146102f1578063b88d4fde14610304578063c87b56dd14610317578063e61987051461032a578063e985e9c51461033c57600080fd5b806370a08231146102775780637c88e3d91461028a578063906571471461029d57806395d89b41146102b05780639b77ef11146102b85780639dc29fac146102cb57600080fd5b80631f2d0065116101155780631f2d0065146101e257806323b872dd146101f45780632d0335ab1461020757806340c10f191461023e57806342842e0e146102515780636352211e1461026457600080fd5b806301ffc9a71461015257806306fdde031461017a578063081812fc1461018f578063095ea7b3146101ba5780630c53c51c146101cf575b600080fd5b610165610160366004611a73565b61034f565b60405190151581526020015b60405180910390f35b6101826103a1565b6040516101719190611ae0565b6101a261019d366004611af3565b610433565b6040516001600160a01b039091168152602001610171565b6101cd6101c8366004611b28565b61045a565b005b6101826101dd366004611b9a565b610586565b610103546001600160a01b03166101a2565b6101cd610202366004611c19565b610864565b610230610215366004611c55565b6001600160a01b031660009081526038602052604090205490565b604051908152602001610171565b61016561024c366004611b28565b61089c565b6101cd61025f366004611c19565b6108dd565b6101a2610272366004611af3565b6108f8565b610230610285366004611c55565b61092d565b610165610298366004611cb4565b6109b3565b6101cd6102ab366004611d1f565b610a9b565b610182610d0b565b6101cd6102c6366004611af3565b610d1a565b6101656102d9366004611b28565b610d41565b6101cd6102ec366004611d9f565b610db1565b6101656102ff366004611ddb565b610dc7565b6101cd610312366004611e43565b610e75565b610182610325366004611af3565b610eb4565b610102546001600160a01b03166101a2565b61016561034a366004611f1e565b610f28565b60006001600160e01b031982166380ac58cd60e01b148061038057506001600160e01b03198216635b5e139f60e01b145b8061039b57506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060d080546103b090611f51565b80601f01602080910402602001604051908101604052809291908181526020018280546103dc90611f51565b80156104295780601f106103fe57610100808354040283529160200191610429565b820191906000526020600020905b81548152906001019060200180831161040c57829003601f168201915b5050505050905090565b600061043e82610f56565b50600090815260d460205260409020546001600160a01b031690565b6000610465826108f8565b9050806001600160a01b0316836001600160a01b0316036104d75760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b806001600160a01b03166104e9610f7e565b6001600160a01b0316148061050557506105058161034a610f7e565b6105775760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c00000060648201526084016104ce565b6105818383610f8d565b505050565b606060006105c987878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610ffb92505050565b90506001600160e01b031960003581169082160361064f5760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f6400000060648201526084016104ce565b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506106c08982888888611016565b6107165760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b60648201526084016104ce565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d60405160200161076b93929190611f8b565b60408051601f198184030181529082905261078591611fb1565b6000604051808303816000865af19150503d80600081146107c2576040519150601f19603f3d011682016040523d82523d6000602084013e6107c7565b606091505b5091509150816108195760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c0000000060448201526064016104ce565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c60405161084e9493929190611fcd565b60405180910390a19a9950505050505050505050565b61087561086f610f7e565b826110f2565b6108915760405162461bcd60e51b81526004016104ce90612019565b610581838383611150565b610102546000906001600160a01b031633146108ca5760405162461bcd60e51b81526004016104ce90612066565b6108d483836112a2565b50600192915050565b61058183838360405180602001604052806000815250610e75565b600081815260d260205260408120546001600160a01b03168061039b5760405162461bcd60e51b81526004016104ce906120aa565b60006001600160a01b0382166109975760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016104ce565b506001600160a01b0316600090815260d3602052604090205490565b610102546000906001600160a01b031633146109e15760405162461bcd60e51b81526004016104ce90612066565b83828114610a315760405162461bcd60e51b815260206004820152601f60248201527f4368696c644552433732313a204172726179206c656e206d69736d617463680060448201526064016104ce565b60005b81811015610a8c57610a84878783818110610a5157610a516120dc565b9050602002016020810190610a669190611c55565b868684818110610a7857610a786120dc565b905060200201356112a2565b600101610a34565b5060019150505b949350505050565b606b54610100900460ff1615808015610abb5750606b54600160ff909116105b80610ad55750303b158015610ad55750606b5460ff166001145b610b385760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104ce565b606b805460ff191660011790558015610b5b57606b805461ff0019166101001790555b6001600160a01b03861615801590610b7257508315155b8015610b7d57508115155b610bc95760405162461bcd60e51b815260206004820152601f60248201527f4368696c644552433732313a2042616420696e697469616c697a6174696f6e0060448201526064016104ce565b61010380546001600160a01b0388166001600160a01b031991821617909155610102805490911633179055604080516020601f8701819004810282018101909252858152610c6591879087908190840183828082843760009201919091525050604080516020601f890181900481028201810190925287815292508791508690819084018382808284376000920191909152506112bc92505050565b610cbd85858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805180820190915260018152603160f81b602082015291506112ed9050565b8015610d0357606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b606060d180546103b090611f51565b3360009081526038602052604081208054839290610d399084906120f2565b909155505050565b610102546000906001600160a01b03163314610d6f5760405162461bcd60e51b81526004016104ce90612066565b610d78826108f8565b6001600160a01b0316836001600160a01b031614610da85760405162461bcd60e51b81526004016104ce90612113565b6108d482611359565b610dc3610dbc610f7e565b83836113dc565b5050565b610102546000906001600160a01b03163314610df55760405162461bcd60e51b81526004016104ce90612066565b8160005b81811015610e69576000858583818110610e1557610e156120dc565b905060200201359050610e27816108f8565b6001600160a01b0316876001600160a01b031614610e575760405162461bcd60e51b81526004016104ce90612113565b610e6081611359565b50600101610df9565b50600195945050505050565b610e86610e80610f7e565b836110f2565b610ea25760405162461bcd60e51b81526004016104ce90612019565b610eae848484846114a6565b50505050565b6060610ebf82610f56565b6000610ed660408051602081019091526000815290565b90506000815111610ef65760405180602001604052806000815250610f21565b80610f00846114d9565b604051602001610f11929190612148565b6040516020818303038152906040525b9392505050565b6001600160a01b03918216600090815260d56020908152604080832093909416825291909152205460ff1690565b610f5f8161156b565b610f7b5760405162461bcd60e51b81526004016104ce906120aa565b50565b6000610f88611588565b905090565b600081815260d46020526040902080546001600160a01b0319166001600160a01b0384169081179091558190610fc2826108f8565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000815160000361100e57506000919050565b506020015190565b600080600161102c611027886115e4565b611661565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa15801561107a573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166110d15760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b60448201526064016104ce565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6000806110fe836108f8565b9050806001600160a01b0316846001600160a01b0316148061112557506111258185610f28565b80610a935750836001600160a01b031661113e84610433565b6001600160a01b031614949350505050565b826001600160a01b0316611163826108f8565b6001600160a01b0316146111895760405162461bcd60e51b81526004016104ce90612177565b6001600160a01b0382166111eb5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016104ce565b826001600160a01b03166111fe826108f8565b6001600160a01b0316146112245760405162461bcd60e51b81526004016104ce90612177565b600081815260d46020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260d3855283862080546000190190559087168086528386208054600101905586865260d2909452828520805490921684179091559051849360008051602061243383398151915291a4505050565b610dc382826040518060200160405280600081525061168e565b606b54610100900460ff166112e35760405162461bcd60e51b81526004016104ce906121bc565b610dc382826116c1565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f61133b818484611701565b600055600280546001600160a01b0319163017905560055550505050565b6000611364826108f8565b905061136f826108f8565b600083815260d46020908152604080832080546001600160a01b03199081169091556001600160a01b03851680855260d38452828520805460001901905587855260d290935281842080549091169055519293508492600080516020612433833981519152908390a45050565b816001600160a01b0316836001600160a01b0316036114395760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b60448201526064016104ce565b6001600160a01b03838116600081815260d56020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6114b1848484611150565b6114bd8484848461174a565b610eae5760405162461bcd60e51b81526004016104ce90612207565b606060006114e68361184f565b60010190506000816001600160401b0381111561150557611505611e2d565b6040519080825280601f01601f19166020018201604052801561152f576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a850494508461153957509392505050565b600090815260d260205260409020546001600160a01b0316151590565b60003033036115de57600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506115e19050565b50335b90565b60006040518060800160405280604381526020016123f06043913980516020918201208351848301516040808701518051908601209051611644950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039b61166e611927565b8360405161190160f01b8152600281019290925260228201526042902090565b6116988383611962565b6116a5600084848461174a565b6105815760405162461bcd60e51b81526004016104ce90612207565b606b54610100900460ff166116e85760405162461bcd60e51b81526004016104ce906121bc565b60d06116f4838261229f565b5060d1610581828261229f565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b60006001600160a01b0384163b1561184757836001600160a01b031663150b7a02611773610f7e565b8786866040518563ffffffff1660e01b8152600401611795949392919061235e565b6020604051808303816000875af19250505080156117d0575060408051601f3d908101601f191682019092526117cd9181019061239b565b60015b61182d573d8080156117fe576040519150601f19603f3d011682016040523d82523d6000602084013e611803565b606091505b5080516000036118255760405162461bcd60e51b81526004016104ce90612207565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610a93565b506001610a93565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b831061188e5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef810000000083106118ba576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106118d857662386f26fc10000830492506010015b6305f5e10083106118f0576305f5e100830492506008015b612710831061190457612710830492506004015b60648310611916576064830492506002015b600a831061039b5760010192915050565b6002546000906001600160a01b031630148015611945575060015446145b15611951575060005490565b610f88600554600354600454611701565b6001600160a01b0382166119b85760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016104ce565b6119c18161156b565b156119de5760405162461bcd60e51b81526004016104ce906123b8565b6119e78161156b565b15611a045760405162461bcd60e51b81526004016104ce906123b8565b6001600160a01b038216600081815260d3602090815260408083208054600101905584835260d290915280822080546001600160a01b031916841790555183929190600080516020612433833981519152908290a45050565b6001600160e01b031981168114610f7b57600080fd5b600060208284031215611a8557600080fd5b8135610f2181611a5d565b60005b83811015611aab578181015183820152602001611a93565b50506000910152565b60008151808452611acc816020860160208601611a90565b601f01601f19169290920160200192915050565b602081526000610f216020830184611ab4565b600060208284031215611b0557600080fd5b5035919050565b80356001600160a01b0381168114611b2357600080fd5b919050565b60008060408385031215611b3b57600080fd5b611b4483611b0c565b946020939093013593505050565b60008083601f840112611b6457600080fd5b5081356001600160401b03811115611b7b57600080fd5b602083019150836020828501011115611b9357600080fd5b9250929050565b60008060008060008060a08789031215611bb357600080fd5b611bbc87611b0c565b955060208701356001600160401b03811115611bd757600080fd5b611be389828a01611b52565b9096509450506040870135925060608701359150608087013560ff81168114611c0b57600080fd5b809150509295509295509295565b600080600060608486031215611c2e57600080fd5b611c3784611b0c565b9250611c4560208501611b0c565b9150604084013590509250925092565b600060208284031215611c6757600080fd5b610f2182611b0c565b60008083601f840112611c8257600080fd5b5081356001600160401b03811115611c9957600080fd5b6020830191508360208260051b8501011115611b9357600080fd5b60008060008060408587031215611cca57600080fd5b84356001600160401b0380821115611ce157600080fd5b611ced88838901611c70565b90965094506020870135915080821115611d0657600080fd5b50611d1387828801611c70565b95989497509550505050565b600080600080600060608688031215611d3757600080fd5b611d4086611b0c565b945060208601356001600160401b0380821115611d5c57600080fd5b611d6889838a01611b52565b90965094506040880135915080821115611d8157600080fd5b50611d8e88828901611b52565b969995985093965092949392505050565b60008060408385031215611db257600080fd5b611dbb83611b0c565b915060208301358015158114611dd057600080fd5b809150509250929050565b600080600060408486031215611df057600080fd5b611df984611b0c565b925060208401356001600160401b03811115611e1457600080fd5b611e2086828701611c70565b9497909650939450505050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215611e5957600080fd5b611e6285611b0c565b9350611e7060208601611b0c565b92506040850135915060608501356001600160401b0380821115611e9357600080fd5b818701915087601f830112611ea757600080fd5b813581811115611eb957611eb9611e2d565b604051601f8201601f19908116603f01168101908382118183101715611ee157611ee1611e2d565b816040528281528a6020848701011115611efa57600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215611f3157600080fd5b611f3a83611b0c565b9150611f4860208401611b0c565b90509250929050565b600181811c90821680611f6557607f821691505b602082108103611f8557634e487b7160e01b600052602260045260246000fd5b50919050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60008251611fc3818460208701611a90565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b60208082526024908201527f4368696c644552433732313a204f6e6c79207072656469636174652063616e2060408201526318d85b1b60e21b606082015260800190565b602080825260189082015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b8082018082111561039b57634e487b7160e01b600052601160045260246000fd5b6020808252818101527f4368696c644552433732313a204f6e6c79206f776e65722063616e206275726e604082015260600190565b6000835161215a818460208801611a90565b83519083019061216e818360208801611a90565b01949350505050565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b601f82111561058157600081815260208120601f850160051c810160208610156122805750805b601f850160051c820191505b81811015610d035782815560010161228c565b81516001600160401b038111156122b8576122b8611e2d565b6122cc816122c68454611f51565b84612259565b602080601f83116001811461230157600084156122e95750858301515b600019600386901b1c1916600185901b178555610d03565b600085815260208120601f198616915b8281101561233057888601518255948401946001909101908401612311565b508582101561234e5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061239190830184611ab4565b9695505050505050565b6000602082840312156123ad57600080fd5b8151610f2181611a5d565b6020808252601c908201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060408201526060019056fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220667d3c30bcd6799bcd5d1501bea0d3a68235675f8ae26bea6b04951c37765f7164736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildERC721PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC721Predicate","sourceName":"contracts/blade/ChildERC721Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2ERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2ERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2ERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2ERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611fc4806100206000396000f3fe608060405234801561001057600080fd5b50600436106101585760003560e01c8063b1768065116100c3578063e0563ab11161007c578063e0563ab114610306578063eeb499451461030f578063f3fef3a314610322578063f645125514610335578063f691325c1461035c578063f8c8765e1461036f57600080fd5b8063b176806514610244578063b68ad1e41461026b578063c3b35a7e1461027e578063c5ac2b1c14610291578063d41f1771146102b8578063d7c9e3ec146102df57600080fd5b806355b01e4d1161011557806355b01e4d146101ce5780635ea5df79146101dc5780636f33e695146101f35780637efab4f514610208578063947287cf1461023157806397e5230d1461023a57600080fd5b806305dc2e8f1461015d57806307b3e2521461018d5780631bc114ba1461019b578063284017f5146101ae5780633b878c22146101b757806351351d53146101c0575b600080fd5b603454610170906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101706004600360981b0181565b603354610170906001600160a01b031681565b61017061202081565b61017061101081565b6101706002600160a01b0381565b6101706004600160991b0181565b6101e561138881565b604051908152602001610184565b61020661020136600461166f565b610382565b005b6101706102163660046116f1565b6037602052600090815260409020546001600160a01b031681565b6101e561520881565b6101e5620249f081565b6101e57f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b603654610170906001600160a01b031681565b61020661028c366004611715565b610396565b6101e57faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6101e57f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101e57f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61017061203081565b61020661031d366004611756565b6103a6565b6102066103303660046117de565b6105c9565b6101e57f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b603554610170906001600160a01b031681565b61020661037d36600461180a565b6105d8565b61038f8585858585610734565b5050505050565b6103a1838383610a98565b505050565b6034546001600160a01b031633146104175760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f53544154456044820152682fa922a1a2a4ab22a960b91b60648201526084015b60405180910390fd5b6035546001600160a01b038481169116146104865760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f524f4f545f60448201526850524544494341544560b81b606482015260840161040e565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216104b5602060008486611866565b6104be91611890565b036104dd576104d86104d38260208186611866565b610da1565b6105c3565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1861050c602060008486611866565b61051591611890565b03610524576104d88282611017565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad610553602060008486611866565b61055c91611890565b0361056b576104d8828261127d565b60405162461bcd60e51b815260206004820152602760248201527f4368696c644552433732315072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b606482015260840161040e565b50505050565b6105d4823383610a98565b5050565b336002600160a01b031461061c5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b604482015260640161040e565b600054610100900460ff161580801561063c5750600054600160ff909116105b806106565750303b158015610656575060005460ff166001145b6106b95760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161040e565b6000805460ff1916600117905580156106dc576000805461ff0019166101001790555b6106e8858585856113eb565b801561038f576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b8461073e816114e0565b61075a5760405162461bcd60e51b815260040161040e906118ae565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561079a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107be91906118f0565b6001600160a01b038181166000908152603760205260409020549192508881169116146107fd5760405162461bcd60e51b815260040161040e9061190d565b6001600160a01b03811661081357610813611951565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561085b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061087f91906118f0565b6001600160a01b03161461089557610895611951565b8483146108f05760405162461bcd60e51b8152602060048201526024808201527f4368696c644552433732315072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b606482015260840161040e565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc39061092090339088908890600401611999565b6020604051808303816000875af115801561093f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061096391906119c7565b61097f5760405162461bcd60e51b815260040161040e906119e9565b6033546035546040516001600160a01b03928316926316f198319216906109d6907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d90602001611a73565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610a02929190611b0d565b600060405180830381600087803b158015610a1c57600080fd5b505af1158015610a30573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167fa80bc76d6e1849a9088a9c00a2aeaa54eeb78f15565a18da3e8873438976f52289898989604051610a879493929190611b39565b60405180910390a450505050505050565b82610aa2816114e0565b610abe5760405162461bcd60e51b815260040161040e906118ae565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610afe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b2291906118f0565b6001600160a01b03818116600090815260376020526040902054919250868116911614610b615760405162461bcd60e51b815260040161040e9061190d565b6001600160a01b038116610b7757610b77611951565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610bbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610be391906118f0565b6001600160a01b031614610bf957610bf9611951565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610c279033908790600401611b6b565b6020604051808303816000875af1158015610c46573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c6a91906119c7565b610c865760405162461bcd60e51b815260040161040e906119e9565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610d119391169160c401611b0d565b600060405180830381600087803b158015610d2b57600080fd5b505af1158015610d3f573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f1e0ef6131232b1090efc3ec1cf7b53aa17f4b7cd8a4f9e033b49ee237379b0133387604051610d92929190611b6b565b60405180910390a45050505050565b6000808080610db285870187611b84565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610df55760405162461bcd60e51b815260040161040e9061190d565b610dfe816114e0565b610e0a57610e0a611951565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e4a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e6e91906118f0565b9050856001600160a01b0316816001600160a01b031614610e9157610e91611951565b6001600160a01b038116610ea757610ea7611951565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610eef573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1391906118f0565b6001600160a01b031614610f2957610f29611951565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610f579087908790600401611b6b565b6020604051808303816000875af1158015610f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f9a91906119c7565b610fb65760405162461bcd60e51b815260040161040e90611bd5565b836001600160a01b0316826001600160a01b0316876001600160a01b03167f37589fd8c906c19ea68eeb7e6b3e03efc06ff8aa4b1830588eba75f4375b16118887604051611005929190611b6b565b60405180910390a45050505050505050565b600080808061102885870187611cea565b6001600160a01b0380851660009081526037602052604090205494995092975090955093501690508061106d5760405162461bcd60e51b815260040161040e9061190d565b611076816114e0565b61108257611082611951565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110c2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110e691906118f0565b9050856001600160a01b0316816001600160a01b03161461110957611109611951565b6001600160a01b03811661111f5761111f611951565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611167573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061118b91906118f0565b6001600160a01b0316146111a1576111a1611951565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d9906111cf9087908790600401611ddc565b6020604051808303816000875af11580156111ee573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061121291906119c7565b61122e5760405162461bcd60e51b815260040161040e90611bd5565b846001600160a01b0316826001600160a01b0316876001600160a01b03167fc1b1a5c1b97cc8e5ac82b47496f5ebdadf9c7d119b30a116e2bdafd56f6ed4758787604051611005929190611ddc565b6000808061128d84860186611ecf565b91955093509150506001600160a01b0383166112ab576112ab611951565b6001600160a01b0383811660009081526037602052604090205416156112d3576112d3611951565b6036546040516bffffffffffffffffffffffff19606086901b166020820152600091611323916001600160a01b039091169060340160405160208183030381529060405280519060200120611575565b6001600160a01b038581166000908152603760205260409081902080546001600160a01b031916928416928317905551639065714760e01b81529192509063906571479061137990879087908790600401611f4e565b600060405180830381600087803b15801561139357600080fd5b505af11580156113a7573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a3505050505050565b6001600160a01b0384161580159061140b57506001600160a01b03831615155b801561141f57506001600160a01b03821615155b801561143357506001600160a01b03811615155b6114905760405162461bcd60e51b815260206004820152602860248201527f4368696c644552433732315072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b606482015260840161040e565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000816001600160a01b03163b6000036114fc57506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611563575060408051601f3d908101601f19168201909252611560918101906119c7565b60015b61156f57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b03811661156f5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b604482015260640161040e565b6001600160a01b038116811461162157600080fd5b50565b60008083601f84011261163657600080fd5b5081356001600160401b0381111561164d57600080fd5b6020830191508360208260051b850101111561166857600080fd5b9250929050565b60008060008060006060868803121561168757600080fd5b85356116928161160c565b945060208601356001600160401b03808211156116ae57600080fd5b6116ba89838a01611624565b909650945060408801359150808211156116d357600080fd5b506116e088828901611624565b969995985093965092949392505050565b60006020828403121561170357600080fd5b813561170e8161160c565b9392505050565b60008060006060848603121561172a57600080fd5b83356117358161160c565b925060208401356117458161160c565b929592945050506040919091013590565b6000806000806060858703121561176c57600080fd5b84359350602085013561177e8161160c565b925060408501356001600160401b038082111561179a57600080fd5b818701915087601f8301126117ae57600080fd5b8135818111156117bd57600080fd5b8860208285010111156117cf57600080fd5b95989497505060200194505050565b600080604083850312156117f157600080fd5b82356117fc8161160c565b946020939093013593505050565b6000806000806080858703121561182057600080fd5b843561182b8161160c565b9350602085013561183b8161160c565b9250604085013561184b8161160c565b9150606085013561185b8161160c565b939692955090935050565b6000808585111561187657600080fd5b8386111561188357600080fd5b5050820193919092039150565b8035602083101561156f57600019602084900360031b1b1692915050565b60208082526022908201527f4368696c644552433732315072656469636174653a204e4f545f434f4e54524160408201526110d560f21b606082015260800190565b60006020828403121561190257600080fd5b815161170e8161160c565b60208082526024908201527f4368696c644552433732315072656469636174653a20554e4d41505045445f5460408201526327a5a2a760e11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561198057600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b03841681526040602082018190526000906119be9083018486611967565b95945050505050565b6000602082840312156119d957600080fd5b8151801515811461170e57600080fd5b60208082526021908201527f4368696c644552433732315072656469636174653a204255524e5f4641494c456040820152601160fa1b606082015260800190565b8183526000602080850194508260005b85811015611a68578135611a4d8161160c565b6001600160a01b031687529582019590820190600101611a3a565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a060608201819052600090611aa69083018688611a2a565b8281036080840152611ab9818587611967565b9a9950505050505050505050565b6000815180845260005b81811015611aed57602081850181015186830182015201611ad1565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611b3190830184611ac7565b949350505050565b604081526000611b4d604083018688611a2a565b8281036020840152611b60818587611967565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611b9a57600080fd5b8435611ba58161160c565b93506020850135611bb58161160c565b92506040850135611bc58161160c565b9396929550929360600135925050565b60208082526021908201527f4368696c644552433732315072656469636174653a204d494e545f4641494c456040820152601160fa1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611c5457611c54611c16565b604052919050565b60006001600160401b03821115611c7557611c75611c16565b5060051b60200190565b600082601f830112611c9057600080fd5b81356020611ca5611ca083611c5c565b611c2c565b82815260059290921b84018101918181019086841115611cc457600080fd5b8286015b84811015611cdf5780358352918301918301611cc8565b509695505050505050565b600080600080600060a08688031215611d0257600080fd5b85359450602080870135611d158161160c565b94506040870135611d258161160c565b935060608701356001600160401b0380821115611d4157600080fd5b818901915089601f830112611d5557600080fd5b8135611d63611ca082611c5c565b81815260059190911b8301840190848101908c831115611d8257600080fd5b938501935b82851015611da9578435611d9a8161160c565b82529385019390850190611d87565b965050506080890135925080831115611dc157600080fd5b5050611dcf88828901611c7f565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b82811015611e1e5781516001600160a01b031684529284019290840190600101611df9565b5050508381038285015284518082528583019183019060005b81811015611e5357835183529284019291840191600101611e37565b5090979650505050505050565b600082601f830112611e7157600080fd5b81356001600160401b03811115611e8a57611e8a611c16565b611e9d601f8201601f1916602001611c2c565b818152846020838601011115611eb257600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611ee557600080fd5b843593506020850135611ef78161160c565b925060408501356001600160401b0380821115611f1357600080fd5b611f1f88838901611e60565b93506060870135915080821115611f3557600080fd5b50611f4287828801611e60565b91505092959194509250565b6001600160a01b0384168152606060208201819052600090611f7290830185611ac7565b8281036040840152611f848185611ac7565b969550505050505056fea26469706673582212205bff80e6d0798f90b406762b37ac0e9e73f04e45fab814558747c6e7f65d31f764736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101585760003560e01c8063b1768065116100c3578063e0563ab11161007c578063e0563ab114610306578063eeb499451461030f578063f3fef3a314610322578063f645125514610335578063f691325c1461035c578063f8c8765e1461036f57600080fd5b8063b176806514610244578063b68ad1e41461026b578063c3b35a7e1461027e578063c5ac2b1c14610291578063d41f1771146102b8578063d7c9e3ec146102df57600080fd5b806355b01e4d1161011557806355b01e4d146101ce5780635ea5df79146101dc5780636f33e695146101f35780637efab4f514610208578063947287cf1461023157806397e5230d1461023a57600080fd5b806305dc2e8f1461015d57806307b3e2521461018d5780631bc114ba1461019b578063284017f5146101ae5780633b878c22146101b757806351351d53146101c0575b600080fd5b603454610170906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101706004600360981b0181565b603354610170906001600160a01b031681565b61017061202081565b61017061101081565b6101706002600160a01b0381565b6101706004600160991b0181565b6101e561138881565b604051908152602001610184565b61020661020136600461166f565b610382565b005b6101706102163660046116f1565b6037602052600090815260409020546001600160a01b031681565b6101e561520881565b6101e5620249f081565b6101e57f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b603654610170906001600160a01b031681565b61020661028c366004611715565b610396565b6101e57faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6101e57f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101e57f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61017061203081565b61020661031d366004611756565b6103a6565b6102066103303660046117de565b6105c9565b6101e57f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b603554610170906001600160a01b031681565b61020661037d36600461180a565b6105d8565b61038f8585858585610734565b5050505050565b6103a1838383610a98565b505050565b6034546001600160a01b031633146104175760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f53544154456044820152682fa922a1a2a4ab22a960b91b60648201526084015b60405180910390fd5b6035546001600160a01b038481169116146104865760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f524f4f545f60448201526850524544494341544560b81b606482015260840161040e565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216104b5602060008486611866565b6104be91611890565b036104dd576104d86104d38260208186611866565b610da1565b6105c3565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1861050c602060008486611866565b61051591611890565b03610524576104d88282611017565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad610553602060008486611866565b61055c91611890565b0361056b576104d8828261127d565b60405162461bcd60e51b815260206004820152602760248201527f4368696c644552433732315072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b606482015260840161040e565b50505050565b6105d4823383610a98565b5050565b336002600160a01b031461061c5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b604482015260640161040e565b600054610100900460ff161580801561063c5750600054600160ff909116105b806106565750303b158015610656575060005460ff166001145b6106b95760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161040e565b6000805460ff1916600117905580156106dc576000805461ff0019166101001790555b6106e8858585856113eb565b801561038f576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b8461073e816114e0565b61075a5760405162461bcd60e51b815260040161040e906118ae565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561079a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107be91906118f0565b6001600160a01b038181166000908152603760205260409020549192508881169116146107fd5760405162461bcd60e51b815260040161040e9061190d565b6001600160a01b03811661081357610813611951565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561085b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061087f91906118f0565b6001600160a01b03161461089557610895611951565b8483146108f05760405162461bcd60e51b8152602060048201526024808201527f4368696c644552433732315072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b606482015260840161040e565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc39061092090339088908890600401611999565b6020604051808303816000875af115801561093f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061096391906119c7565b61097f5760405162461bcd60e51b815260040161040e906119e9565b6033546035546040516001600160a01b03928316926316f198319216906109d6907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d90602001611a73565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610a02929190611b0d565b600060405180830381600087803b158015610a1c57600080fd5b505af1158015610a30573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167fa80bc76d6e1849a9088a9c00a2aeaa54eeb78f15565a18da3e8873438976f52289898989604051610a879493929190611b39565b60405180910390a450505050505050565b82610aa2816114e0565b610abe5760405162461bcd60e51b815260040161040e906118ae565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610afe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b2291906118f0565b6001600160a01b03818116600090815260376020526040902054919250868116911614610b615760405162461bcd60e51b815260040161040e9061190d565b6001600160a01b038116610b7757610b77611951565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610bbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610be391906118f0565b6001600160a01b031614610bf957610bf9611951565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610c279033908790600401611b6b565b6020604051808303816000875af1158015610c46573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c6a91906119c7565b610c865760405162461bcd60e51b815260040161040e906119e9565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352938416936316f1983193610d119391169160c401611b0d565b600060405180830381600087803b158015610d2b57600080fd5b505af1158015610d3f573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f1e0ef6131232b1090efc3ec1cf7b53aa17f4b7cd8a4f9e033b49ee237379b0133387604051610d92929190611b6b565b60405180910390a45050505050565b6000808080610db285870187611b84565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610df55760405162461bcd60e51b815260040161040e9061190d565b610dfe816114e0565b610e0a57610e0a611951565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e4a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e6e91906118f0565b9050856001600160a01b0316816001600160a01b031614610e9157610e91611951565b6001600160a01b038116610ea757610ea7611951565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610eef573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1391906118f0565b6001600160a01b031614610f2957610f29611951565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610f579087908790600401611b6b565b6020604051808303816000875af1158015610f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f9a91906119c7565b610fb65760405162461bcd60e51b815260040161040e90611bd5565b836001600160a01b0316826001600160a01b0316876001600160a01b03167f37589fd8c906c19ea68eeb7e6b3e03efc06ff8aa4b1830588eba75f4375b16118887604051611005929190611b6b565b60405180910390a45050505050505050565b600080808061102885870187611cea565b6001600160a01b0380851660009081526037602052604090205494995092975090955093501690508061106d5760405162461bcd60e51b815260040161040e9061190d565b611076816114e0565b61108257611082611951565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110c2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110e691906118f0565b9050856001600160a01b0316816001600160a01b03161461110957611109611951565b6001600160a01b03811661111f5761111f611951565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611167573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061118b91906118f0565b6001600160a01b0316146111a1576111a1611951565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d9906111cf9087908790600401611ddc565b6020604051808303816000875af11580156111ee573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061121291906119c7565b61122e5760405162461bcd60e51b815260040161040e90611bd5565b846001600160a01b0316826001600160a01b0316876001600160a01b03167fc1b1a5c1b97cc8e5ac82b47496f5ebdadf9c7d119b30a116e2bdafd56f6ed4758787604051611005929190611ddc565b6000808061128d84860186611ecf565b91955093509150506001600160a01b0383166112ab576112ab611951565b6001600160a01b0383811660009081526037602052604090205416156112d3576112d3611951565b6036546040516bffffffffffffffffffffffff19606086901b166020820152600091611323916001600160a01b039091169060340160405160208183030381529060405280519060200120611575565b6001600160a01b038581166000908152603760205260409081902080546001600160a01b031916928416928317905551639065714760e01b81529192509063906571479061137990879087908790600401611f4e565b600060405180830381600087803b15801561139357600080fd5b505af11580156113a7573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a3505050505050565b6001600160a01b0384161580159061140b57506001600160a01b03831615155b801561141f57506001600160a01b03821615155b801561143357506001600160a01b03811615155b6114905760405162461bcd60e51b815260206004820152602860248201527f4368696c644552433732315072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b606482015260840161040e565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000816001600160a01b03163b6000036114fc57506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611563575060408051601f3d908101601f19168201909252611560918101906119c7565b60015b61156f57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b03811661156f5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b604482015260640161040e565b6001600160a01b038116811461162157600080fd5b50565b60008083601f84011261163657600080fd5b5081356001600160401b0381111561164d57600080fd5b6020830191508360208260051b850101111561166857600080fd5b9250929050565b60008060008060006060868803121561168757600080fd5b85356116928161160c565b945060208601356001600160401b03808211156116ae57600080fd5b6116ba89838a01611624565b909650945060408801359150808211156116d357600080fd5b506116e088828901611624565b969995985093965092949392505050565b60006020828403121561170357600080fd5b813561170e8161160c565b9392505050565b60008060006060848603121561172a57600080fd5b83356117358161160c565b925060208401356117458161160c565b929592945050506040919091013590565b6000806000806060858703121561176c57600080fd5b84359350602085013561177e8161160c565b925060408501356001600160401b038082111561179a57600080fd5b818701915087601f8301126117ae57600080fd5b8135818111156117bd57600080fd5b8860208285010111156117cf57600080fd5b95989497505060200194505050565b600080604083850312156117f157600080fd5b82356117fc8161160c565b946020939093013593505050565b6000806000806080858703121561182057600080fd5b843561182b8161160c565b9350602085013561183b8161160c565b9250604085013561184b8161160c565b9150606085013561185b8161160c565b939692955090935050565b6000808585111561187657600080fd5b8386111561188357600080fd5b5050820193919092039150565b8035602083101561156f57600019602084900360031b1b1692915050565b60208082526022908201527f4368696c644552433732315072656469636174653a204e4f545f434f4e54524160408201526110d560f21b606082015260800190565b60006020828403121561190257600080fd5b815161170e8161160c565b60208082526024908201527f4368696c644552433732315072656469636174653a20554e4d41505045445f5460408201526327a5a2a760e11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561198057600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b03841681526040602082018190526000906119be9083018486611967565b95945050505050565b6000602082840312156119d957600080fd5b8151801515811461170e57600080fd5b60208082526021908201527f4368696c644552433732315072656469636174653a204255524e5f4641494c456040820152601160fa1b606082015260800190565b8183526000602080850194508260005b85811015611a68578135611a4d8161160c565b6001600160a01b031687529582019590820190600101611a3a565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a060608201819052600090611aa69083018688611a2a565b8281036080840152611ab9818587611967565b9a9950505050505050505050565b6000815180845260005b81811015611aed57602081850181015186830182015201611ad1565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611b3190830184611ac7565b949350505050565b604081526000611b4d604083018688611a2a565b8281036020840152611b60818587611967565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611b9a57600080fd5b8435611ba58161160c565b93506020850135611bb58161160c565b92506040850135611bc58161160c565b9396929550929360600135925050565b60208082526021908201527f4368696c644552433732315072656469636174653a204d494e545f4641494c456040820152601160fa1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611c5457611c54611c16565b604052919050565b60006001600160401b03821115611c7557611c75611c16565b5060051b60200190565b600082601f830112611c9057600080fd5b81356020611ca5611ca083611c5c565b611c2c565b82815260059290921b84018101918181019086841115611cc457600080fd5b8286015b84811015611cdf5780358352918301918301611cc8565b509695505050505050565b600080600080600060a08688031215611d0257600080fd5b85359450602080870135611d158161160c565b94506040870135611d258161160c565b935060608701356001600160401b0380821115611d4157600080fd5b818901915089601f830112611d5557600080fd5b8135611d63611ca082611c5c565b81815260059190911b8301840190848101908c831115611d8257600080fd5b938501935b82851015611da9578435611d9a8161160c565b82529385019390850190611d87565b965050506080890135925080831115611dc157600080fd5b5050611dcf88828901611c7f565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b82811015611e1e5781516001600160a01b031684529284019290840190600101611df9565b5050508381038285015284518082528583019183019060005b81811015611e5357835183529284019291840191600101611e37565b5090979650505050505050565b600082601f830112611e7157600080fd5b81356001600160401b03811115611e8a57611e8a611c16565b611e9d601f8201601f1916602001611c2c565b818152846020838601011115611eb257600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611ee557600080fd5b843593506020850135611ef78161160c565b925060408501356001600160401b0380821115611f1357600080fd5b611f1f88838901611e60565b93506060870135915080821115611f3557600080fd5b50611f4287828801611e60565b91505092959194509250565b6001600160a01b0384168152606060208201819052600090611f7290830185611ac7565b8281036040840152611f848185611ac7565b969550505050505056fea26469706673582212205bff80e6d0798f90b406762b37ac0e9e73f04e45fab814558747c6e7f65d31f764736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildERC721PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC721PredicateAccessList","sourceName":"contracts/blade/ChildERC721PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2ERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2ERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2ERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2ERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","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":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612758806100206000396000f3fe608060405234801561001057600080fd5b50600436106101b05760003560e01c8063b68ad1e4116100ef578063e0563ab111610092578063e0563ab1146103b9578063e30c3978146103c2578063eeb49945146103d3578063f2fde38b146103e6578063f3fef3a3146103f9578063f64512551461040c578063f691325c14610433578063f8c8765e1461044657600080fd5b8063b68ad1e4146102e5578063c1225a20146102f8578063c3b35a7e1461030b578063c5ac2b1c1461031e578063c5e4683a14610345578063d41f177114610358578063d7c9e3ec1461037f578063d8dd1773146103a657600080fd5b80636f33e695116101575780636f33e6951461024b578063715018a61461026057806379ba5097146102685780637efab4f5146102705780638da5cb5b1461029a578063947287cf146102ab57806397e5230d146102b4578063b1768065146102be57600080fd5b806305dc2e8f146101b557806307b3e252146101e55780631bc114ba146101f3578063284017f5146102065780633b878c221461020f57806351351d531461021857806355b01e4d146102265780635ea5df7914610234575b600080fd5b60fd546101c8906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101c86004600360981b0181565b60fc546101c8906001600160a01b031681565b6101c861202081565b6101c861101081565b6101c86002600160a01b0381565b6101c86004600160991b0181565b61023d61138881565b6040519081526020016101dc565b61025e610259366004611c96565b610459565b005b61025e610475565b61025e610489565b6101c861027e366004611d18565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101c8565b61023d61520881565b61023d620249f081565b61023d7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101c8906001600160a01b031681565b61025e610306366004611d4a565b610508565b61025e610319366004611d67565b610557565b61023d7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b61025e610353366004611d4a565b61056f565b61023d7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61023d7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61025e6103b4366004611da8565b6105b6565b6101c861203081565b6065546001600160a01b03166101c8565b61025e6103e1366004611e3e565b6106d7565b61025e6103f4366004611d18565b6108f5565b61025e610407366004611ec6565b610966565b61023d7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b60fe546101c8906001600160a01b031681565b61025e610454366004611ef2565b61097d565b610461610a75565b61046e8585858585610a7d565b5050505050565b61047d610de2565b6104876000610e3c565b565b60655433906001600160a01b031681146104fc5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61050581610e3c565b50565b610510610de2565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b61055f610a75565b61056a838383610e55565b505050565b610577610de2565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105dd5760405163973d02cb60e01b81526004016104f390611f4e565b600054610100900460ff16158080156105fd5750600054600160ff909116105b806106175750303b158015610617575060005460ff166001145b6106335760405162461bcd60e51b81526004016104f390611f72565b6000805460ff191660011790558015610656576000805461ff0019166101001790555b6106628888888861115f565b60c9805461ffff191685151561ff001916176101008515150217905561068782610e3c565b80156106cd576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107435760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f53544154456044820152682fa922a1a2a4ab22a960b91b60648201526084016104f3565b60fe546001600160a01b038481169116146107b25760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f524f4f545f60448201526850524544494341544560b81b60648201526084016104f3565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216107e1602060008486611fc0565b6107ea91611fea565b03610809576108046107ff8260208186611fc0565b611254565b6108ef565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18610838602060008486611fc0565b61084191611fea565b036108505761080482826114cb565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61087f602060008486611fc0565b61088891611fea565b03610897576108048282611732565b60405162461bcd60e51b815260206004820152602760248201527f4368696c644552433732315072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b60648201526084016104f3565b50505050565b6108fd610de2565b606580546001600160a01b0383166001600160a01b0319909116811790915561092e6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b61096e610a75565b610979823383610e55565b5050565b336002600160a01b03146109a45760405163973d02cb60e01b81526004016104f390611f4e565b600054610100900460ff16158080156109c45750600054600160ff909116105b806109de5750303b1580156109de575060005460ff166001145b6109fa5760405162461bcd60e51b81526004016104f390611f72565b6000805460ff191660011790558015610a1d576000805461ff0019166101001790555b610a298585858561115f565b801561046e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b6104876118a2565b84610a8781611ab8565b610aa35760405162461bcd60e51b81526004016104f390612008565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ae3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b07919061204a565b6001600160a01b0381811660009081526101006020526040902054919250888116911614610b475760405162461bcd60e51b81526004016104f390612067565b6001600160a01b038116610b5d57610b5d6120ab565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ba5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bc9919061204a565b6001600160a01b031614610bdf57610bdf6120ab565b848314610c3a5760405162461bcd60e51b8152602060048201526024808201527f4368696c644552433732315072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b60648201526084016104f3565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc390610c6a903390889088906004016120f3565b6020604051808303816000875af1158015610c89573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cad9190612121565b610cc95760405162461bcd60e51b81526004016104f39061213e565b60fc5460fe546040516001600160a01b03928316926316f19831921690610d20907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d906020016121c8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d4c92919061226c565b600060405180830381600087803b158015610d6657600080fd5b505af1158015610d7a573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167fa80bc76d6e1849a9088a9c00a2aeaa54eeb78f15565a18da3e8873438976f52289898989604051610dd19493929190612298565b60405180910390a450505050505050565b6033546001600160a01b031633146104875760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104f3565b606580546001600160a01b031916905561050581611b4d565b82610e5f81611ab8565b610e7b5760405162461bcd60e51b81526004016104f390612008565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ebb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610edf919061204a565b6001600160a01b0381811660009081526101006020526040902054919250868116911614610f1f5760405162461bcd60e51b81526004016104f390612067565b6001600160a01b038116610f3557610f356120ab565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f7d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fa1919061204a565b6001600160a01b031614610fb757610fb76120ab565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610fe590339087906004016122ca565b6020604051808303816000875af1158015611004573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110289190612121565b6110445760405162461bcd60e51b81526004016104f39061213e565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352938416936316f19831936110cf9391169160c40161226c565b600060405180830381600087803b1580156110e957600080fd5b505af11580156110fd573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f1e0ef6131232b1090efc3ec1cf7b53aa17f4b7cd8a4f9e033b49ee237379b01333876040516111509291906122ca565b60405180910390a45050505050565b6001600160a01b0384161580159061117f57506001600160a01b03831615155b801561119357506001600160a01b03821615155b80156111a757506001600160a01b03811615155b6112045760405162461bcd60e51b815260206004820152602860248201527f4368696c644552433732315072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b60648201526084016104f3565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b6000808080611265858701876122e3565b6001600160a01b0380851660009081526101006020526040902054949850929650909450925016806112a95760405162461bcd60e51b81526004016104f390612067565b6112b281611ab8565b6112be576112be6120ab565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156112fe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611322919061204a565b9050856001600160a01b0316816001600160a01b031614611345576113456120ab565b6001600160a01b03811661135b5761135b6120ab565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113c7919061204a565b6001600160a01b0316146113dd576113dd6120ab565b6040516340c10f1960e01b81526001600160a01b038316906340c10f199061140b90879087906004016122ca565b6020604051808303816000875af115801561142a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061144e9190612121565b61146a5760405162461bcd60e51b81526004016104f390612334565b836001600160a01b0316826001600160a01b0316876001600160a01b03167f37589fd8c906c19ea68eeb7e6b3e03efc06ff8aa4b1830588eba75f4375b161188876040516114b99291906122ca565b60405180910390a45050505050505050565b60008080806114dc85870187612449565b6001600160a01b03808516600090815261010060205260409020549499509297509095509350169050806115225760405162461bcd60e51b81526004016104f390612067565b61152b81611ab8565b611537576115376120ab565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015611577573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061159b919061204a565b9050856001600160a01b0316816001600160a01b0316146115be576115be6120ab565b6001600160a01b0381166115d4576115d46120ab565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561161c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611640919061204a565b6001600160a01b031614611656576116566120ab565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d990611684908790879060040161253b565b6020604051808303816000875af11580156116a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116c79190612121565b6116e35760405162461bcd60e51b81526004016104f390612334565b846001600160a01b0316826001600160a01b0316876001600160a01b03167fc1b1a5c1b97cc8e5ac82b47496f5ebdadf9c7d119b30a116e2bdafd56f6ed47587876040516114b992919061253b565b600080806117428486018661262e565b91955093509150506001600160a01b038316611760576117606120ab565b6001600160a01b03838116600090815261010060205260409020541615611789576117896120ab565b60ff546040516bffffffffffffffffffffffff19606086901b1660208201526000916117d9916001600160a01b039091169060340160405160208183030381529060405280519060200120611b9f565b6001600160a01b03858116600090815261010060205260409081902080546001600160a01b031916928416928317905551639065714760e01b815291925090639065714790611830908790879087906004016126ad565b600060405180830381600087803b15801561184a57600080fd5b505af115801561185e573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a3505050505050565b60c95460ff16156119ad57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161190491906126ed565b6000604051808303818686fa925050503d8060008114611940576040519150601f19603f3d011682016040523d82523d6000602084013e611945565b606091505b509150915081801561196a57506000818060200190518101906119689190612709565b115b6119aa5760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016104f3565b50505b60c954610100900460ff161561048757604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b019161138891611a1491906126ed565b6000604051808303818686fa925050503d8060008114611a50576040519150601f19603f3d011682016040523d82523d6000602084013e611a55565b606091505b5091509150818015611a7b575080806020019051810190611a769190612709565b600114155b6109795760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016104f3565b6000816001600160a01b03163b600003611ad457506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611b3b575060408051601f3d908101601f19168201909252611b3891810190612121565b60015b611b4757506000919050565b92915050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116611b475760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016104f3565b6001600160a01b038116811461050557600080fd5b60008083601f840112611c5d57600080fd5b5081356001600160401b03811115611c7457600080fd5b6020830191508360208260051b8501011115611c8f57600080fd5b9250929050565b600080600080600060608688031215611cae57600080fd5b8535611cb981611c36565b945060208601356001600160401b0380821115611cd557600080fd5b611ce189838a01611c4b565b90965094506040880135915080821115611cfa57600080fd5b50611d0788828901611c4b565b969995985093965092949392505050565b600060208284031215611d2a57600080fd5b8135611d3581611c36565b9392505050565b801515811461050557600080fd5b600060208284031215611d5c57600080fd5b8135611d3581611d3c565b600080600060608486031215611d7c57600080fd5b8335611d8781611c36565b92506020840135611d9781611c36565b929592945050506040919091013590565b600080600080600080600060e0888a031215611dc357600080fd5b8735611dce81611c36565b96506020880135611dde81611c36565b95506040880135611dee81611c36565b94506060880135611dfe81611c36565b93506080880135611e0e81611d3c565b925060a0880135611e1e81611d3c565b915060c0880135611e2e81611c36565b8091505092959891949750929550565b60008060008060608587031215611e5457600080fd5b843593506020850135611e6681611c36565b925060408501356001600160401b0380821115611e8257600080fd5b818701915087601f830112611e9657600080fd5b813581811115611ea557600080fd5b886020828501011115611eb757600080fd5b95989497505060200194505050565b60008060408385031215611ed957600080fd5b8235611ee481611c36565b946020939093013593505050565b60008060008060808587031215611f0857600080fd5b8435611f1381611c36565b93506020850135611f2381611c36565b92506040850135611f3381611c36565b91506060850135611f4381611c36565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611fd057600080fd5b83861115611fdd57600080fd5b5050820193919092039150565b80356020831015611b4757600019602084900360031b1b1692915050565b60208082526022908201527f4368696c644552433732315072656469636174653a204e4f545f434f4e54524160408201526110d560f21b606082015260800190565b60006020828403121561205c57600080fd5b8151611d3581611c36565b60208082526024908201527f4368696c644552433732315072656469636174653a20554e4d41505045445f5460408201526327a5a2a760e11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156120da57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038416815260406020820181905260009061211890830184866120c1565b95945050505050565b60006020828403121561213357600080fd5b8151611d3581611d3c565b60208082526021908201527f4368696c644552433732315072656469636174653a204255524e5f4641494c456040820152601160fa1b606082015260800190565b8183526000602080850194508260005b858110156121bd5781356121a281611c36565b6001600160a01b03168752958201959082019060010161218f565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906121fb908301868861217f565b828103608084015261220e8185876120c1565b9a9950505050505050505050565b60005b8381101561223757818101518382015260200161221f565b50506000910152565b6000815180845261225881602086016020860161221c565b601f01601f19169290920160200192915050565b6001600160a01b038316815260406020820181905260009061229090830184612240565b949350505050565b6040815260006122ac60408301868861217f565b82810360208401526122bf8185876120c1565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b600080600080608085870312156122f957600080fd5b843561230481611c36565b9350602085013561231481611c36565b9250604085013561232481611c36565b9396929550929360600135925050565b60208082526021908201527f4368696c644552433732315072656469636174653a204d494e545f4641494c456040820152601160fa1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156123b3576123b3612375565b604052919050565b60006001600160401b038211156123d4576123d4612375565b5060051b60200190565b600082601f8301126123ef57600080fd5b813560206124046123ff836123bb565b61238b565b82815260059290921b8401810191818101908684111561242357600080fd5b8286015b8481101561243e5780358352918301918301612427565b509695505050505050565b600080600080600060a0868803121561246157600080fd5b8535945060208087013561247481611c36565b9450604087013561248481611c36565b935060608701356001600160401b03808211156124a057600080fd5b818901915089601f8301126124b457600080fd5b81356124c26123ff826123bb565b81815260059190911b8301840190848101908c8311156124e157600080fd5b938501935b828510156125085784356124f981611c36565b825293850193908501906124e6565b96505050608089013592508083111561252057600080fd5b505061252e888289016123de565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b8281101561257d5781516001600160a01b031684529284019290840190600101612558565b5050508381038285015284518082528583019183019060005b818110156125b257835183529284019291840191600101612596565b5090979650505050505050565b600082601f8301126125d057600080fd5b81356001600160401b038111156125e9576125e9612375565b6125fc601f8201601f191660200161238b565b81815284602083860101111561261157600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000806080858703121561264457600080fd5b84359350602085013561265681611c36565b925060408501356001600160401b038082111561267257600080fd5b61267e888389016125bf565b9350606087013591508082111561269457600080fd5b506126a1878288016125bf565b91505092959194509250565b6001600160a01b03841681526060602082018190526000906126d190830185612240565b82810360408401526126e38185612240565b9695505050505050565b600082516126ff81846020870161221c565b9190910192915050565b60006020828403121561271b57600080fd5b505191905056fea26469706673582212209fb96730231af9e41bf678810325933de9ae73b8e3281f6ee32437340a3b952d64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101b05760003560e01c8063b68ad1e4116100ef578063e0563ab111610092578063e0563ab1146103b9578063e30c3978146103c2578063eeb49945146103d3578063f2fde38b146103e6578063f3fef3a3146103f9578063f64512551461040c578063f691325c14610433578063f8c8765e1461044657600080fd5b8063b68ad1e4146102e5578063c1225a20146102f8578063c3b35a7e1461030b578063c5ac2b1c1461031e578063c5e4683a14610345578063d41f177114610358578063d7c9e3ec1461037f578063d8dd1773146103a657600080fd5b80636f33e695116101575780636f33e6951461024b578063715018a61461026057806379ba5097146102685780637efab4f5146102705780638da5cb5b1461029a578063947287cf146102ab57806397e5230d146102b4578063b1768065146102be57600080fd5b806305dc2e8f146101b557806307b3e252146101e55780631bc114ba146101f3578063284017f5146102065780633b878c221461020f57806351351d531461021857806355b01e4d146102265780635ea5df7914610234575b600080fd5b60fd546101c8906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101c86004600360981b0181565b60fc546101c8906001600160a01b031681565b6101c861202081565b6101c861101081565b6101c86002600160a01b0381565b6101c86004600160991b0181565b61023d61138881565b6040519081526020016101dc565b61025e610259366004611c96565b610459565b005b61025e610475565b61025e610489565b6101c861027e366004611d18565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101c8565b61023d61520881565b61023d620249f081565b61023d7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101c8906001600160a01b031681565b61025e610306366004611d4a565b610508565b61025e610319366004611d67565b610557565b61023d7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b61025e610353366004611d4a565b61056f565b61023d7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61023d7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61025e6103b4366004611da8565b6105b6565b6101c861203081565b6065546001600160a01b03166101c8565b61025e6103e1366004611e3e565b6106d7565b61025e6103f4366004611d18565b6108f5565b61025e610407366004611ec6565b610966565b61023d7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b60fe546101c8906001600160a01b031681565b61025e610454366004611ef2565b61097d565b610461610a75565b61046e8585858585610a7d565b5050505050565b61047d610de2565b6104876000610e3c565b565b60655433906001600160a01b031681146104fc5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61050581610e3c565b50565b610510610de2565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b61055f610a75565b61056a838383610e55565b505050565b610577610de2565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105dd5760405163973d02cb60e01b81526004016104f390611f4e565b600054610100900460ff16158080156105fd5750600054600160ff909116105b806106175750303b158015610617575060005460ff166001145b6106335760405162461bcd60e51b81526004016104f390611f72565b6000805460ff191660011790558015610656576000805461ff0019166101001790555b6106628888888861115f565b60c9805461ffff191685151561ff001916176101008515150217905561068782610e3c565b80156106cd576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107435760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f53544154456044820152682fa922a1a2a4ab22a960b91b60648201526084016104f3565b60fe546001600160a01b038481169116146107b25760405162461bcd60e51b815260206004820152602960248201527f4368696c644552433732315072656469636174653a204f4e4c595f524f4f545f60448201526850524544494341544560b81b60648201526084016104f3565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216107e1602060008486611fc0565b6107ea91611fea565b03610809576108046107ff8260208186611fc0565b611254565b6108ef565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18610838602060008486611fc0565b61084191611fea565b036108505761080482826114cb565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61087f602060008486611fc0565b61088891611fea565b03610897576108048282611732565b60405162461bcd60e51b815260206004820152602760248201527f4368696c644552433732315072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b60648201526084016104f3565b50505050565b6108fd610de2565b606580546001600160a01b0383166001600160a01b0319909116811790915561092e6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b61096e610a75565b610979823383610e55565b5050565b336002600160a01b03146109a45760405163973d02cb60e01b81526004016104f390611f4e565b600054610100900460ff16158080156109c45750600054600160ff909116105b806109de5750303b1580156109de575060005460ff166001145b6109fa5760405162461bcd60e51b81526004016104f390611f72565b6000805460ff191660011790558015610a1d576000805461ff0019166101001790555b610a298585858561115f565b801561046e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b6104876118a2565b84610a8781611ab8565b610aa35760405162461bcd60e51b81526004016104f390612008565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ae3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b07919061204a565b6001600160a01b0381811660009081526101006020526040902054919250888116911614610b475760405162461bcd60e51b81526004016104f390612067565b6001600160a01b038116610b5d57610b5d6120ab565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ba5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bc9919061204a565b6001600160a01b031614610bdf57610bdf6120ab565b848314610c3a5760405162461bcd60e51b8152602060048201526024808201527f4368696c644552433732315072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b60648201526084016104f3565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc390610c6a903390889088906004016120f3565b6020604051808303816000875af1158015610c89573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cad9190612121565b610cc95760405162461bcd60e51b81526004016104f39061213e565b60fc5460fe546040516001600160a01b03928316926316f19831921690610d20907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d906020016121c8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d4c92919061226c565b600060405180830381600087803b158015610d6657600080fd5b505af1158015610d7a573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167fa80bc76d6e1849a9088a9c00a2aeaa54eeb78f15565a18da3e8873438976f52289898989604051610dd19493929190612298565b60405180910390a450505050505050565b6033546001600160a01b031633146104875760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104f3565b606580546001600160a01b031916905561050581611b4d565b82610e5f81611ab8565b610e7b5760405162461bcd60e51b81526004016104f390612008565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ebb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610edf919061204a565b6001600160a01b0381811660009081526101006020526040902054919250868116911614610f1f5760405162461bcd60e51b81526004016104f390612067565b6001600160a01b038116610f3557610f356120ab565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f7d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fa1919061204a565b6001600160a01b031614610fb757610fb76120ab565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610fe590339087906004016122ca565b6020604051808303816000875af1158015611004573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110289190612121565b6110445760405162461bcd60e51b81526004016104f39061213e565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352938416936316f19831936110cf9391169160c40161226c565b600060405180830381600087803b1580156110e957600080fd5b505af11580156110fd573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f1e0ef6131232b1090efc3ec1cf7b53aa17f4b7cd8a4f9e033b49ee237379b01333876040516111509291906122ca565b60405180910390a45050505050565b6001600160a01b0384161580159061117f57506001600160a01b03831615155b801561119357506001600160a01b03821615155b80156111a757506001600160a01b03811615155b6112045760405162461bcd60e51b815260206004820152602860248201527f4368696c644552433732315072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b60648201526084016104f3565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b6000808080611265858701876122e3565b6001600160a01b0380851660009081526101006020526040902054949850929650909450925016806112a95760405162461bcd60e51b81526004016104f390612067565b6112b281611ab8565b6112be576112be6120ab565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156112fe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611322919061204a565b9050856001600160a01b0316816001600160a01b031614611345576113456120ab565b6001600160a01b03811661135b5761135b6120ab565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113c7919061204a565b6001600160a01b0316146113dd576113dd6120ab565b6040516340c10f1960e01b81526001600160a01b038316906340c10f199061140b90879087906004016122ca565b6020604051808303816000875af115801561142a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061144e9190612121565b61146a5760405162461bcd60e51b81526004016104f390612334565b836001600160a01b0316826001600160a01b0316876001600160a01b03167f37589fd8c906c19ea68eeb7e6b3e03efc06ff8aa4b1830588eba75f4375b161188876040516114b99291906122ca565b60405180910390a45050505050505050565b60008080806114dc85870187612449565b6001600160a01b03808516600090815261010060205260409020549499509297509095509350169050806115225760405162461bcd60e51b81526004016104f390612067565b61152b81611ab8565b611537576115376120ab565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015611577573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061159b919061204a565b9050856001600160a01b0316816001600160a01b0316146115be576115be6120ab565b6001600160a01b0381166115d4576115d46120ab565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561161c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611640919061204a565b6001600160a01b031614611656576116566120ab565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d990611684908790879060040161253b565b6020604051808303816000875af11580156116a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116c79190612121565b6116e35760405162461bcd60e51b81526004016104f390612334565b846001600160a01b0316826001600160a01b0316876001600160a01b03167fc1b1a5c1b97cc8e5ac82b47496f5ebdadf9c7d119b30a116e2bdafd56f6ed47587876040516114b992919061253b565b600080806117428486018661262e565b91955093509150506001600160a01b038316611760576117606120ab565b6001600160a01b03838116600090815261010060205260409020541615611789576117896120ab565b60ff546040516bffffffffffffffffffffffff19606086901b1660208201526000916117d9916001600160a01b039091169060340160405160208183030381529060405280519060200120611b9f565b6001600160a01b03858116600090815261010060205260409081902080546001600160a01b031916928416928317905551639065714760e01b815291925090639065714790611830908790879087906004016126ad565b600060405180830381600087803b15801561184a57600080fd5b505af115801561185e573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a3505050505050565b60c95460ff16156119ad57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161190491906126ed565b6000604051808303818686fa925050503d8060008114611940576040519150601f19603f3d011682016040523d82523d6000602084013e611945565b606091505b509150915081801561196a57506000818060200190518101906119689190612709565b115b6119aa5760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016104f3565b50505b60c954610100900460ff161561048757604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b019161138891611a1491906126ed565b6000604051808303818686fa925050503d8060008114611a50576040519150601f19603f3d011682016040523d82523d6000602084013e611a55565b606091505b5091509150818015611a7b575080806020019051810190611a769190612709565b600114155b6109795760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016104f3565b6000816001600160a01b03163b600003611ad457506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611b3b575060408051601f3d908101601f19168201909252611b3891810190612121565b60015b611b4757506000919050565b92915050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116611b475760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016104f3565b6001600160a01b038116811461050557600080fd5b60008083601f840112611c5d57600080fd5b5081356001600160401b03811115611c7457600080fd5b6020830191508360208260051b8501011115611c8f57600080fd5b9250929050565b600080600080600060608688031215611cae57600080fd5b8535611cb981611c36565b945060208601356001600160401b0380821115611cd557600080fd5b611ce189838a01611c4b565b90965094506040880135915080821115611cfa57600080fd5b50611d0788828901611c4b565b969995985093965092949392505050565b600060208284031215611d2a57600080fd5b8135611d3581611c36565b9392505050565b801515811461050557600080fd5b600060208284031215611d5c57600080fd5b8135611d3581611d3c565b600080600060608486031215611d7c57600080fd5b8335611d8781611c36565b92506020840135611d9781611c36565b929592945050506040919091013590565b600080600080600080600060e0888a031215611dc357600080fd5b8735611dce81611c36565b96506020880135611dde81611c36565b95506040880135611dee81611c36565b94506060880135611dfe81611c36565b93506080880135611e0e81611d3c565b925060a0880135611e1e81611d3c565b915060c0880135611e2e81611c36565b8091505092959891949750929550565b60008060008060608587031215611e5457600080fd5b843593506020850135611e6681611c36565b925060408501356001600160401b0380821115611e8257600080fd5b818701915087601f830112611e9657600080fd5b813581811115611ea557600080fd5b886020828501011115611eb757600080fd5b95989497505060200194505050565b60008060408385031215611ed957600080fd5b8235611ee481611c36565b946020939093013593505050565b60008060008060808587031215611f0857600080fd5b8435611f1381611c36565b93506020850135611f2381611c36565b92506040850135611f3381611c36565b91506060850135611f4381611c36565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611fd057600080fd5b83861115611fdd57600080fd5b5050820193919092039150565b80356020831015611b4757600019602084900360031b1b1692915050565b60208082526022908201527f4368696c644552433732315072656469636174653a204e4f545f434f4e54524160408201526110d560f21b606082015260800190565b60006020828403121561205c57600080fd5b8151611d3581611c36565b60208082526024908201527f4368696c644552433732315072656469636174653a20554e4d41505045445f5460408201526327a5a2a760e11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156120da57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038416815260406020820181905260009061211890830184866120c1565b95945050505050565b60006020828403121561213357600080fd5b8151611d3581611d3c565b60208082526021908201527f4368696c644552433732315072656469636174653a204255524e5f4641494c456040820152601160fa1b606082015260800190565b8183526000602080850194508260005b858110156121bd5781356121a281611c36565b6001600160a01b03168752958201959082019060010161218f565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906121fb908301868861217f565b828103608084015261220e8185876120c1565b9a9950505050505050505050565b60005b8381101561223757818101518382015260200161221f565b50506000910152565b6000815180845261225881602086016020860161221c565b601f01601f19169290920160200192915050565b6001600160a01b038316815260406020820181905260009061229090830184612240565b949350505050565b6040815260006122ac60408301868861217f565b82810360208401526122bf8185876120c1565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b600080600080608085870312156122f957600080fd5b843561230481611c36565b9350602085013561231481611c36565b9250604085013561232481611c36565b9396929550929360600135925050565b60208082526021908201527f4368696c644552433732315072656469636174653a204d494e545f4641494c456040820152601160fa1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156123b3576123b3612375565b604052919050565b60006001600160401b038211156123d4576123d4612375565b5060051b60200190565b600082601f8301126123ef57600080fd5b813560206124046123ff836123bb565b61238b565b82815260059290921b8401810191818101908684111561242357600080fd5b8286015b8481101561243e5780358352918301918301612427565b509695505050505050565b600080600080600060a0868803121561246157600080fd5b8535945060208087013561247481611c36565b9450604087013561248481611c36565b935060608701356001600160401b03808211156124a057600080fd5b818901915089601f8301126124b457600080fd5b81356124c26123ff826123bb565b81815260059190911b8301840190848101908c8311156124e157600080fd5b938501935b828510156125085784356124f981611c36565b825293850193908501906124e6565b96505050608089013592508083111561252057600080fd5b505061252e888289016123de565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b8281101561257d5781516001600160a01b031684529284019290840190600101612558565b5050508381038285015284518082528583019183019060005b818110156125b257835183529284019291840191600101612596565b5090979650505050505050565b600082601f8301126125d057600080fd5b81356001600160401b038111156125e9576125e9612375565b6125fc601f8201601f191660200161238b565b81815284602083860101111561261157600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000806080858703121561264457600080fd5b84359350602085013561265681611c36565b925060408501356001600160401b038082111561267257600080fd5b61267e888389016125bf565b9350606087013591508082111561269457600080fd5b506126a1878288016125bf565b91505092959194509250565b6001600160a01b03841681526060602082018190526000906126d190830185612240565b82810360408401526126e38185612240565b9695505050505050565b600082516126ff81846020870161221c565b9190910192915050565b60006020828403121561271b57600080fd5b505191905056fea26469706673582212209fb96730231af9e41bf678810325933de9ae73b8e3281f6ee32437340a3b952d64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var RootMintableERC721PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC721Predicate","sourceName":"contracts/blade/RootMintableERC721Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2MintableERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2MintableERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2MintableERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2MintableERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611a8f806100206000396000f3fe608060405234801561001057600080fd5b506004361061016e5760003560e01c806397e5230d116100ce578063e0563ab111610087578063e0563ab114610353578063eeb499451461035c578063f213159c1461036f578063f4a120f714610382578063f645125514610395578063f8c8765e146103bc578063ff6f870c146103cf57600080fd5b806397e5230d1461029a578063b1768065146102a4578063b68ad1e4146102cb578063c5ac2b1c146102de578063d41f177114610305578063d7c9e3ec1461032c57600080fd5b806347e7ef241161012b57806347e7ef241461020d5780634fdca69d1461022257806351351d531461023557806355b01e4d146102435780635ea5df79146102515780637efab4f514610268578063947287cf1461029157600080fd5b806305dc2e8f1461017357806307b3e252146101a3578063150b7a02146101b15780631bc114ba146101e8578063284017f5146101fb5780633b878c2214610204575b600080fd5b603454610186906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101866004600360981b0181565b6101cf6101bf366004611231565b630a85bd0160e11b949350505050565b6040516001600160e01b0319909116815260200161019a565b603354610186906001600160a01b031681565b61018661202081565b61018661101081565b61022061021b3660046112df565b6103e2565b005b603554610186906001600160a01b031681565b6101866002600160a01b0381565b6101866004600160991b0181565b61025a61138881565b60405190815260200161019a565b61018661027636600461130b565b6037602052600090815260409020546001600160a01b031681565b61025a61520881565b61025a620249f081565b61025a7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b603654610186906001600160a01b031681565b61025a7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b61025a7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61025a7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61018661203081565b61022061036a36600461132f565b6103f1565b61022061037d3660046113b7565b6105d1565b61018661039036600461130b565b6105e1565b61025a7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102206103ca3660046113f8565b61093a565b6102206103dd36600461149f565b610a97565b6103ed823383610af5565b5050565b6034546001600160a01b031633146104695760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b60648201526084015b60405180910390fd5b6035546001600160a01b038481169116146104e05760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c604482015270595f4348494c445f50524544494341544560781b6064820152608401610460565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961050f602060008486611521565b6105189161154b565b036105375761053261052d8260208186611521565b610c74565b6105cb565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed2610566602060008486611521565b61056f9161154b565b0361057e576105328282610d72565b60405162461bcd60e51b815260206004820152602e6024820152600080516020611a3a83398151915260448201526d414c49445f5349474e415455524560901b6064820152608401610460565b50505050565b6105dc838383610af5565b505050565b60006001600160a01b03821661063a5760405162461bcd60e51b815260206004820152602a6024820152600080516020611a3a83398151915260448201526920a624a22faa27a5a2a760b11b6064820152608401610460565b6001600160a01b0382811660009081526037602052604090205416156106b65760405162461bcd60e51b815260206004820152602b60248201527f526f6f744d696e7461626c654552433732315072656469636174653a20414c5260448201526a1150511657d3505414115160aa1b6064820152608401610460565b6035546036546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261076492911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0385811660008181526037602052604080822080546001600160a01b03191686861617905560335481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa1580156107fc573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610824919081019061158e565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610862573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261088a919081019061158e565b60405160200161089d9493929190611630565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108c9929190611677565b600060405180830381600087803b1580156108e357600080fd5b505af11580156108f7573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b031461097e5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610460565b600054610100900460ff161580801561099e5750600054600160ff909116105b806109b85750303b1580156109b8575060005460ff166001145b610a1b5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610460565b6000805460ff191660011790558015610a3e576000805461ff0019166101001790555b610a4a85858585610eb3565b8015610a90576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610ae85760405162461bcd60e51b815260206004820152602b6024820152600080516020611a3a83398151915260448201526a082989288be988a9c8ea8960ab1b6064820152608401610460565b610a908585858585610faf565b6000610b0084611165565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610b33903390309087906004016116a3565b600060405180830381600087803b158015610b4d57600080fd5b505af1158015610b61573d6000803e3d6000fd5b5050603354603554604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935293841695506316f198319450610bf1939092169160c401611677565b600060405180830381600087803b158015610c0b57600080fd5b505af1158015610c1f573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917fe3abb9ec195b50242582cc6cb7abc990ac26439b9ed7635ed72f7bd720e7477a910160405180910390a46105cb565b6000808080610c85858701876116c7565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610cb857610cb8611718565b604051632142170760e11b81526001600160a01b038616906342842e0e90610ce8903090879087906004016116a3565b600060405180830381600087803b158015610d0257600080fd5b505af1158015610d16573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f80afffd84aa825dd9b3c1ba262eb55eef58f78616634437a367a263f3c48fe3d91015b60405180910390a450505050505050565b6000808080610d83858701876117b7565b6001600160a01b03808516600090815260376020526040902054949950929750909550935016905080610db857610db8611718565b60005b8251811015610e6357856001600160a01b03166342842e0e30868481518110610de657610de66118a9565b6020026020010151868581518110610e0057610e006118a9565b60200260200101516040518463ffffffff1660e01b8152600401610e26939291906116a3565b600060405180830381600087803b158015610e4057600080fd5b505af1158015610e54573d6000803e3d6000fd5b50505050806001019050610dbb565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167ff64537485d843fa8a1f4354cb9937954c64282de0828be9f096355006222186b8686604051610d619291906118bf565b6001600160a01b03841615801590610ed357506001600160a01b03831615155b8015610ee757506001600160a01b03821615155b8015610efb57506001600160a01b03811615155b610f5f5760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c654552433732315072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b6064820152608401610460565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000610fba86611165565b905060005b8281101561104c57866001600160a01b03166342842e0e3330878786818110610fea57610fea6118a9565b905060200201356040518463ffffffff1660e01b815260040161100f939291906116a3565b600060405180830381600087803b15801561102957600080fd5b505af115801561103d573d6000803e3d6000fd5b50505050806001019050610fbf565b506033546035546040516001600160a01b03928316926316f198319216906110a4907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c906020016119be565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016110d0929190611677565b600060405180830381600087803b1580156110ea57600080fd5b505af11580156110fe573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f0ca5d99e0f7e7651c00c76347baa68a333790cbc9fb039a10843d1bd61f578c5888888886040516111559493929190611a12565b60405180910390a4505050505050565b6001600160a01b0380821660009081526037602052604090205416806111915761118e826105e1565b90505b6001600160a01b0381166111a7576111a7611718565b919050565b6001600160a01b03811681146111c157600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611202576112026111c4565b604052919050565b60006001600160401b03821115611223576112236111c4565b50601f01601f191660200190565b6000806000806080858703121561124757600080fd5b8435611252816111ac565b93506020850135611262816111ac565b92506040850135915060608501356001600160401b0381111561128457600080fd5b8501601f8101871361129557600080fd5b80356112a86112a38261120a565b6111da565b8181528860208385010111156112bd57600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b600080604083850312156112f257600080fd5b82356112fd816111ac565b946020939093013593505050565b60006020828403121561131d57600080fd5b8135611328816111ac565b9392505050565b6000806000806060858703121561134557600080fd5b843593506020850135611357816111ac565b925060408501356001600160401b038082111561137357600080fd5b818701915087601f83011261138757600080fd5b81358181111561139657600080fd5b8860208285010111156113a857600080fd5b95989497505060200194505050565b6000806000606084860312156113cc57600080fd5b83356113d7816111ac565b925060208401356113e7816111ac565b929592945050506040919091013590565b6000806000806080858703121561140e57600080fd5b8435611419816111ac565b93506020850135611429816111ac565b92506040850135611439816111ac565b91506060850135611449816111ac565b939692955090935050565b60008083601f84011261146657600080fd5b5081356001600160401b0381111561147d57600080fd5b6020830191508360208260051b850101111561149857600080fd5b9250929050565b6000806000806000606086880312156114b757600080fd5b85356114c2816111ac565b945060208601356001600160401b03808211156114de57600080fd5b6114ea89838a01611454565b9096509450604088013591508082111561150357600080fd5b5061151088828901611454565b969995985093965092949392505050565b6000808585111561153157600080fd5b8386111561153e57600080fd5b5050820193919092039150565b8035602083101561156457600019602084900360031b1b165b92915050565b60005b8381101561158557818101518382015260200161156d565b50506000910152565b6000602082840312156115a057600080fd5b81516001600160401b038111156115b657600080fd5b8201601f810184136115c757600080fd5b80516115d56112a38261120a565b8181528560208385010111156115ea57600080fd5b6115fb82602083016020860161156a565b95945050505050565b6000815180845261161c81602086016020860161156a565b601f01601f19169290920160200192915050565b8481526001600160a01b038416602082015260806040820181905260009061165a90830185611604565b828103606084015261166c8185611604565b979650505050505050565b6001600160a01b038316815260406020820181905260009061169b90830184611604565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600080600080608085870312156116dd57600080fd5b84356116e8816111ac565b935060208501356116f8816111ac565b92506040850135611708816111ac565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611747576117476111c4565b5060051b60200190565b600082601f83011261176257600080fd5b813560206117726112a38361172e565b82815260059290921b8401810191818101908684111561179157600080fd5b8286015b848110156117ac5780358352918301918301611795565b509695505050505050565b600080600080600060a086880312156117cf57600080fd5b853594506020808701356117e2816111ac565b945060408701356117f2816111ac565b935060608701356001600160401b038082111561180e57600080fd5b818901915089601f83011261182257600080fd5b81356118306112a38261172e565b81815260059190911b8301840190848101908c83111561184f57600080fd5b938501935b82851015611876578435611867816111ac565b82529385019390850190611854565b96505050608089013592508083111561188e57600080fd5b505061189c88828901611751565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b828110156119015781516001600160a01b0316845292840192908401906001016118dc565b5050508381038285015284518082528583019183019060005b818110156119365783518352928401929184019160010161191a565b5090979650505050505050565b8183526000602080850194508260005b85811015611981578135611966816111ac565b6001600160a01b031687529582019590820190600101611953565b509495945050505050565b81835260006001600160fb1b038311156119a557600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906119f19083018688611943565b8281036080840152611a0481858761198c565b9a9950505050505050505050565b604081526000611a26604083018688611943565b828103602084015261166c81858761198c56fe526f6f744d696e7461626c654552433732315072656469636174653a20494e56a26469706673582212200f778b972adc84d2886b623874e8c1689c290b3a1736e33161fa9cdfde1f71a964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061016e5760003560e01c806397e5230d116100ce578063e0563ab111610087578063e0563ab114610353578063eeb499451461035c578063f213159c1461036f578063f4a120f714610382578063f645125514610395578063f8c8765e146103bc578063ff6f870c146103cf57600080fd5b806397e5230d1461029a578063b1768065146102a4578063b68ad1e4146102cb578063c5ac2b1c146102de578063d41f177114610305578063d7c9e3ec1461032c57600080fd5b806347e7ef241161012b57806347e7ef241461020d5780634fdca69d1461022257806351351d531461023557806355b01e4d146102435780635ea5df79146102515780637efab4f514610268578063947287cf1461029157600080fd5b806305dc2e8f1461017357806307b3e252146101a3578063150b7a02146101b15780631bc114ba146101e8578063284017f5146101fb5780633b878c2214610204575b600080fd5b603454610186906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101866004600360981b0181565b6101cf6101bf366004611231565b630a85bd0160e11b949350505050565b6040516001600160e01b0319909116815260200161019a565b603354610186906001600160a01b031681565b61018661202081565b61018661101081565b61022061021b3660046112df565b6103e2565b005b603554610186906001600160a01b031681565b6101866002600160a01b0381565b6101866004600160991b0181565b61025a61138881565b60405190815260200161019a565b61018661027636600461130b565b6037602052600090815260409020546001600160a01b031681565b61025a61520881565b61025a620249f081565b61025a7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b603654610186906001600160a01b031681565b61025a7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b61025a7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61025a7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61018661203081565b61022061036a36600461132f565b6103f1565b61022061037d3660046113b7565b6105d1565b61018661039036600461130b565b6105e1565b61025a7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102206103ca3660046113f8565b61093a565b6102206103dd36600461149f565b610a97565b6103ed823383610af5565b5050565b6034546001600160a01b031633146104695760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b60648201526084015b60405180910390fd5b6035546001600160a01b038481169116146104e05760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c604482015270595f4348494c445f50524544494341544560781b6064820152608401610460565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961050f602060008486611521565b6105189161154b565b036105375761053261052d8260208186611521565b610c74565b6105cb565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed2610566602060008486611521565b61056f9161154b565b0361057e576105328282610d72565b60405162461bcd60e51b815260206004820152602e6024820152600080516020611a3a83398151915260448201526d414c49445f5349474e415455524560901b6064820152608401610460565b50505050565b6105dc838383610af5565b505050565b60006001600160a01b03821661063a5760405162461bcd60e51b815260206004820152602a6024820152600080516020611a3a83398151915260448201526920a624a22faa27a5a2a760b11b6064820152608401610460565b6001600160a01b0382811660009081526037602052604090205416156106b65760405162461bcd60e51b815260206004820152602b60248201527f526f6f744d696e7461626c654552433732315072656469636174653a20414c5260448201526a1150511657d3505414115160aa1b6064820152608401610460565b6035546036546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261076492911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0385811660008181526037602052604080822080546001600160a01b03191686861617905560335481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa1580156107fc573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610824919081019061158e565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610862573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261088a919081019061158e565b60405160200161089d9493929190611630565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108c9929190611677565b600060405180830381600087803b1580156108e357600080fd5b505af11580156108f7573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b031461097e5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610460565b600054610100900460ff161580801561099e5750600054600160ff909116105b806109b85750303b1580156109b8575060005460ff166001145b610a1b5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610460565b6000805460ff191660011790558015610a3e576000805461ff0019166101001790555b610a4a85858585610eb3565b8015610a90576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610ae85760405162461bcd60e51b815260206004820152602b6024820152600080516020611a3a83398151915260448201526a082989288be988a9c8ea8960ab1b6064820152608401610460565b610a908585858585610faf565b6000610b0084611165565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610b33903390309087906004016116a3565b600060405180830381600087803b158015610b4d57600080fd5b505af1158015610b61573d6000803e3d6000fd5b5050603354603554604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935293841695506316f198319450610bf1939092169160c401611677565b600060405180830381600087803b158015610c0b57600080fd5b505af1158015610c1f573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917fe3abb9ec195b50242582cc6cb7abc990ac26439b9ed7635ed72f7bd720e7477a910160405180910390a46105cb565b6000808080610c85858701876116c7565b6001600160a01b0380851660009081526037602052604090205494985092965090945092501680610cb857610cb8611718565b604051632142170760e11b81526001600160a01b038616906342842e0e90610ce8903090879087906004016116a3565b600060405180830381600087803b158015610d0257600080fd5b505af1158015610d16573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f80afffd84aa825dd9b3c1ba262eb55eef58f78616634437a367a263f3c48fe3d91015b60405180910390a450505050505050565b6000808080610d83858701876117b7565b6001600160a01b03808516600090815260376020526040902054949950929750909550935016905080610db857610db8611718565b60005b8251811015610e6357856001600160a01b03166342842e0e30868481518110610de657610de66118a9565b6020026020010151868581518110610e0057610e006118a9565b60200260200101516040518463ffffffff1660e01b8152600401610e26939291906116a3565b600060405180830381600087803b158015610e4057600080fd5b505af1158015610e54573d6000803e3d6000fd5b50505050806001019050610dbb565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167ff64537485d843fa8a1f4354cb9937954c64282de0828be9f096355006222186b8686604051610d619291906118bf565b6001600160a01b03841615801590610ed357506001600160a01b03831615155b8015610ee757506001600160a01b03821615155b8015610efb57506001600160a01b03811615155b610f5f5760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c654552433732315072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b6064820152608401610460565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000610fba86611165565b905060005b8281101561104c57866001600160a01b03166342842e0e3330878786818110610fea57610fea6118a9565b905060200201356040518463ffffffff1660e01b815260040161100f939291906116a3565b600060405180830381600087803b15801561102957600080fd5b505af115801561103d573d6000803e3d6000fd5b50505050806001019050610fbf565b506033546035546040516001600160a01b03928316926316f198319216906110a4907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c906020016119be565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016110d0929190611677565b600060405180830381600087803b1580156110ea57600080fd5b505af11580156110fe573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f0ca5d99e0f7e7651c00c76347baa68a333790cbc9fb039a10843d1bd61f578c5888888886040516111559493929190611a12565b60405180910390a4505050505050565b6001600160a01b0380821660009081526037602052604090205416806111915761118e826105e1565b90505b6001600160a01b0381166111a7576111a7611718565b919050565b6001600160a01b03811681146111c157600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611202576112026111c4565b604052919050565b60006001600160401b03821115611223576112236111c4565b50601f01601f191660200190565b6000806000806080858703121561124757600080fd5b8435611252816111ac565b93506020850135611262816111ac565b92506040850135915060608501356001600160401b0381111561128457600080fd5b8501601f8101871361129557600080fd5b80356112a86112a38261120a565b6111da565b8181528860208385010111156112bd57600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b600080604083850312156112f257600080fd5b82356112fd816111ac565b946020939093013593505050565b60006020828403121561131d57600080fd5b8135611328816111ac565b9392505050565b6000806000806060858703121561134557600080fd5b843593506020850135611357816111ac565b925060408501356001600160401b038082111561137357600080fd5b818701915087601f83011261138757600080fd5b81358181111561139657600080fd5b8860208285010111156113a857600080fd5b95989497505060200194505050565b6000806000606084860312156113cc57600080fd5b83356113d7816111ac565b925060208401356113e7816111ac565b929592945050506040919091013590565b6000806000806080858703121561140e57600080fd5b8435611419816111ac565b93506020850135611429816111ac565b92506040850135611439816111ac565b91506060850135611449816111ac565b939692955090935050565b60008083601f84011261146657600080fd5b5081356001600160401b0381111561147d57600080fd5b6020830191508360208260051b850101111561149857600080fd5b9250929050565b6000806000806000606086880312156114b757600080fd5b85356114c2816111ac565b945060208601356001600160401b03808211156114de57600080fd5b6114ea89838a01611454565b9096509450604088013591508082111561150357600080fd5b5061151088828901611454565b969995985093965092949392505050565b6000808585111561153157600080fd5b8386111561153e57600080fd5b5050820193919092039150565b8035602083101561156457600019602084900360031b1b165b92915050565b60005b8381101561158557818101518382015260200161156d565b50506000910152565b6000602082840312156115a057600080fd5b81516001600160401b038111156115b657600080fd5b8201601f810184136115c757600080fd5b80516115d56112a38261120a565b8181528560208385010111156115ea57600080fd5b6115fb82602083016020860161156a565b95945050505050565b6000815180845261161c81602086016020860161156a565b601f01601f19169290920160200192915050565b8481526001600160a01b038416602082015260806040820181905260009061165a90830185611604565b828103606084015261166c8185611604565b979650505050505050565b6001600160a01b038316815260406020820181905260009061169b90830184611604565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600080600080608085870312156116dd57600080fd5b84356116e8816111ac565b935060208501356116f8816111ac565b92506040850135611708816111ac565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611747576117476111c4565b5060051b60200190565b600082601f83011261176257600080fd5b813560206117726112a38361172e565b82815260059290921b8401810191818101908684111561179157600080fd5b8286015b848110156117ac5780358352918301918301611795565b509695505050505050565b600080600080600060a086880312156117cf57600080fd5b853594506020808701356117e2816111ac565b945060408701356117f2816111ac565b935060608701356001600160401b038082111561180e57600080fd5b818901915089601f83011261182257600080fd5b81356118306112a38261172e565b81815260059190911b8301840190848101908c83111561184f57600080fd5b938501935b82851015611876578435611867816111ac565b82529385019390850190611854565b96505050608089013592508083111561188e57600080fd5b505061189c88828901611751565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b828110156119015781516001600160a01b0316845292840192908401906001016118dc565b5050508381038285015284518082528583019183019060005b818110156119365783518352928401929184019160010161191a565b5090979650505050505050565b8183526000602080850194508260005b85811015611981578135611966816111ac565b6001600160a01b031687529582019590820190600101611953565b509495945050505050565b81835260006001600160fb1b038311156119a557600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906119f19083018688611943565b8281036080840152611a0481858761198c565b9a9950505050505050505050565b604081526000611a26604083018688611943565b828103602084015261166c81858761198c56fe526f6f744d696e7461626c654552433732315072656469636174653a20494e56a26469706673582212200f778b972adc84d2886b623874e8c1689c290b3a1736e33161fa9cdfde1f71a964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var RootMintableERC721PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC721PredicateAccessList","sourceName":"contracts/blade/RootMintableERC721PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2MintableERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2MintableERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"L2MintableERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"L2MintableERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612231806100206000396000f3fe608060405234801561001057600080fd5b50600436106101e65760003560e01c8063b17680651161010a578063e0563ab1116100ad578063f2fde38b1161007c578063f2fde38b14610466578063f4a120f714610479578063f64512551461048c578063f8c8765e146104b3578063ff6f870c146104c657600080fd5b8063e0563ab114610426578063e30c39781461042f578063eeb4994514610440578063f213159c1461045357600080fd5b8063b17680651461033e578063b68ad1e414610365578063c1225a2014610378578063c5ac2b1c1461038b578063c5e4683a146103b2578063d41f1771146103c5578063d7c9e3ec146103ec578063d8dd17731461041357600080fd5b806351351d531161018d57806379ba50971161015c57806379ba5097146102e85780637efab4f5146102f05780638da5cb5b1461031a578063947287cf1461032b57806397e5230d1461033457600080fd5b806351351d53146102ad57806355b01e4d146102bb5780635ea5df79146102c9578063715018a6146102e057600080fd5b806305dc2e8f146101eb57806307b3e2521461021b578063150b7a02146102295780631bc114ba14610260578063284017f5146102735780633b878c221461027c57806347e7ef24146102855780634fdca69d1461029a575b600080fd5b60fd546101fe906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101fe6004600360981b0181565b61024761023736600461186f565b630a85bd0160e11b949350505050565b6040516001600160e01b03199091168152602001610212565b60fc546101fe906001600160a01b031681565b6101fe61202081565b6101fe61101081565b61029861029336600461191d565b6104d9565b005b60fe546101fe906001600160a01b031681565b6101fe6002600160a01b0381565b6101fe6004600160991b0181565b6102d261138881565b604051908152602001610212565b6102986104e8565b6102986104fc565b6101fe6102fe366004611949565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101fe565b6102d261520881565b6102d2620249f081565b6102d27f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101fe906001600160a01b031681565b61029861038636600461197d565b61057b565b6102d27faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6102986103c036600461197d565b6105ca565b6102d27f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102d27f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b610298610421366004611998565b610611565b6101fe61203081565b6065546001600160a01b03166101fe565b61029861044e366004611a2a565b610732565b610298610461366004611ab2565b61090d565b610298610474366004611949565b61091d565b6101fe610487366004611949565b61098e565b6102d27f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102986104c1366004611af3565b610ce9565b6102986104d4366004611b9a565b610de2565b6104e4823383610e40565b5050565b6104f0610fc7565b6104fa6000611021565b565b60655433906001600160a01b0316811461056f5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61057881611021565b50565b610583610fc7565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6105d2610fc7565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146106385760405163973d02cb60e01b815260040161056690611c1c565b600054610100900460ff16158080156106585750600054600160ff909116105b806106725750303b158015610672575060005460ff166001145b61068e5760405162461bcd60e51b815260040161056690611c40565b6000805460ff1916600117905580156106b1576000805461ff0019166101001790555b6106bd8888888861103a565b60c9805461ffff191685151561ff00191617610100851515021790556106e282611021565b8015610728576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107a55760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b6064820152608401610566565b60fe546001600160a01b0384811691161461081c5760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c604482015270595f4348494c445f50524544494341544560781b6064820152608401610566565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961084b602060008486611c8e565b61085491611cb8565b036108735761086e6108698260208186611c8e565b611136565b610907565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26108a2602060008486611c8e565b6108ab91611cb8565b036108ba5761086e8282611235565b60405162461bcd60e51b815260206004820152602e60248201526000805160206121dc83398151915260448201526d414c49445f5349474e415455524560901b6064820152608401610566565b50505050565b610918838383610e40565b505050565b610925610fc7565b606580546001600160a01b0383166001600160a01b031990911681179091556109566033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b0382166109e75760405162461bcd60e51b815260206004820152602a60248201526000805160206121dc83398151915260448201526920a624a22faa27a5a2a760b11b6064820152608401610566565b6001600160a01b03828116600090815261010060205260409020541615610a645760405162461bcd60e51b815260206004820152602b60248201527f526f6f744d696e7461626c654552433732315072656469636174653a20414c5260448201526a1150511657d3505414115160aa1b6064820152608401610566565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692600092610b1292911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b038581166000818152610100602052604080822080546001600160a01b03191686861617905560fc5481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610bab573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610bd39190810190611cfb565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610c11573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610c399190810190611cfb565b604051602001610c4c9493929190611d9d565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610c78929190611de4565b600060405180830381600087803b158015610c9257600080fd5b505af1158015610ca6573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b0314610d105760405163973d02cb60e01b815260040161056690611c1c565b600054610100900460ff1615808015610d305750600054600160ff909116105b80610d4a5750303b158015610d4a575060005460ff166001145b610d665760405162461bcd60e51b815260040161056690611c40565b6000805460ff191660011790558015610d89576000805461ff0019166101001790555b610d958585858561103a565b8015610ddb576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610e335760405162461bcd60e51b815260206004820152602b60248201526000805160206121dc83398151915260448201526a082989288be988a9c8ea8960ab1b6064820152608401610566565b610ddb8585858585611377565b610e48611535565b6000610e538461153d565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610e8690339030908790600401611e10565b600060405180830381600087803b158015610ea057600080fd5b505af1158015610eb4573d6000803e3d6000fd5b505060fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935293841695506316f198319450610f44939092169160c401611de4565b600060405180830381600087803b158015610f5e57600080fd5b505af1158015610f72573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917fe3abb9ec195b50242582cc6cb7abc990ac26439b9ed7635ed72f7bd720e7477a910160405180910390a4610907565b6033546001600160a01b031633146104fa5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610566565b606580546001600160a01b031916905561057881611585565b6001600160a01b0384161580159061105a57506001600160a01b03831615155b801561106e57506001600160a01b03821615155b801561108257506001600160a01b03811615155b6110e65760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c654552433732315072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b6064820152608401610566565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b600080808061114785870187611e34565b6001600160a01b03808516600090815261010060205260409020549498509296509094509250168061117b5761117b611e85565b604051632142170760e11b81526001600160a01b038616906342842e0e906111ab90309087908790600401611e10565b600060405180830381600087803b1580156111c557600080fd5b505af11580156111d9573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f80afffd84aa825dd9b3c1ba262eb55eef58f78616634437a367a263f3c48fe3d91015b60405180910390a450505050505050565b600080808061124685870187611f24565b6001600160a01b038085166000908152610100602052604090205494995092975090955093501690508061127c5761127c611e85565b60005b825181101561132757856001600160a01b03166342842e0e308684815181106112aa576112aa612016565b60200260200101518685815181106112c4576112c4612016565b60200260200101516040518463ffffffff1660e01b81526004016112ea93929190611e10565b600060405180830381600087803b15801561130457600080fd5b505af1158015611318573d6000803e3d6000fd5b5050505080600101905061127f565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167ff64537485d843fa8a1f4354cb9937954c64282de0828be9f096355006222186b868660405161122492919061202c565b61137f611535565b600061138a8661153d565b905060005b8281101561141c57866001600160a01b03166342842e0e33308787868181106113ba576113ba612016565b905060200201356040518463ffffffff1660e01b81526004016113df93929190611e10565b600060405180830381600087803b1580156113f957600080fd5b505af115801561140d573d6000803e3d6000fd5b5050505080600101905061138f565b5060fc5460fe546040516001600160a01b03928316926316f19831921690611474907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c9060200161212b565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016114a0929190611de4565b600060405180830381600087803b1580156114ba57600080fd5b505af11580156114ce573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f0ca5d99e0f7e7651c00c76347baa68a333790cbc9fb039a10843d1bd61f578c588888888604051611525949392919061217f565b60405180910390a4505050505050565b6104fa6115d7565b6001600160a01b0380821660009081526101006020526040902054168061156a576115678261098e565b90505b6001600160a01b03811661158057611580611e85565b919050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff16156116e257604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161163991906121a6565b6000604051808303818686fa925050503d8060008114611675576040519150601f19603f3d011682016040523d82523d6000602084013e61167a565b606091505b509150915081801561169f575060008180602001905181019061169d91906121c2565b115b6116df5760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b6044820152606401610566565b50505b60c954610100900460ff16156104fa57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161174991906121a6565b6000604051808303818686fa925050503d8060008114611785576040519150601f19603f3d011682016040523d82523d6000602084013e61178a565b606091505b50915091508180156117b05750808060200190518101906117ab91906121c2565b600114155b6104e45760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b6044820152606401610566565b6001600160a01b038116811461057857600080fd5b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171561184057611840611802565b604052919050565b60006001600160401b0382111561186157611861611802565b50601f01601f191660200190565b6000806000806080858703121561188557600080fd5b8435611890816117ed565b935060208501356118a0816117ed565b92506040850135915060608501356001600160401b038111156118c257600080fd5b8501601f810187136118d357600080fd5b80356118e66118e182611848565b611818565b8181528860208385010111156118fb57600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b6000806040838503121561193057600080fd5b823561193b816117ed565b946020939093013593505050565b60006020828403121561195b57600080fd5b8135611966816117ed565b9392505050565b8035801515811461158057600080fd5b60006020828403121561198f57600080fd5b6119668261196d565b600080600080600080600060e0888a0312156119b357600080fd5b87356119be816117ed565b965060208801356119ce816117ed565b955060408801356119de816117ed565b945060608801356119ee816117ed565b93506119fc6080890161196d565b9250611a0a60a0890161196d565b915060c0880135611a1a816117ed565b8091505092959891949750929550565b60008060008060608587031215611a4057600080fd5b843593506020850135611a52816117ed565b925060408501356001600160401b0380821115611a6e57600080fd5b818701915087601f830112611a8257600080fd5b813581811115611a9157600080fd5b886020828501011115611aa357600080fd5b95989497505060200194505050565b600080600060608486031215611ac757600080fd5b8335611ad2816117ed565b92506020840135611ae2816117ed565b929592945050506040919091013590565b60008060008060808587031215611b0957600080fd5b8435611b14816117ed565b93506020850135611b24816117ed565b92506040850135611b34816117ed565b91506060850135611b44816117ed565b939692955090935050565b60008083601f840112611b6157600080fd5b5081356001600160401b03811115611b7857600080fd5b6020830191508360208260051b8501011115611b9357600080fd5b9250929050565b600080600080600060608688031215611bb257600080fd5b8535611bbd816117ed565b945060208601356001600160401b0380821115611bd957600080fd5b611be589838a01611b4f565b90965094506040880135915080821115611bfe57600080fd5b50611c0b88828901611b4f565b969995985093965092949392505050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611c9e57600080fd5b83861115611cab57600080fd5b5050820193919092039150565b80356020831015611cd157600019602084900360031b1b165b92915050565b60005b83811015611cf2578181015183820152602001611cda565b50506000910152565b600060208284031215611d0d57600080fd5b81516001600160401b03811115611d2357600080fd5b8201601f81018413611d3457600080fd5b8051611d426118e182611848565b818152856020838501011115611d5757600080fd5b611d68826020830160208601611cd7565b95945050505050565b60008151808452611d89816020860160208601611cd7565b601f01601f19169290920160200192915050565b8481526001600160a01b0384166020820152608060408201819052600090611dc790830185611d71565b8281036060840152611dd98185611d71565b979650505050505050565b6001600160a01b0383168152604060208201819052600090611e0890830184611d71565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008060008060808587031215611e4a57600080fd5b8435611e55816117ed565b93506020850135611e65816117ed565b92506040850135611e75816117ed565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611eb457611eb4611802565b5060051b60200190565b600082601f830112611ecf57600080fd5b81356020611edf6118e183611e9b565b82815260059290921b84018101918181019086841115611efe57600080fd5b8286015b84811015611f195780358352918301918301611f02565b509695505050505050565b600080600080600060a08688031215611f3c57600080fd5b85359450602080870135611f4f816117ed565b94506040870135611f5f816117ed565b935060608701356001600160401b0380821115611f7b57600080fd5b818901915089601f830112611f8f57600080fd5b8135611f9d6118e182611e9b565b81815260059190911b8301840190848101908c831115611fbc57600080fd5b938501935b82851015611fe3578435611fd4816117ed565b82529385019390850190611fc1565b965050506080890135925080831115611ffb57600080fd5b505061200988828901611ebe565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b8281101561206e5781516001600160a01b031684529284019290840190600101612049565b5050508381038285015284518082528583019183019060005b818110156120a357835183529284019291840191600101612087565b5090979650505050505050565b8183526000602080850194508260005b858110156120ee5781356120d3816117ed565b6001600160a01b0316875295820195908201906001016120c0565b509495945050505050565b81835260006001600160fb1b0383111561211257600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a06060820181905260009061215e90830186886120b0565b82810360808401526121718185876120f9565b9a9950505050505050505050565b6040815260006121936040830186886120b0565b8281036020840152611dd98185876120f9565b600082516121b8818460208701611cd7565b9190910192915050565b6000602082840312156121d457600080fd5b505191905056fe526f6f744d696e7461626c654552433732315072656469636174653a20494e56a2646970667358221220e8888c77d125cc5e5492b1feebf8c10b660690c7f3cd639566a0966527f713c164736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101e65760003560e01c8063b17680651161010a578063e0563ab1116100ad578063f2fde38b1161007c578063f2fde38b14610466578063f4a120f714610479578063f64512551461048c578063f8c8765e146104b3578063ff6f870c146104c657600080fd5b8063e0563ab114610426578063e30c39781461042f578063eeb4994514610440578063f213159c1461045357600080fd5b8063b17680651461033e578063b68ad1e414610365578063c1225a2014610378578063c5ac2b1c1461038b578063c5e4683a146103b2578063d41f1771146103c5578063d7c9e3ec146103ec578063d8dd17731461041357600080fd5b806351351d531161018d57806379ba50971161015c57806379ba5097146102e85780637efab4f5146102f05780638da5cb5b1461031a578063947287cf1461032b57806397e5230d1461033457600080fd5b806351351d53146102ad57806355b01e4d146102bb5780635ea5df79146102c9578063715018a6146102e057600080fd5b806305dc2e8f146101eb57806307b3e2521461021b578063150b7a02146102295780631bc114ba14610260578063284017f5146102735780633b878c221461027c57806347e7ef24146102855780634fdca69d1461029a575b600080fd5b60fd546101fe906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6101fe6004600360981b0181565b61024761023736600461186f565b630a85bd0160e11b949350505050565b6040516001600160e01b03199091168152602001610212565b60fc546101fe906001600160a01b031681565b6101fe61202081565b6101fe61101081565b61029861029336600461191d565b6104d9565b005b60fe546101fe906001600160a01b031681565b6101fe6002600160a01b0381565b6101fe6004600160991b0181565b6102d261138881565b604051908152602001610212565b6102986104e8565b6102986104fc565b6101fe6102fe366004611949565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b03166101fe565b6102d261520881565b6102d2620249f081565b6102d27f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff546101fe906001600160a01b031681565b61029861038636600461197d565b61057b565b6102d27faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6102986103c036600461197d565b6105ca565b6102d27f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102d27f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b610298610421366004611998565b610611565b6101fe61203081565b6065546001600160a01b03166101fe565b61029861044e366004611a2a565b610732565b610298610461366004611ab2565b61090d565b610298610474366004611949565b61091d565b6101fe610487366004611949565b61098e565b6102d27f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b6102986104c1366004611af3565b610ce9565b6102986104d4366004611b9a565b610de2565b6104e4823383610e40565b5050565b6104f0610fc7565b6104fa6000611021565b565b60655433906001600160a01b0316811461056f5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b61057881611021565b50565b610583610fc7565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b6105d2610fc7565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146106385760405163973d02cb60e01b815260040161056690611c1c565b600054610100900460ff16158080156106585750600054600160ff909116105b806106725750303b158015610672575060005460ff166001145b61068e5760405162461bcd60e51b815260040161056690611c40565b6000805460ff1916600117905580156106b1576000805461ff0019166101001790555b6106bd8888888861103a565b60c9805461ffff191685151561ff00191617610100851515021790556106e282611021565b8015610728576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107a55760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b6064820152608401610566565b60fe546001600160a01b0384811691161461081c5760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c654552433732315072656469636174653a204f4e4c604482015270595f4348494c445f50524544494341544560781b6064820152608401610566565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961084b602060008486611c8e565b61085491611cb8565b036108735761086e6108698260208186611c8e565b611136565b610907565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26108a2602060008486611c8e565b6108ab91611cb8565b036108ba5761086e8282611235565b60405162461bcd60e51b815260206004820152602e60248201526000805160206121dc83398151915260448201526d414c49445f5349474e415455524560901b6064820152608401610566565b50505050565b610918838383610e40565b505050565b610925610fc7565b606580546001600160a01b0383166001600160a01b031990911681179091556109566033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b0382166109e75760405162461bcd60e51b815260206004820152602a60248201526000805160206121dc83398151915260448201526920a624a22faa27a5a2a760b11b6064820152608401610566565b6001600160a01b03828116600090815261010060205260409020541615610a645760405162461bcd60e51b815260206004820152602b60248201527f526f6f744d696e7461626c654552433732315072656469636174653a20414c5260448201526a1150511657d3505414115160aa1b6064820152608401610566565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692600092610b1292911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b038581166000818152610100602052604080822080546001600160a01b03191686861617905560fc5481516306fdde0360e01b81529151959650909316936316f198319387937f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad938b9391926306fdde0392600480830193928290030181865afa158015610bab573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610bd39190810190611cfb565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610c11573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610c399190810190611cfb565b604051602001610c4c9493929190611d9d565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610c78929190611de4565b600060405180830381600087803b158015610c9257600080fd5b505af1158015610ca6573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a39392505050565b336002600160a01b0314610d105760405163973d02cb60e01b815260040161056690611c1c565b600054610100900460ff1615808015610d305750600054600160ff909116105b80610d4a5750303b158015610d4a575060005460ff166001145b610d665760405162461bcd60e51b815260040161056690611c40565b6000805460ff191660011790558015610d89576000805461ff0019166101001790555b610d958585858561103a565b8015610ddb576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610e335760405162461bcd60e51b815260206004820152602b60248201526000805160206121dc83398151915260448201526a082989288be988a9c8ea8960ab1b6064820152608401610566565b610ddb8585858585611377565b610e48611535565b6000610e538461153d565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610e8690339030908790600401611e10565b600060405180830381600087803b158015610ea057600080fd5b505af1158015610eb4573d6000803e3d6000fd5b505060fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935293841695506316f198319450610f44939092169160c401611de4565b600060405180830381600087803b158015610f5e57600080fd5b505af1158015610f72573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917fe3abb9ec195b50242582cc6cb7abc990ac26439b9ed7635ed72f7bd720e7477a910160405180910390a4610907565b6033546001600160a01b031633146104fa5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610566565b606580546001600160a01b031916905561057881611585565b6001600160a01b0384161580159061105a57506001600160a01b03831615155b801561106e57506001600160a01b03821615155b801561108257506001600160a01b03811615155b6110e65760405162461bcd60e51b815260206004820152602f60248201527f526f6f744d696e7461626c654552433732315072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b6064820152608401610566565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b600080808061114785870187611e34565b6001600160a01b03808516600090815261010060205260409020549498509296509094509250168061117b5761117b611e85565b604051632142170760e11b81526001600160a01b038616906342842e0e906111ab90309087908790600401611e10565b600060405180830381600087803b1580156111c557600080fd5b505af11580156111d9573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f80afffd84aa825dd9b3c1ba262eb55eef58f78616634437a367a263f3c48fe3d91015b60405180910390a450505050505050565b600080808061124685870187611f24565b6001600160a01b038085166000908152610100602052604090205494995092975090955093501690508061127c5761127c611e85565b60005b825181101561132757856001600160a01b03166342842e0e308684815181106112aa576112aa612016565b60200260200101518685815181106112c4576112c4612016565b60200260200101516040518463ffffffff1660e01b81526004016112ea93929190611e10565b600060405180830381600087803b15801561130457600080fd5b505af1158015611318573d6000803e3d6000fd5b5050505080600101905061127f565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167ff64537485d843fa8a1f4354cb9937954c64282de0828be9f096355006222186b868660405161122492919061202c565b61137f611535565b600061138a8661153d565b905060005b8281101561141c57866001600160a01b03166342842e0e33308787868181106113ba576113ba612016565b905060200201356040518463ffffffff1660e01b81526004016113df93929190611e10565b600060405180830381600087803b1580156113f957600080fd5b505af115801561140d573d6000803e3d6000fd5b5050505080600101905061138f565b5060fc5460fe546040516001600160a01b03928316926316f19831921690611474907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c9060200161212b565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016114a0929190611de4565b600060405180830381600087803b1580156114ba57600080fd5b505af11580156114ce573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f0ca5d99e0f7e7651c00c76347baa68a333790cbc9fb039a10843d1bd61f578c588888888604051611525949392919061217f565b60405180910390a4505050505050565b6104fa6115d7565b6001600160a01b0380821660009081526101006020526040902054168061156a576115678261098e565b90505b6001600160a01b03811661158057611580611e85565b919050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff16156116e257604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161163991906121a6565b6000604051808303818686fa925050503d8060008114611675576040519150601f19603f3d011682016040523d82523d6000602084013e61167a565b606091505b509150915081801561169f575060008180602001905181019061169d91906121c2565b115b6116df5760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b6044820152606401610566565b50505b60c954610100900460ff16156104fa57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161174991906121a6565b6000604051808303818686fa925050503d8060008114611785576040519150601f19603f3d011682016040523d82523d6000602084013e61178a565b606091505b50915091508180156117b05750808060200190518101906117ab91906121c2565b600114155b6104e45760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b6044820152606401610566565b6001600160a01b038116811461057857600080fd5b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171561184057611840611802565b604052919050565b60006001600160401b0382111561186157611861611802565b50601f01601f191660200190565b6000806000806080858703121561188557600080fd5b8435611890816117ed565b935060208501356118a0816117ed565b92506040850135915060608501356001600160401b038111156118c257600080fd5b8501601f810187136118d357600080fd5b80356118e66118e182611848565b611818565b8181528860208385010111156118fb57600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b6000806040838503121561193057600080fd5b823561193b816117ed565b946020939093013593505050565b60006020828403121561195b57600080fd5b8135611966816117ed565b9392505050565b8035801515811461158057600080fd5b60006020828403121561198f57600080fd5b6119668261196d565b600080600080600080600060e0888a0312156119b357600080fd5b87356119be816117ed565b965060208801356119ce816117ed565b955060408801356119de816117ed565b945060608801356119ee816117ed565b93506119fc6080890161196d565b9250611a0a60a0890161196d565b915060c0880135611a1a816117ed565b8091505092959891949750929550565b60008060008060608587031215611a4057600080fd5b843593506020850135611a52816117ed565b925060408501356001600160401b0380821115611a6e57600080fd5b818701915087601f830112611a8257600080fd5b813581811115611a9157600080fd5b886020828501011115611aa357600080fd5b95989497505060200194505050565b600080600060608486031215611ac757600080fd5b8335611ad2816117ed565b92506020840135611ae2816117ed565b929592945050506040919091013590565b60008060008060808587031215611b0957600080fd5b8435611b14816117ed565b93506020850135611b24816117ed565b92506040850135611b34816117ed565b91506060850135611b44816117ed565b939692955090935050565b60008083601f840112611b6157600080fd5b5081356001600160401b03811115611b7857600080fd5b6020830191508360208260051b8501011115611b9357600080fd5b9250929050565b600080600080600060608688031215611bb257600080fd5b8535611bbd816117ed565b945060208601356001600160401b0380821115611bd957600080fd5b611be589838a01611b4f565b90965094506040880135915080821115611bfe57600080fd5b50611c0b88828901611b4f565b969995985093965092949392505050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611c9e57600080fd5b83861115611cab57600080fd5b5050820193919092039150565b80356020831015611cd157600019602084900360031b1b165b92915050565b60005b83811015611cf2578181015183820152602001611cda565b50506000910152565b600060208284031215611d0d57600080fd5b81516001600160401b03811115611d2357600080fd5b8201601f81018413611d3457600080fd5b8051611d426118e182611848565b818152856020838501011115611d5757600080fd5b611d68826020830160208601611cd7565b95945050505050565b60008151808452611d89816020860160208601611cd7565b601f01601f19169290920160200192915050565b8481526001600160a01b0384166020820152608060408201819052600090611dc790830185611d71565b8281036060840152611dd98185611d71565b979650505050505050565b6001600160a01b0383168152604060208201819052600090611e0890830184611d71565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b60008060008060808587031215611e4a57600080fd5b8435611e55816117ed565b93506020850135611e65816117ed565b92506040850135611e75816117ed565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611eb457611eb4611802565b5060051b60200190565b600082601f830112611ecf57600080fd5b81356020611edf6118e183611e9b565b82815260059290921b84018101918181019086841115611efe57600080fd5b8286015b84811015611f195780358352918301918301611f02565b509695505050505050565b600080600080600060a08688031215611f3c57600080fd5b85359450602080870135611f4f816117ed565b94506040870135611f5f816117ed565b935060608701356001600160401b0380821115611f7b57600080fd5b818901915089601f830112611f8f57600080fd5b8135611f9d6118e182611e9b565b81815260059190911b8301840190848101908c831115611fbc57600080fd5b938501935b82851015611fe3578435611fd4816117ed565b82529385019390850190611fc1565b965050506080890135925080831115611ffb57600080fd5b505061200988828901611ebe565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b8281101561206e5781516001600160a01b031684529284019290840190600101612049565b5050508381038285015284518082528583019183019060005b818110156120a357835183529284019291840191600101612087565b5090979650505050505050565b8183526000602080850194508260005b858110156120ee5781356120d3816117ed565b6001600160a01b0316875295820195908201906001016120c0565b509495945050505050565b81835260006001600160fb1b0383111561211257600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a06060820181905260009061215e90830186886120b0565b82810360808401526121718185876120f9565b9a9950505050505050505050565b6040815260006121936040830186886120b0565b8281036020840152611dd98185876120f9565b600082516121b8818460208701611cd7565b9190910192915050565b6000602082840312156121d457600080fd5b505191905056fe526f6f744d696e7461626c654552433732315072656469636174653a20494e56a2646970667358221220e8888c77d125cc5e5492b1feebf8c10b660690c7f3cd639566a0966527f713c164736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildERC1155Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC1155","sourceName":"contracts/blade/ChildERC1155.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"userAddress","type":"address"},{"indexed":false,"internalType":"address","name":"relayerAddress","type":"address"},{"indexed":false,"internalType":"bytes","name":"functionSignature","type":"bytes"}],"name":"MetaTransactionExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"TransferBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferSingle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"value","type":"string"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"URI","type":"event"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"balanceOfBatch","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"burnBatch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"userAddress","type":"address"},{"internalType":"bytes","name":"functionSignature","type":"bytes"},{"internalType":"bytes32","name":"sigR","type":"bytes32"},{"internalType":"bytes32","name":"sigS","type":"bytes32"},{"internalType":"uint8","name":"sigV","type":"uint8"}],"name":"executeMetaTransaction","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getNonce","outputs":[{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"rootToken_","type":"address"},{"internalType":"string","name":"uri_","type":"string"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"offset","type":"uint256"}],"name":"invalidateNext","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"mintBatch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rootToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeBatchTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"uri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612b8b806100206000396000f3fe608060405234801561001057600080fd5b50600436106101155760003560e01c806357128683116100a2578063e619870511610071578063e619870514610279578063e985e9c51461028b578063f242432a146102c7578063f399e22e146102da578063f5298aca146102ed57600080fd5b8063571286831461022d5780636b20c454146102405780639b77ef1114610253578063a22cb4651461026657600080fd5b8063156e29f6116100e9578063156e29f6146101965780631f2d0065146101a95780632d0335ab146101cf5780632eb2c2d6146101f85780634e1273f41461020d57600080fd5b8062fdd58e1461011a57806301ffc9a7146101405780630c53c51c146101635780630e89341c14610183575b600080fd5b61012d610128366004611cd5565b610300565b6040519081526020015b60405180910390f35b61015361014e366004611d15565b61039b565b6040519015158152602001610137565b610176610171366004611d7a565b6103eb565b6040516101379190611e49565b610176610191366004611e5c565b6106c9565b6101536101a4366004611e75565b61075d565b610103546001600160a01b03165b6040516001600160a01b039091168152602001610137565b61012d6101dd366004611ea8565b6001600160a01b031660009081526038602052604090205490565b61020b61020636600461200c565b6107b0565b005b61022061021b3660046120b5565b61080e565b60405161013791906121ba565b61015361023b366004612211565b610937565b61015361024e3660046122aa565b610a53565b61020b610261366004611e5c565b610afb565b61020b61027436600461232a565b610b22565b610102546001600160a01b03166101b7565b610153610299366004612366565b6001600160a01b03918216600090815260d16020908152604080832093909416825291909152205460ff1690565b61020b6102d5366004612399565b610b38565b61020b6102e83660046123fd565b610b8f565b6101536102fb366004611e75565b610da5565b60006001600160a01b0383166103705760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b50600081815260d0602090815260408083206001600160a01b03861684529091529020545b92915050565b60006001600160e01b03198216636cdb3d1360e11b14806103cc57506001600160e01b031982166303a24d0760e21b145b8061039557506301ffc9a760e01b6001600160e01b0319831614610395565b6060600061042e87878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610dde92505050565b90506001600160e01b03196000358116908216036104b45760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f640000006064820152608401610367565b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506105258982888888610df9565b61057b5760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b6064820152608401610367565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d6040516020016105d09392919061244f565b60408051601f19818403018152908290526105ea91612475565b6000604051808303816000865af19150503d8060008114610627576040519150601f19603f3d011682016040523d82523d6000602084013e61062c565b606091505b50915091508161067e5760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610367565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c6040516106b39493929190612491565b60405180910390a19a9950505050505050505050565b606060d280546106d8906124dd565b80601f0160208091040260200160405190810160405280929190818152602001828054610704906124dd565b80156107515780601f1061072657610100808354040283529160200191610751565b820191906000526020600020905b81548152906001019060200180831161073457829003601f168201915b50505050509050919050565b610102546000906001600160a01b0316331461078b5760405162461bcd60e51b815260040161036790612517565b6107a684848460405180602001604052806000815250610ed5565b5060019392505050565b6107b8610fe4565b6001600160a01b0316856001600160a01b031614806107de57506107de85610299610fe4565b6107fa5760405162461bcd60e51b81526004016103679061255c565b6108078585858585610ff3565b5050505050565b606081518351146108735760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610367565b600083516001600160401b0381111561088e5761088e611ec3565b6040519080825280602002602001820160405280156108b7578160200160208202803683370190505b50905060005b845181101561092f576109028582815181106108db576108db6125aa565b60200260200101518583815181106108f5576108f56125aa565b6020026020010151610300565b828281518110610914576109146125aa565b6020908102919091010152610928816125d6565b90506108bd565b509392505050565b610102546000906001600160a01b031633146109655760405162461bcd60e51b815260040161036790612517565b85848114801561097457508083145b6109c05760405162461bcd60e51b815260206004820181905260248201527f4368696c64455243313135353a206172726179206c656e206d69736d617463686044820152606401610367565b60005b81811015610a4457610a3c8989838181106109e0576109e06125aa565b90506020020160208101906109f59190611ea8565b888884818110610a0757610a076125aa565b90506020020135878785818110610a2057610a206125aa565b9050602002013560405180602001604052806000815250610ed5565b6001016109c3565b50600198975050505050505050565b610102546000906001600160a01b03163314610a815760405162461bcd60e51b815260040161036790612517565b610aef8686868080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808a0282810182019093528982529093508992508891829185019084908082843760009201919091525061119d92505050565b50600195945050505050565b3360009081526038602052604081208054839290610b1a9084906125ef565b909155505050565b610b34610b2d610fe4565b8383611334565b5050565b610b40610fe4565b6001600160a01b0316856001600160a01b03161480610b665750610b6685610299610fe4565b610b825760405162461bcd60e51b81526004016103679061255c565b6108078585858585611414565b606b54610100900460ff1615808015610baf5750606b54600160ff909116105b80610bc95750303b158015610bc95750606b5460ff166001145b610c2c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610367565b606b805460ff191660011790558015610c4f57606b805461ff0019166101001790555b6001600160a01b038416610ca55760405162461bcd60e51b815260206004820181905260248201527f4368696c64455243313135353a204241445f494e495449414c495a4154494f4e6044820152606401610367565b61010380546001600160a01b0386166001600160a01b031991821617909155610102805490911633179055604080516020601f8501819004810282018101909252838152610d0d91859085908190840183828082843760009201919091525061153b92505050565b610d59610d22856001600160a01b031661156e565b604051602001610d329190612602565b60408051601f1981840301815282820190915260018252603160f81b602083015290611584565b8015610d9f57606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050565b610102546000906001600160a01b03163314610dd35760405162461bcd60e51b815260040161036790612517565b6107a68484846115f0565b60008151600003610df157506000919050565b506020015190565b6000806001610e0f610e0a886116f0565b61176d565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa158015610e5d573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610eb45760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610367565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6001600160a01b038416610f355760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610367565b6000610f3f610fe4565b90506000610f4c8561179a565b90506000610f598561179a565b9050600086815260d0602090815260408083206001600160a01b038b16845290915281208054879290610f8d9084906125ef565b909155505060408051878152602081018790526001600160a01b03808a169260009291871691600080516020612af3833981519152910160405180910390a4610fdb836000898989896117e5565b50505050505050565b6000610fee611940565b905090565b81518351146110145760405162461bcd60e51b815260040161036790612637565b6001600160a01b03841661103a5760405162461bcd60e51b81526004016103679061267f565b6000611044610fe4565b905060005b845181101561112f576000858281518110611066576110666125aa565b602002602001015190506000858381518110611084576110846125aa565b602090810291909101810151600084815260d0835260408082206001600160a01b038e1683529093529190912054909150818110156110d55760405162461bcd60e51b8152600401610367906126c4565b600083815260d0602090815260408083206001600160a01b038e8116855292528083208585039055908b168252812080548492906111149084906125ef565b9250508190555050505080611128906125d6565b9050611049565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb878760405161117f92919061270e565b60405180910390a461119581878787878761199c565b505050505050565b6001600160a01b0383166111c35760405162461bcd60e51b81526004016103679061273c565b80518251146111e45760405162461bcd60e51b815260040161036790612637565b60006111ee610fe4565b604080516020810190915260009052905060005b83518110156112c757600084828151811061121f5761121f6125aa565b60200260200101519050600084838151811061123d5761123d6125aa565b602090810291909101810151600084815260d0835260408082206001600160a01b038c16835290935291909120549091508181101561128e5760405162461bcd60e51b81526004016103679061277f565b600092835260d0602090815260408085206001600160a01b038b16865290915290922091039055806112bf816125d6565b915050611202565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb868660405161131892919061270e565b60405180910390a4604080516020810190915260009052610d9f565b816001600160a01b0316836001600160a01b0316036113a75760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610367565b6001600160a01b03838116600081815260d16020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b03841661143a5760405162461bcd60e51b81526004016103679061267f565b6000611444610fe4565b905060006114518561179a565b9050600061145e8561179a565b9050600086815260d0602090815260408083206001600160a01b038c168452909152902054858110156114a35760405162461bcd60e51b8152600401610367906126c4565b600087815260d0602090815260408083206001600160a01b038d8116855292528083208985039055908a168252812080548892906114e29084906125ef565b909155505060408051888152602081018890526001600160a01b03808b16928c82169291881691600080516020612af3833981519152910160405180910390a4611530848a8a8a8a8a6117e5565b505050505050505050565b606b54610100900460ff166115625760405162461bcd60e51b8152600401610367906127c3565b61156b81611a57565b50565b60606103956001600160a01b0383166014611a87565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6115d2818484611c29565b600055600280546001600160a01b0319163017905560055550505050565b6001600160a01b0383166116165760405162461bcd60e51b81526004016103679061273c565b6000611620610fe4565b9050600061162d8461179a565b9050600061163a8461179a565b604080516020808201835260009182905288825260d081528282206001600160a01b038b16835290522054909150848110156116885760405162461bcd60e51b81526004016103679061277f565b600086815260d0602090815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a9052909290881691600080516020612af3833981519152910160405180910390a4604080516020810190915260009052610fdb565b6000604051806080016040528060438152602001612b136043913980516020918201208351848301516040808701518051908601209051611750950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039561177a611c72565b8360405161190160f01b8152600281019290925260228201526042902090565b604080516001808252818301909252606091600091906020808301908036833701905050905082816000815181106117d4576117d46125aa565b602090810291909101015292915050565b6001600160a01b0384163b156111955760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190611829908990899088908890889060040161280e565b6020604051808303816000875af1925050508015611864575060408051601f3d908101601f1916820190925261186191810190612853565b60015b61191057611870612870565b806308c379a0036118a9575061188461288b565b8061188f57506118ab565b8060405162461bcd60e51b81526004016103679190611e49565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e2d455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610367565b6001600160e01b0319811663f23a6e6160e01b14610fdb5760405162461bcd60e51b815260040161036790612914565b600030330361199657600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506119999050565b50335b90565b6001600160a01b0384163b156111955760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906119e0908990899088908890889060040161295c565b6020604051808303816000875af1925050508015611a1b575060408051601f3d908101601f19168201909252611a1891810190612853565b60015b611a2757611870612870565b6001600160e01b0319811663bc197c8160e01b14610fdb5760405162461bcd60e51b815260040161036790612914565b606b54610100900460ff16611a7e5760405162461bcd60e51b8152600401610367906127c3565b61156b81611cad565b60606000611a968360026129ba565b611aa19060026125ef565b6001600160401b03811115611ab857611ab8611ec3565b6040519080825280601f01601f191660200182016040528015611ae2576020820181803683370190505b509050600360fc1b81600081518110611afd57611afd6125aa565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110611b2c57611b2c6125aa565b60200101906001600160f81b031916908160001a9053506000611b508460026129ba565b611b5b9060016125ef565b90505b6001811115611bd3576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110611b8f57611b8f6125aa565b1a60f81b828281518110611ba557611ba56125aa565b60200101906001600160f81b031916908160001a90535060049490941c93611bcc816129d1565b9050611b5e565b508315611c225760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610367565b9392505050565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b6002546000906001600160a01b031630148015611c90575060015446145b15611c9c575060005490565b610fee600554600354600454611c29565b60d2610b348282612a33565b80356001600160a01b0381168114611cd057600080fd5b919050565b60008060408385031215611ce857600080fd5b611cf183611cb9565b946020939093013593505050565b6001600160e01b03198116811461156b57600080fd5b600060208284031215611d2757600080fd5b8135611c2281611cff565b60008083601f840112611d4457600080fd5b5081356001600160401b03811115611d5b57600080fd5b602083019150836020828501011115611d7357600080fd5b9250929050565b60008060008060008060a08789031215611d9357600080fd5b611d9c87611cb9565b955060208701356001600160401b03811115611db757600080fd5b611dc389828a01611d32565b9096509450506040870135925060608701359150608087013560ff81168114611deb57600080fd5b809150509295509295509295565b60005b83811015611e14578181015183820152602001611dfc565b50506000910152565b60008151808452611e35816020860160208601611df9565b601f01601f19169290920160200192915050565b602081526000611c226020830184611e1d565b600060208284031215611e6e57600080fd5b5035919050565b600080600060608486031215611e8a57600080fd5b611e9384611cb9565b95602085013595506040909401359392505050565b600060208284031215611eba57600080fd5b611c2282611cb9565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b0381118282101715611efe57611efe611ec3565b6040525050565b60006001600160401b03821115611f1e57611f1e611ec3565b5060051b60200190565b600082601f830112611f3957600080fd5b81356020611f4682611f05565b604051611f538282611ed9565b83815260059390931b8501820192828101915086841115611f7357600080fd5b8286015b84811015611f8e5780358352918301918301611f77565b509695505050505050565b600082601f830112611faa57600080fd5b81356001600160401b03811115611fc357611fc3611ec3565b604051611fda601f8301601f191660200182611ed9565b818152846020838601011115611fef57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a0868803121561202457600080fd5b61202d86611cb9565b945061203b60208701611cb9565b935060408601356001600160401b038082111561205757600080fd5b61206389838a01611f28565b9450606088013591508082111561207957600080fd5b61208589838a01611f28565b9350608088013591508082111561209b57600080fd5b506120a888828901611f99565b9150509295509295909350565b600080604083850312156120c857600080fd5b82356001600160401b03808211156120df57600080fd5b818501915085601f8301126120f357600080fd5b8135602061210082611f05565b60405161210d8282611ed9565b83815260059390931b850182019282810191508984111561212d57600080fd5b948201945b838610156121525761214386611cb9565b82529482019490820190612132565b9650508601359250508082111561216857600080fd5b5061217585828601611f28565b9150509250929050565b600081518084526020808501945080840160005b838110156121af57815187529582019590820190600101612193565b509495945050505050565b602081526000611c22602083018461217f565b60008083601f8401126121df57600080fd5b5081356001600160401b038111156121f657600080fd5b6020830191508360208260051b8501011115611d7357600080fd5b6000806000806000806060878903121561222a57600080fd5b86356001600160401b038082111561224157600080fd5b61224d8a838b016121cd565b9098509650602089013591508082111561226657600080fd5b6122728a838b016121cd565b9096509450604089013591508082111561228b57600080fd5b5061229889828a016121cd565b979a9699509497509295939492505050565b6000806000806000606086880312156122c257600080fd5b6122cb86611cb9565b945060208601356001600160401b03808211156122e757600080fd5b6122f389838a016121cd565b9096509450604088013591508082111561230c57600080fd5b50612319888289016121cd565b969995985093965092949392505050565b6000806040838503121561233d57600080fd5b61234683611cb9565b91506020830135801515811461235b57600080fd5b809150509250929050565b6000806040838503121561237957600080fd5b61238283611cb9565b915061239060208401611cb9565b90509250929050565b600080600080600060a086880312156123b157600080fd5b6123ba86611cb9565b94506123c860208701611cb9565b9350604086013592506060860135915060808601356001600160401b038111156123f157600080fd5b6120a888828901611f99565b60008060006040848603121561241257600080fd5b61241b84611cb9565b925060208401356001600160401b0381111561243657600080fd5b61244286828701611d32565b9497909650939450505050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60008251612487818460208701611df9565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b600181811c908216806124f157607f821691505b60208210810361251157634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526025908201527f4368696c64455243313135353a204f6e6c79207072656469636174652063616e6040820152640818d85b1b60da1b606082015260800190565b6020808252602e908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526d195c881bdc88185c1c1c9bdd995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016125e8576125e86125c0565b5060010190565b80820180821115610395576103956125c0565b6c4368696c64455243313135352d60981b81526000825161262a81600d850160208701611df9565b91909101600d0192915050565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b604081526000612721604083018561217f565b8281036020840152612733818561217f565b95945050505050565b60208082526023908201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260408201526265737360e81b606082015260800190565b60208082526024908201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604082015263616e636560e01b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a06080820181905260009061284890830184611e1d565b979650505050505050565b60006020828403121561286557600080fd5b8151611c2281611cff565b600060033d11156119995760046000803e5060005160e01c90565b600060443d10156128995790565b6040516003193d81016004833e81513d6001600160401b0381602484011181841117156128c857505050505090565b82850191508151818111156128e05750505050505090565b843d87010160208285010111156128fa5750505050505090565b61290960208286010187611ed9565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b0386811682528516602082015260a0604082018190526000906129889083018661217f565b828103606084015261299a818661217f565b905082810360808401526129ae8185611e1d565b98975050505050505050565b8082028115828204841417610395576103956125c0565b6000816129e0576129e06125c0565b506000190190565b601f821115612a2e57600081815260208120601f850160051c81016020861015612a0f5750805b601f850160051c820191505b8181101561119557828155600101612a1b565b505050565b81516001600160401b03811115612a4c57612a4c611ec3565b612a6081612a5a84546124dd565b846129e8565b602080601f831160018114612a955760008415612a7d5750858301515b600019600386901b1c1916600185901b178555611195565b600085815260208120601f198616915b82811015612ac457888601518255948401946001909101908401612aa5565b5085821015612ae25787850151600019600388901b60f8161c191681555b5050505050600190811b0190555056fec3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f624d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529a26469706673582212202046d92ec7be30a191562bffbef1457bea854798a6fb2c92ea4ce3b6343c32a064736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101155760003560e01c806357128683116100a2578063e619870511610071578063e619870514610279578063e985e9c51461028b578063f242432a146102c7578063f399e22e146102da578063f5298aca146102ed57600080fd5b8063571286831461022d5780636b20c454146102405780639b77ef1114610253578063a22cb4651461026657600080fd5b8063156e29f6116100e9578063156e29f6146101965780631f2d0065146101a95780632d0335ab146101cf5780632eb2c2d6146101f85780634e1273f41461020d57600080fd5b8062fdd58e1461011a57806301ffc9a7146101405780630c53c51c146101635780630e89341c14610183575b600080fd5b61012d610128366004611cd5565b610300565b6040519081526020015b60405180910390f35b61015361014e366004611d15565b61039b565b6040519015158152602001610137565b610176610171366004611d7a565b6103eb565b6040516101379190611e49565b610176610191366004611e5c565b6106c9565b6101536101a4366004611e75565b61075d565b610103546001600160a01b03165b6040516001600160a01b039091168152602001610137565b61012d6101dd366004611ea8565b6001600160a01b031660009081526038602052604090205490565b61020b61020636600461200c565b6107b0565b005b61022061021b3660046120b5565b61080e565b60405161013791906121ba565b61015361023b366004612211565b610937565b61015361024e3660046122aa565b610a53565b61020b610261366004611e5c565b610afb565b61020b61027436600461232a565b610b22565b610102546001600160a01b03166101b7565b610153610299366004612366565b6001600160a01b03918216600090815260d16020908152604080832093909416825291909152205460ff1690565b61020b6102d5366004612399565b610b38565b61020b6102e83660046123fd565b610b8f565b6101536102fb366004611e75565b610da5565b60006001600160a01b0383166103705760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b50600081815260d0602090815260408083206001600160a01b03861684529091529020545b92915050565b60006001600160e01b03198216636cdb3d1360e11b14806103cc57506001600160e01b031982166303a24d0760e21b145b8061039557506301ffc9a760e01b6001600160e01b0319831614610395565b6060600061042e87878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610dde92505050565b90506001600160e01b03196000358116908216036104b45760405162461bcd60e51b815260206004820152603d60248201527f66756e6374696f6e5369676e61747572652063616e206e6f74206265206f662060448201527f657865637574654d6574615472616e73616374696f6e206d6574686f640000006064820152608401610367565b604080516060810182526001600160a01b038a16600081815260386020908152848220548452808401929092528351601f8b0183900483028101830185528a815290938301918b908b9081908401838280828437600092019190915250505091525090506105258982888888610df9565b61057b5760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d6174636044820152600d60fb1b6064820152608401610367565b603860008a6001600160a01b03166001600160a01b031681526020019081526020016000206000815460010191905081905550600080306001600160a01b03168a8a8d6040516020016105d09392919061244f565b60408051601f19818403018152908290526105ea91612475565b6000604051808303816000865af19150503d8060008114610627576040519150601f19603f3d011682016040523d82523d6000602084013e61062c565b606091505b50915091508161067e5760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610367565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b8b338c8c6040516106b39493929190612491565b60405180910390a19a9950505050505050505050565b606060d280546106d8906124dd565b80601f0160208091040260200160405190810160405280929190818152602001828054610704906124dd565b80156107515780601f1061072657610100808354040283529160200191610751565b820191906000526020600020905b81548152906001019060200180831161073457829003601f168201915b50505050509050919050565b610102546000906001600160a01b0316331461078b5760405162461bcd60e51b815260040161036790612517565b6107a684848460405180602001604052806000815250610ed5565b5060019392505050565b6107b8610fe4565b6001600160a01b0316856001600160a01b031614806107de57506107de85610299610fe4565b6107fa5760405162461bcd60e51b81526004016103679061255c565b6108078585858585610ff3565b5050505050565b606081518351146108735760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610367565b600083516001600160401b0381111561088e5761088e611ec3565b6040519080825280602002602001820160405280156108b7578160200160208202803683370190505b50905060005b845181101561092f576109028582815181106108db576108db6125aa565b60200260200101518583815181106108f5576108f56125aa565b6020026020010151610300565b828281518110610914576109146125aa565b6020908102919091010152610928816125d6565b90506108bd565b509392505050565b610102546000906001600160a01b031633146109655760405162461bcd60e51b815260040161036790612517565b85848114801561097457508083145b6109c05760405162461bcd60e51b815260206004820181905260248201527f4368696c64455243313135353a206172726179206c656e206d69736d617463686044820152606401610367565b60005b81811015610a4457610a3c8989838181106109e0576109e06125aa565b90506020020160208101906109f59190611ea8565b888884818110610a0757610a076125aa565b90506020020135878785818110610a2057610a206125aa565b9050602002013560405180602001604052806000815250610ed5565b6001016109c3565b50600198975050505050505050565b610102546000906001600160a01b03163314610a815760405162461bcd60e51b815260040161036790612517565b610aef8686868080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808a0282810182019093528982529093508992508891829185019084908082843760009201919091525061119d92505050565b50600195945050505050565b3360009081526038602052604081208054839290610b1a9084906125ef565b909155505050565b610b34610b2d610fe4565b8383611334565b5050565b610b40610fe4565b6001600160a01b0316856001600160a01b03161480610b665750610b6685610299610fe4565b610b825760405162461bcd60e51b81526004016103679061255c565b6108078585858585611414565b606b54610100900460ff1615808015610baf5750606b54600160ff909116105b80610bc95750303b158015610bc95750606b5460ff166001145b610c2c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610367565b606b805460ff191660011790558015610c4f57606b805461ff0019166101001790555b6001600160a01b038416610ca55760405162461bcd60e51b815260206004820181905260248201527f4368696c64455243313135353a204241445f494e495449414c495a4154494f4e6044820152606401610367565b61010380546001600160a01b0386166001600160a01b031991821617909155610102805490911633179055604080516020601f8501819004810282018101909252838152610d0d91859085908190840183828082843760009201919091525061153b92505050565b610d59610d22856001600160a01b031661156e565b604051602001610d329190612602565b60408051601f1981840301815282820190915260018252603160f81b602083015290611584565b8015610d9f57606b805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050565b610102546000906001600160a01b03163314610dd35760405162461bcd60e51b815260040161036790612517565b6107a68484846115f0565b60008151600003610df157506000919050565b506020015190565b6000806001610e0f610e0a886116f0565b61176d565b6040805160008152602081018083529290925260ff861690820152606081018790526080810186905260a0016020604051602081039080840390855afa158015610e5d573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610eb45760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610367565b866001600160a01b0316816001600160a01b03161491505095945050505050565b6001600160a01b038416610f355760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610367565b6000610f3f610fe4565b90506000610f4c8561179a565b90506000610f598561179a565b9050600086815260d0602090815260408083206001600160a01b038b16845290915281208054879290610f8d9084906125ef565b909155505060408051878152602081018790526001600160a01b03808a169260009291871691600080516020612af3833981519152910160405180910390a4610fdb836000898989896117e5565b50505050505050565b6000610fee611940565b905090565b81518351146110145760405162461bcd60e51b815260040161036790612637565b6001600160a01b03841661103a5760405162461bcd60e51b81526004016103679061267f565b6000611044610fe4565b905060005b845181101561112f576000858281518110611066576110666125aa565b602002602001015190506000858381518110611084576110846125aa565b602090810291909101810151600084815260d0835260408082206001600160a01b038e1683529093529190912054909150818110156110d55760405162461bcd60e51b8152600401610367906126c4565b600083815260d0602090815260408083206001600160a01b038e8116855292528083208585039055908b168252812080548492906111149084906125ef565b9250508190555050505080611128906125d6565b9050611049565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb878760405161117f92919061270e565b60405180910390a461119581878787878761199c565b505050505050565b6001600160a01b0383166111c35760405162461bcd60e51b81526004016103679061273c565b80518251146111e45760405162461bcd60e51b815260040161036790612637565b60006111ee610fe4565b604080516020810190915260009052905060005b83518110156112c757600084828151811061121f5761121f6125aa565b60200260200101519050600084838151811061123d5761123d6125aa565b602090810291909101810151600084815260d0835260408082206001600160a01b038c16835290935291909120549091508181101561128e5760405162461bcd60e51b81526004016103679061277f565b600092835260d0602090815260408085206001600160a01b038b16865290915290922091039055806112bf816125d6565b915050611202565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb868660405161131892919061270e565b60405180910390a4604080516020810190915260009052610d9f565b816001600160a01b0316836001600160a01b0316036113a75760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610367565b6001600160a01b03838116600081815260d16020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b03841661143a5760405162461bcd60e51b81526004016103679061267f565b6000611444610fe4565b905060006114518561179a565b9050600061145e8561179a565b9050600086815260d0602090815260408083206001600160a01b038c168452909152902054858110156114a35760405162461bcd60e51b8152600401610367906126c4565b600087815260d0602090815260408083206001600160a01b038d8116855292528083208985039055908a168252812080548892906114e29084906125ef565b909155505060408051888152602081018890526001600160a01b03808b16928c82169291881691600080516020612af3833981519152910160405180910390a4611530848a8a8a8a8a6117e5565b505050505050505050565b606b54610100900460ff166115625760405162461bcd60e51b8152600401610367906127c3565b61156b81611a57565b50565b60606103956001600160a01b0383166014611a87565b815160208084019190912082519183019190912060038290556004819055466001557f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6115d2818484611c29565b600055600280546001600160a01b0319163017905560055550505050565b6001600160a01b0383166116165760405162461bcd60e51b81526004016103679061273c565b6000611620610fe4565b9050600061162d8461179a565b9050600061163a8461179a565b604080516020808201835260009182905288825260d081528282206001600160a01b038b16835290522054909150848110156116885760405162461bcd60e51b81526004016103679061277f565b600086815260d0602090815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a9052909290881691600080516020612af3833981519152910160405180910390a4604080516020810190915260009052610fdb565b6000604051806080016040528060438152602001612b136043913980516020918201208351848301516040808701518051908601209051611750950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061039561177a611c72565b8360405161190160f01b8152600281019290925260228201526042902090565b604080516001808252818301909252606091600091906020808301908036833701905050905082816000815181106117d4576117d46125aa565b602090810291909101015292915050565b6001600160a01b0384163b156111955760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190611829908990899088908890889060040161280e565b6020604051808303816000875af1925050508015611864575060408051601f3d908101601f1916820190925261186191810190612853565b60015b61191057611870612870565b806308c379a0036118a9575061188461288b565b8061188f57506118ab565b8060405162461bcd60e51b81526004016103679190611e49565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e2d455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610367565b6001600160e01b0319811663f23a6e6160e01b14610fdb5760405162461bcd60e51b815260040161036790612914565b600030330361199657600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b031691506119999050565b50335b90565b6001600160a01b0384163b156111955760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906119e0908990899088908890889060040161295c565b6020604051808303816000875af1925050508015611a1b575060408051601f3d908101601f19168201909252611a1891810190612853565b60015b611a2757611870612870565b6001600160e01b0319811663bc197c8160e01b14610fdb5760405162461bcd60e51b815260040161036790612914565b606b54610100900460ff16611a7e5760405162461bcd60e51b8152600401610367906127c3565b61156b81611cad565b60606000611a968360026129ba565b611aa19060026125ef565b6001600160401b03811115611ab857611ab8611ec3565b6040519080825280601f01601f191660200182016040528015611ae2576020820181803683370190505b509050600360fc1b81600081518110611afd57611afd6125aa565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110611b2c57611b2c6125aa565b60200101906001600160f81b031916908160001a9053506000611b508460026129ba565b611b5b9060016125ef565b90505b6001811115611bd3576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110611b8f57611b8f6125aa565b1a60f81b828281518110611ba557611ba56125aa565b60200101906001600160f81b031916908160001a90535060049490941c93611bcc816129d1565b9050611b5e565b508315611c225760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610367565b9392505050565b6040805160208101859052908101839052606081018290524660808201523060a082015260009060c0016040516020818303038152906040528051906020012090509392505050565b6002546000906001600160a01b031630148015611c90575060015446145b15611c9c575060005490565b610fee600554600354600454611c29565b60d2610b348282612a33565b80356001600160a01b0381168114611cd057600080fd5b919050565b60008060408385031215611ce857600080fd5b611cf183611cb9565b946020939093013593505050565b6001600160e01b03198116811461156b57600080fd5b600060208284031215611d2757600080fd5b8135611c2281611cff565b60008083601f840112611d4457600080fd5b5081356001600160401b03811115611d5b57600080fd5b602083019150836020828501011115611d7357600080fd5b9250929050565b60008060008060008060a08789031215611d9357600080fd5b611d9c87611cb9565b955060208701356001600160401b03811115611db757600080fd5b611dc389828a01611d32565b9096509450506040870135925060608701359150608087013560ff81168114611deb57600080fd5b809150509295509295509295565b60005b83811015611e14578181015183820152602001611dfc565b50506000910152565b60008151808452611e35816020860160208601611df9565b601f01601f19169290920160200192915050565b602081526000611c226020830184611e1d565b600060208284031215611e6e57600080fd5b5035919050565b600080600060608486031215611e8a57600080fd5b611e9384611cb9565b95602085013595506040909401359392505050565b600060208284031215611eba57600080fd5b611c2282611cb9565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b0381118282101715611efe57611efe611ec3565b6040525050565b60006001600160401b03821115611f1e57611f1e611ec3565b5060051b60200190565b600082601f830112611f3957600080fd5b81356020611f4682611f05565b604051611f538282611ed9565b83815260059390931b8501820192828101915086841115611f7357600080fd5b8286015b84811015611f8e5780358352918301918301611f77565b509695505050505050565b600082601f830112611faa57600080fd5b81356001600160401b03811115611fc357611fc3611ec3565b604051611fda601f8301601f191660200182611ed9565b818152846020838601011115611fef57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a0868803121561202457600080fd5b61202d86611cb9565b945061203b60208701611cb9565b935060408601356001600160401b038082111561205757600080fd5b61206389838a01611f28565b9450606088013591508082111561207957600080fd5b61208589838a01611f28565b9350608088013591508082111561209b57600080fd5b506120a888828901611f99565b9150509295509295909350565b600080604083850312156120c857600080fd5b82356001600160401b03808211156120df57600080fd5b818501915085601f8301126120f357600080fd5b8135602061210082611f05565b60405161210d8282611ed9565b83815260059390931b850182019282810191508984111561212d57600080fd5b948201945b838610156121525761214386611cb9565b82529482019490820190612132565b9650508601359250508082111561216857600080fd5b5061217585828601611f28565b9150509250929050565b600081518084526020808501945080840160005b838110156121af57815187529582019590820190600101612193565b509495945050505050565b602081526000611c22602083018461217f565b60008083601f8401126121df57600080fd5b5081356001600160401b038111156121f657600080fd5b6020830191508360208260051b8501011115611d7357600080fd5b6000806000806000806060878903121561222a57600080fd5b86356001600160401b038082111561224157600080fd5b61224d8a838b016121cd565b9098509650602089013591508082111561226657600080fd5b6122728a838b016121cd565b9096509450604089013591508082111561228b57600080fd5b5061229889828a016121cd565b979a9699509497509295939492505050565b6000806000806000606086880312156122c257600080fd5b6122cb86611cb9565b945060208601356001600160401b03808211156122e757600080fd5b6122f389838a016121cd565b9096509450604088013591508082111561230c57600080fd5b50612319888289016121cd565b969995985093965092949392505050565b6000806040838503121561233d57600080fd5b61234683611cb9565b91506020830135801515811461235b57600080fd5b809150509250929050565b6000806040838503121561237957600080fd5b61238283611cb9565b915061239060208401611cb9565b90509250929050565b600080600080600060a086880312156123b157600080fd5b6123ba86611cb9565b94506123c860208701611cb9565b9350604086013592506060860135915060808601356001600160401b038111156123f157600080fd5b6120a888828901611f99565b60008060006040848603121561241257600080fd5b61241b84611cb9565b925060208401356001600160401b0381111561243657600080fd5b61244286828701611d32565b9497909650939450505050565b8284823760609190911b6bffffffffffffffffffffffff19169101908152601401919050565b60008251612487818460208701611df9565b9190910192915050565b6001600160a01b0385811682528416602082015260606040820181905281018290526000828460808401376000608084840101526080601f19601f850116830101905095945050505050565b600181811c908216806124f157607f821691505b60208210810361251157634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526025908201527f4368696c64455243313135353a204f6e6c79207072656469636174652063616e6040820152640818d85b1b60da1b606082015260800190565b6020808252602e908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526d195c881bdc88185c1c1c9bdd995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016125e8576125e86125c0565b5060010190565b80820180821115610395576103956125c0565b6c4368696c64455243313135352d60981b81526000825161262a81600d850160208701611df9565b91909101600d0192915050565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b604081526000612721604083018561217f565b8281036020840152612733818561217f565b95945050505050565b60208082526023908201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260408201526265737360e81b606082015260800190565b60208082526024908201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604082015263616e636560e01b606082015260800190565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a06080820181905260009061284890830184611e1d565b979650505050505050565b60006020828403121561286557600080fd5b8151611c2281611cff565b600060033d11156119995760046000803e5060005160e01c90565b600060443d10156128995790565b6040516003193d81016004833e81513d6001600160401b0381602484011181841117156128c857505050505090565b82850191508151818111156128e05750505050505090565b843d87010160208285010111156128fa5750505050505090565b61290960208286010187611ed9565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b0386811682528516602082015260a0604082018190526000906129889083018661217f565b828103606084015261299a818661217f565b905082810360808401526129ae8185611e1d565b98975050505050505050565b8082028115828204841417610395576103956125c0565b6000816129e0576129e06125c0565b506000190190565b601f821115612a2e57600081815260208120601f850160051c81016020861015612a0f5750805b601f850160051c820191505b8181101561119557828155600101612a1b565b505050565b81516001600160401b03811115612a4c57612a4c611ec3565b612a6081612a5a84546124dd565b846129e8565b602080601f831160018114612a955760008415612a7d5750858301515b600019600386901b1c1916600185901b178555611195565b600085815260208120601f198616915b82811015612ac457888601518255948401946001909101908401612aa5565b5085821015612ae25787850151600019600388901b60f8161c191681555b5050505050600190811b0190555056fec3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f624d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529a26469706673582212202046d92ec7be30a191562bffbef1457bea854798a6fb2c92ea4ce3b6343c32a064736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildERC1155PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC1155Predicate","sourceName":"contracts/blade/ChildERC1155Predicate.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2ERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2ERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612040806100206000396000f3fe608060405234801561001057600080fd5b50600436106101585760003560e01c806397e5230d116100c3578063d41f17711161007c578063d41f1771146102de578063d7c9e3ec14610305578063e0563ab11461032c578063eeb4994514610335578063f645125514610348578063f8c8765e1461036f57600080fd5b806397e5230d1461024d578063b176806514610257578063b5c5f6721461027e578063b68ad1e414610291578063b8cd3ec0146102a4578063c5ac2b1c146102b757600080fd5b806351351d531161011557806351351d53146101d357806355b01e4d146101e15780635ea5df79146101ef5780637efab4f51461020657806386937eb41461022f578063947287cf1461024457600080fd5b8063051eb2e21461015d57806305dc2e8f1461018d57806307b3e252146101a05780631bc114ba146101ae578063284017f5146101c15780633b878c22146101ca575b600080fd5b603554610170906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b603454610170906001600160a01b031681565b6101706004600360981b0181565b603354610170906001600160a01b031681565b61017061202081565b61017061101081565b6101706002600160a01b0381565b6101706004600160991b0181565b6101f861138881565b604051908152602001610184565b610170610214366004611648565b6037602052600090815260409020546001600160a01b031681565b61024261023d3660046116b7565b610382565b005b6101f861520881565b6101f8620249f081565b6101f87f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b61024261028c366004611763565b61039a565b603654610170906001600160a01b031681565b6102426102b2366004611798565b6103ab565b6101f87faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6101f87f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101f87f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61017061203081565b6102426103433660046117de565b6103bd565b6101f87f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61024261037d366004611866565b6105dd565b6103918787878787878761073a565b50505050505050565b6103a683338484610ab9565b505050565b6103b784848484610ab9565b50505050565b6034546001600160a01b0316331461042f5760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f5354415460448201526922afa922a1a2a4ab22a960b11b60648201526084015b60405180910390fd5b6035546001600160a01b0384811691161461049f5760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f524f4f546044820152695f50524544494341544560b01b6064820152608401610426565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216104ce6020600084866118c2565b6104d7916118ec565b036104f6576104f16104ec82602081866118c2565b610dce565b6103b7565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d186105256020600084866118c2565b61052e916118ec565b0361053d576104f18282611039565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61056c6020600084866118c2565b610575916118ec565b03610584576104f182826112a6565b60405162461bcd60e51b815260206004820152602860248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f5360448201526749474e415455524560c01b6064820152608401610426565b336002600160a01b03146106215760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610426565b600054610100900460ff16158080156106415750600054600160ff909116105b8061065b5750303b15801561065b575060005460ff166001145b6106be5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610426565b6000805460ff1916600117905580156106e1576000805461ff0019166101001790555b6106ed8585858561140e565b8015610733576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b8661074481611504565b6107605760405162461bcd60e51b81526004016104269061190a565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107c4919061194d565b6001600160a01b038181166000908152603760205260409020549192508a81169116146108035760405162461bcd60e51b81526004016104269061196a565b6001600160a01b038116610819576108196119af565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610861573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610885919061194d565b6001600160a01b03161461089b5761089b6119af565b86851480156108a957508483145b6109035760405162461bcd60e51b815260206004820152602560248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f4c60448201526408a9c8ea8960db1b6064820152608401610426565b604051631ac8311560e21b81526001600160a01b038a1690636b20c454906109379033908a908a908a908a906004016119f7565b6020604051808303816000875af1158015610956573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061097a9190611a3b565b6109965760405162461bcd60e51b815260040161042690611a5d565b6033546035546040516001600160a01b03928316926316f198319216906109f1907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001611ae8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610a1d929190611b99565b600060405180830381600087803b158015610a3757600080fd5b505af1158015610a4b573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167f7a10660242ca367951ff3777cdb3c2a761e3ccad204bac118501e24693f3683d8b8b8b8b8b8b604051610aa696959493929190611bc5565b60405180910390a4505050505050505050565b83610ac381611504565b610adf5760405162461bcd60e51b81526004016104269061190a565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b1f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b43919061194d565b6001600160a01b03818116600090815260376020526040902054919250878116911614610b825760405162461bcd60e51b81526004016104269061196a565b6001600160a01b038116610b9857610b986119af565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610be0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c04919061194d565b6001600160a01b031614610c1a57610c1a6119af565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca90610c4a90339088908890600401611c0e565b6020604051808303816000875af1158015610c69573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c8d9190611a3b565b610ca95760405162461bcd60e51b815260040161042690611a5d565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352938416936316f1983193610d3b9391169160e401611b99565b600060405180830381600087803b158015610d5557600080fd5b505af1158015610d69573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167f2ca9093e8b5356801039806c6a08003e5b7013fb8ae48f720fc90fc1c1a8bec2338888604051610dbe93929190611c0e565b60405180910390a4505050505050565b600080808080610de086880188611c2f565b6001600160a01b03808616600090815260376020526040902054959a50939850919650945092501680610e255760405162461bcd60e51b81526004016104269061196a565b610e2e81611504565b610e3a57610e3a6119af565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e7a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e9e919061194d565b9050866001600160a01b0316816001600160a01b031614610ec157610ec16119af565b6001600160a01b038116610ed757610ed76119af565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f1f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f43919061194d565b6001600160a01b031614610f5957610f596119af565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f690610f8990889088908890600401611c0e565b6020604051808303816000875af1158015610fa8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fcc9190611a3b565b610fe85760405162461bcd60e51b815260040161042690611c8a565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f2930d932c1cccd6add2e0e2d706ede9015db8a194405f2a3e1783703515e104f898888604051610aa693929190611c0e565b60008080808061104b86880188611da0565b6001600160a01b03808616600090815260376020526040902054959b5093995091975095509350169050806110925760405162461bcd60e51b81526004016104269061196a565b61109b81611504565b6110a7576110a76119af565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110e7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061110b919061194d565b9050866001600160a01b0316816001600160a01b03161461112e5761112e6119af565b6001600160a01b038116611144576111446119af565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561118c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b0919061194d565b6001600160a01b0316146111c6576111c66119af565b604051635712868360e01b81526001600160a01b038316906357128683906111f690889088908890600401611ee5565b6020604051808303816000875af1158015611215573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112399190611a3b565b6112555760405162461bcd60e51b815260040161042690611c8a565b856001600160a01b0316826001600160a01b0316886001600160a01b03167f17304b99f8dfa5a2b8dd5695d82f9947c2abfbc9cb64bab610b9a1a0feadb9a0888888604051610aa693929190611ee5565b6000806112b583850185611f5a565b9093509150506001600160a01b0382166112d1576112d16119af565b6001600160a01b0382811660009081526037602052604090205416156112f9576112f96119af565b6036546040516bffffffffffffffffffffffff19606085901b166020820152600091611349916001600160a01b039091169060340160405160208183030381529060405280519060200120611599565b6001600160a01b038481166000908152603760205260409081902080546001600160a01b0319169284169283179055516379ccf11760e11b81529192509063f399e22e9061139d9086908690600401611b99565b600060405180830381600087803b1580156113b757600080fd5b505af11580156113cb573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a35050505050565b6001600160a01b0384161580159061142e57506001600160a01b03831615155b801561144257506001600160a01b03821615155b801561145657506001600160a01b03811615155b6114b45760405162461bcd60e51b815260206004820152602960248201527f4368696c64455243313135355072656469636174653a204241445f494e49544960448201526820a624ad20aa24a7a760b91b6064820152608401610426565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000816001600160a01b03163b60000361152057506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611587575060408051601f3d908101601f1916820190925261158491810190611a3b565b60015b61159357506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166115935760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610426565b6001600160a01b038116811461164557600080fd5b50565b60006020828403121561165a57600080fd5b813561166581611630565b9392505050565b60008083601f84011261167e57600080fd5b5081356001600160401b0381111561169557600080fd5b6020830191508360208260051b85010111156116b057600080fd5b9250929050565b60008060008060008060006080888a0312156116d257600080fd5b87356116dd81611630565b965060208801356001600160401b03808211156116f957600080fd5b6117058b838c0161166c565b909850965060408a013591508082111561171e57600080fd5b61172a8b838c0161166c565b909650945060608a013591508082111561174357600080fd5b506117508a828b0161166c565b989b979a50959850939692959293505050565b60008060006060848603121561177857600080fd5b833561178381611630565b95602085013595506040909401359392505050565b600080600080608085870312156117ae57600080fd5b84356117b981611630565b935060208501356117c981611630565b93969395505050506040820135916060013590565b600080600080606085870312156117f457600080fd5b84359350602085013561180681611630565b925060408501356001600160401b038082111561182257600080fd5b818701915087601f83011261183657600080fd5b81358181111561184557600080fd5b88602082850101111561185757600080fd5b95989497505060200194505050565b6000806000806080858703121561187c57600080fd5b843561188781611630565b9350602085013561189781611630565b925060408501356118a781611630565b915060608501356118b781611630565b939692955090935050565b600080858511156118d257600080fd5b838611156118df57600080fd5b5050820193919092039150565b8035602083101561159357600019602084900360031b1b1692915050565b60208082526023908201527f4368696c64455243313135355072656469636174653a204e4f545f434f4e54526040820152621050d560ea1b606082015260800190565b60006020828403121561195f57600080fd5b815161166581611630565b60208082526025908201527f4368696c64455243313135355072656469636174653a20554e4d41505045445f6040820152642a27a5a2a760d91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156119de57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b0386168152606060208201819052600090611a1c90830186886119c5565b8281036040840152611a2f8185876119c5565b98975050505050505050565b600060208284031215611a4d57600080fd5b8151801515811461166557600080fd5b60208082526022908201527f4368696c64455243313135355072656469636174653a204255524e5f4641494c604082015261115160f21b606082015260800190565b8183526000602080850194508260005b85811015611add578135611ac281611630565b6001600160a01b031687529582019590820190600101611aaf565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090611b1b908301888a611a9f565b8281036080840152611b2e8187896119c5565b905082810360a0840152611b438185876119c5565b9c9b505050505050505050505050565b6000815180845260005b81811015611b7957602081850181015186830182015201611b5d565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611bbd90830184611b53565b949350505050565b606081526000611bd960608301888a611a9f565b8281036020840152611bec8187896119c5565b90508281036040840152611c018185876119c5565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a08688031215611c4757600080fd5b8535611c5281611630565b94506020860135611c6281611630565b93506040860135611c7281611630565b94979396509394606081013594506080013592915050565b60208082526022908201527f4368696c64455243313135355072656469636174653a204d494e545f4641494c604082015261115160f21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611d0a57611d0a611ccc565b604052919050565b60006001600160401b03821115611d2b57611d2b611ccc565b5060051b60200190565b600082601f830112611d4657600080fd5b81356020611d5b611d5683611d12565b611ce2565b82815260059290921b84018101918181019086841115611d7a57600080fd5b8286015b84811015611d955780358352918301918301611d7e565b509695505050505050565b60008060008060008060c08789031215611db957600080fd5b86359550602080880135611dcc81611630565b95506040880135611ddc81611630565b945060608801356001600160401b0380821115611df857600080fd5b818a0191508a601f830112611e0c57600080fd5b8135611e1a611d5682611d12565b81815260059190911b8301840190848101908d831115611e3957600080fd5b938501935b82851015611e60578435611e5181611630565b82529385019390850190611e3e565b9750505060808a0135925080831115611e7857600080fd5b611e848b848c01611d35565b945060a08a0135925080831115611e9a57600080fd5b5050611ea889828a01611d35565b9150509295509295509295565b600081518084526020808501945080840160005b83811015611add57815187529582019590820190600101611ec9565b606080825284519082018190526000906020906080840190828801845b82811015611f275781516001600160a01b031684529284019290840190600101611f02565b50505083810382850152611f3b8187611eb5565b9150508281036040840152611f508185611eb5565b9695505050505050565b600080600060608486031215611f6f57600080fd5b83359250602080850135611f8281611630565b925060408501356001600160401b0380821115611f9e57600080fd5b818701915087601f830112611fb257600080fd5b813581811115611fc457611fc4611ccc565b611fd6601f8201601f19168501611ce2565b91508082528884828501011115611fec57600080fd5b8084840185840137600084828401015250809350505050925092509256fea264697066735822122053ae18826f34a4bc4701445b741b196cc04ea8076fbe399a2e21a27f72aa0ac964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101585760003560e01c806397e5230d116100c3578063d41f17711161007c578063d41f1771146102de578063d7c9e3ec14610305578063e0563ab11461032c578063eeb4994514610335578063f645125514610348578063f8c8765e1461036f57600080fd5b806397e5230d1461024d578063b176806514610257578063b5c5f6721461027e578063b68ad1e414610291578063b8cd3ec0146102a4578063c5ac2b1c146102b757600080fd5b806351351d531161011557806351351d53146101d357806355b01e4d146101e15780635ea5df79146101ef5780637efab4f51461020657806386937eb41461022f578063947287cf1461024457600080fd5b8063051eb2e21461015d57806305dc2e8f1461018d57806307b3e252146101a05780631bc114ba146101ae578063284017f5146101c15780633b878c22146101ca575b600080fd5b603554610170906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b603454610170906001600160a01b031681565b6101706004600360981b0181565b603354610170906001600160a01b031681565b61017061202081565b61017061101081565b6101706002600160a01b0381565b6101706004600160991b0181565b6101f861138881565b604051908152602001610184565b610170610214366004611648565b6037602052600090815260409020546001600160a01b031681565b61024261023d3660046116b7565b610382565b005b6101f861520881565b6101f8620249f081565b6101f87f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b61024261028c366004611763565b61039a565b603654610170906001600160a01b031681565b6102426102b2366004611798565b6103ab565b6101f87faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6101f87f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101f87f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61017061203081565b6102426103433660046117de565b6103bd565b6101f87f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61024261037d366004611866565b6105dd565b6103918787878787878761073a565b50505050505050565b6103a683338484610ab9565b505050565b6103b784848484610ab9565b50505050565b6034546001600160a01b0316331461042f5760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f5354415460448201526922afa922a1a2a4ab22a960b11b60648201526084015b60405180910390fd5b6035546001600160a01b0384811691161461049f5760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f524f4f546044820152695f50524544494341544560b01b6064820152608401610426565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216104ce6020600084866118c2565b6104d7916118ec565b036104f6576104f16104ec82602081866118c2565b610dce565b6103b7565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d186105256020600084866118c2565b61052e916118ec565b0361053d576104f18282611039565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61056c6020600084866118c2565b610575916118ec565b03610584576104f182826112a6565b60405162461bcd60e51b815260206004820152602860248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f5360448201526749474e415455524560c01b6064820152608401610426565b336002600160a01b03146106215760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b6044820152606401610426565b600054610100900460ff16158080156106415750600054600160ff909116105b8061065b5750303b15801561065b575060005460ff166001145b6106be5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610426565b6000805460ff1916600117905580156106e1576000805461ff0019166101001790555b6106ed8585858561140e565b8015610733576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b8661074481611504565b6107605760405162461bcd60e51b81526004016104269061190a565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107c4919061194d565b6001600160a01b038181166000908152603760205260409020549192508a81169116146108035760405162461bcd60e51b81526004016104269061196a565b6001600160a01b038116610819576108196119af565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610861573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610885919061194d565b6001600160a01b03161461089b5761089b6119af565b86851480156108a957508483145b6109035760405162461bcd60e51b815260206004820152602560248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f4c60448201526408a9c8ea8960db1b6064820152608401610426565b604051631ac8311560e21b81526001600160a01b038a1690636b20c454906109379033908a908a908a908a906004016119f7565b6020604051808303816000875af1158015610956573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061097a9190611a3b565b6109965760405162461bcd60e51b815260040161042690611a5d565b6033546035546040516001600160a01b03928316926316f198319216906109f1907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001611ae8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610a1d929190611b99565b600060405180830381600087803b158015610a3757600080fd5b505af1158015610a4b573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167f7a10660242ca367951ff3777cdb3c2a761e3ccad204bac118501e24693f3683d8b8b8b8b8b8b604051610aa696959493929190611bc5565b60405180910390a4505050505050505050565b83610ac381611504565b610adf5760405162461bcd60e51b81526004016104269061190a565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b1f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b43919061194d565b6001600160a01b03818116600090815260376020526040902054919250878116911614610b825760405162461bcd60e51b81526004016104269061196a565b6001600160a01b038116610b9857610b986119af565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610be0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c04919061194d565b6001600160a01b031614610c1a57610c1a6119af565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca90610c4a90339088908890600401611c0e565b6020604051808303816000875af1158015610c69573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c8d9190611a3b565b610ca95760405162461bcd60e51b815260040161042690611a5d565b603354603554604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352938416936316f1983193610d3b9391169160e401611b99565b600060405180830381600087803b158015610d5557600080fd5b505af1158015610d69573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167f2ca9093e8b5356801039806c6a08003e5b7013fb8ae48f720fc90fc1c1a8bec2338888604051610dbe93929190611c0e565b60405180910390a4505050505050565b600080808080610de086880188611c2f565b6001600160a01b03808616600090815260376020526040902054959a50939850919650945092501680610e255760405162461bcd60e51b81526004016104269061196a565b610e2e81611504565b610e3a57610e3a6119af565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e7a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e9e919061194d565b9050866001600160a01b0316816001600160a01b031614610ec157610ec16119af565b6001600160a01b038116610ed757610ed76119af565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f1f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f43919061194d565b6001600160a01b031614610f5957610f596119af565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f690610f8990889088908890600401611c0e565b6020604051808303816000875af1158015610fa8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fcc9190611a3b565b610fe85760405162461bcd60e51b815260040161042690611c8a565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f2930d932c1cccd6add2e0e2d706ede9015db8a194405f2a3e1783703515e104f898888604051610aa693929190611c0e565b60008080808061104b86880188611da0565b6001600160a01b03808616600090815260376020526040902054959b5093995091975095509350169050806110925760405162461bcd60e51b81526004016104269061196a565b61109b81611504565b6110a7576110a76119af565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110e7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061110b919061194d565b9050866001600160a01b0316816001600160a01b03161461112e5761112e6119af565b6001600160a01b038116611144576111446119af565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561118c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b0919061194d565b6001600160a01b0316146111c6576111c66119af565b604051635712868360e01b81526001600160a01b038316906357128683906111f690889088908890600401611ee5565b6020604051808303816000875af1158015611215573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112399190611a3b565b6112555760405162461bcd60e51b815260040161042690611c8a565b856001600160a01b0316826001600160a01b0316886001600160a01b03167f17304b99f8dfa5a2b8dd5695d82f9947c2abfbc9cb64bab610b9a1a0feadb9a0888888604051610aa693929190611ee5565b6000806112b583850185611f5a565b9093509150506001600160a01b0382166112d1576112d16119af565b6001600160a01b0382811660009081526037602052604090205416156112f9576112f96119af565b6036546040516bffffffffffffffffffffffff19606085901b166020820152600091611349916001600160a01b039091169060340160405160208183030381529060405280519060200120611599565b6001600160a01b038481166000908152603760205260409081902080546001600160a01b0319169284169283179055516379ccf11760e11b81529192509063f399e22e9061139d9086908690600401611b99565b600060405180830381600087803b1580156113b757600080fd5b505af11580156113cb573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a35050505050565b6001600160a01b0384161580159061142e57506001600160a01b03831615155b801561144257506001600160a01b03821615155b801561145657506001600160a01b03811615155b6114b45760405162461bcd60e51b815260206004820152602960248201527f4368696c64455243313135355072656469636174653a204241445f494e49544960448201526820a624ad20aa24a7a760b91b6064820152608401610426565b603380546001600160a01b039586166001600160a01b0319918216179091556034805494861694821694909417909355603580549285169284169290921790915560368054919093169116179055565b6000816001600160a01b03163b60000361152057506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611587575060408051601f3d908101601f1916820190925261158491810190611a3b565b60015b61159357506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166115935760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610426565b6001600160a01b038116811461164557600080fd5b50565b60006020828403121561165a57600080fd5b813561166581611630565b9392505050565b60008083601f84011261167e57600080fd5b5081356001600160401b0381111561169557600080fd5b6020830191508360208260051b85010111156116b057600080fd5b9250929050565b60008060008060008060006080888a0312156116d257600080fd5b87356116dd81611630565b965060208801356001600160401b03808211156116f957600080fd5b6117058b838c0161166c565b909850965060408a013591508082111561171e57600080fd5b61172a8b838c0161166c565b909650945060608a013591508082111561174357600080fd5b506117508a828b0161166c565b989b979a50959850939692959293505050565b60008060006060848603121561177857600080fd5b833561178381611630565b95602085013595506040909401359392505050565b600080600080608085870312156117ae57600080fd5b84356117b981611630565b935060208501356117c981611630565b93969395505050506040820135916060013590565b600080600080606085870312156117f457600080fd5b84359350602085013561180681611630565b925060408501356001600160401b038082111561182257600080fd5b818701915087601f83011261183657600080fd5b81358181111561184557600080fd5b88602082850101111561185757600080fd5b95989497505060200194505050565b6000806000806080858703121561187c57600080fd5b843561188781611630565b9350602085013561189781611630565b925060408501356118a781611630565b915060608501356118b781611630565b939692955090935050565b600080858511156118d257600080fd5b838611156118df57600080fd5b5050820193919092039150565b8035602083101561159357600019602084900360031b1b1692915050565b60208082526023908201527f4368696c64455243313135355072656469636174653a204e4f545f434f4e54526040820152621050d560ea1b606082015260800190565b60006020828403121561195f57600080fd5b815161166581611630565b60208082526025908201527f4368696c64455243313135355072656469636174653a20554e4d41505045445f6040820152642a27a5a2a760d91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156119de57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b0386168152606060208201819052600090611a1c90830186886119c5565b8281036040840152611a2f8185876119c5565b98975050505050505050565b600060208284031215611a4d57600080fd5b8151801515811461166557600080fd5b60208082526022908201527f4368696c64455243313135355072656469636174653a204255524e5f4641494c604082015261115160f21b606082015260800190565b8183526000602080850194508260005b85811015611add578135611ac281611630565b6001600160a01b031687529582019590820190600101611aaf565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090611b1b908301888a611a9f565b8281036080840152611b2e8187896119c5565b905082810360a0840152611b438185876119c5565b9c9b505050505050505050505050565b6000815180845260005b81811015611b7957602081850181015186830182015201611b5d565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611bbd90830184611b53565b949350505050565b606081526000611bd960608301888a611a9f565b8281036020840152611bec8187896119c5565b90508281036040840152611c018185876119c5565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a08688031215611c4757600080fd5b8535611c5281611630565b94506020860135611c6281611630565b93506040860135611c7281611630565b94979396509394606081013594506080013592915050565b60208082526022908201527f4368696c64455243313135355072656469636174653a204d494e545f4641494c604082015261115160f21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611d0a57611d0a611ccc565b604052919050565b60006001600160401b03821115611d2b57611d2b611ccc565b5060051b60200190565b600082601f830112611d4657600080fd5b81356020611d5b611d5683611d12565b611ce2565b82815260059290921b84018101918181019086841115611d7a57600080fd5b8286015b84811015611d955780358352918301918301611d7e565b509695505050505050565b60008060008060008060c08789031215611db957600080fd5b86359550602080880135611dcc81611630565b95506040880135611ddc81611630565b945060608801356001600160401b0380821115611df857600080fd5b818a0191508a601f830112611e0c57600080fd5b8135611e1a611d5682611d12565b81815260059190911b8301840190848101908d831115611e3957600080fd5b938501935b82851015611e60578435611e5181611630565b82529385019390850190611e3e565b9750505060808a0135925080831115611e7857600080fd5b611e848b848c01611d35565b945060a08a0135925080831115611e9a57600080fd5b5050611ea889828a01611d35565b9150509295509295509295565b600081518084526020808501945080840160005b83811015611add57815187529582019590820190600101611ec9565b606080825284519082018190526000906020906080840190828801845b82811015611f275781516001600160a01b031684529284019290840190600101611f02565b50505083810382850152611f3b8187611eb5565b9150508281036040840152611f508185611eb5565b9695505050505050565b600080600060608486031215611f6f57600080fd5b83359250602080850135611f8281611630565b925060408501356001600160401b0380821115611f9e57600080fd5b818701915087601f830112611fb257600080fd5b813581811115611fc457611fc4611ccc565b611fd6601f8201601f19168501611ce2565b91508082528884828501011115611fec57600080fd5b8084840185840137600084828401015250809350505050925092509256fea264697066735822122053ae18826f34a4bc4701445b741b196cc04ea8076fbe399a2e21a27f72aa0ac964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildERC1155PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildERC1155PredicateAccessList","sourceName":"contracts/blade/ChildERC1155PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2ERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2ERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2ERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2TokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","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":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506127d8806100206000396000f3fe608060405234801561001057600080fd5b50600436106101b05760003560e01c8063b1768065116100ef578063d7c9e3ec11610092578063d7c9e3ec146103a5578063d8dd1773146103cc578063e0563ab1146103df578063e30c3978146103e8578063eeb49945146103f9578063f2fde38b1461040c578063f64512551461041f578063f8c8765e1461044657600080fd5b8063b1768065146102d1578063b5c5f672146102f8578063b68ad1e41461030b578063b8cd3ec01461031e578063c1225a2014610331578063c5ac2b1c14610344578063c5e4683a1461036b578063d41f17711461037e57600080fd5b80635ea5df79116101575780635ea5df7914610247578063715018a61461025e57806379ba5097146102685780637efab4f51461027057806386937eb41461029a5780638da5cb5b146102ad578063947287cf146102be57806397e5230d146102c757600080fd5b8063051eb2e2146101b557806305dc2e8f146101e557806307b3e252146101f85780631bc114ba14610206578063284017f5146102195780633b878c221461022257806351351d531461022b57806355b01e4d14610239575b600080fd5b60fe546101c8906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b60fd546101c8906001600160a01b031681565b6101c86004600360981b0181565b60fc546101c8906001600160a01b031681565b6101c861202081565b6101c861101081565b6101c86002600160a01b0381565b6101c86004600160991b0181565b61025061138881565b6040519081526020016101dc565b610266610459565b005b61026661046d565b6101c861027e366004611c73565b610100602052600090815260409020546001600160a01b031681565b6102666102a8366004611ce2565b6104ec565b6033546001600160a01b03166101c8565b61025061520881565b610250620249f081565b6102507f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b610266610306366004611d8e565b61050c565b60ff546101c8906001600160a01b031681565b61026661032c366004611dc3565b610525565b61026661033f366004611e17565b61053f565b6102507faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b610266610379366004611e17565b61058e565b6102507f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102507f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6102666103da366004611e34565b6105d5565b6101c861203081565b6065546001600160a01b03166101c8565b610266610407366004611eca565b6106f6565b61026661041a366004611c73565b610911565b6102507f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b610266610454366004611f52565b610982565b610461610a7b565b61046b6000610ad5565b565b60655433906001600160a01b031681146104e05760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b6104e981610ad5565b50565b6104f4610aee565b61050387878787878787610af6565b50505050505050565b610514610aee565b61052083338484610e76565b505050565b61052d610aee565b61053984848484610e76565b50505050565b610547610a7b565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b610596610a7b565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105fc5760405163973d02cb60e01b81526004016104d790611fae565b600054610100900460ff161580801561061c5750600054600160ff909116105b806106365750303b158015610636575060005460ff166001145b6106525760405162461bcd60e51b81526004016104d790611fd2565b6000805460ff191660011790558015610675576000805461ff0019166101001790555b6106818888888861118c565b60c9805461ffff191685151561ff00191617610100851515021790556106a682610ad5565b80156106ec576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107635760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f5354415460448201526922afa922a1a2a4ab22a960b11b60648201526084016104d7565b60fe546001600160a01b038481169116146107d35760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f524f4f546044820152695f50524544494341544560b01b60648201526084016104d7565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f821610802602060008486612020565b61080b9161204a565b0361082a576108256108208260208186612020565b611282565b610539565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18610859602060008486612020565b6108629161204a565b036108715761082582826114ee565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6108a0602060008486612020565b6108a99161204a565b036108b857610825828261175c565b60405162461bcd60e51b815260206004820152602860248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f5360448201526749474e415455524560c01b60648201526084016104d7565b610919610a7b565b606580546001600160a01b0383166001600160a01b0319909116811790915561094a6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b336002600160a01b03146109a95760405163973d02cb60e01b81526004016104d790611fae565b600054610100900460ff16158080156109c95750600054600160ff909116105b806109e35750303b1580156109e3575060005460ff166001145b6109ff5760405162461bcd60e51b81526004016104d790611fd2565b6000805460ff191660011790558015610a22576000805461ff0019166101001790555b610a2e8585858561118c565b8015610a74576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6033546001600160a01b0316331461046b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104d7565b606580546001600160a01b03191690556104e9816118c6565b61046b611918565b86610b0081611b32565b610b1c5760405162461bcd60e51b81526004016104d790612068565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b5c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8091906120ab565b6001600160a01b03818116600090815261010060205260409020549192508a8116911614610bc05760405162461bcd60e51b81526004016104d7906120c8565b6001600160a01b038116610bd657610bd661210d565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c1e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c4291906120ab565b6001600160a01b031614610c5857610c5861210d565b8685148015610c6657508483145b610cc05760405162461bcd60e51b815260206004820152602560248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f4c60448201526408a9c8ea8960db1b60648201526084016104d7565b604051631ac8311560e21b81526001600160a01b038a1690636b20c45490610cf49033908a908a908a908a90600401612155565b6020604051808303816000875af1158015610d13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d379190612199565b610d535760405162461bcd60e51b81526004016104d7906121b6565b60fc5460fe546040516001600160a01b03928316926316f19831921690610dae907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001612241565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610dda9291906122fc565b600060405180830381600087803b158015610df457600080fd5b505af1158015610e08573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167f7a10660242ca367951ff3777cdb3c2a761e3ccad204bac118501e24693f3683d8b8b8b8b8b8b604051610e6396959493929190612328565b60405180910390a4505050505050505050565b83610e8081611b32565b610e9c5760405162461bcd60e51b81526004016104d790612068565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610edc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f0091906120ab565b6001600160a01b0381811660009081526101006020526040902054919250878116911614610f405760405162461bcd60e51b81526004016104d7906120c8565b6001600160a01b038116610f5657610f5661210d565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f9e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fc291906120ab565b6001600160a01b031614610fd857610fd861210d565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca9061100890339088908890600401612371565b6020604051808303816000875af1158015611027573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061104b9190612199565b6110675760405162461bcd60e51b81526004016104d7906121b6565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352938416936316f19831936110f99391169160e4016122fc565b600060405180830381600087803b15801561111357600080fd5b505af1158015611127573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167f2ca9093e8b5356801039806c6a08003e5b7013fb8ae48f720fc90fc1c1a8bec233888860405161117c93929190612371565b60405180910390a4505050505050565b6001600160a01b038416158015906111ac57506001600160a01b03831615155b80156111c057506001600160a01b03821615155b80156111d457506001600160a01b03811615155b6112325760405162461bcd60e51b815260206004820152602960248201527f4368696c64455243313135355072656469636174653a204241445f494e49544960448201526820a624ad20aa24a7a760b91b60648201526084016104d7565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b60008080808061129486880188612392565b6001600160a01b0380861660009081526101006020526040902054959a509398509196509450925016806112da5760405162461bcd60e51b81526004016104d7906120c8565b6112e381611b32565b6112ef576112ef61210d565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561132f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061135391906120ab565b9050866001600160a01b0316816001600160a01b0316146113765761137661210d565b6001600160a01b03811661138c5761138c61210d565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113f891906120ab565b6001600160a01b03161461140e5761140e61210d565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f69061143e90889088908890600401612371565b6020604051808303816000875af115801561145d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114819190612199565b61149d5760405162461bcd60e51b81526004016104d7906123ed565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f2930d932c1cccd6add2e0e2d706ede9015db8a194405f2a3e1783703515e104f898888604051610e6393929190612371565b60008080808061150086880188612503565b6001600160a01b0380861660009081526101006020526040902054959b5093995091975095509350169050806115485760405162461bcd60e51b81526004016104d7906120c8565b61155181611b32565b61155d5761155d61210d565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561159d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115c191906120ab565b9050866001600160a01b0316816001600160a01b0316146115e4576115e461210d565b6001600160a01b0381166115fa576115fa61210d565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611642573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061166691906120ab565b6001600160a01b03161461167c5761167c61210d565b604051635712868360e01b81526001600160a01b038316906357128683906116ac90889088908890600401612648565b6020604051808303816000875af11580156116cb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116ef9190612199565b61170b5760405162461bcd60e51b81526004016104d7906123ed565b856001600160a01b0316826001600160a01b0316886001600160a01b03167f17304b99f8dfa5a2b8dd5695d82f9947c2abfbc9cb64bab610b9a1a0feadb9a0888888604051610e6393929190612648565b60008061176b838501856126bd565b9093509150506001600160a01b0382166117875761178761210d565b6001600160a01b038281166000908152610100602052604090205416156117b0576117b061210d565b60ff546040516bffffffffffffffffffffffff19606085901b166020820152600091611800916001600160a01b039091169060340160405160208183030381529060405280519060200120611bc7565b6001600160a01b03848116600090815261010060205260409081902080546001600160a01b0319169284169283179055516379ccf11760e11b81529192509063f399e22e9061185590869086906004016122fc565b600060405180830381600087803b15801561186f57600080fd5b505af1158015611883573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a35050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff1615611a2357604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161197a919061276d565b6000604051808303818686fa925050503d80600081146119b6576040519150601f19603f3d011682016040523d82523d6000602084013e6119bb565b606091505b50915091508180156119e057506000818060200190518101906119de9190612789565b115b611a205760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016104d7565b50505b60c954610100900460ff161561046b57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b019161138891611a8a919061276d565b6000604051808303818686fa925050503d8060008114611ac6576040519150601f19603f3d011682016040523d82523d6000602084013e611acb565b606091505b5091509150818015611af1575080806020019051810190611aec9190612789565b600114155b611b2e5760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016104d7565b5050565b6000816001600160a01b03163b600003611b4e57506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611bb5575060408051601f3d908101601f19168201909252611bb291810190612199565b60015b611bc157506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116611bc15760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016104d7565b6001600160a01b03811681146104e957600080fd5b600060208284031215611c8557600080fd5b8135611c9081611c5e565b9392505050565b60008083601f840112611ca957600080fd5b5081356001600160401b03811115611cc057600080fd5b6020830191508360208260051b8501011115611cdb57600080fd5b9250929050565b60008060008060008060006080888a031215611cfd57600080fd5b8735611d0881611c5e565b965060208801356001600160401b0380821115611d2457600080fd5b611d308b838c01611c97565b909850965060408a0135915080821115611d4957600080fd5b611d558b838c01611c97565b909650945060608a0135915080821115611d6e57600080fd5b50611d7b8a828b01611c97565b989b979a50959850939692959293505050565b600080600060608486031215611da357600080fd5b8335611dae81611c5e565b95602085013595506040909401359392505050565b60008060008060808587031215611dd957600080fd5b8435611de481611c5e565b93506020850135611df481611c5e565b93969395505050506040820135916060013590565b80151581146104e957600080fd5b600060208284031215611e2957600080fd5b8135611c9081611e09565b600080600080600080600060e0888a031215611e4f57600080fd5b8735611e5a81611c5e565b96506020880135611e6a81611c5e565b95506040880135611e7a81611c5e565b94506060880135611e8a81611c5e565b93506080880135611e9a81611e09565b925060a0880135611eaa81611e09565b915060c0880135611eba81611c5e565b8091505092959891949750929550565b60008060008060608587031215611ee057600080fd5b843593506020850135611ef281611c5e565b925060408501356001600160401b0380821115611f0e57600080fd5b818701915087601f830112611f2257600080fd5b813581811115611f3157600080fd5b886020828501011115611f4357600080fd5b95989497505060200194505050565b60008060008060808587031215611f6857600080fd5b8435611f7381611c5e565b93506020850135611f8381611c5e565b92506040850135611f9381611c5e565b91506060850135611fa381611c5e565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b6000808585111561203057600080fd5b8386111561203d57600080fd5b5050820193919092039150565b80356020831015611bc157600019602084900360031b1b1692915050565b60208082526023908201527f4368696c64455243313135355072656469636174653a204e4f545f434f4e54526040820152621050d560ea1b606082015260800190565b6000602082840312156120bd57600080fd5b8151611c9081611c5e565b60208082526025908201527f4368696c64455243313135355072656469636174653a20554e4d41505045445f6040820152642a27a5a2a760d91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561213c57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038616815260606020820181905260009061217a9083018688612123565b828103604084015261218d818587612123565b98975050505050505050565b6000602082840312156121ab57600080fd5b8151611c9081611e09565b60208082526022908201527f4368696c64455243313135355072656469636174653a204255524e5f4641494c604082015261115160f21b606082015260800190565b8183526000602080850194508260005b8581101561223657813561221b81611c5e565b6001600160a01b031687529582019590820190600101612208565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090612274908301888a6121f8565b8281036080840152612287818789612123565b905082810360a084015261229c818587612123565b9c9b505050505050505050505050565b60005b838110156122c75781810151838201526020016122af565b50506000910152565b600081518084526122e88160208601602086016122ac565b601f01601f19169290920160200192915050565b6001600160a01b0383168152604060208201819052600090612320908301846122d0565b949350505050565b60608152600061233c60608301888a6121f8565b828103602084015261234f818789612123565b90508281036040840152612364818587612123565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a086880312156123aa57600080fd5b85356123b581611c5e565b945060208601356123c581611c5e565b935060408601356123d581611c5e565b94979396509394606081013594506080013592915050565b60208082526022908201527f4368696c64455243313135355072656469636174653a204d494e545f4641494c604082015261115160f21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171561246d5761246d61242f565b604052919050565b60006001600160401b0382111561248e5761248e61242f565b5060051b60200190565b600082601f8301126124a957600080fd5b813560206124be6124b983612475565b612445565b82815260059290921b840181019181810190868411156124dd57600080fd5b8286015b848110156124f857803583529183019183016124e1565b509695505050505050565b60008060008060008060c0878903121561251c57600080fd5b8635955060208088013561252f81611c5e565b9550604088013561253f81611c5e565b945060608801356001600160401b038082111561255b57600080fd5b818a0191508a601f83011261256f57600080fd5b813561257d6124b982612475565b81815260059190911b8301840190848101908d83111561259c57600080fd5b938501935b828510156125c35784356125b481611c5e565b825293850193908501906125a1565b9750505060808a01359250808311156125db57600080fd5b6125e78b848c01612498565b945060a08a01359250808311156125fd57600080fd5b505061260b89828a01612498565b9150509295509295509295565b600081518084526020808501945080840160005b838110156122365781518752958201959082019060010161262c565b606080825284519082018190526000906020906080840190828801845b8281101561268a5781516001600160a01b031684529284019290840190600101612665565b5050508381038285015261269e8187612618565b91505082810360408401526126b38185612618565b9695505050505050565b6000806000606084860312156126d257600080fd5b833592506020808501356126e581611c5e565b925060408501356001600160401b038082111561270157600080fd5b818701915087601f83011261271557600080fd5b8135818111156127275761272761242f565b612739601f8201601f19168501612445565b9150808252888482850101111561274f57600080fd5b80848401858401376000848284010152508093505050509250925092565b6000825161277f8184602087016122ac565b9190910192915050565b60006020828403121561279b57600080fd5b505191905056fea2646970667358221220887bf471458c3e1d14f7e4d0d8309bb7ad3d8e2c50a3a70b98da790abea668b264736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101b05760003560e01c8063b1768065116100ef578063d7c9e3ec11610092578063d7c9e3ec146103a5578063d8dd1773146103cc578063e0563ab1146103df578063e30c3978146103e8578063eeb49945146103f9578063f2fde38b1461040c578063f64512551461041f578063f8c8765e1461044657600080fd5b8063b1768065146102d1578063b5c5f672146102f8578063b68ad1e41461030b578063b8cd3ec01461031e578063c1225a2014610331578063c5ac2b1c14610344578063c5e4683a1461036b578063d41f17711461037e57600080fd5b80635ea5df79116101575780635ea5df7914610247578063715018a61461025e57806379ba5097146102685780637efab4f51461027057806386937eb41461029a5780638da5cb5b146102ad578063947287cf146102be57806397e5230d146102c757600080fd5b8063051eb2e2146101b557806305dc2e8f146101e557806307b3e252146101f85780631bc114ba14610206578063284017f5146102195780633b878c221461022257806351351d531461022b57806355b01e4d14610239575b600080fd5b60fe546101c8906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b60fd546101c8906001600160a01b031681565b6101c86004600360981b0181565b60fc546101c8906001600160a01b031681565b6101c861202081565b6101c861101081565b6101c86002600160a01b0381565b6101c86004600160991b0181565b61025061138881565b6040519081526020016101dc565b610266610459565b005b61026661046d565b6101c861027e366004611c73565b610100602052600090815260409020546001600160a01b031681565b6102666102a8366004611ce2565b6104ec565b6033546001600160a01b03166101c8565b61025061520881565b610250620249f081565b6102507f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b610266610306366004611d8e565b61050c565b60ff546101c8906001600160a01b031681565b61026661032c366004611dc3565b610525565b61026661033f366004611e17565b61053f565b6102507faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b610266610379366004611e17565b61058e565b6102507f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102507f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6102666103da366004611e34565b6105d5565b6101c861203081565b6065546001600160a01b03166101c8565b610266610407366004611eca565b6106f6565b61026661041a366004611c73565b610911565b6102507f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b610266610454366004611f52565b610982565b610461610a7b565b61046b6000610ad5565b565b60655433906001600160a01b031681146104e05760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084015b60405180910390fd5b6104e981610ad5565b50565b6104f4610aee565b61050387878787878787610af6565b50505050505050565b610514610aee565b61052083338484610e76565b505050565b61052d610aee565b61053984848484610e76565b50505050565b610547610a7b565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b610596610a7b565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b03146105fc5760405163973d02cb60e01b81526004016104d790611fae565b600054610100900460ff161580801561061c5750600054600160ff909116105b806106365750303b158015610636575060005460ff166001145b6106525760405162461bcd60e51b81526004016104d790611fd2565b6000805460ff191660011790558015610675576000805461ff0019166101001790555b6106818888888861118c565b60c9805461ffff191685151561ff00191617610100851515021790556106a682610ad5565b80156106ec576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146107635760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f5354415460448201526922afa922a1a2a4ab22a960b11b60648201526084016104d7565b60fe546001600160a01b038481169116146107d35760405162461bcd60e51b815260206004820152602a60248201527f4368696c64455243313135355072656469636174653a204f4e4c595f524f4f546044820152695f50524544494341544560b01b60648201526084016104d7565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f821610802602060008486612020565b61080b9161204a565b0361082a576108256108208260208186612020565b611282565b610539565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18610859602060008486612020565b6108629161204a565b036108715761082582826114ee565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6108a0602060008486612020565b6108a99161204a565b036108b857610825828261175c565b60405162461bcd60e51b815260206004820152602860248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f5360448201526749474e415455524560c01b60648201526084016104d7565b610919610a7b565b606580546001600160a01b0383166001600160a01b0319909116811790915561094a6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b336002600160a01b03146109a95760405163973d02cb60e01b81526004016104d790611fae565b600054610100900460ff16158080156109c95750600054600160ff909116105b806109e35750303b1580156109e3575060005460ff166001145b6109ff5760405162461bcd60e51b81526004016104d790611fd2565b6000805460ff191660011790558015610a22576000805461ff0019166101001790555b610a2e8585858561118c565b8015610a74576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6033546001600160a01b0316331461046b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104d7565b606580546001600160a01b03191690556104e9816118c6565b61046b611918565b86610b0081611b32565b610b1c5760405162461bcd60e51b81526004016104d790612068565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b5c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8091906120ab565b6001600160a01b03818116600090815261010060205260409020549192508a8116911614610bc05760405162461bcd60e51b81526004016104d7906120c8565b6001600160a01b038116610bd657610bd661210d565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c1e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c4291906120ab565b6001600160a01b031614610c5857610c5861210d565b8685148015610c6657508483145b610cc05760405162461bcd60e51b815260206004820152602560248201527f4368696c64455243313135355072656469636174653a20494e56414c49445f4c60448201526408a9c8ea8960db1b60648201526084016104d7565b604051631ac8311560e21b81526001600160a01b038a1690636b20c45490610cf49033908a908a908a908a90600401612155565b6020604051808303816000875af1158015610d13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d379190612199565b610d535760405162461bcd60e51b81526004016104d7906121b6565b60fc5460fe546040516001600160a01b03928316926316f19831921690610dae907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001612241565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610dda9291906122fc565b600060405180830381600087803b158015610df457600080fd5b505af1158015610e08573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167f7a10660242ca367951ff3777cdb3c2a761e3ccad204bac118501e24693f3683d8b8b8b8b8b8b604051610e6396959493929190612328565b60405180910390a4505050505050505050565b83610e8081611b32565b610e9c5760405162461bcd60e51b81526004016104d790612068565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610edc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f0091906120ab565b6001600160a01b0381811660009081526101006020526040902054919250878116911614610f405760405162461bcd60e51b81526004016104d7906120c8565b6001600160a01b038116610f5657610f5661210d565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f9e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fc291906120ab565b6001600160a01b031614610fd857610fd861210d565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca9061100890339088908890600401612371565b6020604051808303816000875af1158015611027573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061104b9190612199565b6110675760405162461bcd60e51b81526004016104d7906121b6565b60fc5460fe54604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352938416936316f19831936110f99391169160e4016122fc565b600060405180830381600087803b15801561111357600080fd5b505af1158015611127573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167f2ca9093e8b5356801039806c6a08003e5b7013fb8ae48f720fc90fc1c1a8bec233888860405161117c93929190612371565b60405180910390a4505050505050565b6001600160a01b038416158015906111ac57506001600160a01b03831615155b80156111c057506001600160a01b03821615155b80156111d457506001600160a01b03811615155b6112325760405162461bcd60e51b815260206004820152602960248201527f4368696c64455243313135355072656469636174653a204241445f494e49544960448201526820a624ad20aa24a7a760b91b60648201526084016104d7565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b60008080808061129486880188612392565b6001600160a01b0380861660009081526101006020526040902054959a509398509196509450925016806112da5760405162461bcd60e51b81526004016104d7906120c8565b6112e381611b32565b6112ef576112ef61210d565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561132f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061135391906120ab565b9050866001600160a01b0316816001600160a01b0316146113765761137661210d565b6001600160a01b03811661138c5761138c61210d565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113f891906120ab565b6001600160a01b03161461140e5761140e61210d565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f69061143e90889088908890600401612371565b6020604051808303816000875af115801561145d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114819190612199565b61149d5760405162461bcd60e51b81526004016104d7906123ed565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f2930d932c1cccd6add2e0e2d706ede9015db8a194405f2a3e1783703515e104f898888604051610e6393929190612371565b60008080808061150086880188612503565b6001600160a01b0380861660009081526101006020526040902054959b5093995091975095509350169050806115485760405162461bcd60e51b81526004016104d7906120c8565b61155181611b32565b61155d5761155d61210d565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561159d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115c191906120ab565b9050866001600160a01b0316816001600160a01b0316146115e4576115e461210d565b6001600160a01b0381166115fa576115fa61210d565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611642573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061166691906120ab565b6001600160a01b03161461167c5761167c61210d565b604051635712868360e01b81526001600160a01b038316906357128683906116ac90889088908890600401612648565b6020604051808303816000875af11580156116cb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116ef9190612199565b61170b5760405162461bcd60e51b81526004016104d7906123ed565b856001600160a01b0316826001600160a01b0316886001600160a01b03167f17304b99f8dfa5a2b8dd5695d82f9947c2abfbc9cb64bab610b9a1a0feadb9a0888888604051610e6393929190612648565b60008061176b838501856126bd565b9093509150506001600160a01b0382166117875761178761210d565b6001600160a01b038281166000908152610100602052604090205416156117b0576117b061210d565b60ff546040516bffffffffffffffffffffffff19606085901b166020820152600091611800916001600160a01b039091169060340160405160208183030381529060405280519060200120611bc7565b6001600160a01b03848116600090815261010060205260409081902080546001600160a01b0319169284169283179055516379ccf11760e11b81529192509063f399e22e9061185590869086906004016122fc565b600060405180830381600087803b15801561186f57600080fd5b505af1158015611883573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f46bd56f98e1b14fd35691959270a6e1edf7cb8fcd489e0f9dda89e46c0d1ff0d90600090a35050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff1615611a2357604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161197a919061276d565b6000604051808303818686fa925050503d80600081146119b6576040519150601f19603f3d011682016040523d82523d6000602084013e6119bb565b606091505b50915091508180156119e057506000818060200190518101906119de9190612789565b115b611a205760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016104d7565b50505b60c954610100900460ff161561046b57604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b019161138891611a8a919061276d565b6000604051808303818686fa925050503d8060008114611ac6576040519150601f19603f3d011682016040523d82523d6000602084013e611acb565b606091505b5091509150818015611af1575080806020019051810190611aec9190612789565b600114155b611b2e5760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016104d7565b5050565b6000816001600160a01b03163b600003611b4e57506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611bb5575060408051601f3d908101601f19168201909252611bb291810190612199565b60015b611bc157506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116611bc15760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016104d7565b6001600160a01b03811681146104e957600080fd5b600060208284031215611c8557600080fd5b8135611c9081611c5e565b9392505050565b60008083601f840112611ca957600080fd5b5081356001600160401b03811115611cc057600080fd5b6020830191508360208260051b8501011115611cdb57600080fd5b9250929050565b60008060008060008060006080888a031215611cfd57600080fd5b8735611d0881611c5e565b965060208801356001600160401b0380821115611d2457600080fd5b611d308b838c01611c97565b909850965060408a0135915080821115611d4957600080fd5b611d558b838c01611c97565b909650945060608a0135915080821115611d6e57600080fd5b50611d7b8a828b01611c97565b989b979a50959850939692959293505050565b600080600060608486031215611da357600080fd5b8335611dae81611c5e565b95602085013595506040909401359392505050565b60008060008060808587031215611dd957600080fd5b8435611de481611c5e565b93506020850135611df481611c5e565b93969395505050506040820135916060013590565b80151581146104e957600080fd5b600060208284031215611e2957600080fd5b8135611c9081611e09565b600080600080600080600060e0888a031215611e4f57600080fd5b8735611e5a81611c5e565b96506020880135611e6a81611c5e565b95506040880135611e7a81611c5e565b94506060880135611e8a81611c5e565b93506080880135611e9a81611e09565b925060a0880135611eaa81611e09565b915060c0880135611eba81611c5e565b8091505092959891949750929550565b60008060008060608587031215611ee057600080fd5b843593506020850135611ef281611c5e565b925060408501356001600160401b0380821115611f0e57600080fd5b818701915087601f830112611f2257600080fd5b813581811115611f3157600080fd5b886020828501011115611f4357600080fd5b95989497505060200194505050565b60008060008060808587031215611f6857600080fd5b8435611f7381611c5e565b93506020850135611f8381611c5e565b92506040850135611f9381611c5e565b91506060850135611fa381611c5e565b939692955090935050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b6000808585111561203057600080fd5b8386111561203d57600080fd5b5050820193919092039150565b80356020831015611bc157600019602084900360031b1b1692915050565b60208082526023908201527f4368696c64455243313135355072656469636174653a204e4f545f434f4e54526040820152621050d560ea1b606082015260800190565b6000602082840312156120bd57600080fd5b8151611c9081611c5e565b60208082526025908201527f4368696c64455243313135355072656469636174653a20554e4d41505045445f6040820152642a27a5a2a760d91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561213c57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038616815260606020820181905260009061217a9083018688612123565b828103604084015261218d818587612123565b98975050505050505050565b6000602082840312156121ab57600080fd5b8151611c9081611e09565b60208082526022908201527f4368696c64455243313135355072656469636174653a204255524e5f4641494c604082015261115160f21b606082015260800190565b8183526000602080850194508260005b8581101561223657813561221b81611c5e565b6001600160a01b031687529582019590820190600101612208565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090612274908301888a6121f8565b8281036080840152612287818789612123565b905082810360a084015261229c818587612123565b9c9b505050505050505050505050565b60005b838110156122c75781810151838201526020016122af565b50506000910152565b600081518084526122e88160208601602086016122ac565b601f01601f19169290920160200192915050565b6001600160a01b0383168152604060208201819052600090612320908301846122d0565b949350505050565b60608152600061233c60608301888a6121f8565b828103602084015261234f818789612123565b90508281036040840152612364818587612123565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a086880312156123aa57600080fd5b85356123b581611c5e565b945060208601356123c581611c5e565b935060408601356123d581611c5e565b94979396509394606081013594506080013592915050565b60208082526022908201527f4368696c64455243313135355072656469636174653a204d494e545f4641494c604082015261115160f21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171561246d5761246d61242f565b604052919050565b60006001600160401b0382111561248e5761248e61242f565b5060051b60200190565b600082601f8301126124a957600080fd5b813560206124be6124b983612475565b612445565b82815260059290921b840181019181810190868411156124dd57600080fd5b8286015b848110156124f857803583529183019183016124e1565b509695505050505050565b60008060008060008060c0878903121561251c57600080fd5b8635955060208088013561252f81611c5e565b9550604088013561253f81611c5e565b945060608801356001600160401b038082111561255b57600080fd5b818a0191508a601f83011261256f57600080fd5b813561257d6124b982612475565b81815260059190911b8301840190848101908d83111561259c57600080fd5b938501935b828510156125c35784356125b481611c5e565b825293850193908501906125a1565b9750505060808a01359250808311156125db57600080fd5b6125e78b848c01612498565b945060a08a01359250808311156125fd57600080fd5b505061260b89828a01612498565b9150509295509295509295565b600081518084526020808501945080840160005b838110156122365781518752958201959082019060010161262c565b606080825284519082018190526000906020906080840190828801845b8281101561268a5781516001600160a01b031684529284019290840190600101612665565b5050508381038285015261269e8187612618565b91505082810360408401526126b38185612618565b9695505050505050565b6000806000606084860312156126d257600080fd5b833592506020808501356126e581611c5e565b925060408501356001600160401b038082111561270157600080fd5b818701915087601f83011261271557600080fd5b8135818111156127275761272761242f565b612739601f8201601f19168501612445565b9150808252888482850101111561274f57600080fd5b80848401858401376000848284010152508093505050509250925092565b6000825161277f8184602087016122ac565b9190910192915050565b60006020828403121561279b57600080fd5b505191905056fea2646970667358221220887bf471458c3e1d14f7e4d0d8309bb7ad3d8e2c50a3a70b98da790abea668b264736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var RootMintableERC1155PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC1155Predicate","sourceName":"contracts/blade/RootMintableERC1155Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2MintableERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2MintableERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"childToken","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155BatchReceived","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611c01806100206000396000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c8063b68ad1e4116100ad578063eeb4994511610071578063eeb49945146102fe578063f23a6e6114610311578063f4a120f714610330578063f645125514610343578063f8c8765e1461036a57600080fd5b8063b68ad1e41461023e578063bc197c8114610251578063c5ac2b1c14610289578063d41f1771146102b0578063d7c9e3ec146102d757600080fd5b80634c4c45de116100f45780634c4c45de146101a7578063654715e6146101ba5780637efab4f5146101cd578063a78e111c146101f6578063b17680651461020957600080fd5b806301ffc9a71461012657806305dc2e8f1461014e5780630efe6a8b146101795780631bc114ba1461018e575b600080fd5b610139610134366004611182565b61037d565b60405190151581526020015b60405180910390f35b600154610161906001600160a01b031681565b6040516001600160a01b039091168152602001610145565b61018c6101873660046111cb565b6103b4565b005b600054610161906201000090046001600160a01b031681565b61018c6101b536600461124b565b6103c5565b600254610161906001600160a01b031681565b6101616101db3660046112f7565b6004602052600090815260409020546001600160a01b031681565b61018c610204366004611314565b61043f565b6102307f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610145565b600354610161906001600160a01b031681565b61027061025f3660046114a6565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610145565b6102307faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6102307f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102307f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61018c61030c366004611553565b610451565b61027061031f3660046115db565b63f23a6e6160e01b95945050505050565b61016161033e3660046112f7565b610629565b6102307f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61018c610378366004611643565b610944565b60006001600160e01b03198216630271189760e51b14806103ae57506301ffc9a760e01b6001600160e01b03198316145b92915050565b6103c083338484610a5d565b505050565b84831480156103d357508481145b6104275760405162461bcd60e51b815260206004820152602c6024820152600080516020611bac83398151915260448201526b0ac82989288be988a9c8ea8960a31b60648201526084015b60405180910390fd5b61043687878787878787610bf3565b50505050505050565b61044b84848484610a5d565b50505050565b6001546001600160a01b031633146104c55760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e604482015270262cafa9aa20aa22afa922a1a2a4ab22a960791b606482015260840161041e565b6002546001600160a01b0384811691161461053d5760405162461bcd60e51b815260206004820152603260248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e6044820152714c595f4348494c445f50524544494341544560701b606482015260840161041e565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961056c60206000848661169f565b610575916116c9565b036105945761058f61058a826020818661169f565b610dd3565b61044b565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26105c360206000848661169f565b6105cc916116c9565b036105db5761058f8282610ed2565b60405162461bcd60e51b815260206004820152602f6024820152600080516020611bac83398151915260448201526e56414c49445f5349474e415455524560881b606482015260840161041e565b60006001600160a01b0382166106835760405162461bcd60e51b815260206004820152602b6024820152600080516020611bac83398151915260448201526a2b20a624a22faa27a5a2a760a91b606482015260840161041e565b6001600160a01b0382811660009081526004602052604090205416156107005760405162461bcd60e51b815260206004820152602c60248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20414c60448201526b149150511657d3505414115160a21b606482015260840161041e565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b03928316926107aa921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03848116600081815260046020818152604080842080546001600160a01b031916968816969096179095558451908101855282815293516303a24d0760e21b8152908101919091529294509091630e89341c90602401600060405180830381865afa92505050801561084557506040513d6000823e601f3d908101601f19168201604052610842919081019061170b565b60015b1561084d5790505b600060029054906101000a90046001600160a01b03166001600160a01b03166316f19831837f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad87856040516020016108a7939291906117ad565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108d39291906117d7565b600060405180830381600087803b1580156108ed57600080fd5b505af1158015610901573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a35050919050565b600054610100900460ff16158080156109645750600054600160ff909116105b8061097e5750303b15801561097e575060005460ff166001145b6109e15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161041e565b6000805460ff191660011790558015610a04576000805461ff0019166101001790555b610a1085858585611033565b8015610a56576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6000610a688561113b565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610a9d903390309088908890600401611803565b600060405180830381600087803b158015610ab757600080fd5b505af1158015610acb573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935262010000909404841695506316f198319450610b68939092169160e4016117d7565b600060405180830381600087803b158015610b8257600080fd5b505af1158015610b96573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fe6f1fb6bb1930a5d4b997d56e0a4a8cb6f3f941f0d5391f63c1f6914ee01e0b89060600160405180910390a4610a56565b6000610bfe8861113b565b905060005b84811015610caa57886001600160a01b031663f242432a3330898986818110610c2e57610c2e61183b565b90506020020135888887818110610c4757610c4761183b565b905060200201356040518563ffffffff1660e01b8152600401610c6d9493929190611803565b600060405180830381600087803b158015610c8757600080fd5b505af1158015610c9b573d6000803e3d6000fd5b50505050806001019050610c03565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610d0c907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e906020016118cc565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d389291906117d7565b600060405180830381600087803b158015610d5257600080fd5b505af1158015610d66573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167fa7d9cd27143f817fe006011faf3c04351f70f75cd30e7b21405817f2f670041e8a8a8a8a8a8a604051610dc196959493929190611937565b60405180910390a45050505050505050565b600080808080610de586880188611980565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610e1a57610e1a6119db565b604051637921219560e11b81526001600160a01b0387169063f242432a90610e4c903090889088908890600401611803565b600060405180830381600087803b158015610e6657600080fd5b505af1158015610e7a573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907f52cdfbe452878311d3237a4c20a951600d8e3a4fe6691d967d33788dc12d19c690606001610dc1565b600080808080610ee4868801886119f1565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080610f1b57610f1b6119db565b60005b8351811015610fe157866001600160a01b031663f242432a30878481518110610f4957610f4961183b565b6020026020010151878581518110610f6357610f6361183b565b6020026020010151878681518110610f7d57610f7d61183b565b60200260200101516040518563ffffffff1660e01b8152600401610fa49493929190611803565b600060405180830381600087803b158015610fbe57600080fd5b505af1158015610fd2573d6000803e3d6000fd5b50505050806001019050610f1e565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167f52733a40a0466155541c2fc4044165dd37a3db116bc834bab2f020665e90fd20878787604051610dc193929190611b36565b6001600160a01b0384161580159061105357506001600160a01b03831615155b801561106757506001600160a01b03821615155b801561107b57506001600160a01b03811615155b6110e05760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b606482015260840161041e565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6001600160a01b0380821660009081526004602052604090205416806111675761116482610629565b90505b6001600160a01b03811661117d5761117d6119db565b919050565b60006020828403121561119457600080fd5b81356001600160e01b0319811681146111ac57600080fd5b9392505050565b6001600160a01b03811681146111c857600080fd5b50565b6000806000606084860312156111e057600080fd5b83356111eb816111b3565b95602085013595506040909401359392505050565b60008083601f84011261121257600080fd5b5081356001600160401b0381111561122957600080fd5b6020830191508360208260051b850101111561124457600080fd5b9250929050565b60008060008060008060006080888a03121561126657600080fd5b8735611271816111b3565b965060208801356001600160401b038082111561128d57600080fd5b6112998b838c01611200565b909850965060408a01359150808211156112b257600080fd5b6112be8b838c01611200565b909650945060608a01359150808211156112d757600080fd5b506112e48a828b01611200565b989b979a50959850939692959293505050565b60006020828403121561130957600080fd5b81356111ac816111b3565b6000806000806080858703121561132a57600080fd5b8435611335816111b3565b93506020850135611345816111b3565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156113985761139861135a565b604052919050565b60006001600160401b038211156113b9576113b961135a565b5060051b60200190565b600082601f8301126113d457600080fd5b813560206113e96113e4836113a0565b611370565b82815260059290921b8401810191818101908684111561140857600080fd5b8286015b84811015611423578035835291830191830161140c565b509695505050505050565b60006001600160401b038211156114475761144761135a565b50601f01601f191660200190565b600082601f83011261146657600080fd5b81356114746113e48261142e565b81815284602083860101111561148957600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156114be57600080fd5b85356114c9816111b3565b945060208601356114d9816111b3565b935060408601356001600160401b03808211156114f557600080fd5b61150189838a016113c3565b9450606088013591508082111561151757600080fd5b61152389838a016113c3565b9350608088013591508082111561153957600080fd5b5061154688828901611455565b9150509295509295909350565b6000806000806060858703121561156957600080fd5b84359350602085013561157b816111b3565b925060408501356001600160401b038082111561159757600080fd5b818701915087601f8301126115ab57600080fd5b8135818111156115ba57600080fd5b8860208285010111156115cc57600080fd5b95989497505060200194505050565b600080600080600060a086880312156115f357600080fd5b85356115fe816111b3565b9450602086013561160e816111b3565b9350604086013592506060860135915060808601356001600160401b0381111561163757600080fd5b61154688828901611455565b6000806000806080858703121561165957600080fd5b8435611664816111b3565b93506020850135611674816111b3565b92506040850135611684816111b3565b91506060850135611694816111b3565b939692955090935050565b600080858511156116af57600080fd5b838611156116bc57600080fd5b5050820193919092039150565b803560208310156103ae57600019602084900360031b1b1692915050565b60005b838110156117025781810151838201526020016116ea565b50506000910152565b60006020828403121561171d57600080fd5b81516001600160401b0381111561173357600080fd5b8201601f8101841361174457600080fd5b80516117526113e48261142e565b81815285602083850101111561176757600080fd5b6117788260208301602086016116e7565b95945050505050565b600081518084526117998160208601602086016116e7565b601f01601f19169290920160200192915050565b8381526001600160a01b038316602082015260606040820181905260009061177890830184611781565b6001600160a01b03831681526040602082018190526000906117fb90830184611781565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b8581101561188f578135611874816111b3565b6001600160a01b031687529582019590820190600101611861565b509495945050505050565b81835260006001600160fb1b038311156118b357600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c0606082018190526000906118ff908301888a611851565b828103608084015261191281878961189a565b905082810360a084015261192781858761189a565b9c9b505050505050505050505050565b60608152600061194b60608301888a611851565b828103602084015261195e81878961189a565b9050828103604084015261197381858761189a565b9998505050505050505050565b600080600080600060a0868803121561199857600080fd5b85356119a3816111b3565b945060208601356119b3816111b3565b935060408601356119c3816111b3565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c08789031215611a0a57600080fd5b86359550602080880135611a1d816111b3565b95506040880135611a2d816111b3565b945060608801356001600160401b0380821115611a4957600080fd5b818a0191508a601f830112611a5d57600080fd5b8135611a6b6113e4826113a0565b81815260059190911b8301840190848101908d831115611a8a57600080fd5b938501935b82851015611ab1578435611aa2816111b3565b82529385019390850190611a8f565b9750505060808a0135925080831115611ac957600080fd5b611ad58b848c016113c3565b945060a08a0135925080831115611aeb57600080fd5b5050611af989828a016113c3565b9150509295509295509295565b600081518084526020808501945080840160005b8381101561188f57815187529582019590820190600101611b1a565b606080825284519082018190526000906020906080840190828801845b82811015611b785781516001600160a01b031684529284019290840190600101611b53565b50505083810382850152611b8c8187611b06565b9150508281036040840152611ba18185611b06565b969550505050505056fe526f6f744d696e7461626c65455243313135355072656469636174653a20494ea2646970667358221220c6c2c51460c32206787a2a64b080348b9a559444d6cdc3ed1faaeff0cc95312164736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101215760003560e01c8063b68ad1e4116100ad578063eeb4994511610071578063eeb49945146102fe578063f23a6e6114610311578063f4a120f714610330578063f645125514610343578063f8c8765e1461036a57600080fd5b8063b68ad1e41461023e578063bc197c8114610251578063c5ac2b1c14610289578063d41f1771146102b0578063d7c9e3ec146102d757600080fd5b80634c4c45de116100f45780634c4c45de146101a7578063654715e6146101ba5780637efab4f5146101cd578063a78e111c146101f6578063b17680651461020957600080fd5b806301ffc9a71461012657806305dc2e8f1461014e5780630efe6a8b146101795780631bc114ba1461018e575b600080fd5b610139610134366004611182565b61037d565b60405190151581526020015b60405180910390f35b600154610161906001600160a01b031681565b6040516001600160a01b039091168152602001610145565b61018c6101873660046111cb565b6103b4565b005b600054610161906201000090046001600160a01b031681565b61018c6101b536600461124b565b6103c5565b600254610161906001600160a01b031681565b6101616101db3660046112f7565b6004602052600090815260409020546001600160a01b031681565b61018c610204366004611314565b61043f565b6102307f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610145565b600354610161906001600160a01b031681565b61027061025f3660046114a6565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610145565b6102307faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6102307f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102307f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61018c61030c366004611553565b610451565b61027061031f3660046115db565b63f23a6e6160e01b95945050505050565b61016161033e3660046112f7565b610629565b6102307f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61018c610378366004611643565b610944565b60006001600160e01b03198216630271189760e51b14806103ae57506301ffc9a760e01b6001600160e01b03198316145b92915050565b6103c083338484610a5d565b505050565b84831480156103d357508481145b6104275760405162461bcd60e51b815260206004820152602c6024820152600080516020611bac83398151915260448201526b0ac82989288be988a9c8ea8960a31b60648201526084015b60405180910390fd5b61043687878787878787610bf3565b50505050505050565b61044b84848484610a5d565b50505050565b6001546001600160a01b031633146104c55760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e604482015270262cafa9aa20aa22afa922a1a2a4ab22a960791b606482015260840161041e565b6002546001600160a01b0384811691161461053d5760405162461bcd60e51b815260206004820152603260248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e6044820152714c595f4348494c445f50524544494341544560701b606482015260840161041e565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961056c60206000848661169f565b610575916116c9565b036105945761058f61058a826020818661169f565b610dd3565b61044b565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26105c360206000848661169f565b6105cc916116c9565b036105db5761058f8282610ed2565b60405162461bcd60e51b815260206004820152602f6024820152600080516020611bac83398151915260448201526e56414c49445f5349474e415455524560881b606482015260840161041e565b60006001600160a01b0382166106835760405162461bcd60e51b815260206004820152602b6024820152600080516020611bac83398151915260448201526a2b20a624a22faa27a5a2a760a91b606482015260840161041e565b6001600160a01b0382811660009081526004602052604090205416156107005760405162461bcd60e51b815260206004820152602c60248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20414c60448201526b149150511657d3505414115160a21b606482015260840161041e565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b03928316926107aa921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03848116600081815260046020818152604080842080546001600160a01b031916968816969096179095558451908101855282815293516303a24d0760e21b8152908101919091529294509091630e89341c90602401600060405180830381865afa92505050801561084557506040513d6000823e601f3d908101601f19168201604052610842919081019061170b565b60015b1561084d5790505b600060029054906101000a90046001600160a01b03166001600160a01b03166316f19831837f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad87856040516020016108a7939291906117ad565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108d39291906117d7565b600060405180830381600087803b1580156108ed57600080fd5b505af1158015610901573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a35050919050565b600054610100900460ff16158080156109645750600054600160ff909116105b8061097e5750303b15801561097e575060005460ff166001145b6109e15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161041e565b6000805460ff191660011790558015610a04576000805461ff0019166101001790555b610a1085858585611033565b8015610a56576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6000610a688561113b565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610a9d903390309088908890600401611803565b600060405180830381600087803b158015610ab757600080fd5b505af1158015610acb573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935262010000909404841695506316f198319450610b68939092169160e4016117d7565b600060405180830381600087803b158015610b8257600080fd5b505af1158015610b96573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fe6f1fb6bb1930a5d4b997d56e0a4a8cb6f3f941f0d5391f63c1f6914ee01e0b89060600160405180910390a4610a56565b6000610bfe8861113b565b905060005b84811015610caa57886001600160a01b031663f242432a3330898986818110610c2e57610c2e61183b565b90506020020135888887818110610c4757610c4761183b565b905060200201356040518563ffffffff1660e01b8152600401610c6d9493929190611803565b600060405180830381600087803b158015610c8757600080fd5b505af1158015610c9b573d6000803e3d6000fd5b50505050806001019050610c03565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610d0c907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e906020016118cc565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d389291906117d7565b600060405180830381600087803b158015610d5257600080fd5b505af1158015610d66573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167fa7d9cd27143f817fe006011faf3c04351f70f75cd30e7b21405817f2f670041e8a8a8a8a8a8a604051610dc196959493929190611937565b60405180910390a45050505050505050565b600080808080610de586880188611980565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610e1a57610e1a6119db565b604051637921219560e11b81526001600160a01b0387169063f242432a90610e4c903090889088908890600401611803565b600060405180830381600087803b158015610e6657600080fd5b505af1158015610e7a573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907f52cdfbe452878311d3237a4c20a951600d8e3a4fe6691d967d33788dc12d19c690606001610dc1565b600080808080610ee4868801886119f1565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080610f1b57610f1b6119db565b60005b8351811015610fe157866001600160a01b031663f242432a30878481518110610f4957610f4961183b565b6020026020010151878581518110610f6357610f6361183b565b6020026020010151878681518110610f7d57610f7d61183b565b60200260200101516040518563ffffffff1660e01b8152600401610fa49493929190611803565b600060405180830381600087803b158015610fbe57600080fd5b505af1158015610fd2573d6000803e3d6000fd5b50505050806001019050610f1e565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167f52733a40a0466155541c2fc4044165dd37a3db116bc834bab2f020665e90fd20878787604051610dc193929190611b36565b6001600160a01b0384161580159061105357506001600160a01b03831615155b801561106757506001600160a01b03821615155b801561107b57506001600160a01b03811615155b6110e05760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b606482015260840161041e565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6001600160a01b0380821660009081526004602052604090205416806111675761116482610629565b90505b6001600160a01b03811661117d5761117d6119db565b919050565b60006020828403121561119457600080fd5b81356001600160e01b0319811681146111ac57600080fd5b9392505050565b6001600160a01b03811681146111c857600080fd5b50565b6000806000606084860312156111e057600080fd5b83356111eb816111b3565b95602085013595506040909401359392505050565b60008083601f84011261121257600080fd5b5081356001600160401b0381111561122957600080fd5b6020830191508360208260051b850101111561124457600080fd5b9250929050565b60008060008060008060006080888a03121561126657600080fd5b8735611271816111b3565b965060208801356001600160401b038082111561128d57600080fd5b6112998b838c01611200565b909850965060408a01359150808211156112b257600080fd5b6112be8b838c01611200565b909650945060608a01359150808211156112d757600080fd5b506112e48a828b01611200565b989b979a50959850939692959293505050565b60006020828403121561130957600080fd5b81356111ac816111b3565b6000806000806080858703121561132a57600080fd5b8435611335816111b3565b93506020850135611345816111b3565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156113985761139861135a565b604052919050565b60006001600160401b038211156113b9576113b961135a565b5060051b60200190565b600082601f8301126113d457600080fd5b813560206113e96113e4836113a0565b611370565b82815260059290921b8401810191818101908684111561140857600080fd5b8286015b84811015611423578035835291830191830161140c565b509695505050505050565b60006001600160401b038211156114475761144761135a565b50601f01601f191660200190565b600082601f83011261146657600080fd5b81356114746113e48261142e565b81815284602083860101111561148957600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156114be57600080fd5b85356114c9816111b3565b945060208601356114d9816111b3565b935060408601356001600160401b03808211156114f557600080fd5b61150189838a016113c3565b9450606088013591508082111561151757600080fd5b61152389838a016113c3565b9350608088013591508082111561153957600080fd5b5061154688828901611455565b9150509295509295909350565b6000806000806060858703121561156957600080fd5b84359350602085013561157b816111b3565b925060408501356001600160401b038082111561159757600080fd5b818701915087601f8301126115ab57600080fd5b8135818111156115ba57600080fd5b8860208285010111156115cc57600080fd5b95989497505060200194505050565b600080600080600060a086880312156115f357600080fd5b85356115fe816111b3565b9450602086013561160e816111b3565b9350604086013592506060860135915060808601356001600160401b0381111561163757600080fd5b61154688828901611455565b6000806000806080858703121561165957600080fd5b8435611664816111b3565b93506020850135611674816111b3565b92506040850135611684816111b3565b91506060850135611694816111b3565b939692955090935050565b600080858511156116af57600080fd5b838611156116bc57600080fd5b5050820193919092039150565b803560208310156103ae57600019602084900360031b1b1692915050565b60005b838110156117025781810151838201526020016116ea565b50506000910152565b60006020828403121561171d57600080fd5b81516001600160401b0381111561173357600080fd5b8201601f8101841361174457600080fd5b80516117526113e48261142e565b81815285602083850101111561176757600080fd5b6117788260208301602086016116e7565b95945050505050565b600081518084526117998160208601602086016116e7565b601f01601f19169290920160200192915050565b8381526001600160a01b038316602082015260606040820181905260009061177890830184611781565b6001600160a01b03831681526040602082018190526000906117fb90830184611781565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b8581101561188f578135611874816111b3565b6001600160a01b031687529582019590820190600101611861565b509495945050505050565b81835260006001600160fb1b038311156118b357600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c0606082018190526000906118ff908301888a611851565b828103608084015261191281878961189a565b905082810360a084015261192781858761189a565b9c9b505050505050505050505050565b60608152600061194b60608301888a611851565b828103602084015261195e81878961189a565b9050828103604084015261197381858761189a565b9998505050505050505050565b600080600080600060a0868803121561199857600080fd5b85356119a3816111b3565b945060208601356119b3816111b3565b935060408601356119c3816111b3565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c08789031215611a0a57600080fd5b86359550602080880135611a1d816111b3565b95506040880135611a2d816111b3565b945060608801356001600160401b0380821115611a4957600080fd5b818a0191508a601f830112611a5d57600080fd5b8135611a6b6113e4826113a0565b81815260059190911b8301840190848101908d831115611a8a57600080fd5b938501935b82851015611ab1578435611aa2816111b3565b82529385019390850190611a8f565b9750505060808a0135925080831115611ac957600080fd5b611ad58b848c016113c3565b945060a08a0135925080831115611aeb57600080fd5b5050611af989828a016113c3565b9150509295509295509295565b600081518084526020808501945080840160005b8381101561188f57815187529582019590820190600101611b1a565b606080825284519082018190526000906020906080840190828801845b82811015611b785781516001600160a01b031684529284019290840190600101611b53565b50505083810382850152611b8c8187611b06565b9150508281036040840152611ba18185611b06565b969550505050505056fe526f6f744d696e7461626c65455243313135355072656469636174653a20494ea2646970667358221220c6c2c51460c32206787a2a64b080348b9a559444d6cdc3ed1faaeff0cc95312164736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var RootMintableERC1155PredicateACLArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootMintableERC1155PredicateAccessList","sourceName":"contracts/blade/RootMintableERC1155PredicateAccessList.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"AllowListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"block","type":"uint256"},{"indexed":true,"internalType":"bool","name":"status","type":"bool"}],"name":"BlockListUsageSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2MintableERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"L2MintableERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"L2MintableERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"L2MintableTokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"childERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"bool","name":"newUseAllowList","type":"bool"},{"internalType":"bool","name":"newUseBlockList","type":"bool"},{"internalType":"address","name":"newOwner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newL2StateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newChildERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l2StateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"childToken","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155BatchReceived","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseAllowList","type":"bool"}],"name":"setAllowList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"newUseBlockList","type":"bool"}],"name":"setBlockList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stateReceiver","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612480806100206000396000f3fe608060405234801561001057600080fd5b506004361061021c5760003560e01c8063a78e111c11610125578063d8dd1773116100ad578063f23a6e611161007c578063f23a6e61146104d3578063f2fde38b146104f2578063f4a120f714610505578063f645125514610518578063f8c8765e1461053f57600080fd5b8063d8dd177314610493578063e0563ab1146104a6578063e30c3978146104af578063eeb49945146104c057600080fd5b8063c1225a20116100f4578063c1225a20146103f8578063c5ac2b1c1461040b578063c5e4683a14610432578063d41f177114610445578063d7c9e3ec1461046c57600080fd5b8063a78e111c14610373578063b176806514610386578063b68ad1e4146103ad578063bc197c81146103c057600080fd5b806355b01e4d116101a857806379ba50971161017757806379ba50971461031d5780637efab4f5146103255780638da5cb5b1461034f578063947287cf1461036057806397e5230d1461036957600080fd5b806355b01e4d146102dd5780635ea5df79146102eb578063654715e614610302578063715018a61461031557600080fd5b80631bc114ba116101ef5780631bc114ba14610297578063284017f5146102aa5780633b878c22146102b35780634c4c45de146102bc57806351351d53146102cf57600080fd5b806301ffc9a71461022157806305dc2e8f1461024957806307b3e252146102745780630efe6a8b14610282575b600080fd5b61023461022f3660046118c4565b610552565b60405190151581526020015b60405180910390f35b60fd5461025c906001600160a01b031681565b6040516001600160a01b039091168152602001610240565b61025c6004600360981b0181565b61029561029036600461190a565b610589565b005b60fc5461025c906001600160a01b031681565b61025c61202081565b61025c61101081565b6102956102ca36600461198a565b61059a565b61025c6002600160a01b0381565b61025c6004600160991b0181565b6102f461138881565b604051908152602001610240565b60fe5461025c906001600160a01b031681565b610295610614565b610295610628565b61025c610333366004611a36565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b031661025c565b6102f461520881565b6102f4620249f081565b610295610381366004611a53565b6106a2565b6102f47f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff5461025c906001600160a01b031681565b6103df6103ce366004611be5565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610240565b610295610406366004611ca2565b6106b4565b6102f47faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b610295610440366004611ca2565b610703565b6102f47f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102f47f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6102956104a1366004611cbd565b61074a565b61025c61203081565b6065546001600160a01b031661025c565b6102956104ce366004611d4f565b610888565b6103df6104e1366004611dd7565b63f23a6e6160e01b95945050505050565b610295610500366004611a36565b610a60565b61025c610513366004611a36565b610ad1565b6102f47f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61029561054d366004611e3f565b610de1565b60006001600160e01b03198216630271189760e51b148061058357506301ffc9a760e01b6001600160e01b03198316145b92915050565b61059583338484610eb3565b505050565b84831480156105a857508481145b6105fc5760405162461bcd60e51b815260206004820152602c602482015260008051602061242b83398151915260448201526b0ac82989288be988a9c8ea8960a31b60648201526084015b60405180910390fd5b61060b8787878787878761104b565b50505050505050565b61061c611228565b6106266000611282565b565b60655433906001600160a01b031681146106965760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016105f3565b61069f81611282565b50565b6106ae84848484610eb3565b50505050565b6106bc611228565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b61070b611228565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b031461078e5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064016105f3565b600054610100900460ff16158080156107ae5750600054600160ff909116105b806107c85750303b1580156107c8575060005460ff166001145b6107e45760405162461bcd60e51b81526004016105f390611e9b565b6000805460ff191660011790558015610807576000805461ff0019166101001790555b6108138888888861129b565b60c9805461ffff191685151561ff001916176101008515150217905561083882611282565b801561087e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146108fc5760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e604482015270262cafa9aa20aa22afa922a1a2a4ab22a960791b60648201526084016105f3565b60fe546001600160a01b038481169116146109745760405162461bcd60e51b815260206004820152603260248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e6044820152714c595f4348494c445f50524544494341544560701b60648201526084016105f3565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696109a3602060008486611ee9565b6109ac91611f13565b036109cb576109c66109c18260208186611ee9565b611398565b6106ae565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26109fa602060008486611ee9565b610a0391611f13565b03610a12576109c682826114a6565b60405162461bcd60e51b815260206004820152602f602482015260008051602061242b83398151915260448201526e56414c49445f5349474e415455524560881b60648201526084016105f3565b610a68611228565b606580546001600160a01b0383166001600160a01b03199091168117909155610a996033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b038216610b2b5760405162461bcd60e51b815260206004820152602b602482015260008051602061242b83398151915260448201526a2b20a624a22faa27a5a2a760a91b60648201526084016105f3565b6001600160a01b03828116600090815261010060205260409020541615610ba95760405162461bcd60e51b815260206004820152602c60248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20414c60448201526b149150511657d3505414115160a21b60648201526084016105f3565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692610c53921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0384811660008181526101006020908152604080832080546001600160a01b031916958716959095179094558351908101845281815292516303a24d0760e21b815260048101919091529294509091630e89341c90602401600060405180830381865afa925050508015610cf057506040513d6000823e601f3d908101601f19168201604052610ced9190810190611f55565b60015b15610cf85790505b60fc546040516001600160a01b03909116906316f19831908490610d44907f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad9089908790602001611ff7565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d70929190612021565b600060405180830381600087803b158015610d8a57600080fd5b505af1158015610d9e573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a35050919050565b600054610100900460ff1615808015610e015750600054600160ff909116105b80610e1b5750303b158015610e1b575060005460ff166001145b610e375760405162461bcd60e51b81526004016105f390611e9b565b6000805460ff191660011790558015610e5a576000805461ff0019166101001790555b610e668585858561129b565b8015610eac576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b610ebb611608565b6000610ec685611610565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610efb90339030908890889060040161204d565b600060405180830381600087803b158015610f1557600080fd5b505af1158015610f29573d6000803e3d6000fd5b505060fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935293841695506316f198319450610fc0939092169160e401612021565b600060405180830381600087803b158015610fda57600080fd5b505af1158015610fee573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fe6f1fb6bb1930a5d4b997d56e0a4a8cb6f3f941f0d5391f63c1f6914ee01e0b89060600160405180910390a4610eac565b611053611608565b600061105e88611610565b905060005b8481101561110a57886001600160a01b031663f242432a333089898681811061108e5761108e612085565b905060200201358888878181106110a7576110a7612085565b905060200201356040518563ffffffff1660e01b81526004016110cd949392919061204d565b600060405180830381600087803b1580156110e757600080fd5b505af11580156110fb573d6000803e3d6000fd5b50505050806001019050611063565b5060fc5460fe546040516001600160a01b03928316926316f19831921690611166907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e90602001612116565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401611192929190612021565b600060405180830381600087803b1580156111ac57600080fd5b505af11580156111c0573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167fa7d9cd27143f817fe006011faf3c04351f70f75cd30e7b21405817f2f670041e8a8a8a8a8a8a60405161121b96959493929190612181565b60405180910390a461087e565b6033546001600160a01b031633146106265760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016105f3565b606580546001600160a01b031916905561069f81611658565b6001600160a01b038416158015906112bb57506001600160a01b03831615155b80156112cf57506001600160a01b03821615155b80156112e357506001600160a01b03811615155b6113485760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b60648201526084016105f3565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b6000808080806113aa868801886121ca565b6001600160a01b0380861660009081526101006020526040902054959a509398509196509450925016806113e0576113e0612225565b604051637921219560e11b81526001600160a01b0387169063f242432a9061141290309088908890889060040161204d565b600060405180830381600087803b15801561142c57600080fd5b505af1158015611440573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907f52cdfbe452878311d3237a4c20a951600d8e3a4fe6691d967d33788dc12d19c6906060015b60405180910390a45050505050505050565b6000808080806114b88688018861223b565b6001600160a01b0380861660009081526101006020526040902054959b5093995091975095509350169050806114f0576114f0612225565b60005b83518110156115b657866001600160a01b031663f242432a3087848151811061151e5761151e612085565b602002602001015187858151811061153857611538612085565b602002602001015187868151811061155257611552612085565b60200260200101516040518563ffffffff1660e01b8152600401611579949392919061204d565b600060405180830381600087803b15801561159357600080fd5b505af11580156115a7573d6000803e3d6000fd5b505050508060010190506114f3565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167f52733a40a0466155541c2fc4044165dd37a3db116bc834bab2f020665e90fd2087878760405161149493929190612380565b6106266116aa565b6001600160a01b0380821660009081526101006020526040902054168061163d5761163a82610ad1565b90505b6001600160a01b03811661165357611653612225565b919050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff16156117b557604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161170c91906123f5565b6000604051808303818686fa925050503d8060008114611748576040519150601f19603f3d011682016040523d82523d6000602084013e61174d565b606091505b509150915081801561177257506000818060200190518101906117709190612411565b115b6117b25760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016105f3565b50505b60c954610100900460ff161561062657604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161181c91906123f5565b6000604051808303818686fa925050503d8060008114611858576040519150601f19603f3d011682016040523d82523d6000602084013e61185d565b606091505b509150915081801561188357508080602001905181019061187e9190612411565b600114155b6118c05760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016105f3565b5050565b6000602082840312156118d657600080fd5b81356001600160e01b0319811681146118ee57600080fd5b9392505050565b6001600160a01b038116811461069f57600080fd5b60008060006060848603121561191f57600080fd5b833561192a816118f5565b95602085013595506040909401359392505050565b60008083601f84011261195157600080fd5b5081356001600160401b0381111561196857600080fd5b6020830191508360208260051b850101111561198357600080fd5b9250929050565b60008060008060008060006080888a0312156119a557600080fd5b87356119b0816118f5565b965060208801356001600160401b03808211156119cc57600080fd5b6119d88b838c0161193f565b909850965060408a01359150808211156119f157600080fd5b6119fd8b838c0161193f565b909650945060608a0135915080821115611a1657600080fd5b50611a238a828b0161193f565b989b979a50959850939692959293505050565b600060208284031215611a4857600080fd5b81356118ee816118f5565b60008060008060808587031215611a6957600080fd5b8435611a74816118f5565b93506020850135611a84816118f5565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611ad757611ad7611a99565b604052919050565b60006001600160401b03821115611af857611af8611a99565b5060051b60200190565b600082601f830112611b1357600080fd5b81356020611b28611b2383611adf565b611aaf565b82815260059290921b84018101918181019086841115611b4757600080fd5b8286015b84811015611b625780358352918301918301611b4b565b509695505050505050565b60006001600160401b03821115611b8657611b86611a99565b50601f01601f191660200190565b600082601f830112611ba557600080fd5b8135611bb3611b2382611b6d565b818152846020838601011115611bc857600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a08688031215611bfd57600080fd5b8535611c08816118f5565b94506020860135611c18816118f5565b935060408601356001600160401b0380821115611c3457600080fd5b611c4089838a01611b02565b94506060880135915080821115611c5657600080fd5b611c6289838a01611b02565b93506080880135915080821115611c7857600080fd5b50611c8588828901611b94565b9150509295509295909350565b8035801515811461165357600080fd5b600060208284031215611cb457600080fd5b6118ee82611c92565b600080600080600080600060e0888a031215611cd857600080fd5b8735611ce3816118f5565b96506020880135611cf3816118f5565b95506040880135611d03816118f5565b94506060880135611d13816118f5565b9350611d2160808901611c92565b9250611d2f60a08901611c92565b915060c0880135611d3f816118f5565b8091505092959891949750929550565b60008060008060608587031215611d6557600080fd5b843593506020850135611d77816118f5565b925060408501356001600160401b0380821115611d9357600080fd5b818701915087601f830112611da757600080fd5b813581811115611db657600080fd5b886020828501011115611dc857600080fd5b95989497505060200194505050565b600080600080600060a08688031215611def57600080fd5b8535611dfa816118f5565b94506020860135611e0a816118f5565b9350604086013592506060860135915060808601356001600160401b03811115611e3357600080fd5b611c8588828901611b94565b60008060008060808587031215611e5557600080fd5b8435611e60816118f5565b93506020850135611e70816118f5565b92506040850135611e80816118f5565b91506060850135611e90816118f5565b939692955090935050565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611ef957600080fd5b83861115611f0657600080fd5b5050820193919092039150565b8035602083101561058357600019602084900360031b1b1692915050565b60005b83811015611f4c578181015183820152602001611f34565b50506000910152565b600060208284031215611f6757600080fd5b81516001600160401b03811115611f7d57600080fd5b8201601f81018413611f8e57600080fd5b8051611f9c611b2382611b6d565b818152856020838501011115611fb157600080fd5b611fc2826020830160208601611f31565b95945050505050565b60008151808452611fe3816020860160208601611f31565b601f01601f19169290920160200192915050565b8381526001600160a01b0383166020820152606060408201819052600090611fc290830184611fcb565b6001600160a01b038316815260406020820181905260009061204590830184611fcb565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b858110156120d95781356120be816118f5565b6001600160a01b0316875295820195908201906001016120ab565b509495945050505050565b81835260006001600160fb1b038311156120fd57600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090612149908301888a61209b565b828103608084015261215c8187896120e4565b905082810360a08401526121718185876120e4565b9c9b505050505050505050505050565b60608152600061219560608301888a61209b565b82810360208401526121a88187896120e4565b905082810360408401526121bd8185876120e4565b9998505050505050505050565b600080600080600060a086880312156121e257600080fd5b85356121ed816118f5565b945060208601356121fd816118f5565b9350604086013561220d816118f5565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c0878903121561225457600080fd5b86359550602080880135612267816118f5565b95506040880135612277816118f5565b945060608801356001600160401b038082111561229357600080fd5b818a0191508a601f8301126122a757600080fd5b81356122b5611b2382611adf565b81815260059190911b8301840190848101908d8311156122d457600080fd5b938501935b828510156122fb5784356122ec816118f5565b825293850193908501906122d9565b9750505060808a013592508083111561231357600080fd5b61231f8b848c01611b02565b945060a08a013592508083111561233557600080fd5b505061234389828a01611b02565b9150509295509295509295565b600081518084526020808501945080840160005b838110156120d957815187529582019590820190600101612364565b606080825284519082018190526000906020906080840190828801845b828110156123c25781516001600160a01b03168452928401929084019060010161239d565b505050838103828501526123d68187612350565b91505082810360408401526123eb8185612350565b9695505050505050565b60008251612407818460208701611f31565b9190910192915050565b60006020828403121561242357600080fd5b505191905056fe526f6f744d696e7461626c65455243313135355072656469636174653a20494ea26469706673582212209e659c40b5544a3ccbd0398212102d92d64f6d85aa23a717c5158820131e49d064736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061021c5760003560e01c8063a78e111c11610125578063d8dd1773116100ad578063f23a6e611161007c578063f23a6e61146104d3578063f2fde38b146104f2578063f4a120f714610505578063f645125514610518578063f8c8765e1461053f57600080fd5b8063d8dd177314610493578063e0563ab1146104a6578063e30c3978146104af578063eeb49945146104c057600080fd5b8063c1225a20116100f4578063c1225a20146103f8578063c5ac2b1c1461040b578063c5e4683a14610432578063d41f177114610445578063d7c9e3ec1461046c57600080fd5b8063a78e111c14610373578063b176806514610386578063b68ad1e4146103ad578063bc197c81146103c057600080fd5b806355b01e4d116101a857806379ba50971161017757806379ba50971461031d5780637efab4f5146103255780638da5cb5b1461034f578063947287cf1461036057806397e5230d1461036957600080fd5b806355b01e4d146102dd5780635ea5df79146102eb578063654715e614610302578063715018a61461031557600080fd5b80631bc114ba116101ef5780631bc114ba14610297578063284017f5146102aa5780633b878c22146102b35780634c4c45de146102bc57806351351d53146102cf57600080fd5b806301ffc9a71461022157806305dc2e8f1461024957806307b3e252146102745780630efe6a8b14610282575b600080fd5b61023461022f3660046118c4565b610552565b60405190151581526020015b60405180910390f35b60fd5461025c906001600160a01b031681565b6040516001600160a01b039091168152602001610240565b61025c6004600360981b0181565b61029561029036600461190a565b610589565b005b60fc5461025c906001600160a01b031681565b61025c61202081565b61025c61101081565b6102956102ca36600461198a565b61059a565b61025c6002600160a01b0381565b61025c6004600160991b0181565b6102f461138881565b604051908152602001610240565b60fe5461025c906001600160a01b031681565b610295610614565b610295610628565b61025c610333366004611a36565b610100602052600090815260409020546001600160a01b031681565b6033546001600160a01b031661025c565b6102f461520881565b6102f4620249f081565b610295610381366004611a53565b6106a2565b6102f47f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60ff5461025c906001600160a01b031681565b6103df6103ce366004611be5565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610240565b610295610406366004611ca2565b6106b4565b6102f47faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b610295610440366004611ca2565b610703565b6102f47f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102f47f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6102956104a1366004611cbd565b61074a565b61025c61203081565b6065546001600160a01b031661025c565b6102956104ce366004611d4f565b610888565b6103df6104e1366004611dd7565b63f23a6e6160e01b95945050505050565b610295610500366004611a36565b610a60565b61025c610513366004611a36565b610ad1565b6102f47f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61029561054d366004611e3f565b610de1565b60006001600160e01b03198216630271189760e51b148061058357506301ffc9a760e01b6001600160e01b03198316145b92915050565b61059583338484610eb3565b505050565b84831480156105a857508481145b6105fc5760405162461bcd60e51b815260206004820152602c602482015260008051602061242b83398151915260448201526b0ac82989288be988a9c8ea8960a31b60648201526084015b60405180910390fd5b61060b8787878787878761104b565b50505050505050565b61061c611228565b6106266000611282565b565b60655433906001600160a01b031681146106965760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016105f3565b61069f81611282565b50565b6106ae84848484610eb3565b50505050565b6106bc611228565b60c9805461ff0019166101008315159081029190911790915560405143907f61d574757cde41a357d030b39b2705796ccd699578037ab9a1cfd8117d82bf8690600090a350565b61070b611228565b60c9805460ff191682151590811790915560405143907fe0a0f0fa52db091cb71c202d80420311430ce1ae2e7794149877b6720ce8bf0b90600090a350565b336002600160a01b031461078e5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064016105f3565b600054610100900460ff16158080156107ae5750600054600160ff909116105b806107c85750303b1580156107c8575060005460ff166001145b6107e45760405162461bcd60e51b81526004016105f390611e9b565b6000805460ff191660011790558015610807576000805461ff0019166101001790555b6108138888888861129b565b60c9805461ffff191685151561ff001916176101008515150217905561083882611282565b801561087e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050565b60fd546001600160a01b031633146108fc5760405162461bcd60e51b815260206004820152603160248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e604482015270262cafa9aa20aa22afa922a1a2a4ab22a960791b60648201526084016105f3565b60fe546001600160a01b038481169116146109745760405162461bcd60e51b815260206004820152603260248201527f526f6f744d696e7461626c65455243313135355072656469636174653a204f4e6044820152714c595f4348494c445f50524544494341544560701b60648201526084016105f3565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696109a3602060008486611ee9565b6109ac91611f13565b036109cb576109c66109c18260208186611ee9565b611398565b6106ae565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26109fa602060008486611ee9565b610a0391611f13565b03610a12576109c682826114a6565b60405162461bcd60e51b815260206004820152602f602482015260008051602061242b83398151915260448201526e56414c49445f5349474e415455524560881b60648201526084016105f3565b610a68611228565b606580546001600160a01b0383166001600160a01b03199091168117909155610a996033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006001600160a01b038216610b2b5760405162461bcd60e51b815260206004820152602b602482015260008051602061242b83398151915260448201526a2b20a624a22faa27a5a2a760a91b60648201526084016105f3565b6001600160a01b03828116600090815261010060205260409020541615610ba95760405162461bcd60e51b815260206004820152602c60248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20414c60448201526b149150511657d3505414115160a21b60648201526084016105f3565b60fe5460ff546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b0392831692610c53921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b0384811660008181526101006020908152604080832080546001600160a01b031916958716959095179094558351908101845281815292516303a24d0760e21b815260048101919091529294509091630e89341c90602401600060405180830381865afa925050508015610cf057506040513d6000823e601f3d908101601f19168201604052610ced9190810190611f55565b60015b15610cf85790505b60fc546040516001600160a01b03909116906316f19831908490610d44907f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad9089908790602001611ff7565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610d70929190612021565b600060405180830381600087803b158015610d8a57600080fd5b505af1158015610d9e573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507fb96a191bae4e25ffdff7f4136994eb0dec75d263750a07c035202c348c9515f090600090a35050919050565b600054610100900460ff1615808015610e015750600054600160ff909116105b80610e1b5750303b158015610e1b575060005460ff166001145b610e375760405162461bcd60e51b81526004016105f390611e9b565b6000805460ff191660011790558015610e5a576000805461ff0019166101001790555b610e668585858561129b565b8015610eac576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b610ebb611608565b6000610ec685611610565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610efb90339030908890889060040161204d565b600060405180830381600087803b158015610f1557600080fd5b505af1158015610f29573d6000803e3d6000fd5b505060fc5460fe54604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935293841695506316f198319450610fc0939092169160e401612021565b600060405180830381600087803b158015610fda57600080fd5b505af1158015610fee573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fe6f1fb6bb1930a5d4b997d56e0a4a8cb6f3f941f0d5391f63c1f6914ee01e0b89060600160405180910390a4610eac565b611053611608565b600061105e88611610565b905060005b8481101561110a57886001600160a01b031663f242432a333089898681811061108e5761108e612085565b905060200201358888878181106110a7576110a7612085565b905060200201356040518563ffffffff1660e01b81526004016110cd949392919061204d565b600060405180830381600087803b1580156110e757600080fd5b505af11580156110fb573d6000803e3d6000fd5b50505050806001019050611063565b5060fc5460fe546040516001600160a01b03928316926316f19831921690611166907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e90602001612116565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401611192929190612021565b600060405180830381600087803b1580156111ac57600080fd5b505af11580156111c0573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167fa7d9cd27143f817fe006011faf3c04351f70f75cd30e7b21405817f2f670041e8a8a8a8a8a8a60405161121b96959493929190612181565b60405180910390a461087e565b6033546001600160a01b031633146106265760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016105f3565b606580546001600160a01b031916905561069f81611658565b6001600160a01b038416158015906112bb57506001600160a01b03831615155b80156112cf57506001600160a01b03821615155b80156112e357506001600160a01b03811615155b6113485760405162461bcd60e51b815260206004820152603060248201527f526f6f744d696e7461626c65455243313135355072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b60648201526084016105f3565b60fc80546001600160a01b039586166001600160a01b03199182161790915560fd80549486169482169490941790935560fe80549285169284169290921790915560ff8054919093169116179055565b6000808080806113aa868801886121ca565b6001600160a01b0380861660009081526101006020526040902054959a509398509196509450925016806113e0576113e0612225565b604051637921219560e11b81526001600160a01b0387169063f242432a9061141290309088908890889060040161204d565b600060405180830381600087803b15801561142c57600080fd5b505af1158015611440573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907f52cdfbe452878311d3237a4c20a951600d8e3a4fe6691d967d33788dc12d19c6906060015b60405180910390a45050505050505050565b6000808080806114b88688018861223b565b6001600160a01b0380861660009081526101006020526040902054959b5093995091975095509350169050806114f0576114f0612225565b60005b83518110156115b657866001600160a01b031663f242432a3087848151811061151e5761151e612085565b602002602001015187858151811061153857611538612085565b602002602001015187868151811061155257611552612085565b60200260200101516040518563ffffffff1660e01b8152600401611579949392919061204d565b600060405180830381600087803b15801561159357600080fd5b505af11580156115a7573d6000803e3d6000fd5b505050508060010190506114f3565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167f52733a40a0466155541c2fc4044165dd37a3db116bc834bab2f020665e90fd2087878760405161149493929190612380565b6106266116aa565b6001600160a01b0380821660009081526101006020526040902054168061163d5761163a82610ad1565b90505b6001600160a01b03811661165357611653612225565b919050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60c95460ff16156117b557604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600160991b01916113889161170c91906123f5565b6000604051808303818686fa925050503d8060008114611748576040519150601f19603f3d011682016040523d82523d6000602084013e61174d565b606091505b509150915081801561177257506000818060200190518101906117709190612411565b115b6117b25760405162461bcd60e51b81526020600482015260116024820152702224a9a0a62627aba2a22fa9a2a72222a960791b60448201526064016105f3565b50505b60c954610100900460ff161561062657604080513360248083019190915282518083039091018152604490910182526020810180516001600160e01b031663d78bca6960e01b179052905160009182916004600360981b01916113889161181c91906123f5565b6000604051808303818686fa925050503d8060008114611858576040519150601f19603f3d011682016040523d82523d6000602084013e61185d565b606091505b509150915081801561188357508080602001905181019061187e9190612411565b600114155b6118c05760405162461bcd60e51b815260206004820152600e60248201526d212627a1a5a2a22fa9a2a72222a960911b60448201526064016105f3565b5050565b6000602082840312156118d657600080fd5b81356001600160e01b0319811681146118ee57600080fd5b9392505050565b6001600160a01b038116811461069f57600080fd5b60008060006060848603121561191f57600080fd5b833561192a816118f5565b95602085013595506040909401359392505050565b60008083601f84011261195157600080fd5b5081356001600160401b0381111561196857600080fd5b6020830191508360208260051b850101111561198357600080fd5b9250929050565b60008060008060008060006080888a0312156119a557600080fd5b87356119b0816118f5565b965060208801356001600160401b03808211156119cc57600080fd5b6119d88b838c0161193f565b909850965060408a01359150808211156119f157600080fd5b6119fd8b838c0161193f565b909650945060608a0135915080821115611a1657600080fd5b50611a238a828b0161193f565b989b979a50959850939692959293505050565b600060208284031215611a4857600080fd5b81356118ee816118f5565b60008060008060808587031215611a6957600080fd5b8435611a74816118f5565b93506020850135611a84816118f5565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611ad757611ad7611a99565b604052919050565b60006001600160401b03821115611af857611af8611a99565b5060051b60200190565b600082601f830112611b1357600080fd5b81356020611b28611b2383611adf565b611aaf565b82815260059290921b84018101918181019086841115611b4757600080fd5b8286015b84811015611b625780358352918301918301611b4b565b509695505050505050565b60006001600160401b03821115611b8657611b86611a99565b50601f01601f191660200190565b600082601f830112611ba557600080fd5b8135611bb3611b2382611b6d565b818152846020838601011115611bc857600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a08688031215611bfd57600080fd5b8535611c08816118f5565b94506020860135611c18816118f5565b935060408601356001600160401b0380821115611c3457600080fd5b611c4089838a01611b02565b94506060880135915080821115611c5657600080fd5b611c6289838a01611b02565b93506080880135915080821115611c7857600080fd5b50611c8588828901611b94565b9150509295509295909350565b8035801515811461165357600080fd5b600060208284031215611cb457600080fd5b6118ee82611c92565b600080600080600080600060e0888a031215611cd857600080fd5b8735611ce3816118f5565b96506020880135611cf3816118f5565b95506040880135611d03816118f5565b94506060880135611d13816118f5565b9350611d2160808901611c92565b9250611d2f60a08901611c92565b915060c0880135611d3f816118f5565b8091505092959891949750929550565b60008060008060608587031215611d6557600080fd5b843593506020850135611d77816118f5565b925060408501356001600160401b0380821115611d9357600080fd5b818701915087601f830112611da757600080fd5b813581811115611db657600080fd5b886020828501011115611dc857600080fd5b95989497505060200194505050565b600080600080600060a08688031215611def57600080fd5b8535611dfa816118f5565b94506020860135611e0a816118f5565b9350604086013592506060860135915060808601356001600160401b03811115611e3357600080fd5b611c8588828901611b94565b60008060008060808587031215611e5557600080fd5b8435611e60816118f5565b93506020850135611e70816118f5565b92506040850135611e80816118f5565b91506060850135611e90816118f5565b939692955090935050565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60008085851115611ef957600080fd5b83861115611f0657600080fd5b5050820193919092039150565b8035602083101561058357600019602084900360031b1b1692915050565b60005b83811015611f4c578181015183820152602001611f34565b50506000910152565b600060208284031215611f6757600080fd5b81516001600160401b03811115611f7d57600080fd5b8201601f81018413611f8e57600080fd5b8051611f9c611b2382611b6d565b818152856020838501011115611fb157600080fd5b611fc2826020830160208601611f31565b95945050505050565b60008151808452611fe3816020860160208601611f31565b601f01601f19169290920160200192915050565b8381526001600160a01b0383166020820152606060408201819052600090611fc290830184611fcb565b6001600160a01b038316815260406020820181905260009061204590830184611fcb565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b858110156120d95781356120be816118f5565b6001600160a01b0316875295820195908201906001016120ab565b509495945050505050565b81835260006001600160fb1b038311156120fd57600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090612149908301888a61209b565b828103608084015261215c8187896120e4565b905082810360a08401526121718185876120e4565b9c9b505050505050505050505050565b60608152600061219560608301888a61209b565b82810360208401526121a88187896120e4565b905082810360408401526121bd8185876120e4565b9998505050505050505050565b600080600080600060a086880312156121e257600080fd5b85356121ed816118f5565b945060208601356121fd816118f5565b9350604086013561220d816118f5565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c0878903121561225457600080fd5b86359550602080880135612267816118f5565b95506040880135612277816118f5565b945060608801356001600160401b038082111561229357600080fd5b818a0191508a601f8301126122a757600080fd5b81356122b5611b2382611adf565b81815260059190911b8301840190848101908d8311156122d457600080fd5b938501935b828510156122fb5784356122ec816118f5565b825293850193908501906122d9565b9750505060808a013592508083111561231357600080fd5b61231f8b848c01611b02565b945060a08a013592508083111561233557600080fd5b505061234389828a01611b02565b9150509295509295509295565b600081518084526020808501945080840160005b838110156120d957815187529582019590820190600101612364565b606080825284519082018190526000906020906080840190828801845b828110156123c25781516001600160a01b03168452928401929084019060010161239d565b505050838103828501526123d68187612350565b91505082810360408401526123eb8185612350565b9695505050505050565b60008251612407818460208701611f31565b9190910192915050565b60006020828403121561242357600080fd5b505191905056fe526f6f744d696e7461626c65455243313135355072656469636174653a20494ea26469706673582212209e659c40b5544a3ccbd0398212102d92d64f6d85aa23a717c5158820131e49d064736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var SystemArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"System","sourceName":"contracts/blade/System.sol","abi":[{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061015a806100206000396000f3fe608060405234801561001057600080fd5b50600436106100935760003560e01c806355b01e4d1161006657806355b01e4d146100e35780635ea5df79146100f1578063947287cf1461010857806397e5230d14610111578063e0563ab11461011b57600080fd5b806307b3e25214610098578063284017f5146100c35780633b878c22146100cc57806351351d53146100d5575b600080fd5b6100a66004600360981b0181565b6040516001600160a01b0390911681526020015b60405180910390f35b6100a661202081565b6100a661101081565b6100a66002600160a01b0381565b6100a66004600160991b0181565b6100fa61138881565b6040519081526020016100ba565b6100fa61520881565b6100fa620249f081565b6100a66120308156fea264697066735822122039c7a31428ed5d365268b9c0d51ea72ced8bfd9f7fed2654d0f2104655a0adab64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100935760003560e01c806355b01e4d1161006657806355b01e4d146100e35780635ea5df79146100f1578063947287cf1461010857806397e5230d14610111578063e0563ab11461011b57600080fd5b806307b3e25214610098578063284017f5146100c35780633b878c22146100cc57806351351d53146100d5575b600080fd5b6100a66004600360981b0181565b6040516001600160a01b0390911681526020015b60405180910390f35b6100a661202081565b6100a661101081565b6100a66002600160a01b0381565b6100a66004600160991b0181565b6100fa61138881565b6040519081526020016100ba565b6100fa61520881565b6100fa620249f081565b6100a66120308156fea264697066735822122039c7a31428ed5d365268b9c0d51ea72ced8bfd9f7fed2654d0f2104655a0adab64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` var BLSArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"BLS","sourceName":"contracts/common/BLS.sol","abi":[{"inputs":[{"internalType":"bytes32","name":"domain","type":"bytes32"},{"internalType":"bytes","name":"message","type":"bytes"}],"name":"expandMsgTo96","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"bytes32","name":"domain","type":"bytes32"},{"internalType":"bytes","name":"messages","type":"bytes"}],"name":"hashToField","outputs":[{"internalType":"uint256[2]","name":"","type":"uint256[2]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"domain","type":"bytes32"},{"internalType":"bytes","name":"message","type":"bytes"}],"name":"hashToPoint","outputs":[{"internalType":"uint256[2]","name":"","type":"uint256[2]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[2]","name":"point","type":"uint256[2]"}],"name":"isOnCurveG1","outputs":[{"internalType":"bool","name":"_isOnCurve","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256[4]","name":"point","type":"uint256[4]"}],"name":"isOnCurveG2","outputs":[{"internalType":"bool","name":"_isOnCurve","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256[2]","name":"signature","type":"uint256[2]"}],"name":"isValidSignature","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_x","type":"uint256"}],"name":"mapToPoint","outputs":[{"internalType":"uint256[2]","name":"p","type":"uint256[2]"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256[2]","name":"signature","type":"uint256[2]"},{"internalType":"uint256[4][]","name":"pubkeys","type":"uint256[4][]"},{"internalType":"uint256[2][]","name":"messages","type":"uint256[2][]"}],"name":"verifyMultiple","outputs":[{"internalType":"bool","name":"checkResult","type":"bool"},{"internalType":"bool","name":"callSuccess","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[2]","name":"signature","type":"uint256[2]"},{"internalType":"uint256[4][]","name":"pubkeys","type":"uint256[4][]"},{"internalType":"uint256[2]","name":"message","type":"uint256[2]"}],"name":"verifyMultipleSameMsg","outputs":[{"internalType":"bool","name":"checkResult","type":"bool"},{"internalType":"bool","name":"callSuccess","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[2]","name":"signature","type":"uint256[2]"},{"internalType":"uint256[4]","name":"pubkey","type":"uint256[4]"},{"internalType":"uint256[2]","name":"message","type":"uint256[2]"}],"name":"verifySingle","outputs":[{"internalType":"bool","name":"","type":"bool"},{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612df8806100206000396000f3fe608060405234801561001057600080fd5b506004361061009e5760003560e01c806391ec2d2b1161006657806391ec2d2b1461013b578063a850a9091461015b578063d58e77331461016e578063e242cce914610181578063ebbdac911461019457600080fd5b8063115000fe146100a3578063247dd9fb146100cb5780633e5476ce146100de5780638669026f146101085780639141376314610128575b600080fd5b6100b66100b1366004612708565b6101a7565b60405190151581526020015b60405180910390f35b6100b66100d9366004612785565b61030e565b6100f16100ec366004612841565b6103b8565b6040805192151583529015156020830152016100c2565b61011b6101163660046128ce565b61079f565b6040516100c29190612957565b6100f1610136366004612988565b6108bb565b61014e6101493660046128ce565b610d5c565b6040516100c29190612a86565b61011b6101693660046128ce565b610ff8565b61011b61017c366004612aa0565b6111d4565b6100b661018f366004612785565b6115aa565b6100f16101a2366004612ab9565b611609565b600081516020830151600080516020612d63833981519152828309600080516020612d638339815191528283098182830101600080516020612d638339815191528283840108600080516020612d638339815191528682600080516020612d6383398151915203860109935050600080516020612d638339815191528483600080516020612d63833981519152038301099150600080516020612d638339815191527f2b149d40ceb8aaae81be18991be06ac3b5b4c5e559dbefa33267e6dc24a138e584089450600080516020612d638339815191527e9713b03af0fed4cd2cafadeed8fdf4a74fa084e52d1852e4a2bd0685c315d2830893506040870151925060608701519150600080516020612d638339815191528083600080516020612d63833981519152038508600080516020612d63833981519152848608099050600080516020612d63833981519152828460011b0994149290931491909116949350505050565b8051600090600080516020612d6383398151915211158061034157506020820151600080516020612d6383398151915211155b1561034e57506000919050565b60405163e242cce960e01b8152309063e242cce990610371908590600401612957565b602060405180830381865afa15801561038e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103b29190612b1c565b92915050565b60008083806103e25760405162461bcd60e51b81526004016103d990612b3e565b60405180910390fd5b60006103ef826001612b95565b6103fa906006612ba8565b90506000816001600160401b038111156104165761041661269a565b60405190808252806020026020018201604052801561043f578160200160208202803683370190505b50905088600060200201358160008151811061045d5761045d612b06565b602090810291909101015288600160200201358160018151811061048357610483612b06565b602002602001018181525050600080516020612d43833981519152816002815181106104b1576104b1612b06565b602002602001018181525050600080516020612d23833981519152816003815181106104df576104df612b06565b602002602001018181525050600080516020612d838339815191528160048151811061050d5761050d612b06565b602002602001018181525050600080516020612da38339815191528160058151811061053b5761053b612b06565b60200260200101818152505060005b8381101561075a57863582610560836006612ba8565b61056b906006612b95565b8151811061057b5761057b612b06565b602090810291909101015286600160200201358261059a836006612ba8565b6105a5906007612b95565b815181106105b5576105b5612b06565b6020026020010181815250508888828181106105d3576105d3612b06565b9050608002016001600481106105eb576105eb612b06565b6020020135826105fc836006612ba8565b610607906008612b95565b8151811061061757610617612b06565b60200260200101818152505088888281811061063557610635612b06565b90506080020160006004811061064d5761064d612b06565b60200201358261065e836006612ba8565b610669906009612b95565b8151811061067957610679612b06565b60200260200101818152505088888281811061069757610697612b06565b9050608002016003600481106106af576106af612b06565b6020020135826106c0836006612ba8565b6106cb90600a612b95565b815181106106db576106db612b06565b6020026020010181815250508888828181106106f9576106f9612b06565b90506080020160026004811061071157610711612b06565b602002013582610722836006612ba8565b61072d90600b612b95565b8151811061073d5761073d612b06565b60209081029190910101528061075281612bbf565b91505061054a565b50610763612640565b602081602085026020850160085afa945084610789576000809550955050505050610796565b5115159450600193505050505b94509492505050565b6107a761265e565b6040516391ec2d2b60e01b815260009030906391ec2d2b906107cf9087908790600401612bd8565b600060405180830381865afa1580156107ec573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526108149190810190612bf9565b9050600080600080601885016001600160c01b0381511693506030860190506001600160c01b038151169450600080516020612d6383398151915285600080516020612d63833981519152600160c01b870908604887015160608801516001600160c01b0390811697501694509250600080516020612d6383398151915290508481600160c01b860908604080518082019091529283526020830152509695505050505050565b60008084806108dc5760405162461bcd60e51b81526004016103d990612b3e565b8084146109495760405162461bcd60e51b815260206004820152603560248201527f424c533a206e756d626572206f66207075626c6963206b65797320616e64206d604482015274195cdcd859d95cc81b5d5cdd08189948195c5d585b605a1b60648201526084016103d9565b6000610956826001612b95565b610961906006612ba8565b90506000816001600160401b0381111561097d5761097d61269a565b6040519080825280602002602001820160405280156109a6578160200160208202803683370190505b5090508960006020020135816000815181106109c4576109c4612b06565b60209081029190910101528960016020020135816001815181106109ea576109ea612b06565b602002602001018181525050600080516020612d4383398151915281600281518110610a1857610a18612b06565b602002602001018181525050600080516020612d2383398151915281600381518110610a4657610a46612b06565b602002602001018181525050600080516020612d8383398151915281600481518110610a7457610a74612b06565b602002602001018181525050600080516020612da383398151915281600581518110610aa257610aa2612b06565b60200260200101818152505060005b83811015610d1657878782818110610acb57610acb612b06565b905060400201600060028110610ae357610ae3612b06565b602002013582610af4836006612ba8565b610aff906006612b95565b81518110610b0f57610b0f612b06565b602002602001018181525050878782818110610b2d57610b2d612b06565b905060400201600160028110610b4557610b45612b06565b602002013582610b56836006612ba8565b610b61906007612b95565b81518110610b7157610b71612b06565b602002602001018181525050898982818110610b8f57610b8f612b06565b905060800201600160048110610ba757610ba7612b06565b602002013582610bb8836006612ba8565b610bc3906008612b95565b81518110610bd357610bd3612b06565b602002602001018181525050898982818110610bf157610bf1612b06565b905060800201600060048110610c0957610c09612b06565b602002013582610c1a836006612ba8565b610c25906009612b95565b81518110610c3557610c35612b06565b602002602001018181525050898982818110610c5357610c53612b06565b905060800201600360048110610c6b57610c6b612b06565b602002013582610c7c836006612ba8565b610c8790600a612b95565b81518110610c9757610c97612b06565b602002602001018181525050898982818110610cb557610cb5612b06565b905060800201600260048110610ccd57610ccd612b06565b602002013582610cde836006612ba8565b610ce990600b612b95565b81518110610cf957610cf9612b06565b602090810291909101015280610d0e81612bbf565b915050610ab1565b50610d1f612640565b602081602085026020850160085afa945084610d45576000809550955050505050610d52565b5115159450600193505050505b9550959350505050565b80516060906000610d6e826020612b95565b610d79906040612b95565b610d84906004612b95565b6001600160401b03811115610d9b57610d9b61269a565b6040519080825280601f01601f191660200182016040528015610dc5576020820181803683370190505b5060408051606080825260808201909252919250600091906020820181803683370190505090506060820160005b84811015610e0d5760208188018101518383015201610df3565b5083016000815360010160608153600101600081536001810187905260210160208153506000600283604051610e439190612c6f565b602060405180830381855afa158015610e60573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610e839190612c8b565b9050600060429450848452816020850152600160408501536041840188905260206061850153600284604051610eb99190612c6f565b602060405180830381855afa158015610ed6573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610ef99190612c8b565b905080602084015280821880602086015250600260408501536041840188905260206061850153600284604051610f309190612c6f565b602060405180830381855afa158015610f4d573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610f709190612c8b565b905080604084015280821880602086015250600360408501536041840188905260206061850153600284604051610fa79190612c6f565b602060405180830381855afa158015610fc4573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610fe79190612c8b565b606084015250909695505050505050565b61100061265e565b604051638669026f60e01b81526000903090638669026f906110289087908790600401612bd8565b6040805180830381865afa158015611044573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110689190612ca4565b805160405163d58e773360e01b81526004810191909152909150600090309063d58e7733906024016040805180830381865afa1580156110ac573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d09190612ca4565b602083015160405163d58e773360e01b81526004810191909152909150600090309063d58e7733906024016040805180830381865afa158015611117573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061113b9190612ca4565b905061114561267c565b825181526020808401518282015282516040808401919091529083015160608301526000908460808460066107d05a03fa9050808061118057fe5b50806111c85760405162461bcd60e51b8152602060048201526017602482015276109314ce88189b881859190818d85b1b0819985a5b1959604a1b60448201526064016103d9565b50919695505050505050565b6111dc61265e565b600080516020612d6383398151915282106112455760405162461bcd60e51b815260206004820152602360248201527f6d6170546f506f696e7446543a20696e76616c6964206669656c6420656c656d604482015262195b9d60ea1b60648201526084016103d9565b81600061125182611790565b9150506000600080516020612d638339815191528061127257611272612cf9565b8384099050600080516020612d638339815191526004820890506000600080516020612d6383398151915277b3c4d79d41a91759a9e4c7e359b6b89eaec68e62effffffd850990506000600080516020612d6383398151915283830990506112d9816117b9565b9050600080516020612d638339815191528283099150600080516020612d638339815191528183099150600080516020612d638339815191528286099150600080516020612d6383398151915261133e83600080516020612d63833981519152612d0f565b7759e26bcea0d48bacd4f263f1acdb5c4f5763473177fffffe089450600080516020612d638339815191528586099150600080516020612d638339815191528583099150600080516020612d6383398151915260038308915060006113a283611790565b909350905080156113ea57846113cd576113ca83600080516020612d63833981519152612d0f565b92505b505060408051808201909152938452602084015250909392505050565b600080516020612d638339815191526001870861141590600080516020612d63833981519152612d0f565b9550600080516020612d638339815191528687099250600080516020612d638339815191528684099250600080516020612d6383398151915260038408925061145d83611790565b9093509050801561148557846113cd576113ca83600080516020612d63833981519152612d0f565b600080516020612d638339815191528485099550600080516020612d638339815191528687099550600080516020612d638339815191528287099550600080516020612d638339815191528287099550600080516020612d63833981519152600187089550600080516020612d638339815191528687099250600080516020612d638339815191528684099250600080516020612d6383398151915260038408925061153083611790565b90935090508061158d5760405162461bcd60e51b815260206004820152602260248201527f424c533a20626164206674206d617070696e6720696d706c656d656e7461746960448201526137b760f11b60648201526084016103d9565b846113cd576113ca83600080516020612d63833981519152612d0f565b600081516020830151600080516020612d63833981519152828309600080516020612d638339815191528382099050600080516020612d63833981519152600382089050600080516020612d6383398151915282830914949350505050565b60008060006040518061018001604052808760006002811061162d5761162d612b06565b602002013581526020018760016002811061164a5761164a612b06565b60200201358152602001600080516020612d438339815191528152602001600080516020612d238339815191528152602001600080516020612d838339815191528152602001600080516020612da38339815191528152602001856000600281106116b7576116b7612b06565b60200201358152602001856001600281106116d4576116d4612b06565b60200201358152602001866001600481106116f1576116f1612b06565b602002013581526020018660006004811061170e5761170e612b06565b602002013581526020018660036004811061172b5761172b612b06565b602002013581526020018660026004811061174857611748612b06565b602002013590529050611759612640565b60006020826101808560085afa90508061177c5760008094509450505050611788565b50511515925060019150505b935093915050565b60008061179c836117c4565b915082600080516020612d63833981519152838409149050915091565b60006103b282611ef9565b6000600080516020612d638339815191528083840991508083830981838209828283098385830984848309858484098684850997508684840987858409945087898a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087838a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985050868889099750868889099750868889099750868889099750868889099750868889099750868489099750868889099750868889099750868889099750868889099750868889099750868989099750868889099750868889099750868889099750868889099750868889099750868889099750868989099750868889099750868889099750868889099750868889099750868889099750868689099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868189099750508587880996508587880996508587880996508585880996508587880996508587880996508587880996508585880996508587880996508587880996508587880996508587880996508587880996508587880996508587880996508587880996508583880996508587880996508587880996508587880996508587880996508581880996508587880996508587880996508587880996508587880996508583880996508587880996508587880996508587880996508584880996508587880996508587880996508587880996508587880996508587880996508581880996505050505050808283099392505050565b6000600080516020612d638339815191528083840991508083830981838209828283098385830984848309858484098684850997508684840987858409945087898a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087838a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985050868889099750868889099750868889099750868889099750868889099750868889099750868489099750868889099750868889099750868889099750868889099750868889099750868989099750868889099750868889099750868889099750868889099750868889099750868889099750868989099750868889099750868889099750868889099750868889099750868889099750868689099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868189099750508587880996508587880996508587880996508585880996508587880996508587880996508587880996508585880996508587880996508587880996508587880996508587880996508587880996508587880996508587880996508587880996508583880996508587880996508587880996508587880996508587880996508581880996505050838586099450838586099450838586099450838586099450838186099450508284850993508284850993508284850993508281850993508284850993508284850993508285850993508284850993508284850993508284850993508284850993508284850993508284850993508281850995945050505050565b60405180602001604052806001906020820280368337509192915050565b60405180604001604052806002906020820280368337509192915050565b60405180608001604052806004906020820280368337509192915050565b634e487b7160e01b600052604160045260246000fd5b604080519081016001600160401b03811182821017156126d2576126d261269a565b60405290565b604051601f8201601f191681016001600160401b03811182821017156127005761270061269a565b604052919050565b60006080828403121561271a57600080fd5b82601f83011261272957600080fd5b604051608081018181106001600160401b038211171561274b5761274b61269a565b60405280608084018581111561276057600080fd5b845b8181101561277a578035835260209283019201612762565b509195945050505050565b60006040828403121561279757600080fd5b82601f8301126127a657600080fd5b6127ae6126b0565b8060408401858111156127c057600080fd5b845b818110156127da5780358452602093840193016127c2565b509095945050505050565b80604081018310156103b257600080fd5b60008083601f84011261280857600080fd5b5081356001600160401b0381111561281f57600080fd5b6020830191508360208260071b850101111561283a57600080fd5b9250929050565b60008060008060a0858703121561285757600080fd5b61286186866127e5565b935060408501356001600160401b0381111561287c57600080fd5b612888878288016127f6565b909450925061289c905086606087016127e5565b905092959194509250565b60006001600160401b038211156128c0576128c061269a565b50601f01601f191660200190565b600080604083850312156128e157600080fd5b8235915060208301356001600160401b038111156128fe57600080fd5b8301601f8101851361290f57600080fd5b803561292261291d826128a7565b6126d8565b81815286602083850101111561293757600080fd5b816020840160208301376000602083830101528093505050509250929050565b60408101818360005b600281101561297f578151835260209283019290910190600101612960565b50505092915050565b6000806000806000608086880312156129a057600080fd5b6129aa87876127e5565b945060408601356001600160401b03808211156129c657600080fd5b6129d289838a016127f6565b909650945060608801359150808211156129eb57600080fd5b818801915088601f8301126129ff57600080fd5b813581811115612a0e57600080fd5b8960208260061b8501011115612a2357600080fd5b9699959850939650602001949392505050565b60005b83811015612a51578181015183820152602001612a39565b50506000910152565b60008151808452612a72816020860160208601612a36565b601f01601f19169290920160200192915050565b602081526000612a996020830184612a5a565b9392505050565b600060208284031215612ab257600080fd5b5035919050565b60008060006101008486031215612acf57600080fd5b612ad985856127e5565b925060c0840185811115612aec57600080fd5b604085019250612afc86826127e5565b9150509250925092565b634e487b7160e01b600052603260045260246000fd5b600060208284031215612b2e57600080fd5b81518015158114612a9957600080fd5b60208082526021908201527f424c533a206e756d626572206f66207075626c6963206b6579206973207a65726040820152606f60f81b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b808201808211156103b2576103b2612b7f565b80820281158282048414176103b2576103b2612b7f565b600060018201612bd157612bd1612b7f565b5060010190565b828152604060208201526000612bf16040830184612a5a565b949350505050565b600060208284031215612c0b57600080fd5b81516001600160401b03811115612c2157600080fd5b8201601f81018413612c3257600080fd5b8051612c4061291d826128a7565b818152856020838501011115612c5557600080fd5b612c66826020830160208601612a36565b95945050505050565b60008251612c81818460208701612a36565b9190910192915050565b600060208284031215612c9d57600080fd5b5051919050565b600060408284031215612cb657600080fd5b82601f830112612cc557600080fd5b612ccd6126b0565b806040840185811115612cdf57600080fd5b845b818110156127da578051845260209384019301612ce1565b634e487b7160e01b600052601260045260246000fd5b818103818111156103b2576103b2612b7f56fe1800deef121f1e76426a00665e5c4479674322d4f75edadd46debd5cd992f6ed198e9393920d483a7260bfb731fb5d25f1aa493335a9e71297e485b7aef312c230644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47275dc4a288d1afb3cbb1ac09187524c7db36395df7be3b99e673b13a075a65ec1d9befcd05a5323e6da4d435f3b617cdb3af83285c2df711ef39c01571827f9da26469706673582212204742dc9bfec89e0e4850b0f02ca1922cc3c73b8db4ec85457e11b7fd8d117c1264736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061009e5760003560e01c806391ec2d2b1161006657806391ec2d2b1461013b578063a850a9091461015b578063d58e77331461016e578063e242cce914610181578063ebbdac911461019457600080fd5b8063115000fe146100a3578063247dd9fb146100cb5780633e5476ce146100de5780638669026f146101085780639141376314610128575b600080fd5b6100b66100b1366004612708565b6101a7565b60405190151581526020015b60405180910390f35b6100b66100d9366004612785565b61030e565b6100f16100ec366004612841565b6103b8565b6040805192151583529015156020830152016100c2565b61011b6101163660046128ce565b61079f565b6040516100c29190612957565b6100f1610136366004612988565b6108bb565b61014e6101493660046128ce565b610d5c565b6040516100c29190612a86565b61011b6101693660046128ce565b610ff8565b61011b61017c366004612aa0565b6111d4565b6100b661018f366004612785565b6115aa565b6100f16101a2366004612ab9565b611609565b600081516020830151600080516020612d63833981519152828309600080516020612d638339815191528283098182830101600080516020612d638339815191528283840108600080516020612d638339815191528682600080516020612d6383398151915203860109935050600080516020612d638339815191528483600080516020612d63833981519152038301099150600080516020612d638339815191527f2b149d40ceb8aaae81be18991be06ac3b5b4c5e559dbefa33267e6dc24a138e584089450600080516020612d638339815191527e9713b03af0fed4cd2cafadeed8fdf4a74fa084e52d1852e4a2bd0685c315d2830893506040870151925060608701519150600080516020612d638339815191528083600080516020612d63833981519152038508600080516020612d63833981519152848608099050600080516020612d63833981519152828460011b0994149290931491909116949350505050565b8051600090600080516020612d6383398151915211158061034157506020820151600080516020612d6383398151915211155b1561034e57506000919050565b60405163e242cce960e01b8152309063e242cce990610371908590600401612957565b602060405180830381865afa15801561038e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103b29190612b1c565b92915050565b60008083806103e25760405162461bcd60e51b81526004016103d990612b3e565b60405180910390fd5b60006103ef826001612b95565b6103fa906006612ba8565b90506000816001600160401b038111156104165761041661269a565b60405190808252806020026020018201604052801561043f578160200160208202803683370190505b50905088600060200201358160008151811061045d5761045d612b06565b602090810291909101015288600160200201358160018151811061048357610483612b06565b602002602001018181525050600080516020612d43833981519152816002815181106104b1576104b1612b06565b602002602001018181525050600080516020612d23833981519152816003815181106104df576104df612b06565b602002602001018181525050600080516020612d838339815191528160048151811061050d5761050d612b06565b602002602001018181525050600080516020612da38339815191528160058151811061053b5761053b612b06565b60200260200101818152505060005b8381101561075a57863582610560836006612ba8565b61056b906006612b95565b8151811061057b5761057b612b06565b602090810291909101015286600160200201358261059a836006612ba8565b6105a5906007612b95565b815181106105b5576105b5612b06565b6020026020010181815250508888828181106105d3576105d3612b06565b9050608002016001600481106105eb576105eb612b06565b6020020135826105fc836006612ba8565b610607906008612b95565b8151811061061757610617612b06565b60200260200101818152505088888281811061063557610635612b06565b90506080020160006004811061064d5761064d612b06565b60200201358261065e836006612ba8565b610669906009612b95565b8151811061067957610679612b06565b60200260200101818152505088888281811061069757610697612b06565b9050608002016003600481106106af576106af612b06565b6020020135826106c0836006612ba8565b6106cb90600a612b95565b815181106106db576106db612b06565b6020026020010181815250508888828181106106f9576106f9612b06565b90506080020160026004811061071157610711612b06565b602002013582610722836006612ba8565b61072d90600b612b95565b8151811061073d5761073d612b06565b60209081029190910101528061075281612bbf565b91505061054a565b50610763612640565b602081602085026020850160085afa945084610789576000809550955050505050610796565b5115159450600193505050505b94509492505050565b6107a761265e565b6040516391ec2d2b60e01b815260009030906391ec2d2b906107cf9087908790600401612bd8565b600060405180830381865afa1580156107ec573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526108149190810190612bf9565b9050600080600080601885016001600160c01b0381511693506030860190506001600160c01b038151169450600080516020612d6383398151915285600080516020612d63833981519152600160c01b870908604887015160608801516001600160c01b0390811697501694509250600080516020612d6383398151915290508481600160c01b860908604080518082019091529283526020830152509695505050505050565b60008084806108dc5760405162461bcd60e51b81526004016103d990612b3e565b8084146109495760405162461bcd60e51b815260206004820152603560248201527f424c533a206e756d626572206f66207075626c6963206b65797320616e64206d604482015274195cdcd859d95cc81b5d5cdd08189948195c5d585b605a1b60648201526084016103d9565b6000610956826001612b95565b610961906006612ba8565b90506000816001600160401b0381111561097d5761097d61269a565b6040519080825280602002602001820160405280156109a6578160200160208202803683370190505b5090508960006020020135816000815181106109c4576109c4612b06565b60209081029190910101528960016020020135816001815181106109ea576109ea612b06565b602002602001018181525050600080516020612d4383398151915281600281518110610a1857610a18612b06565b602002602001018181525050600080516020612d2383398151915281600381518110610a4657610a46612b06565b602002602001018181525050600080516020612d8383398151915281600481518110610a7457610a74612b06565b602002602001018181525050600080516020612da383398151915281600581518110610aa257610aa2612b06565b60200260200101818152505060005b83811015610d1657878782818110610acb57610acb612b06565b905060400201600060028110610ae357610ae3612b06565b602002013582610af4836006612ba8565b610aff906006612b95565b81518110610b0f57610b0f612b06565b602002602001018181525050878782818110610b2d57610b2d612b06565b905060400201600160028110610b4557610b45612b06565b602002013582610b56836006612ba8565b610b61906007612b95565b81518110610b7157610b71612b06565b602002602001018181525050898982818110610b8f57610b8f612b06565b905060800201600160048110610ba757610ba7612b06565b602002013582610bb8836006612ba8565b610bc3906008612b95565b81518110610bd357610bd3612b06565b602002602001018181525050898982818110610bf157610bf1612b06565b905060800201600060048110610c0957610c09612b06565b602002013582610c1a836006612ba8565b610c25906009612b95565b81518110610c3557610c35612b06565b602002602001018181525050898982818110610c5357610c53612b06565b905060800201600360048110610c6b57610c6b612b06565b602002013582610c7c836006612ba8565b610c8790600a612b95565b81518110610c9757610c97612b06565b602002602001018181525050898982818110610cb557610cb5612b06565b905060800201600260048110610ccd57610ccd612b06565b602002013582610cde836006612ba8565b610ce990600b612b95565b81518110610cf957610cf9612b06565b602090810291909101015280610d0e81612bbf565b915050610ab1565b50610d1f612640565b602081602085026020850160085afa945084610d45576000809550955050505050610d52565b5115159450600193505050505b9550959350505050565b80516060906000610d6e826020612b95565b610d79906040612b95565b610d84906004612b95565b6001600160401b03811115610d9b57610d9b61269a565b6040519080825280601f01601f191660200182016040528015610dc5576020820181803683370190505b5060408051606080825260808201909252919250600091906020820181803683370190505090506060820160005b84811015610e0d5760208188018101518383015201610df3565b5083016000815360010160608153600101600081536001810187905260210160208153506000600283604051610e439190612c6f565b602060405180830381855afa158015610e60573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610e839190612c8b565b9050600060429450848452816020850152600160408501536041840188905260206061850153600284604051610eb99190612c6f565b602060405180830381855afa158015610ed6573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610ef99190612c8b565b905080602084015280821880602086015250600260408501536041840188905260206061850153600284604051610f309190612c6f565b602060405180830381855afa158015610f4d573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610f709190612c8b565b905080604084015280821880602086015250600360408501536041840188905260206061850153600284604051610fa79190612c6f565b602060405180830381855afa158015610fc4573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610fe79190612c8b565b606084015250909695505050505050565b61100061265e565b604051638669026f60e01b81526000903090638669026f906110289087908790600401612bd8565b6040805180830381865afa158015611044573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110689190612ca4565b805160405163d58e773360e01b81526004810191909152909150600090309063d58e7733906024016040805180830381865afa1580156110ac573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d09190612ca4565b602083015160405163d58e773360e01b81526004810191909152909150600090309063d58e7733906024016040805180830381865afa158015611117573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061113b9190612ca4565b905061114561267c565b825181526020808401518282015282516040808401919091529083015160608301526000908460808460066107d05a03fa9050808061118057fe5b50806111c85760405162461bcd60e51b8152602060048201526017602482015276109314ce88189b881859190818d85b1b0819985a5b1959604a1b60448201526064016103d9565b50919695505050505050565b6111dc61265e565b600080516020612d6383398151915282106112455760405162461bcd60e51b815260206004820152602360248201527f6d6170546f506f696e7446543a20696e76616c6964206669656c6420656c656d604482015262195b9d60ea1b60648201526084016103d9565b81600061125182611790565b9150506000600080516020612d638339815191528061127257611272612cf9565b8384099050600080516020612d638339815191526004820890506000600080516020612d6383398151915277b3c4d79d41a91759a9e4c7e359b6b89eaec68e62effffffd850990506000600080516020612d6383398151915283830990506112d9816117b9565b9050600080516020612d638339815191528283099150600080516020612d638339815191528183099150600080516020612d638339815191528286099150600080516020612d6383398151915261133e83600080516020612d63833981519152612d0f565b7759e26bcea0d48bacd4f263f1acdb5c4f5763473177fffffe089450600080516020612d638339815191528586099150600080516020612d638339815191528583099150600080516020612d6383398151915260038308915060006113a283611790565b909350905080156113ea57846113cd576113ca83600080516020612d63833981519152612d0f565b92505b505060408051808201909152938452602084015250909392505050565b600080516020612d638339815191526001870861141590600080516020612d63833981519152612d0f565b9550600080516020612d638339815191528687099250600080516020612d638339815191528684099250600080516020612d6383398151915260038408925061145d83611790565b9093509050801561148557846113cd576113ca83600080516020612d63833981519152612d0f565b600080516020612d638339815191528485099550600080516020612d638339815191528687099550600080516020612d638339815191528287099550600080516020612d638339815191528287099550600080516020612d63833981519152600187089550600080516020612d638339815191528687099250600080516020612d638339815191528684099250600080516020612d6383398151915260038408925061153083611790565b90935090508061158d5760405162461bcd60e51b815260206004820152602260248201527f424c533a20626164206674206d617070696e6720696d706c656d656e7461746960448201526137b760f11b60648201526084016103d9565b846113cd576113ca83600080516020612d63833981519152612d0f565b600081516020830151600080516020612d63833981519152828309600080516020612d638339815191528382099050600080516020612d63833981519152600382089050600080516020612d6383398151915282830914949350505050565b60008060006040518061018001604052808760006002811061162d5761162d612b06565b602002013581526020018760016002811061164a5761164a612b06565b60200201358152602001600080516020612d438339815191528152602001600080516020612d238339815191528152602001600080516020612d838339815191528152602001600080516020612da38339815191528152602001856000600281106116b7576116b7612b06565b60200201358152602001856001600281106116d4576116d4612b06565b60200201358152602001866001600481106116f1576116f1612b06565b602002013581526020018660006004811061170e5761170e612b06565b602002013581526020018660036004811061172b5761172b612b06565b602002013581526020018660026004811061174857611748612b06565b602002013590529050611759612640565b60006020826101808560085afa90508061177c5760008094509450505050611788565b50511515925060019150505b935093915050565b60008061179c836117c4565b915082600080516020612d63833981519152838409149050915091565b60006103b282611ef9565b6000600080516020612d638339815191528083840991508083830981838209828283098385830984848309858484098684850997508684840987858409945087898a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087838a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985050868889099750868889099750868889099750868889099750868889099750868889099750868489099750868889099750868889099750868889099750868889099750868889099750868989099750868889099750868889099750868889099750868889099750868889099750868889099750868989099750868889099750868889099750868889099750868889099750868889099750868689099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868189099750508587880996508587880996508587880996508585880996508587880996508587880996508587880996508585880996508587880996508587880996508587880996508587880996508587880996508587880996508587880996508587880996508583880996508587880996508587880996508587880996508587880996508581880996508587880996508587880996508587880996508587880996508583880996508587880996508587880996508587880996508584880996508587880996508587880996508587880996508587880996508587880996508581880996505050505050808283099392505050565b6000600080516020612d638339815191528083840991508083830981838209828283098385830984848309858484098684850997508684840987858409945087898a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087878a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a09985087898a09985087898a09985087898a09985087838a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087828a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087848a09985087898a09985087898a09985087898a09985087898a09985087898a09985087868a09985087898a09985087898a099850878a8a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087898a09985087818a09985050868889099750868889099750868889099750868889099750868889099750868889099750868489099750868889099750868889099750868889099750868889099750868889099750868989099750868889099750868889099750868889099750868889099750868889099750868889099750868989099750868889099750868889099750868889099750868889099750868889099750868689099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868889099750868189099750508587880996508587880996508587880996508585880996508587880996508587880996508587880996508585880996508587880996508587880996508587880996508587880996508587880996508587880996508587880996508587880996508583880996508587880996508587880996508587880996508587880996508581880996505050838586099450838586099450838586099450838586099450838186099450508284850993508284850993508284850993508281850993508284850993508284850993508285850993508284850993508284850993508284850993508284850993508284850993508284850993508281850995945050505050565b60405180602001604052806001906020820280368337509192915050565b60405180604001604052806002906020820280368337509192915050565b60405180608001604052806004906020820280368337509192915050565b634e487b7160e01b600052604160045260246000fd5b604080519081016001600160401b03811182821017156126d2576126d261269a565b60405290565b604051601f8201601f191681016001600160401b03811182821017156127005761270061269a565b604052919050565b60006080828403121561271a57600080fd5b82601f83011261272957600080fd5b604051608081018181106001600160401b038211171561274b5761274b61269a565b60405280608084018581111561276057600080fd5b845b8181101561277a578035835260209283019201612762565b509195945050505050565b60006040828403121561279757600080fd5b82601f8301126127a657600080fd5b6127ae6126b0565b8060408401858111156127c057600080fd5b845b818110156127da5780358452602093840193016127c2565b509095945050505050565b80604081018310156103b257600080fd5b60008083601f84011261280857600080fd5b5081356001600160401b0381111561281f57600080fd5b6020830191508360208260071b850101111561283a57600080fd5b9250929050565b60008060008060a0858703121561285757600080fd5b61286186866127e5565b935060408501356001600160401b0381111561287c57600080fd5b612888878288016127f6565b909450925061289c905086606087016127e5565b905092959194509250565b60006001600160401b038211156128c0576128c061269a565b50601f01601f191660200190565b600080604083850312156128e157600080fd5b8235915060208301356001600160401b038111156128fe57600080fd5b8301601f8101851361290f57600080fd5b803561292261291d826128a7565b6126d8565b81815286602083850101111561293757600080fd5b816020840160208301376000602083830101528093505050509250929050565b60408101818360005b600281101561297f578151835260209283019290910190600101612960565b50505092915050565b6000806000806000608086880312156129a057600080fd5b6129aa87876127e5565b945060408601356001600160401b03808211156129c657600080fd5b6129d289838a016127f6565b909650945060608801359150808211156129eb57600080fd5b818801915088601f8301126129ff57600080fd5b813581811115612a0e57600080fd5b8960208260061b8501011115612a2357600080fd5b9699959850939650602001949392505050565b60005b83811015612a51578181015183820152602001612a39565b50506000910152565b60008151808452612a72816020860160208601612a36565b601f01601f19169290920160200192915050565b602081526000612a996020830184612a5a565b9392505050565b600060208284031215612ab257600080fd5b5035919050565b60008060006101008486031215612acf57600080fd5b612ad985856127e5565b925060c0840185811115612aec57600080fd5b604085019250612afc86826127e5565b9150509250925092565b634e487b7160e01b600052603260045260246000fd5b600060208284031215612b2e57600080fd5b81518015158114612a9957600080fd5b60208082526021908201527f424c533a206e756d626572206f66207075626c6963206b6579206973207a65726040820152606f60f81b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b808201808211156103b2576103b2612b7f565b80820281158282048414176103b2576103b2612b7f565b600060018201612bd157612bd1612b7f565b5060010190565b828152604060208201526000612bf16040830184612a5a565b949350505050565b600060208284031215612c0b57600080fd5b81516001600160401b03811115612c2157600080fd5b8201601f81018413612c3257600080fd5b8051612c4061291d826128a7565b818152856020838501011115612c5557600080fd5b612c66826020830160208601612a36565b95945050505050565b60008251612c81818460208701612a36565b9190910192915050565b600060208284031215612c9d57600080fd5b5051919050565b600060408284031215612cb657600080fd5b82601f830112612cc557600080fd5b612ccd6126b0565b806040840185811115612cdf57600080fd5b845b818110156127da578051845260209384019301612ce1565b634e487b7160e01b600052601260045260246000fd5b818103818111156103b2576103b2612b7f56fe1800deef121f1e76426a00665e5c4479674322d4f75edadd46debd5cd992f6ed198e9393920d483a7260bfb731fb5d25f1aa493335a9e71297e485b7aef312c230644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47275dc4a288d1afb3cbb1ac09187524c7db36395df7be3b99e673b13a075a65ec1d9befcd05a5323e6da4d435f3b617cdb3af83285c2df711ef39c01571827f9da26469706673582212204742dc9bfec89e0e4850b0f02ca1922cc3c73b8db4ec85457e11b7fd8d117c1264736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` var BN256G2Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"BN256G2","sourceName":"contracts/common/BN256G2.sol","abi":[{"inputs":[],"name":"G2_NEG_X_IM","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"G2_NEG_X_RE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"G2_NEG_Y_IM","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"G2_NEG_Y_RE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"pt1xx","type":"uint256"},{"internalType":"uint256","name":"pt1xy","type":"uint256"},{"internalType":"uint256","name":"pt1yx","type":"uint256"},{"internalType":"uint256","name":"pt1yy","type":"uint256"},{"internalType":"uint256","name":"pt2xx","type":"uint256"},{"internalType":"uint256","name":"pt2xy","type":"uint256"},{"internalType":"uint256","name":"pt2yx","type":"uint256"},{"internalType":"uint256","name":"pt2yy","type":"uint256"}],"name":"ecTwistAdd","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"s","type":"uint256"},{"internalType":"uint256","name":"pt1xx","type":"uint256"},{"internalType":"uint256","name":"pt1xy","type":"uint256"},{"internalType":"uint256","name":"pt1yx","type":"uint256"},{"internalType":"uint256","name":"pt1yy","type":"uint256"}],"name":"ecTwistMul","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getFieldModulus","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50610dfd806100206000396000f3fe608060405234801561001057600080fd5b506004361061006d5760003560e01c80635120675214610072578063779d890d146100ac578063783bde80146100c05780639b0c399a146100e7578063ad50f9c11461010e578063cbe96a5014610135578063defbcdee14610168575b600080fd5b6100997f1d9befcd05a5323e6da4d435f3b617cdb3af83285c2df711ef39c01571827f9d81565b6040519081526020015b60405180910390f35b600080516020610da8833981519152610099565b6100997f198e9393920d483a7260bfb731fb5d25f1aa493335a9e71297e485b7aef312c281565b6100997f1800deef121f1e76426a00665e5c4479674322d4f75edadd46debd5cd992f6ed81565b6100997f275dc4a288d1afb3cbb1ac09187524c7db36395df7be3b99e673b13a075a65ec81565b610148610143366004610c8c565b61017b565b6040805194855260208501939093529183015260608201526080016100a3565b610148610176366004610ce1565b61031a565b60008080808b15801561018c57508a155b8015610196575089155b80156101a0575088155b1561020a57871580156101b1575086155b80156101bb575085155b80156101c5575084155b6101fa576101d5888888886103b1565b6101fa5760405162461bcd60e51b81526004016101f190610d1c565b60405180910390fd5b508692508591508490508361030b565b87158015610216575086155b8015610220575085155b801561022a575084155b156102675761023b8c8c8c8c6103b1565b6102575760405162461bcd60e51b81526004016101f190610d1c565b508a92508991508890508761030b565b6102738c8c8c8c6103b1565b61028f5760405162461bcd60e51b81526004016101f190610d1c565b61029b888888886103b1565b6102b75760405162461bcd60e51b81526004016101f190610d1c565b60006102d18d8d8d8d600160008f8f8f8f60016000610466565b90506103018160005b602090810291909101519083015160408401516060850151608086015160a08701516106f1565b9450945094509450505b98509850985098945050505050565b600080808060018815801561032d575087155b8015610337575086155b8015610341575085155b15610355575060019750879550600061037d565b610361898989896103b1565b61037d5760405162461bcd60e51b81526004016101f190610d1c565b600061038f8b8b8b8b8b87600061075c565b905061039c8160006102da565b929e919d509b50909950975050505050505050565b60008060008060006103c5878789896107df565b90945092506103d6898981816107df565b90925090506103e782828b8b6107df565b90925090506103f884848484610850565b909450925061044884847f2b149d40ceb8aaae81be18991be06ac3b5b4c5e559dbefa33267e6dc24a138e57e9713b03af0fed4cd2cafadeed8fdf4a74fa084e52d1852e4a2bd0685c315d2610850565b909450925083158015610459575082155b9998505050505050505050565b61046e610c50565b8815801561047a575087155b156104bc578686868686868660005b60a089019290925260808801929092526060870192909252604086019290925260208581019390935290910201526106e1565b821580156104c8575081155b156104db578c8c8c8c8c8c866000610489565b6104e785858b8b6107df565b90955093506104f88b8b85856107df565b6060830152604082015261050e87878b8b6107df565b909750955061051f8d8d85856107df565b60a0830152608082018190528714801561053c575060a081015186145b15610581576040810151851480156105575750606081015184145b156105725761056a8d8d8d8d8d8d610892565b866000610489565b60016000818180808681610489565b61058d898985856107df565b90935091506105ad858583600260200201518460035b6020020151610850565b909d509b506105c887878360045b60200201518460056105a3565b909b5099506105d98b8b81816107df565b90995097506105fa89898360045b60200201518460055b60200201516107df565b909550935061060b89898d8d6107df565b909950975061061c898985856107df565b60a083015260808201526106328d8d81816107df565b9097509550610643878785856107df565b909750955061065487878b8b610850565b909750955061066585856002610ada565b909350915061067687878585610850565b90975095506106878b8b89896107df565b6020830152815261069a85858989610850565b909b5099506106ab8d8d8d8d6107df565b909b5099506106c5898983600260200201518460036105f0565b909d509b506106d68b8b8f8f610850565b606083015260408201525b9c9b505050505050505050505050565b600080600080600080610702610c6e565b61070c8989610b0d565b909350915061071d8d8d85856107df565b602083015281526107308b8b85856107df565b60608301819052604083018290528251602090930151929f929e50909c509a5098505050505050505050565b610764610c50565b87156107d45760018816156107a5578051602082015160408301516060840151608085015160a08601516107a29594939291908d8d8d8d8d8d610466565b90505b6107b3878787878787610892565b949b509299509097509550935091506107cd600289610d5e565b9750610764565b979650505050505050565b60008061081d600080516020610da8833981519152858809600080516020610da8833981519152858809600080516020610da8833981519152610b98565b600080516020610da883398151915280868809600080516020610da8833981519152868a09089150915094509492505050565b60008061086c8685600080516020610da8833981519152610b98565b6108858685600080516020610da8833981519152610b98565b9150915094509492505050565b6000806000806000806108a3610c50565b6108af8d8d6003610ada565b602083018190528183526108c591908f8f6107df565b602083015281526108d88b8b8b8b6107df565b90995097506108e98d8d8d8d6107df565b606083015260408201819052610909908260035b60200201518b8b6107df565b60608301526040820152805161092c908260015b602002015183518460016105f0565b6040830151919e509c5061094a908260035b60200201516008610ada565b60a083015260808201526109618d8d8360046105bb565b909d509b50610972898981816107df565b60a083015260808201526040810151606082015161099291906004610ada565b60608301819052604083018290526109ac91908f8f610850565b6060830152604082018190526109c49082600361091d565b606083015260408201526109da8b8b6008610ada565b602083018190528183526109f091908d8d6107df565b60208301819052818352610a0791908360046105e7565b602083015280825260408201516060830151610a25928460016105a3565b60608301526040820152610a3b8d8d6002610ada565b6020830152808252610a4f908260016108fd565b60208301528152610a6389898360046105e7565b60a083015260808201819052610a7b9082600561093e565b826004602002018360056020020191909152528060006020020151816001602002015182600260200201518360036020020151846004602002015185600560200201519650965096509650965096505096509650965096509650969050565b600080600080516020610da8833981519152838609600080516020610da883398151915284860991509150935093915050565b60008080610b4e600080516020610da883398151915280878809600080516020610da883398151915287880908600080516020610da8833981519152610bbc565b9050600080516020610da8833981519152818609600080516020610da8833981519152828609610b8c90600080516020610da8833981519152610d80565b92509250509250929050565b60008180610ba857610ba8610d48565b610bb28484610d80565b8508949350505050565b60008060405160208152602080820152602060408201528460608201526002840360808201528360a082015260208160c08360056107d05a03fa90519250905080610c495760405162461bcd60e51b815260206004820152601a60248201527f6572726f722077697468206d6f64756c617220696e766572736500000000000060448201526064016101f1565b5092915050565b6040518060c001604052806006906020820280368337509192915050565b60405180608001604052806004906020820280368337509192915050565b600080600080600080600080610100898b031215610ca957600080fd5b505086359860208801359850604088013597606081013597506080810135965060a0810135955060c0810135945060e0013592509050565b600080600080600060a08688031215610cf957600080fd5b505083359560208501359550604085013594606081013594506080013592509050565b602080825260129082015271706f696e74206e6f7420696e20637572766560701b604082015260600190565b634e487b7160e01b600052601260045260246000fd5b600082610d7b57634e487b7160e01b600052601260045260246000fd5b500490565b81810381811115610da157634e487b7160e01b600052601160045260246000fd5b9291505056fe30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47a2646970667358221220bbba255b0b3e97590748f6a15256dba836d9ad9b81608a97cbf4954595465a8664736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061006d5760003560e01c80635120675214610072578063779d890d146100ac578063783bde80146100c05780639b0c399a146100e7578063ad50f9c11461010e578063cbe96a5014610135578063defbcdee14610168575b600080fd5b6100997f1d9befcd05a5323e6da4d435f3b617cdb3af83285c2df711ef39c01571827f9d81565b6040519081526020015b60405180910390f35b600080516020610da8833981519152610099565b6100997f198e9393920d483a7260bfb731fb5d25f1aa493335a9e71297e485b7aef312c281565b6100997f1800deef121f1e76426a00665e5c4479674322d4f75edadd46debd5cd992f6ed81565b6100997f275dc4a288d1afb3cbb1ac09187524c7db36395df7be3b99e673b13a075a65ec81565b610148610143366004610c8c565b61017b565b6040805194855260208501939093529183015260608201526080016100a3565b610148610176366004610ce1565b61031a565b60008080808b15801561018c57508a155b8015610196575089155b80156101a0575088155b1561020a57871580156101b1575086155b80156101bb575085155b80156101c5575084155b6101fa576101d5888888886103b1565b6101fa5760405162461bcd60e51b81526004016101f190610d1c565b60405180910390fd5b508692508591508490508361030b565b87158015610216575086155b8015610220575085155b801561022a575084155b156102675761023b8c8c8c8c6103b1565b6102575760405162461bcd60e51b81526004016101f190610d1c565b508a92508991508890508761030b565b6102738c8c8c8c6103b1565b61028f5760405162461bcd60e51b81526004016101f190610d1c565b61029b888888886103b1565b6102b75760405162461bcd60e51b81526004016101f190610d1c565b60006102d18d8d8d8d600160008f8f8f8f60016000610466565b90506103018160005b602090810291909101519083015160408401516060850151608086015160a08701516106f1565b9450945094509450505b98509850985098945050505050565b600080808060018815801561032d575087155b8015610337575086155b8015610341575085155b15610355575060019750879550600061037d565b610361898989896103b1565b61037d5760405162461bcd60e51b81526004016101f190610d1c565b600061038f8b8b8b8b8b87600061075c565b905061039c8160006102da565b929e919d509b50909950975050505050505050565b60008060008060006103c5878789896107df565b90945092506103d6898981816107df565b90925090506103e782828b8b6107df565b90925090506103f884848484610850565b909450925061044884847f2b149d40ceb8aaae81be18991be06ac3b5b4c5e559dbefa33267e6dc24a138e57e9713b03af0fed4cd2cafadeed8fdf4a74fa084e52d1852e4a2bd0685c315d2610850565b909450925083158015610459575082155b9998505050505050505050565b61046e610c50565b8815801561047a575087155b156104bc578686868686868660005b60a089019290925260808801929092526060870192909252604086019290925260208581019390935290910201526106e1565b821580156104c8575081155b156104db578c8c8c8c8c8c866000610489565b6104e785858b8b6107df565b90955093506104f88b8b85856107df565b6060830152604082015261050e87878b8b6107df565b909750955061051f8d8d85856107df565b60a0830152608082018190528714801561053c575060a081015186145b15610581576040810151851480156105575750606081015184145b156105725761056a8d8d8d8d8d8d610892565b866000610489565b60016000818180808681610489565b61058d898985856107df565b90935091506105ad858583600260200201518460035b6020020151610850565b909d509b506105c887878360045b60200201518460056105a3565b909b5099506105d98b8b81816107df565b90995097506105fa89898360045b60200201518460055b60200201516107df565b909550935061060b89898d8d6107df565b909950975061061c898985856107df565b60a083015260808201526106328d8d81816107df565b9097509550610643878785856107df565b909750955061065487878b8b610850565b909750955061066585856002610ada565b909350915061067687878585610850565b90975095506106878b8b89896107df565b6020830152815261069a85858989610850565b909b5099506106ab8d8d8d8d6107df565b909b5099506106c5898983600260200201518460036105f0565b909d509b506106d68b8b8f8f610850565b606083015260408201525b9c9b505050505050505050505050565b600080600080600080610702610c6e565b61070c8989610b0d565b909350915061071d8d8d85856107df565b602083015281526107308b8b85856107df565b60608301819052604083018290528251602090930151929f929e50909c509a5098505050505050505050565b610764610c50565b87156107d45760018816156107a5578051602082015160408301516060840151608085015160a08601516107a29594939291908d8d8d8d8d8d610466565b90505b6107b3878787878787610892565b949b509299509097509550935091506107cd600289610d5e565b9750610764565b979650505050505050565b60008061081d600080516020610da8833981519152858809600080516020610da8833981519152858809600080516020610da8833981519152610b98565b600080516020610da883398151915280868809600080516020610da8833981519152868a09089150915094509492505050565b60008061086c8685600080516020610da8833981519152610b98565b6108858685600080516020610da8833981519152610b98565b9150915094509492505050565b6000806000806000806108a3610c50565b6108af8d8d6003610ada565b602083018190528183526108c591908f8f6107df565b602083015281526108d88b8b8b8b6107df565b90995097506108e98d8d8d8d6107df565b606083015260408201819052610909908260035b60200201518b8b6107df565b60608301526040820152805161092c908260015b602002015183518460016105f0565b6040830151919e509c5061094a908260035b60200201516008610ada565b60a083015260808201526109618d8d8360046105bb565b909d509b50610972898981816107df565b60a083015260808201526040810151606082015161099291906004610ada565b60608301819052604083018290526109ac91908f8f610850565b6060830152604082018190526109c49082600361091d565b606083015260408201526109da8b8b6008610ada565b602083018190528183526109f091908d8d6107df565b60208301819052818352610a0791908360046105e7565b602083015280825260408201516060830151610a25928460016105a3565b60608301526040820152610a3b8d8d6002610ada565b6020830152808252610a4f908260016108fd565b60208301528152610a6389898360046105e7565b60a083015260808201819052610a7b9082600561093e565b826004602002018360056020020191909152528060006020020151816001602002015182600260200201518360036020020151846004602002015185600560200201519650965096509650965096505096509650965096509650969050565b600080600080516020610da8833981519152838609600080516020610da883398151915284860991509150935093915050565b60008080610b4e600080516020610da883398151915280878809600080516020610da883398151915287880908600080516020610da8833981519152610bbc565b9050600080516020610da8833981519152818609600080516020610da8833981519152828609610b8c90600080516020610da8833981519152610d80565b92509250509250929050565b60008180610ba857610ba8610d48565b610bb28484610d80565b8508949350505050565b60008060405160208152602080820152602060408201528460608201526002840360808201528360a082015260208160c08360056107d05a03fa90519250905080610c495760405162461bcd60e51b815260206004820152601a60248201527f6572726f722077697468206d6f64756c617220696e766572736500000000000060448201526064016101f1565b5092915050565b6040518060c001604052806006906020820280368337509192915050565b60405180608001604052806004906020820280368337509192915050565b600080600080600080600080610100898b031215610ca957600080fd5b505086359860208801359850604088013597606081013597506080810135965060a0810135955060c0810135945060e0013592509050565b600080600080600060a08688031215610cf957600080fd5b505083359560208501359550604085013594606081013594506080013592509050565b602080825260129082015271706f696e74206e6f7420696e20637572766560701b604082015260600190565b634e487b7160e01b600052601260045260246000fd5b600082610d7b57634e487b7160e01b600052601260045260246000fd5b500490565b81810381811115610da157634e487b7160e01b600052601160045260246000fd5b9291505056fe30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47a2646970667358221220bbba255b0b3e97590748f6a15256dba836d9ad9b81608a97cbf4954595465a8664736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var MerkleArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"Merkle","sourceName":"contracts/common/Merkle.sol","abi":[],"bytecode":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212202db2509119c8628b728a484ebc6ba9b1e5898ea19639476f14228eb88863575864736f6c63430008130033","deployedBytecode":"0x73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212202db2509119c8628b728a484ebc6ba9b1e5898ea19639476f14228eb88863575864736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var CheckpointManagerArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"CheckpointManager","sourceName":"contracts/root/CheckpointManager.sol","abi":[{"inputs":[{"internalType":"address","name":"initiator","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"inputs":[],"name":"DOMAIN","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"bls","outputs":[{"internalType":"contract IBLS","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"bn256G2","outputs":[{"internalType":"contract IBN256G2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"chainId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"checkpointBlockNumbers","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"checkpoints","outputs":[{"internalType":"uint256","name":"epoch","type":"uint256"},{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"eventRoot","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentCheckpointBlockNumber","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentEpoch","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"currentValidatorSet","outputs":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"uint256","name":"votingPower","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentValidatorSetHash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentValidatorSetLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"name":"getCheckpointBlock","outputs":[{"internalType":"bool","name":"","type":"bool"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"leaf","type":"bytes32"},{"internalType":"uint256","name":"leafIndex","type":"uint256"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"getEventMembershipByBlockNumber","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"epoch","type":"uint256"},{"internalType":"bytes32","name":"leaf","type":"bytes32"},{"internalType":"uint256","name":"leafIndex","type":"uint256"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"getEventMembershipByEpoch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"name":"getEventRootByBlock","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IBLS","name":"newBls","type":"address"},{"internalType":"contract IBN256G2","name":"newBn256G2","type":"address"},{"internalType":"uint256","name":"chainId_","type":"uint256"},{"components":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"uint256[4]","name":"blsKey","type":"uint256[4]"},{"internalType":"uint256","name":"votingPower","type":"uint256"}],"internalType":"struct ICheckpointManager.Validator[]","name":"newValidatorSet","type":"tuple[]"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"bytes32","name":"blockHash","type":"bytes32"},{"internalType":"uint256","name":"blockRound","type":"uint256"},{"internalType":"bytes32","name":"currentValidatorSetHash","type":"bytes32"}],"internalType":"struct ICheckpointManager.CheckpointMetadata","name":"checkpointMetadata","type":"tuple"},{"components":[{"internalType":"uint256","name":"epoch","type":"uint256"},{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"eventRoot","type":"bytes32"}],"internalType":"struct ICheckpointManager.Checkpoint","name":"checkpoint","type":"tuple"},{"internalType":"uint256[2]","name":"signature","type":"uint256[2]"},{"components":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"uint256[4]","name":"blsKey","type":"uint256[4]"},{"internalType":"uint256","name":"votingPower","type":"uint256"}],"internalType":"struct ICheckpointManager.Validator[]","name":"newValidatorSet","type":"tuple[]"},{"internalType":"bytes","name":"bitmap","type":"bytes"}],"name":"submit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"totalVotingPower","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}],"bytecode":"0x60a060405234801561001057600080fd5b506040516115ed3803806115ed83398101604081905261002f91610040565b6001600160a01b0316608052610070565b60006020828403121561005257600080fd5b81516001600160a01b038116811461006957600080fd5b9392505050565b60805161155b6100926000396000818161052b0152610563015261155b6000f3fe608060405234801561001057600080fd5b50600436106101165760003560e01c806376671808116100a2578063babd4ee411610071578063babd4ee4146102c8578063d4c8e3e8146102db578063e416d677146102ee578063e9193d2b146102f7578063f896f1a51461030a57600080fd5b8063766718081461024157806395b0b0271461024a5780639a8a059214610275578063b8a242521461027e57600080fd5b806361a02208116100e957806361a022081461019b578063671b3793146101be5780636969a25c146101c7578063729e7c6e1461021957806373cb1a111461022c57600080fd5b80631d1d4f261461011b57806322fd1818146101375780633569ed931461016157806352a9674b14610174575b600080fd5b61012460035481565b6040519081526020015b60405180910390f35b61014a610145366004610f34565b610313565b60408051921515835260208301919091520161012e565b61012461016f366004610f34565b610364565b6101247fbee7fa562a38908559e4a988e62d6c08b84ef05f2ebd5d2bb2b855dc19d19fe281565b6101ae6101a9366004610f4d565b610398565b604051901515815260200161012e565b61012460055481565b6101fa6101d5366004610f34565b600960205260009081526040902080546005909101546001600160a01b039091169082565b604080516001600160a01b03909316835260208301919091520161012e565b6101ae610227366004610f4d565b610410565b61023f61023a366004611041565b610469565b005b61012460025481565b60065461025d906001600160a01b031681565b6040516001600160a01b03909116815260200161012e565b61012460015481565b6102ad61028c366004610f34565b60086020526000908152604090208054600182015460029092015490919083565b6040805193845260208401929092529082015260600161012e565b61023f6102d63660046110cc565b61061f565b60075461025d906001600160a01b031681565b61012460045481565b610124610305366004610f34565b610884565b610124600b5481565b60008080610322600a856108a5565b600a54909150810361033a5750600093849350915050565b6001600a828154811061034f5761034f6111a5565b90600052602060002001549250925050915091565b6000600881610374600a856108a5565b61037f9060016111d1565b8152602001908152602001600020600201549050919050565b6000806103a487610364565b9050806103f85760405162461bcd60e51b815260206004820152601e60248201527f4e4f5f4556454e545f524f4f545f464f525f424c4f434b5f4e554d424552000060448201526064015b60405180910390fd5b6104058686838787610954565b979650505050505050565b600085815260086020526040812060020154806103f85760405162461bcd60e51b815260206004820152601760248201527609c9ebe8aac8a9ca8bea49e9ea8be8c9ea4be8aa09e869604b1b60448201526064016103ef565b600054610100900460ff16158080156104895750600054600160ff909116105b806104a35750303b1580156104a3575060005460ff166001145b6105065760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016103ef565b6000805460ff191660011790558015610529576000805461ff0019166101001790555b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03161561058d57336001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161461058d57600080fd5b6001849055600680546001600160a01b038089166001600160a01b031992831617909255600780549288169290911691909117905560038290556105d1838361099e565b8015610617576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b8660400135600b54146106745760405162461bcd60e51b815260206004820152601a60248201527f494e56414c49445f56414c494441544f525f5345545f4841534800000000000060448201526064016103ef565b6000600154876020013589600001358a602001358a600001358b604001358d604001358b8b6040516020016106aa9291906111e4565b604051602081830303815290604052805190602001206040516020016106d7989796959493929190611247565b60408051601f198184030181528282528051602091820120908301520160408051601f198184030181529082905260065463a850a90960e01b83529092506107a3916001600160a01b039091169063a850a9099061075b907fbee7fa562a38908559e4a988e62d6c08b84ef05f2ebd5d2bb2b855dc19d19fe290869060040161127d565b6040805180830381865afa158015610777573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061079b91906112d3565b878585610aa4565b6002546107b08189610dae565b8735600081815260086020908152604091829020838155908b01356001820155908a013560029091015581101561083357600a8054600181018255600091825260208a01357fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a8909101556002805490919061082a90611361565b90915550610867565b600a805460208a0135919061084a9060019061137a565b8154811061085a5761085a6111a5565b6000918252602090912001555b6020880135600455610879868661099e565b505050505050505050565b600a818154811061089457600080fd5b600091825260209091200154905081565b815460009081036108b85750600061094e565b82546000905b808210156109055760006108d28383610e8b565b600087815260209020909150859082015411156108f1578091506108ff565b6108fc8160016111d1565b92505b506108be565b60008211801561093157508361092e8661092060018661137a565b600091825260209091200190565b54145b1561094a5761094160018361137a565b9250505061094e565b5090505b92915050565b60008115610993578160051b8301835b8660011660051b8881528135602082185250604060002097508660011c96506020810190508181106109645750505b505050901591141690565b600381905560405181906109b890849083906020016111e4565b60408051601f198184030181529190528051602090910120600b556000805b82811015610a9b5760008585838181106109f3576109f36111a5565b905060c0020160a00135905060008111610a435760405162461bcd60e51b8152602060048201526011602482015270564f54494e475f504f5745525f5a45524f60781b60448201526064016103ef565b610a4d81846111d1565b9250858583818110610a6157610a616111a5565b905060c00201600960008481526020019081526020016000208181610a8691906113a4565b9050505080610a9490611361565b90506109d7565b50600555505050565b600354610aaf610f16565b6000805b83811015610c3357610ac6868683610ead565b15610c2b5781600003610b1a576000818152600960205260409081902081516080810190925260010160048282826020028201915b815481526020019060010190808311610afb5750505050509250610c0c565b60008181526009602052604080822081516080810190925260010160048282826020028201915b815481526020019060010190808311610b4157505060075488516020808b01516040808d01516060808f01518b51958c0151848d0151928d01519451630cbe96a560e41b81529c9d506001600160a01b039098169b63cbe96a509b50610bb89a509698509396919593949391929091600401611247565b608060405180830381865afa158015610bd5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bf99190611403565b6060880152604087015260208601528452505b600081815260096020526040902060050154610c2890836111d1565b91505b600101610ab3565b5080600003610c765760405162461bcd60e51b815260206004820152600f60248201526e4249544d41505f49535f454d50545960881b60448201526064016103ef565b60036005546002610c87919061138d565b610c91919061144f565b8111610cdb5760405162461bcd60e51b815260206004820152601960248201527824a729aaa32324a1a4a2a72a2fab27aa24a723afa827aba2a960391b60448201526064016103ef565b60065460405163ebbdac9160e01b815260009182916001600160a01b039091169063ebbdac9190610d14908b9088908e90600401611463565b6040805180830381865afa158015610d30573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d5491906114de565b91509150818015610d625750805b6108795760405162461bcd60e51b815260206004820152601d60248201527f5349474e41545552455f564552494649434154494f4e5f4641494c454400000060448201526064016103ef565b600082815260086020908152604091829020825160608101845281548082526001830154938201939093526002909101549281019290925282351480610e0057508051610dfc9060016111d1565b8235145b610e3c5760405162461bcd60e51b815260206004820152600d60248201526c0929cac82989288be8aa09e869609b1b60448201526064016103ef565b8060200151826020013511610e865760405162461bcd60e51b815260206004820152601060248201526f115354151657d0d21150d2d413d2539560821b60448201526064016103ef565b505050565b6000610e9a600284841861144f565b610ea6908484166111d1565b9392505050565b600080610ebb60088461144f565b90506000610eca600885611511565b9050848210610ede57600092505050610ea6565b6000600160ff83161b878785818110610ef957610ef96111a5565b9050013560f81c60f81b60f81c60ff161611925050509392505050565b60405180608001604052806004906020820280368337509192915050565b600060208284031215610f4657600080fd5b5035919050565b600080600080600060808688031215610f6557600080fd5b853594506020860135935060408601359250606086013567ffffffffffffffff80821115610f9257600080fd5b818801915088601f830112610fa657600080fd5b813581811115610fb557600080fd5b8960208260051b8501011115610fca57600080fd5b9699959850939650602001949392505050565b6001600160a01b0381168114610ff257600080fd5b50565b60008083601f84011261100757600080fd5b50813567ffffffffffffffff81111561101f57600080fd5b60208301915083602060c08302850101111561103a57600080fd5b9250929050565b60008060008060006080868803121561105957600080fd5b853561106481610fdd565b9450602086013561107481610fdd565b935060408601359250606086013567ffffffffffffffff81111561109757600080fd5b6110a388828901610ff5565b969995985093965092949392505050565b6000606082840312156110c657600080fd5b50919050565b6000806000806000806000610140888a0312156110e857600080fd5b6110f289896110b4565b96506111018960608a016110b4565b955061010088018981111561111557600080fd5b60c0890195503567ffffffffffffffff8082111561113257600080fd5b61113e8b838c01610ff5565b90965094506101208a013591508082111561115857600080fd5b818a0191508a601f83011261116c57600080fd5b81358181111561117b57600080fd5b8b602082850101111561118d57600080fd5b60208301945080935050505092959891949750929550565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b8082018082111561094e5761094e6111bb565b60208082528181018390526000908460408401835b8681101561123c57823561120c81610fdd565b6001600160a01b0316825260808385018584013760a0838101359083015260c092830192909101906001016111f9565b509695505050505050565b978852602088019690965260408701949094526060860192909252608085015260a084015260c083015260e08201526101000190565b82815260006020604081840152835180604085015260005b818110156112b157858101830151858201606001528201611295565b506000606082860101526060601f19601f830116850101925050509392505050565b6000604082840312156112e557600080fd5b82601f8301126112f457600080fd5b6040516040810181811067ffffffffffffffff8211171561132557634e487b7160e01b600052604160045260246000fd5b806040525080604084018581111561133c57600080fd5b845b8181101561135657805183526020928301920161133e565b509195945050505050565b600060018201611373576113736111bb565b5060010190565b8181038181111561094e5761094e6111bb565b808202811582820484141761094e5761094e6111bb565b81356113af81610fdd565b81546001600160a01b0319166001600160a01b0391909116178155602082810160005b60048110156113f2578135600182860181019190915591830191016113d2565b50505060a082013560058201555050565b6000806000806080858703121561141957600080fd5b505082516020840151604085015160609095015191969095509092509050565b634e487b7160e01b600052601260045260246000fd5b60008261145e5761145e611439565b500490565b61010081016040858337604082018460005b6004811015611494578151835260209283019290910190600101611475565b50505060c082018360005b60028110156114be57815183526020928301929091019060010161149f565b505050949350505050565b805180151581146114d957600080fd5b919050565b600080604083850312156114f157600080fd5b6114fa836114c9565b9150611508602084016114c9565b90509250929050565b60008261152057611520611439565b50069056fea2646970667358221220333371ed350c4bed32fb9f706b6c8919ed167439ab6905122b177e698bce48e964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101165760003560e01c806376671808116100a2578063babd4ee411610071578063babd4ee4146102c8578063d4c8e3e8146102db578063e416d677146102ee578063e9193d2b146102f7578063f896f1a51461030a57600080fd5b8063766718081461024157806395b0b0271461024a5780639a8a059214610275578063b8a242521461027e57600080fd5b806361a02208116100e957806361a022081461019b578063671b3793146101be5780636969a25c146101c7578063729e7c6e1461021957806373cb1a111461022c57600080fd5b80631d1d4f261461011b57806322fd1818146101375780633569ed931461016157806352a9674b14610174575b600080fd5b61012460035481565b6040519081526020015b60405180910390f35b61014a610145366004610f34565b610313565b60408051921515835260208301919091520161012e565b61012461016f366004610f34565b610364565b6101247fbee7fa562a38908559e4a988e62d6c08b84ef05f2ebd5d2bb2b855dc19d19fe281565b6101ae6101a9366004610f4d565b610398565b604051901515815260200161012e565b61012460055481565b6101fa6101d5366004610f34565b600960205260009081526040902080546005909101546001600160a01b039091169082565b604080516001600160a01b03909316835260208301919091520161012e565b6101ae610227366004610f4d565b610410565b61023f61023a366004611041565b610469565b005b61012460025481565b60065461025d906001600160a01b031681565b6040516001600160a01b03909116815260200161012e565b61012460015481565b6102ad61028c366004610f34565b60086020526000908152604090208054600182015460029092015490919083565b6040805193845260208401929092529082015260600161012e565b61023f6102d63660046110cc565b61061f565b60075461025d906001600160a01b031681565b61012460045481565b610124610305366004610f34565b610884565b610124600b5481565b60008080610322600a856108a5565b600a54909150810361033a5750600093849350915050565b6001600a828154811061034f5761034f6111a5565b90600052602060002001549250925050915091565b6000600881610374600a856108a5565b61037f9060016111d1565b8152602001908152602001600020600201549050919050565b6000806103a487610364565b9050806103f85760405162461bcd60e51b815260206004820152601e60248201527f4e4f5f4556454e545f524f4f545f464f525f424c4f434b5f4e554d424552000060448201526064015b60405180910390fd5b6104058686838787610954565b979650505050505050565b600085815260086020526040812060020154806103f85760405162461bcd60e51b815260206004820152601760248201527609c9ebe8aac8a9ca8bea49e9ea8be8c9ea4be8aa09e869604b1b60448201526064016103ef565b600054610100900460ff16158080156104895750600054600160ff909116105b806104a35750303b1580156104a3575060005460ff166001145b6105065760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016103ef565b6000805460ff191660011790558015610529576000805461ff0019166101001790555b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03161561058d57336001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161461058d57600080fd5b6001849055600680546001600160a01b038089166001600160a01b031992831617909255600780549288169290911691909117905560038290556105d1838361099e565b8015610617576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b8660400135600b54146106745760405162461bcd60e51b815260206004820152601a60248201527f494e56414c49445f56414c494441544f525f5345545f4841534800000000000060448201526064016103ef565b6000600154876020013589600001358a602001358a600001358b604001358d604001358b8b6040516020016106aa9291906111e4565b604051602081830303815290604052805190602001206040516020016106d7989796959493929190611247565b60408051601f198184030181528282528051602091820120908301520160408051601f198184030181529082905260065463a850a90960e01b83529092506107a3916001600160a01b039091169063a850a9099061075b907fbee7fa562a38908559e4a988e62d6c08b84ef05f2ebd5d2bb2b855dc19d19fe290869060040161127d565b6040805180830381865afa158015610777573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061079b91906112d3565b878585610aa4565b6002546107b08189610dae565b8735600081815260086020908152604091829020838155908b01356001820155908a013560029091015581101561083357600a8054600181018255600091825260208a01357fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a8909101556002805490919061082a90611361565b90915550610867565b600a805460208a0135919061084a9060019061137a565b8154811061085a5761085a6111a5565b6000918252602090912001555b6020880135600455610879868661099e565b505050505050505050565b600a818154811061089457600080fd5b600091825260209091200154905081565b815460009081036108b85750600061094e565b82546000905b808210156109055760006108d28383610e8b565b600087815260209020909150859082015411156108f1578091506108ff565b6108fc8160016111d1565b92505b506108be565b60008211801561093157508361092e8661092060018661137a565b600091825260209091200190565b54145b1561094a5761094160018361137a565b9250505061094e565b5090505b92915050565b60008115610993578160051b8301835b8660011660051b8881528135602082185250604060002097508660011c96506020810190508181106109645750505b505050901591141690565b600381905560405181906109b890849083906020016111e4565b60408051601f198184030181529190528051602090910120600b556000805b82811015610a9b5760008585838181106109f3576109f36111a5565b905060c0020160a00135905060008111610a435760405162461bcd60e51b8152602060048201526011602482015270564f54494e475f504f5745525f5a45524f60781b60448201526064016103ef565b610a4d81846111d1565b9250858583818110610a6157610a616111a5565b905060c00201600960008481526020019081526020016000208181610a8691906113a4565b9050505080610a9490611361565b90506109d7565b50600555505050565b600354610aaf610f16565b6000805b83811015610c3357610ac6868683610ead565b15610c2b5781600003610b1a576000818152600960205260409081902081516080810190925260010160048282826020028201915b815481526020019060010190808311610afb5750505050509250610c0c565b60008181526009602052604080822081516080810190925260010160048282826020028201915b815481526020019060010190808311610b4157505060075488516020808b01516040808d01516060808f01518b51958c0151848d0151928d01519451630cbe96a560e41b81529c9d506001600160a01b039098169b63cbe96a509b50610bb89a509698509396919593949391929091600401611247565b608060405180830381865afa158015610bd5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bf99190611403565b6060880152604087015260208601528452505b600081815260096020526040902060050154610c2890836111d1565b91505b600101610ab3565b5080600003610c765760405162461bcd60e51b815260206004820152600f60248201526e4249544d41505f49535f454d50545960881b60448201526064016103ef565b60036005546002610c87919061138d565b610c91919061144f565b8111610cdb5760405162461bcd60e51b815260206004820152601960248201527824a729aaa32324a1a4a2a72a2fab27aa24a723afa827aba2a960391b60448201526064016103ef565b60065460405163ebbdac9160e01b815260009182916001600160a01b039091169063ebbdac9190610d14908b9088908e90600401611463565b6040805180830381865afa158015610d30573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d5491906114de565b91509150818015610d625750805b6108795760405162461bcd60e51b815260206004820152601d60248201527f5349474e41545552455f564552494649434154494f4e5f4641494c454400000060448201526064016103ef565b600082815260086020908152604091829020825160608101845281548082526001830154938201939093526002909101549281019290925282351480610e0057508051610dfc9060016111d1565b8235145b610e3c5760405162461bcd60e51b815260206004820152600d60248201526c0929cac82989288be8aa09e869609b1b60448201526064016103ef565b8060200151826020013511610e865760405162461bcd60e51b815260206004820152601060248201526f115354151657d0d21150d2d413d2539560821b60448201526064016103ef565b505050565b6000610e9a600284841861144f565b610ea6908484166111d1565b9392505050565b600080610ebb60088461144f565b90506000610eca600885611511565b9050848210610ede57600092505050610ea6565b6000600160ff83161b878785818110610ef957610ef96111a5565b9050013560f81c60f81b60f81c60ff161611925050509392505050565b60405180608001604052806004906020820280368337509192915050565b600060208284031215610f4657600080fd5b5035919050565b600080600080600060808688031215610f6557600080fd5b853594506020860135935060408601359250606086013567ffffffffffffffff80821115610f9257600080fd5b818801915088601f830112610fa657600080fd5b813581811115610fb557600080fd5b8960208260051b8501011115610fca57600080fd5b9699959850939650602001949392505050565b6001600160a01b0381168114610ff257600080fd5b50565b60008083601f84011261100757600080fd5b50813567ffffffffffffffff81111561101f57600080fd5b60208301915083602060c08302850101111561103a57600080fd5b9250929050565b60008060008060006080868803121561105957600080fd5b853561106481610fdd565b9450602086013561107481610fdd565b935060408601359250606086013567ffffffffffffffff81111561109757600080fd5b6110a388828901610ff5565b969995985093965092949392505050565b6000606082840312156110c657600080fd5b50919050565b6000806000806000806000610140888a0312156110e857600080fd5b6110f289896110b4565b96506111018960608a016110b4565b955061010088018981111561111557600080fd5b60c0890195503567ffffffffffffffff8082111561113257600080fd5b61113e8b838c01610ff5565b90965094506101208a013591508082111561115857600080fd5b818a0191508a601f83011261116c57600080fd5b81358181111561117b57600080fd5b8b602082850101111561118d57600080fd5b60208301945080935050505092959891949750929550565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b8082018082111561094e5761094e6111bb565b60208082528181018390526000908460408401835b8681101561123c57823561120c81610fdd565b6001600160a01b0316825260808385018584013760a0838101359083015260c092830192909101906001016111f9565b509695505050505050565b978852602088019690965260408701949094526060860192909252608085015260a084015260c083015260e08201526101000190565b82815260006020604081840152835180604085015260005b818110156112b157858101830151858201606001528201611295565b506000606082860101526060601f19601f830116850101925050509392505050565b6000604082840312156112e557600080fd5b82601f8301126112f457600080fd5b6040516040810181811067ffffffffffffffff8211171561132557634e487b7160e01b600052604160045260246000fd5b806040525080604084018581111561133c57600080fd5b845b8181101561135657805183526020928301920161133e565b509195945050505050565b600060018201611373576113736111bb565b5060010190565b8181038181111561094e5761094e6111bb565b808202811582820484141761094e5761094e6111bb565b81356113af81610fdd565b81546001600160a01b0319166001600160a01b0391909116178155602082810160005b60048110156113f2578135600182860181019190915591830191016113d2565b50505060a082013560058201555050565b6000806000806080858703121561141957600080fd5b505082516020840151604085015160609095015191969095509092509050565b634e487b7160e01b600052601260045260246000fd5b60008261145e5761145e611439565b500490565b61010081016040858337604082018460005b6004811015611494578151835260209283019290910190600101611475565b50505060c082018360005b60028110156114be57815183526020928301929091019060010161149f565b505050949350505050565b805180151581146114d957600080fd5b919050565b600080604083850312156114f157600080fd5b6114fa836114c9565b9150611508602084016114c9565b90509250929050565b60008261152057611520611439565b50069056fea2646970667358221220333371ed350c4bed32fb9f706b6c8919ed167439ab6905122b177e698bce48e964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ExitHelperArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ExitHelper","sourceName":"contracts/root/ExitHelper.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"bytes","name":"returnData","type":"bytes"}],"name":"ExitProcessed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"inputs":[{"components":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"uint256","name":"leafIndex","type":"uint256"},{"internalType":"bytes","name":"unhashedLeaf","type":"bytes"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"internalType":"struct IExitHelper.BatchExitInput[]","name":"inputs","type":"tuple[]"}],"name":"batchExit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"checkpointManager","outputs":[{"internalType":"contract ICheckpointManager","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"uint256","name":"leafIndex","type":"uint256"},{"internalType":"bytes","name":"unhashedLeaf","type":"bytes"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"exit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract ICheckpointManager","name":"newCheckpointManager","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"processedExits","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50610b62806100206000396000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c806350607b351461005c578063aa209cc314610071578063bd88ea7914610084578063c0857ba0146100bc578063c4d66de8146100e7575b600080fd5b61006f61006a3660046106c9565b6100fa565b005b61006f61007f36600461070b565b610200565b6100a76100923660046107bc565b60016020526000908152604090205460ff1681565b60405190151581526020015b60405180910390f35b6002546100cf906001600160a01b031681565b6040516001600160a01b0390911681526020016100b3565b61006f6100f53660046107ed565b610240565b6002546001600160a01b031661012b5760405162461bcd60e51b815260040161012290610811565b60405180910390fd5b8060005b818110156101fa576101f284848381811061014c5761014c610848565b905060200281019061015e919061085e565b3585858481811061017157610171610848565b9050602002810190610183919061085e565b6020013586868581811061019957610199610848565b90506020028101906101ab919061085e565b6101b990604081019061087e565b8888878181106101cb576101cb610848565b90506020028101906101dd919061085e565b6101eb9060608101906108c5565b60016103d2565b60010161012f565b50505050565b6002546001600160a01b03166102285760405162461bcd60e51b815260040161012290610811565b61023886868686868660006103d2565b505050505050565b600054610100900460ff16158080156102605750600054600160ff909116105b8061027a5750303b15801561027a575060005460ff166001145b6102dd5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610122565b6000805460ff191660011790558015610300576000805461ff0019166101001790555b6001600160a01b0382161580159061032157506001600160a01b0382163b15155b61036d5760405162461bcd60e51b815260206004820152601b60248201527f4578697448656c7065723a20494e56414c49445f4144445245535300000000006044820152606401610122565b600280546001600160a01b0319166001600160a01b03841617905580156103ce576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b60008080806103e3888a018a610925565b935093509350935084156104165760008481526001602052604090205460ff16156104115750505050610674565b610480565b60008481526001602052604090205460ff16156104805760405162461bcd60e51b815260206004820152602260248201527f4578697448656c7065723a20455849545f414c52454144595f50524f43455353604482015261115160f21b6064820152608401610122565b6002546040516001600160a01b03909116906361a02208908d906104a7908d908d90610a05565b6040519081900381206001600160e01b031960e085901b1682526104d492918f908d908d90600401610a15565b602060405180830381865afa1580156104f1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105159190610a62565b61055d5760405162461bcd60e51b815260206004820152601960248201527822bc34ba2432b63832b91d1024a72b20a624a22fa82927a7a360391b6044820152606401610122565b6000848152600160208190526040808320805460ff19169092179091555181906001600160a01b0385169061059a90889088908790602401610ad4565b60408051601f198184030181529181526020820180516001600160e01b031663f43cda8b60e01b179052516105cf9190610b07565b6000604051808303816000865af19150503d806000811461060c576040519150601f19603f3d011682016040523d82523d6000602084013e610611565b606091505b509150915081610632576000868152600160205260409020805460ff191690555b811515867f8bbfa0c9bee3785c03700d2a909592286efb83fc7e7002be5764424b9842f7ec836040516106659190610b19565b60405180910390a35050505050505b50505050505050565b60008083601f84011261068f57600080fd5b50813567ffffffffffffffff8111156106a757600080fd5b6020830191508360208260051b85010111156106c257600080fd5b9250929050565b600080602083850312156106dc57600080fd5b823567ffffffffffffffff8111156106f357600080fd5b6106ff8582860161067d565b90969095509350505050565b6000806000806000806080878903121561072457600080fd5b8635955060208701359450604087013567ffffffffffffffff8082111561074a57600080fd5b818901915089601f83011261075e57600080fd5b81358181111561076d57600080fd5b8a602082850101111561077f57600080fd5b60208301965080955050606089013591508082111561079d57600080fd5b506107aa89828a0161067d565b979a9699509497509295939492505050565b6000602082840312156107ce57600080fd5b5035919050565b6001600160a01b03811681146107ea57600080fd5b50565b6000602082840312156107ff57600080fd5b813561080a816107d5565b9392505050565b6020808252601b908201527f4578697448656c7065723a204e4f545f494e495449414c495a45440000000000604082015260600190565b634e487b7160e01b600052603260045260246000fd5b60008235607e1983360301811261087457600080fd5b9190910192915050565b6000808335601e1984360301811261089557600080fd5b83018035915067ffffffffffffffff8211156108b057600080fd5b6020019150368190038213156106c257600080fd5b6000808335601e198436030181126108dc57600080fd5b83018035915067ffffffffffffffff8211156108f757600080fd5b6020019150600581901b36038213156106c257600080fd5b634e487b7160e01b600052604160045260246000fd5b6000806000806080858703121561093b57600080fd5b84359350602085013561094d816107d5565b9250604085013561095d816107d5565b9150606085013567ffffffffffffffff8082111561097a57600080fd5b818701915087601f83011261098e57600080fd5b8135818111156109a0576109a061090f565b604051601f8201601f19908116603f011681019083821181831017156109c8576109c861090f565b816040528281528a60208487010111156109e157600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b8183823760009101908152919050565b85815284602082015283604082015260806060820152816080820152600060018060fb1b03831115610a4657600080fd5b8260051b808560a08501379190910160a0019695505050505050565b600060208284031215610a7457600080fd5b8151801515811461080a57600080fd5b60005b83811015610a9f578181015183820152602001610a87565b50506000910152565b60008151808452610ac0816020860160208601610a84565b601f01601f19169290920160200192915050565b8381526001600160a01b0383166020820152606060408201819052600090610afe90830184610aa8565b95945050505050565b60008251610874818460208701610a84565b60208152600061080a6020830184610aa856fea264697066735822122062ac4b08903d6279500a6ee30957a69454dadfc7f8af07bc8702efa271a1f6f364736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100575760003560e01c806350607b351461005c578063aa209cc314610071578063bd88ea7914610084578063c0857ba0146100bc578063c4d66de8146100e7575b600080fd5b61006f61006a3660046106c9565b6100fa565b005b61006f61007f36600461070b565b610200565b6100a76100923660046107bc565b60016020526000908152604090205460ff1681565b60405190151581526020015b60405180910390f35b6002546100cf906001600160a01b031681565b6040516001600160a01b0390911681526020016100b3565b61006f6100f53660046107ed565b610240565b6002546001600160a01b031661012b5760405162461bcd60e51b815260040161012290610811565b60405180910390fd5b8060005b818110156101fa576101f284848381811061014c5761014c610848565b905060200281019061015e919061085e565b3585858481811061017157610171610848565b9050602002810190610183919061085e565b6020013586868581811061019957610199610848565b90506020028101906101ab919061085e565b6101b990604081019061087e565b8888878181106101cb576101cb610848565b90506020028101906101dd919061085e565b6101eb9060608101906108c5565b60016103d2565b60010161012f565b50505050565b6002546001600160a01b03166102285760405162461bcd60e51b815260040161012290610811565b61023886868686868660006103d2565b505050505050565b600054610100900460ff16158080156102605750600054600160ff909116105b8061027a5750303b15801561027a575060005460ff166001145b6102dd5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610122565b6000805460ff191660011790558015610300576000805461ff0019166101001790555b6001600160a01b0382161580159061032157506001600160a01b0382163b15155b61036d5760405162461bcd60e51b815260206004820152601b60248201527f4578697448656c7065723a20494e56414c49445f4144445245535300000000006044820152606401610122565b600280546001600160a01b0319166001600160a01b03841617905580156103ce576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b60008080806103e3888a018a610925565b935093509350935084156104165760008481526001602052604090205460ff16156104115750505050610674565b610480565b60008481526001602052604090205460ff16156104805760405162461bcd60e51b815260206004820152602260248201527f4578697448656c7065723a20455849545f414c52454144595f50524f43455353604482015261115160f21b6064820152608401610122565b6002546040516001600160a01b03909116906361a02208908d906104a7908d908d90610a05565b6040519081900381206001600160e01b031960e085901b1682526104d492918f908d908d90600401610a15565b602060405180830381865afa1580156104f1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105159190610a62565b61055d5760405162461bcd60e51b815260206004820152601960248201527822bc34ba2432b63832b91d1024a72b20a624a22fa82927a7a360391b6044820152606401610122565b6000848152600160208190526040808320805460ff19169092179091555181906001600160a01b0385169061059a90889088908790602401610ad4565b60408051601f198184030181529181526020820180516001600160e01b031663f43cda8b60e01b179052516105cf9190610b07565b6000604051808303816000865af19150503d806000811461060c576040519150601f19603f3d011682016040523d82523d6000602084013e610611565b606091505b509150915081610632576000868152600160205260409020805460ff191690555b811515867f8bbfa0c9bee3785c03700d2a909592286efb83fc7e7002be5764424b9842f7ec836040516106659190610b19565b60405180910390a35050505050505b50505050505050565b60008083601f84011261068f57600080fd5b50813567ffffffffffffffff8111156106a757600080fd5b6020830191508360208260051b85010111156106c257600080fd5b9250929050565b600080602083850312156106dc57600080fd5b823567ffffffffffffffff8111156106f357600080fd5b6106ff8582860161067d565b90969095509350505050565b6000806000806000806080878903121561072457600080fd5b8635955060208701359450604087013567ffffffffffffffff8082111561074a57600080fd5b818901915089601f83011261075e57600080fd5b81358181111561076d57600080fd5b8a602082850101111561077f57600080fd5b60208301965080955050606089013591508082111561079d57600080fd5b506107aa89828a0161067d565b979a9699509497509295939492505050565b6000602082840312156107ce57600080fd5b5035919050565b6001600160a01b03811681146107ea57600080fd5b50565b6000602082840312156107ff57600080fd5b813561080a816107d5565b9392505050565b6020808252601b908201527f4578697448656c7065723a204e4f545f494e495449414c495a45440000000000604082015260600190565b634e487b7160e01b600052603260045260246000fd5b60008235607e1983360301811261087457600080fd5b9190910192915050565b6000808335601e1984360301811261089557600080fd5b83018035915067ffffffffffffffff8211156108b057600080fd5b6020019150368190038213156106c257600080fd5b6000808335601e198436030181126108dc57600080fd5b83018035915067ffffffffffffffff8211156108f757600080fd5b6020019150600581901b36038213156106c257600080fd5b634e487b7160e01b600052604160045260246000fd5b6000806000806080858703121561093b57600080fd5b84359350602085013561094d816107d5565b9250604085013561095d816107d5565b9150606085013567ffffffffffffffff8082111561097a57600080fd5b818701915087601f83011261098e57600080fd5b8135818111156109a0576109a061090f565b604051601f8201601f19908116603f011681019083821181831017156109c8576109c861090f565b816040528281528a60208487010111156109e157600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b8183823760009101908152919050565b85815284602082015283604082015260806060820152816080820152600060018060fb1b03831115610a4657600080fd5b8260051b808560a08501379190910160a0019695505050505050565b600060208284031215610a7457600080fd5b8151801515811461080a57600080fd5b60005b83811015610a9f578181015183820152602001610a87565b50506000910152565b60008151808452610ac0816020860160208601610a84565b601f01601f19169290920160200192915050565b8381526001600160a01b0383166020820152606060408201819052600090610afe90830184610aa8565b95945050505050565b60008251610874818460208701610a84565b60208152600061080a6020830184610aa856fea264697066735822122062ac4b08903d6279500a6ee30957a69454dadfc7f8af07bc8702efa271a1f6f364736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var StateSenderArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"StateSender","sourceName":"contracts/root/StateSender.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"bytes","name":"data","type":"bytes"}],"name":"StateSynced","type":"event"},{"inputs":[],"name":"MAX_LENGTH","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"counter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"syncState","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50610297806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806316f198311461004657806361bc221a1461005b578063a6f9885c14610076575b600080fd5b61005961005436600461017a565b61007f565b005b61006460005481565b60405190815260200160405180910390f35b61006461080081565b6001600160a01b0383166100cd5760405162461bcd60e51b815260206004820152601060248201526f24a72b20a624a22fa922a1a2a4ab22a960811b60448201526064015b60405180910390fd5b6108008111156101145760405162461bcd60e51b815260206004820152601260248201527108ab0868a8a88a6be9a82b0be988a9c8ea8960731b60448201526064016100c4565b826001600160a01b0316336001600160a01b031660008081546101369061020b565b9190508190557fd1d7f6609674cc5871fdb4b0bcd4f0a214118411de9e38983866514f22659165858560405161016d929190610232565b60405180910390a4505050565b60008060006040848603121561018f57600080fd5b83356001600160a01b03811681146101a657600080fd5b9250602084013567ffffffffffffffff808211156101c357600080fd5b818601915086601f8301126101d757600080fd5b8135818111156101e657600080fd5b8760208285010111156101f857600080fd5b6020830194508093505050509250925092565b60006001820161022b57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea264697066735822122031b7ec2bc87f0234fe89e0f741bc18f51baa2be5cc844033ea10f35e4b86094c64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100415760003560e01c806316f198311461004657806361bc221a1461005b578063a6f9885c14610076575b600080fd5b61005961005436600461017a565b61007f565b005b61006460005481565b60405190815260200160405180910390f35b61006461080081565b6001600160a01b0383166100cd5760405162461bcd60e51b815260206004820152601060248201526f24a72b20a624a22fa922a1a2a4ab22a960811b60448201526064015b60405180910390fd5b6108008111156101145760405162461bcd60e51b815260206004820152601260248201527108ab0868a8a88a6be9a82b0be988a9c8ea8960731b60448201526064016100c4565b826001600160a01b0316336001600160a01b031660008081546101369061020b565b9190508190557fd1d7f6609674cc5871fdb4b0bcd4f0a214118411de9e38983866514f22659165858560405161016d929190610232565b60405180910390a4505050565b60008060006040848603121561018f57600080fd5b83356001600160a01b03811681146101a657600080fd5b9250602084013567ffffffffffffffff808211156101c357600080fd5b818601915086601f8301126101d757600080fd5b8135818111156101e657600080fd5b8760208285010111156101f857600080fd5b6020830194508093505050509250925092565b60006001820161022b57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea264697066735822122031b7ec2bc87f0234fe89e0f741bc18f51baa2be5cc844033ea10f35e4b86094c64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var MerkleArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"Merkle","sourceName":"contracts/common/Merkle.sol","abi":[],"bytecode":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212205f6d16d82ef441ef4f9bc08a6e0fe81e8f3e358c8c8b82c58f5a473ebb1ed9df64736f6c63430008130033","deployedBytecode":"0x73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212205f6d16d82ef441ef4f9bc08a6e0fe81e8f3e358c8c8b82c58f5a473ebb1ed9df64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var CheckpointManagerArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"CheckpointManager","sourceName":"contracts/bridge/CheckpointManager.sol","abi":[{"inputs":[{"internalType":"address","name":"initiator","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"inputs":[],"name":"DOMAIN","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"bls","outputs":[{"internalType":"contract IBLS","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"bn256G2","outputs":[{"internalType":"contract IBN256G2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"chainId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"checkpointBlockNumbers","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"checkpoints","outputs":[{"internalType":"uint256","name":"epoch","type":"uint256"},{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"eventRoot","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentCheckpointBlockNumber","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentEpoch","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"currentValidatorSet","outputs":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"uint256","name":"votingPower","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentValidatorSetHash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentValidatorSetLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"name":"getCheckpointBlock","outputs":[{"internalType":"bool","name":"","type":"bool"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"leaf","type":"bytes32"},{"internalType":"uint256","name":"leafIndex","type":"uint256"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"getEventMembershipByBlockNumber","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"epoch","type":"uint256"},{"internalType":"bytes32","name":"leaf","type":"bytes32"},{"internalType":"uint256","name":"leafIndex","type":"uint256"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"getEventMembershipByEpoch","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"name":"getEventRootByBlock","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IBLS","name":"newBls","type":"address"},{"internalType":"contract IBN256G2","name":"newBn256G2","type":"address"},{"internalType":"uint256","name":"chainId_","type":"uint256"},{"components":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"uint256[4]","name":"blsKey","type":"uint256[4]"},{"internalType":"uint256","name":"votingPower","type":"uint256"}],"internalType":"struct ICheckpointManager.Validator[]","name":"newValidatorSet","type":"tuple[]"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"bytes32","name":"blockHash","type":"bytes32"},{"internalType":"uint256","name":"blockRound","type":"uint256"},{"internalType":"bytes32","name":"currentValidatorSetHash","type":"bytes32"}],"internalType":"struct ICheckpointManager.CheckpointMetadata","name":"checkpointMetadata","type":"tuple"},{"components":[{"internalType":"uint256","name":"epoch","type":"uint256"},{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"eventRoot","type":"bytes32"}],"internalType":"struct ICheckpointManager.Checkpoint","name":"checkpoint","type":"tuple"},{"internalType":"uint256[2]","name":"signature","type":"uint256[2]"},{"components":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"uint256[4]","name":"blsKey","type":"uint256[4]"},{"internalType":"uint256","name":"votingPower","type":"uint256"}],"internalType":"struct ICheckpointManager.Validator[]","name":"newValidatorSet","type":"tuple[]"},{"internalType":"bytes","name":"bitmap","type":"bytes"}],"name":"submit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"totalVotingPower","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}],"bytecode":"0x60a060405234801561001057600080fd5b506040516115ed3803806115ed83398101604081905261002f91610040565b6001600160a01b0316608052610070565b60006020828403121561005257600080fd5b81516001600160a01b038116811461006957600080fd5b9392505050565b60805161155b6100926000396000818161052b0152610563015261155b6000f3fe608060405234801561001057600080fd5b50600436106101165760003560e01c806376671808116100a2578063babd4ee411610071578063babd4ee4146102c8578063d4c8e3e8146102db578063e416d677146102ee578063e9193d2b146102f7578063f896f1a51461030a57600080fd5b8063766718081461024157806395b0b0271461024a5780639a8a059214610275578063b8a242521461027e57600080fd5b806361a02208116100e957806361a022081461019b578063671b3793146101be5780636969a25c146101c7578063729e7c6e1461021957806373cb1a111461022c57600080fd5b80631d1d4f261461011b57806322fd1818146101375780633569ed931461016157806352a9674b14610174575b600080fd5b61012460035481565b6040519081526020015b60405180910390f35b61014a610145366004610f34565b610313565b60408051921515835260208301919091520161012e565b61012461016f366004610f34565b610364565b6101247fbee7fa562a38908559e4a988e62d6c08b84ef05f2ebd5d2bb2b855dc19d19fe281565b6101ae6101a9366004610f4d565b610398565b604051901515815260200161012e565b61012460055481565b6101fa6101d5366004610f34565b600960205260009081526040902080546005909101546001600160a01b039091169082565b604080516001600160a01b03909316835260208301919091520161012e565b6101ae610227366004610f4d565b610410565b61023f61023a366004611041565b610469565b005b61012460025481565b60065461025d906001600160a01b031681565b6040516001600160a01b03909116815260200161012e565b61012460015481565b6102ad61028c366004610f34565b60086020526000908152604090208054600182015460029092015490919083565b6040805193845260208401929092529082015260600161012e565b61023f6102d63660046110cc565b61061f565b60075461025d906001600160a01b031681565b61012460045481565b610124610305366004610f34565b610884565b610124600b5481565b60008080610322600a856108a5565b600a54909150810361033a5750600093849350915050565b6001600a828154811061034f5761034f6111a5565b90600052602060002001549250925050915091565b6000600881610374600a856108a5565b61037f9060016111d1565b8152602001908152602001600020600201549050919050565b6000806103a487610364565b9050806103f85760405162461bcd60e51b815260206004820152601e60248201527f4e4f5f4556454e545f524f4f545f464f525f424c4f434b5f4e554d424552000060448201526064015b60405180910390fd5b6104058686838787610954565b979650505050505050565b600085815260086020526040812060020154806103f85760405162461bcd60e51b815260206004820152601760248201527609c9ebe8aac8a9ca8bea49e9ea8be8c9ea4be8aa09e869604b1b60448201526064016103ef565b600054610100900460ff16158080156104895750600054600160ff909116105b806104a35750303b1580156104a3575060005460ff166001145b6105065760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016103ef565b6000805460ff191660011790558015610529576000805461ff0019166101001790555b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03161561058d57336001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161461058d57600080fd5b6001849055600680546001600160a01b038089166001600160a01b031992831617909255600780549288169290911691909117905560038290556105d1838361099e565b8015610617576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b8660400135600b54146106745760405162461bcd60e51b815260206004820152601a60248201527f494e56414c49445f56414c494441544f525f5345545f4841534800000000000060448201526064016103ef565b6000600154876020013589600001358a602001358a600001358b604001358d604001358b8b6040516020016106aa9291906111e4565b604051602081830303815290604052805190602001206040516020016106d7989796959493929190611247565b60408051601f198184030181528282528051602091820120908301520160408051601f198184030181529082905260065463a850a90960e01b83529092506107a3916001600160a01b039091169063a850a9099061075b907fbee7fa562a38908559e4a988e62d6c08b84ef05f2ebd5d2bb2b855dc19d19fe290869060040161127d565b6040805180830381865afa158015610777573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061079b91906112d3565b878585610aa4565b6002546107b08189610dae565b8735600081815260086020908152604091829020838155908b01356001820155908a013560029091015581101561083357600a8054600181018255600091825260208a01357fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a8909101556002805490919061082a90611361565b90915550610867565b600a805460208a0135919061084a9060019061137a565b8154811061085a5761085a6111a5565b6000918252602090912001555b6020880135600455610879868661099e565b505050505050505050565b600a818154811061089457600080fd5b600091825260209091200154905081565b815460009081036108b85750600061094e565b82546000905b808210156109055760006108d28383610e8b565b600087815260209020909150859082015411156108f1578091506108ff565b6108fc8160016111d1565b92505b506108be565b60008211801561093157508361092e8661092060018661137a565b600091825260209091200190565b54145b1561094a5761094160018361137a565b9250505061094e565b5090505b92915050565b60008115610993578160051b8301835b8660011660051b8881528135602082185250604060002097508660011c96506020810190508181106109645750505b505050901591141690565b600381905560405181906109b890849083906020016111e4565b60408051601f198184030181529190528051602090910120600b556000805b82811015610a9b5760008585838181106109f3576109f36111a5565b905060c0020160a00135905060008111610a435760405162461bcd60e51b8152602060048201526011602482015270564f54494e475f504f5745525f5a45524f60781b60448201526064016103ef565b610a4d81846111d1565b9250858583818110610a6157610a616111a5565b905060c00201600960008481526020019081526020016000208181610a8691906113a4565b9050505080610a9490611361565b90506109d7565b50600555505050565b600354610aaf610f16565b6000805b83811015610c3357610ac6868683610ead565b15610c2b5781600003610b1a576000818152600960205260409081902081516080810190925260010160048282826020028201915b815481526020019060010190808311610afb5750505050509250610c0c565b60008181526009602052604080822081516080810190925260010160048282826020028201915b815481526020019060010190808311610b4157505060075488516020808b01516040808d01516060808f01518b51958c0151848d0151928d01519451630cbe96a560e41b81529c9d506001600160a01b039098169b63cbe96a509b50610bb89a509698509396919593949391929091600401611247565b608060405180830381865afa158015610bd5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bf99190611403565b6060880152604087015260208601528452505b600081815260096020526040902060050154610c2890836111d1565b91505b600101610ab3565b5080600003610c765760405162461bcd60e51b815260206004820152600f60248201526e4249544d41505f49535f454d50545960881b60448201526064016103ef565b60036005546002610c87919061138d565b610c91919061144f565b8111610cdb5760405162461bcd60e51b815260206004820152601960248201527824a729aaa32324a1a4a2a72a2fab27aa24a723afa827aba2a960391b60448201526064016103ef565b60065460405163ebbdac9160e01b815260009182916001600160a01b039091169063ebbdac9190610d14908b9088908e90600401611463565b6040805180830381865afa158015610d30573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d5491906114de565b91509150818015610d625750805b6108795760405162461bcd60e51b815260206004820152601d60248201527f5349474e41545552455f564552494649434154494f4e5f4641494c454400000060448201526064016103ef565b600082815260086020908152604091829020825160608101845281548082526001830154938201939093526002909101549281019290925282351480610e0057508051610dfc9060016111d1565b8235145b610e3c5760405162461bcd60e51b815260206004820152600d60248201526c0929cac82989288be8aa09e869609b1b60448201526064016103ef565b8060200151826020013511610e865760405162461bcd60e51b815260206004820152601060248201526f115354151657d0d21150d2d413d2539560821b60448201526064016103ef565b505050565b6000610e9a600284841861144f565b610ea6908484166111d1565b9392505050565b600080610ebb60088461144f565b90506000610eca600885611511565b9050848210610ede57600092505050610ea6565b6000600160ff83161b878785818110610ef957610ef96111a5565b9050013560f81c60f81b60f81c60ff161611925050509392505050565b60405180608001604052806004906020820280368337509192915050565b600060208284031215610f4657600080fd5b5035919050565b600080600080600060808688031215610f6557600080fd5b853594506020860135935060408601359250606086013567ffffffffffffffff80821115610f9257600080fd5b818801915088601f830112610fa657600080fd5b813581811115610fb557600080fd5b8960208260051b8501011115610fca57600080fd5b9699959850939650602001949392505050565b6001600160a01b0381168114610ff257600080fd5b50565b60008083601f84011261100757600080fd5b50813567ffffffffffffffff81111561101f57600080fd5b60208301915083602060c08302850101111561103a57600080fd5b9250929050565b60008060008060006080868803121561105957600080fd5b853561106481610fdd565b9450602086013561107481610fdd565b935060408601359250606086013567ffffffffffffffff81111561109757600080fd5b6110a388828901610ff5565b969995985093965092949392505050565b6000606082840312156110c657600080fd5b50919050565b6000806000806000806000610140888a0312156110e857600080fd5b6110f289896110b4565b96506111018960608a016110b4565b955061010088018981111561111557600080fd5b60c0890195503567ffffffffffffffff8082111561113257600080fd5b61113e8b838c01610ff5565b90965094506101208a013591508082111561115857600080fd5b818a0191508a601f83011261116c57600080fd5b81358181111561117b57600080fd5b8b602082850101111561118d57600080fd5b60208301945080935050505092959891949750929550565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b8082018082111561094e5761094e6111bb565b60208082528181018390526000908460408401835b8681101561123c57823561120c81610fdd565b6001600160a01b0316825260808385018584013760a0838101359083015260c092830192909101906001016111f9565b509695505050505050565b978852602088019690965260408701949094526060860192909252608085015260a084015260c083015260e08201526101000190565b82815260006020604081840152835180604085015260005b818110156112b157858101830151858201606001528201611295565b506000606082860101526060601f19601f830116850101925050509392505050565b6000604082840312156112e557600080fd5b82601f8301126112f457600080fd5b6040516040810181811067ffffffffffffffff8211171561132557634e487b7160e01b600052604160045260246000fd5b806040525080604084018581111561133c57600080fd5b845b8181101561135657805183526020928301920161133e565b509195945050505050565b600060018201611373576113736111bb565b5060010190565b8181038181111561094e5761094e6111bb565b808202811582820484141761094e5761094e6111bb565b81356113af81610fdd565b81546001600160a01b0319166001600160a01b0391909116178155602082810160005b60048110156113f2578135600182860181019190915591830191016113d2565b50505060a082013560058201555050565b6000806000806080858703121561141957600080fd5b505082516020840151604085015160609095015191969095509092509050565b634e487b7160e01b600052601260045260246000fd5b60008261145e5761145e611439565b500490565b61010081016040858337604082018460005b6004811015611494578151835260209283019290910190600101611475565b50505060c082018360005b60028110156114be57815183526020928301929091019060010161149f565b505050949350505050565b805180151581146114d957600080fd5b919050565b600080604083850312156114f157600080fd5b6114fa836114c9565b9150611508602084016114c9565b90509250929050565b60008261152057611520611439565b50069056fea2646970667358221220401d0bd0a4d45a0bbd3ef6f46479dcfce20905e1e8bd31ee1f449a3074614fb064736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101165760003560e01c806376671808116100a2578063babd4ee411610071578063babd4ee4146102c8578063d4c8e3e8146102db578063e416d677146102ee578063e9193d2b146102f7578063f896f1a51461030a57600080fd5b8063766718081461024157806395b0b0271461024a5780639a8a059214610275578063b8a242521461027e57600080fd5b806361a02208116100e957806361a022081461019b578063671b3793146101be5780636969a25c146101c7578063729e7c6e1461021957806373cb1a111461022c57600080fd5b80631d1d4f261461011b57806322fd1818146101375780633569ed931461016157806352a9674b14610174575b600080fd5b61012460035481565b6040519081526020015b60405180910390f35b61014a610145366004610f34565b610313565b60408051921515835260208301919091520161012e565b61012461016f366004610f34565b610364565b6101247fbee7fa562a38908559e4a988e62d6c08b84ef05f2ebd5d2bb2b855dc19d19fe281565b6101ae6101a9366004610f4d565b610398565b604051901515815260200161012e565b61012460055481565b6101fa6101d5366004610f34565b600960205260009081526040902080546005909101546001600160a01b039091169082565b604080516001600160a01b03909316835260208301919091520161012e565b6101ae610227366004610f4d565b610410565b61023f61023a366004611041565b610469565b005b61012460025481565b60065461025d906001600160a01b031681565b6040516001600160a01b03909116815260200161012e565b61012460015481565b6102ad61028c366004610f34565b60086020526000908152604090208054600182015460029092015490919083565b6040805193845260208401929092529082015260600161012e565b61023f6102d63660046110cc565b61061f565b60075461025d906001600160a01b031681565b61012460045481565b610124610305366004610f34565b610884565b610124600b5481565b60008080610322600a856108a5565b600a54909150810361033a5750600093849350915050565b6001600a828154811061034f5761034f6111a5565b90600052602060002001549250925050915091565b6000600881610374600a856108a5565b61037f9060016111d1565b8152602001908152602001600020600201549050919050565b6000806103a487610364565b9050806103f85760405162461bcd60e51b815260206004820152601e60248201527f4e4f5f4556454e545f524f4f545f464f525f424c4f434b5f4e554d424552000060448201526064015b60405180910390fd5b6104058686838787610954565b979650505050505050565b600085815260086020526040812060020154806103f85760405162461bcd60e51b815260206004820152601760248201527609c9ebe8aac8a9ca8bea49e9ea8be8c9ea4be8aa09e869604b1b60448201526064016103ef565b600054610100900460ff16158080156104895750600054600160ff909116105b806104a35750303b1580156104a3575060005460ff166001145b6105065760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016103ef565b6000805460ff191660011790558015610529576000805461ff0019166101001790555b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03161561058d57336001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161461058d57600080fd5b6001849055600680546001600160a01b038089166001600160a01b031992831617909255600780549288169290911691909117905560038290556105d1838361099e565b8015610617576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b8660400135600b54146106745760405162461bcd60e51b815260206004820152601a60248201527f494e56414c49445f56414c494441544f525f5345545f4841534800000000000060448201526064016103ef565b6000600154876020013589600001358a602001358a600001358b604001358d604001358b8b6040516020016106aa9291906111e4565b604051602081830303815290604052805190602001206040516020016106d7989796959493929190611247565b60408051601f198184030181528282528051602091820120908301520160408051601f198184030181529082905260065463a850a90960e01b83529092506107a3916001600160a01b039091169063a850a9099061075b907fbee7fa562a38908559e4a988e62d6c08b84ef05f2ebd5d2bb2b855dc19d19fe290869060040161127d565b6040805180830381865afa158015610777573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061079b91906112d3565b878585610aa4565b6002546107b08189610dae565b8735600081815260086020908152604091829020838155908b01356001820155908a013560029091015581101561083357600a8054600181018255600091825260208a01357fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a8909101556002805490919061082a90611361565b90915550610867565b600a805460208a0135919061084a9060019061137a565b8154811061085a5761085a6111a5565b6000918252602090912001555b6020880135600455610879868661099e565b505050505050505050565b600a818154811061089457600080fd5b600091825260209091200154905081565b815460009081036108b85750600061094e565b82546000905b808210156109055760006108d28383610e8b565b600087815260209020909150859082015411156108f1578091506108ff565b6108fc8160016111d1565b92505b506108be565b60008211801561093157508361092e8661092060018661137a565b600091825260209091200190565b54145b1561094a5761094160018361137a565b9250505061094e565b5090505b92915050565b60008115610993578160051b8301835b8660011660051b8881528135602082185250604060002097508660011c96506020810190508181106109645750505b505050901591141690565b600381905560405181906109b890849083906020016111e4565b60408051601f198184030181529190528051602090910120600b556000805b82811015610a9b5760008585838181106109f3576109f36111a5565b905060c0020160a00135905060008111610a435760405162461bcd60e51b8152602060048201526011602482015270564f54494e475f504f5745525f5a45524f60781b60448201526064016103ef565b610a4d81846111d1565b9250858583818110610a6157610a616111a5565b905060c00201600960008481526020019081526020016000208181610a8691906113a4565b9050505080610a9490611361565b90506109d7565b50600555505050565b600354610aaf610f16565b6000805b83811015610c3357610ac6868683610ead565b15610c2b5781600003610b1a576000818152600960205260409081902081516080810190925260010160048282826020028201915b815481526020019060010190808311610afb5750505050509250610c0c565b60008181526009602052604080822081516080810190925260010160048282826020028201915b815481526020019060010190808311610b4157505060075488516020808b01516040808d01516060808f01518b51958c0151848d0151928d01519451630cbe96a560e41b81529c9d506001600160a01b039098169b63cbe96a509b50610bb89a509698509396919593949391929091600401611247565b608060405180830381865afa158015610bd5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bf99190611403565b6060880152604087015260208601528452505b600081815260096020526040902060050154610c2890836111d1565b91505b600101610ab3565b5080600003610c765760405162461bcd60e51b815260206004820152600f60248201526e4249544d41505f49535f454d50545960881b60448201526064016103ef565b60036005546002610c87919061138d565b610c91919061144f565b8111610cdb5760405162461bcd60e51b815260206004820152601960248201527824a729aaa32324a1a4a2a72a2fab27aa24a723afa827aba2a960391b60448201526064016103ef565b60065460405163ebbdac9160e01b815260009182916001600160a01b039091169063ebbdac9190610d14908b9088908e90600401611463565b6040805180830381865afa158015610d30573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d5491906114de565b91509150818015610d625750805b6108795760405162461bcd60e51b815260206004820152601d60248201527f5349474e41545552455f564552494649434154494f4e5f4641494c454400000060448201526064016103ef565b600082815260086020908152604091829020825160608101845281548082526001830154938201939093526002909101549281019290925282351480610e0057508051610dfc9060016111d1565b8235145b610e3c5760405162461bcd60e51b815260206004820152600d60248201526c0929cac82989288be8aa09e869609b1b60448201526064016103ef565b8060200151826020013511610e865760405162461bcd60e51b815260206004820152601060248201526f115354151657d0d21150d2d413d2539560821b60448201526064016103ef565b505050565b6000610e9a600284841861144f565b610ea6908484166111d1565b9392505050565b600080610ebb60088461144f565b90506000610eca600885611511565b9050848210610ede57600092505050610ea6565b6000600160ff83161b878785818110610ef957610ef96111a5565b9050013560f81c60f81b60f81c60ff161611925050509392505050565b60405180608001604052806004906020820280368337509192915050565b600060208284031215610f4657600080fd5b5035919050565b600080600080600060808688031215610f6557600080fd5b853594506020860135935060408601359250606086013567ffffffffffffffff80821115610f9257600080fd5b818801915088601f830112610fa657600080fd5b813581811115610fb557600080fd5b8960208260051b8501011115610fca57600080fd5b9699959850939650602001949392505050565b6001600160a01b0381168114610ff257600080fd5b50565b60008083601f84011261100757600080fd5b50813567ffffffffffffffff81111561101f57600080fd5b60208301915083602060c08302850101111561103a57600080fd5b9250929050565b60008060008060006080868803121561105957600080fd5b853561106481610fdd565b9450602086013561107481610fdd565b935060408601359250606086013567ffffffffffffffff81111561109757600080fd5b6110a388828901610ff5565b969995985093965092949392505050565b6000606082840312156110c657600080fd5b50919050565b6000806000806000806000610140888a0312156110e857600080fd5b6110f289896110b4565b96506111018960608a016110b4565b955061010088018981111561111557600080fd5b60c0890195503567ffffffffffffffff8082111561113257600080fd5b61113e8b838c01610ff5565b90965094506101208a013591508082111561115857600080fd5b818a0191508a601f83011261116c57600080fd5b81358181111561117b57600080fd5b8b602082850101111561118d57600080fd5b60208301945080935050505092959891949750929550565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b8082018082111561094e5761094e6111bb565b60208082528181018390526000908460408401835b8681101561123c57823561120c81610fdd565b6001600160a01b0316825260808385018584013760a0838101359083015260c092830192909101906001016111f9565b509695505050505050565b978852602088019690965260408701949094526060860192909252608085015260a084015260c083015260e08201526101000190565b82815260006020604081840152835180604085015260005b818110156112b157858101830151858201606001528201611295565b506000606082860101526060601f19601f830116850101925050509392505050565b6000604082840312156112e557600080fd5b82601f8301126112f457600080fd5b6040516040810181811067ffffffffffffffff8211171561132557634e487b7160e01b600052604160045260246000fd5b806040525080604084018581111561133c57600080fd5b845b8181101561135657805183526020928301920161133e565b509195945050505050565b600060018201611373576113736111bb565b5060010190565b8181038181111561094e5761094e6111bb565b808202811582820484141761094e5761094e6111bb565b81356113af81610fdd565b81546001600160a01b0319166001600160a01b0391909116178155602082810160005b60048110156113f2578135600182860181019190915591830191016113d2565b50505060a082013560058201555050565b6000806000806080858703121561141957600080fd5b505082516020840151604085015160609095015191969095509092509050565b634e487b7160e01b600052601260045260246000fd5b60008261145e5761145e611439565b500490565b61010081016040858337604082018460005b6004811015611494578151835260209283019290910190600101611475565b50505060c082018360005b60028110156114be57815183526020928301929091019060010161149f565b505050949350505050565b805180151581146114d957600080fd5b919050565b600080604083850312156114f157600080fd5b6114fa836114c9565b9150611508602084016114c9565b90509250929050565b60008261152057611520611439565b50069056fea2646970667358221220401d0bd0a4d45a0bbd3ef6f46479dcfce20905e1e8bd31ee1f449a3074614fb064736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ExitHelperArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ExitHelper","sourceName":"contracts/bridge/ExitHelper.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"bytes","name":"returnData","type":"bytes"}],"name":"ExitProcessed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"inputs":[{"components":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"uint256","name":"leafIndex","type":"uint256"},{"internalType":"bytes","name":"unhashedLeaf","type":"bytes"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"internalType":"struct IExitHelper.BatchExitInput[]","name":"inputs","type":"tuple[]"}],"name":"batchExit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"checkpointManager","outputs":[{"internalType":"contract ICheckpointManager","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"uint256","name":"leafIndex","type":"uint256"},{"internalType":"bytes","name":"unhashedLeaf","type":"bytes"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"exit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract ICheckpointManager","name":"newCheckpointManager","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"processedExits","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50610b62806100206000396000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c806350607b351461005c578063aa209cc314610071578063bd88ea7914610084578063c0857ba0146100bc578063c4d66de8146100e7575b600080fd5b61006f61006a3660046106c9565b6100fa565b005b61006f61007f36600461070b565b610200565b6100a76100923660046107bc565b60016020526000908152604090205460ff1681565b60405190151581526020015b60405180910390f35b6002546100cf906001600160a01b031681565b6040516001600160a01b0390911681526020016100b3565b61006f6100f53660046107ed565b610240565b6002546001600160a01b031661012b5760405162461bcd60e51b815260040161012290610811565b60405180910390fd5b8060005b818110156101fa576101f284848381811061014c5761014c610848565b905060200281019061015e919061085e565b3585858481811061017157610171610848565b9050602002810190610183919061085e565b6020013586868581811061019957610199610848565b90506020028101906101ab919061085e565b6101b990604081019061087e565b8888878181106101cb576101cb610848565b90506020028101906101dd919061085e565b6101eb9060608101906108c5565b60016103d2565b60010161012f565b50505050565b6002546001600160a01b03166102285760405162461bcd60e51b815260040161012290610811565b61023886868686868660006103d2565b505050505050565b600054610100900460ff16158080156102605750600054600160ff909116105b8061027a5750303b15801561027a575060005460ff166001145b6102dd5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610122565b6000805460ff191660011790558015610300576000805461ff0019166101001790555b6001600160a01b0382161580159061032157506001600160a01b0382163b15155b61036d5760405162461bcd60e51b815260206004820152601b60248201527f4578697448656c7065723a20494e56414c49445f4144445245535300000000006044820152606401610122565b600280546001600160a01b0319166001600160a01b03841617905580156103ce576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b60008080806103e3888a018a610925565b935093509350935084156104165760008481526001602052604090205460ff16156104115750505050610674565b610480565b60008481526001602052604090205460ff16156104805760405162461bcd60e51b815260206004820152602260248201527f4578697448656c7065723a20455849545f414c52454144595f50524f43455353604482015261115160f21b6064820152608401610122565b6002546040516001600160a01b03909116906361a02208908d906104a7908d908d90610a05565b6040519081900381206001600160e01b031960e085901b1682526104d492918f908d908d90600401610a15565b602060405180830381865afa1580156104f1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105159190610a62565b61055d5760405162461bcd60e51b815260206004820152601960248201527822bc34ba2432b63832b91d1024a72b20a624a22fa82927a7a360391b6044820152606401610122565b6000848152600160208190526040808320805460ff19169092179091555181906001600160a01b0385169061059a90889088908790602401610ad4565b60408051601f198184030181529181526020820180516001600160e01b031663f43cda8b60e01b179052516105cf9190610b07565b6000604051808303816000865af19150503d806000811461060c576040519150601f19603f3d011682016040523d82523d6000602084013e610611565b606091505b509150915081610632576000868152600160205260409020805460ff191690555b811515867f8bbfa0c9bee3785c03700d2a909592286efb83fc7e7002be5764424b9842f7ec836040516106659190610b19565b60405180910390a35050505050505b50505050505050565b60008083601f84011261068f57600080fd5b50813567ffffffffffffffff8111156106a757600080fd5b6020830191508360208260051b85010111156106c257600080fd5b9250929050565b600080602083850312156106dc57600080fd5b823567ffffffffffffffff8111156106f357600080fd5b6106ff8582860161067d565b90969095509350505050565b6000806000806000806080878903121561072457600080fd5b8635955060208701359450604087013567ffffffffffffffff8082111561074a57600080fd5b818901915089601f83011261075e57600080fd5b81358181111561076d57600080fd5b8a602082850101111561077f57600080fd5b60208301965080955050606089013591508082111561079d57600080fd5b506107aa89828a0161067d565b979a9699509497509295939492505050565b6000602082840312156107ce57600080fd5b5035919050565b6001600160a01b03811681146107ea57600080fd5b50565b6000602082840312156107ff57600080fd5b813561080a816107d5565b9392505050565b6020808252601b908201527f4578697448656c7065723a204e4f545f494e495449414c495a45440000000000604082015260600190565b634e487b7160e01b600052603260045260246000fd5b60008235607e1983360301811261087457600080fd5b9190910192915050565b6000808335601e1984360301811261089557600080fd5b83018035915067ffffffffffffffff8211156108b057600080fd5b6020019150368190038213156106c257600080fd5b6000808335601e198436030181126108dc57600080fd5b83018035915067ffffffffffffffff8211156108f757600080fd5b6020019150600581901b36038213156106c257600080fd5b634e487b7160e01b600052604160045260246000fd5b6000806000806080858703121561093b57600080fd5b84359350602085013561094d816107d5565b9250604085013561095d816107d5565b9150606085013567ffffffffffffffff8082111561097a57600080fd5b818701915087601f83011261098e57600080fd5b8135818111156109a0576109a061090f565b604051601f8201601f19908116603f011681019083821181831017156109c8576109c861090f565b816040528281528a60208487010111156109e157600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b8183823760009101908152919050565b85815284602082015283604082015260806060820152816080820152600060018060fb1b03831115610a4657600080fd5b8260051b808560a08501379190910160a0019695505050505050565b600060208284031215610a7457600080fd5b8151801515811461080a57600080fd5b60005b83811015610a9f578181015183820152602001610a87565b50506000910152565b60008151808452610ac0816020860160208601610a84565b601f01601f19169290920160200192915050565b8381526001600160a01b0383166020820152606060408201819052600090610afe90830184610aa8565b95945050505050565b60008251610874818460208701610a84565b60208152600061080a6020830184610aa856fea2646970667358221220a81301a21e92e84e3257b7e6ce1345432b2cd21d5eed2e5c11ab945887f9aaf164736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100575760003560e01c806350607b351461005c578063aa209cc314610071578063bd88ea7914610084578063c0857ba0146100bc578063c4d66de8146100e7575b600080fd5b61006f61006a3660046106c9565b6100fa565b005b61006f61007f36600461070b565b610200565b6100a76100923660046107bc565b60016020526000908152604090205460ff1681565b60405190151581526020015b60405180910390f35b6002546100cf906001600160a01b031681565b6040516001600160a01b0390911681526020016100b3565b61006f6100f53660046107ed565b610240565b6002546001600160a01b031661012b5760405162461bcd60e51b815260040161012290610811565b60405180910390fd5b8060005b818110156101fa576101f284848381811061014c5761014c610848565b905060200281019061015e919061085e565b3585858481811061017157610171610848565b9050602002810190610183919061085e565b6020013586868581811061019957610199610848565b90506020028101906101ab919061085e565b6101b990604081019061087e565b8888878181106101cb576101cb610848565b90506020028101906101dd919061085e565b6101eb9060608101906108c5565b60016103d2565b60010161012f565b50505050565b6002546001600160a01b03166102285760405162461bcd60e51b815260040161012290610811565b61023886868686868660006103d2565b505050505050565b600054610100900460ff16158080156102605750600054600160ff909116105b8061027a5750303b15801561027a575060005460ff166001145b6102dd5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610122565b6000805460ff191660011790558015610300576000805461ff0019166101001790555b6001600160a01b0382161580159061032157506001600160a01b0382163b15155b61036d5760405162461bcd60e51b815260206004820152601b60248201527f4578697448656c7065723a20494e56414c49445f4144445245535300000000006044820152606401610122565b600280546001600160a01b0319166001600160a01b03841617905580156103ce576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b60008080806103e3888a018a610925565b935093509350935084156104165760008481526001602052604090205460ff16156104115750505050610674565b610480565b60008481526001602052604090205460ff16156104805760405162461bcd60e51b815260206004820152602260248201527f4578697448656c7065723a20455849545f414c52454144595f50524f43455353604482015261115160f21b6064820152608401610122565b6002546040516001600160a01b03909116906361a02208908d906104a7908d908d90610a05565b6040519081900381206001600160e01b031960e085901b1682526104d492918f908d908d90600401610a15565b602060405180830381865afa1580156104f1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105159190610a62565b61055d5760405162461bcd60e51b815260206004820152601960248201527822bc34ba2432b63832b91d1024a72b20a624a22fa82927a7a360391b6044820152606401610122565b6000848152600160208190526040808320805460ff19169092179091555181906001600160a01b0385169061059a90889088908790602401610ad4565b60408051601f198184030181529181526020820180516001600160e01b031663f43cda8b60e01b179052516105cf9190610b07565b6000604051808303816000865af19150503d806000811461060c576040519150601f19603f3d011682016040523d82523d6000602084013e610611565b606091505b509150915081610632576000868152600160205260409020805460ff191690555b811515867f8bbfa0c9bee3785c03700d2a909592286efb83fc7e7002be5764424b9842f7ec836040516106659190610b19565b60405180910390a35050505050505b50505050505050565b60008083601f84011261068f57600080fd5b50813567ffffffffffffffff8111156106a757600080fd5b6020830191508360208260051b85010111156106c257600080fd5b9250929050565b600080602083850312156106dc57600080fd5b823567ffffffffffffffff8111156106f357600080fd5b6106ff8582860161067d565b90969095509350505050565b6000806000806000806080878903121561072457600080fd5b8635955060208701359450604087013567ffffffffffffffff8082111561074a57600080fd5b818901915089601f83011261075e57600080fd5b81358181111561076d57600080fd5b8a602082850101111561077f57600080fd5b60208301965080955050606089013591508082111561079d57600080fd5b506107aa89828a0161067d565b979a9699509497509295939492505050565b6000602082840312156107ce57600080fd5b5035919050565b6001600160a01b03811681146107ea57600080fd5b50565b6000602082840312156107ff57600080fd5b813561080a816107d5565b9392505050565b6020808252601b908201527f4578697448656c7065723a204e4f545f494e495449414c495a45440000000000604082015260600190565b634e487b7160e01b600052603260045260246000fd5b60008235607e1983360301811261087457600080fd5b9190910192915050565b6000808335601e1984360301811261089557600080fd5b83018035915067ffffffffffffffff8211156108b057600080fd5b6020019150368190038213156106c257600080fd5b6000808335601e198436030181126108dc57600080fd5b83018035915067ffffffffffffffff8211156108f757600080fd5b6020019150600581901b36038213156106c257600080fd5b634e487b7160e01b600052604160045260246000fd5b6000806000806080858703121561093b57600080fd5b84359350602085013561094d816107d5565b9250604085013561095d816107d5565b9150606085013567ffffffffffffffff8082111561097a57600080fd5b818701915087601f83011261098e57600080fd5b8135818111156109a0576109a061090f565b604051601f8201601f19908116603f011681019083821181831017156109c8576109c861090f565b816040528281528a60208487010111156109e157600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b8183823760009101908152919050565b85815284602082015283604082015260806060820152816080820152600060018060fb1b03831115610a4657600080fd5b8260051b808560a08501379190910160a0019695505050505050565b600060208284031215610a7457600080fd5b8151801515811461080a57600080fd5b60005b83811015610a9f578181015183820152602001610a87565b50506000910152565b60008151808452610ac0816020860160208601610a84565b601f01601f19169290920160200192915050565b8381526001600160a01b0383166020820152606060408201819052600090610afe90830184610aa8565b95945050505050565b60008251610874818460208701610a84565b60208152600061080a6020830184610aa856fea2646970667358221220a81301a21e92e84e3257b7e6ce1345432b2cd21d5eed2e5c11ab945887f9aaf164736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var StateSenderArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"StateSender","sourceName":"contracts/bridge/StateSender.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"bytes","name":"data","type":"bytes"}],"name":"StateSynced","type":"event"},{"inputs":[],"name":"MAX_LENGTH","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"counter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"syncState","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50610297806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806316f198311461004657806361bc221a1461005b578063a6f9885c14610076575b600080fd5b61005961005436600461017a565b61007f565b005b61006460005481565b60405190815260200160405180910390f35b61006461080081565b6001600160a01b0383166100cd5760405162461bcd60e51b815260206004820152601060248201526f24a72b20a624a22fa922a1a2a4ab22a960811b60448201526064015b60405180910390fd5b6108008111156101145760405162461bcd60e51b815260206004820152601260248201527108ab0868a8a88a6be9a82b0be988a9c8ea8960731b60448201526064016100c4565b826001600160a01b0316336001600160a01b031660008081546101369061020b565b9190508190557fd1d7f6609674cc5871fdb4b0bcd4f0a214118411de9e38983866514f22659165858560405161016d929190610232565b60405180910390a4505050565b60008060006040848603121561018f57600080fd5b83356001600160a01b03811681146101a657600080fd5b9250602084013567ffffffffffffffff808211156101c357600080fd5b818601915086601f8301126101d757600080fd5b8135818111156101e657600080fd5b8760208285010111156101f857600080fd5b6020830194508093505050509250925092565b60006001820161022b57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea2646970667358221220603ee2657ab15fbda1c3cc78556974baadb025ef982221e498aaa929a6c1f63d64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100415760003560e01c806316f198311461004657806361bc221a1461005b578063a6f9885c14610076575b600080fd5b61005961005436600461017a565b61007f565b005b61006460005481565b60405190815260200160405180910390f35b61006461080081565b6001600160a01b0383166100cd5760405162461bcd60e51b815260206004820152601060248201526f24a72b20a624a22fa922a1a2a4ab22a960811b60448201526064015b60405180910390fd5b6108008111156101145760405162461bcd60e51b815260206004820152601260248201527108ab0868a8a88a6be9a82b0be988a9c8ea8960731b60448201526064016100c4565b826001600160a01b0316336001600160a01b031660008081546101369061020b565b9190508190557fd1d7f6609674cc5871fdb4b0bcd4f0a214118411de9e38983866514f22659165858560405161016d929190610232565b60405180910390a4505050565b60008060006040848603121561018f57600080fd5b83356001600160a01b03811681146101a657600080fd5b9250602084013567ffffffffffffffff808211156101c357600080fd5b818601915086601f8301126101d757600080fd5b8135818111156101e657600080fd5b8760208285010111156101f857600080fd5b6020830194508093505050509250925092565b60006001820161022b57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208152816020820152818360408301376000818301604090810191909152601f909201601f1916010191905056fea2646970667358221220603ee2657ab15fbda1c3cc78556974baadb025ef982221e498aaa929a6c1f63d64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` var MockERC20Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"MockERC20","sourceName":"contracts/mocks/MockERC20.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PAUSER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burnFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getRoleMember","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleMemberCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x60806040523480156200001157600080fd5b50604080518082018252600480825263151154d560e21b60208084018290528451808601909552918452908301529081816005620000508382620002ca565b5060066200005f8282620002ca565b50506007805460ff191690555062000079600033620000d9565b620000a57f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a633620000d9565b620000d17f65d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862a33620000d9565b505062000396565b620000e58282620000e9565b5050565b620000f5828262000114565b60008281526001602052604090206200010f9082620001b4565b505050565b6000828152602081815260408083206001600160a01b038516845290915290205460ff16620000e5576000828152602081815260408083206001600160a01b03851684529091529020805460ff19166001179055620001703390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000620001cb836001600160a01b038416620001d4565b90505b92915050565b60008181526001830160205260408120546200021d57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155620001ce565b506000620001ce565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200025157607f821691505b6020821081036200027257634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200010f57600081815260208120601f850160051c81016020861015620002a15750805b601f850160051c820191505b81811015620002c257828155600101620002ad565b505050505050565b81516001600160401b03811115620002e657620002e662000226565b620002fe81620002f784546200023c565b8462000278565b602080601f8311600181146200033657600084156200031d5750858301515b600019600386901b1c1916600185901b178555620002c2565b600085815260208120601f198616915b82811015620003675788860151825594840194600190910190840162000346565b5085821015620003865787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6117fa80620003a66000396000f3fe608060405234801561001057600080fd5b50600436106101845760003560e01c806370a08231116100d9578063a457c2d711610087578063a457c2d714610336578063a9059cbb14610349578063ca15c8731461035c578063d53913931461036f578063d547741f14610396578063dd62ed3e146103a9578063e63ab1e9146103bc57600080fd5b806370a08231146102a457806379cc6790146102cd5780638456cb59146102e05780639010d07c146102e857806391d148541461031357806395d89b4114610326578063a217fddf1461032e57600080fd5b8063313ce56711610136578063313ce5671461023657806336568abe1461024557806339509351146102585780633f4ba83a1461026b57806340c10f191461027357806342966c68146102865780635c975abb1461029957600080fd5b806301ffc9a71461018957806306fdde03146101b1578063095ea7b3146101c657806318160ddd146101d957806323b872dd146101eb578063248a9ca3146101fe5780632f2ff15d14610221575b600080fd5b61019c610197366004611460565b6103d1565b60405190151581526020015b60405180910390f35b6101b96103fc565b6040516101a891906114ae565b61019c6101d43660046114fd565b61048e565b6004545b6040519081526020016101a8565b61019c6101f9366004611527565b6104a6565b6101dd61020c366004611563565b60009081526020819052604090206001015490565b61023461022f36600461157c565b6104ca565b005b604051601281526020016101a8565b61023461025336600461157c565b6104f4565b61019c6102663660046114fd565b610577565b610234610599565b6102346102813660046114fd565b610617565b610234610294366004611563565b6106a4565b60075460ff1661019c565b6101dd6102b23660046115a8565b6001600160a01b031660009081526002602052604090205490565b6102346102db3660046114fd565b6106b1565b6102346106c6565b6102fb6102f63660046115c3565b610740565b6040516001600160a01b0390911681526020016101a8565b61019c61032136600461157c565b61075f565b6101b9610788565b6101dd600081565b61019c6103443660046114fd565b610797565b61019c6103573660046114fd565b610812565b6101dd61036a366004611563565b610820565b6101dd7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b6102346103a436600461157c565b610837565b6101dd6103b73660046115e5565b61085c565b6101dd60008051602061178583398151915281565b60006001600160e01b03198216635a05180f60e01b14806103f657506103f682610887565b92915050565b60606005805461040b9061160f565b80601f01602080910402602001604051908101604052809291908181526020018280546104379061160f565b80156104845780601f1061045957610100808354040283529160200191610484565b820191906000526020600020905b81548152906001019060200180831161046757829003601f168201915b5050505050905090565b60003361049c8185856108bc565b5060019392505050565b6000336104b48582856109e0565b6104bf858585610a5a565b506001949350505050565b6000828152602081905260409020600101546104e581610bfe565b6104ef8383610c08565b505050565b6001600160a01b03811633146105695760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b60648201526084015b60405180910390fd5b6105738282610c2a565b5050565b60003361049c81858561058a838361085c565b610594919061165f565b6108bc565b6105b16000805160206117858339815191523361075f565b61060d5760405162461bcd60e51b8152602060048201526039602482015260008051602061176583398151915260448201527876652070617573657220726f6c6520746f20756e706175736560381b6064820152608401610560565b610615610c4c565b565b6106417f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a63361075f565b61069a5760405162461bcd60e51b815260206004820152603660248201526000805160206117658339815191526044820152751d99481b5a5b9d195c881c9bdb19481d1bc81b5a5b9d60521b6064820152608401610560565b6105738282610c9e565b6106ae3382610d59565b50565b6106bc8233836109e0565b6105738282610d59565b6106de6000805160206117858339815191523361075f565b6107385760405162461bcd60e51b8152602060048201526037602482015260008051602061176583398151915260448201527676652070617573657220726f6c6520746f20706175736560481b6064820152608401610560565b610615610e87565b60008281526001602052604081206107589083610ec4565b9392505050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b60606006805461040b9061160f565b600033816107a5828661085c565b9050838110156108055760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610560565b6104bf82868684036108bc565b60003361049c818585610a5a565b60008181526001602052604081206103f690610ed0565b60008281526020819052604090206001015461085281610bfe565b6104ef8383610c2a565b6001600160a01b03918216600090815260036020908152604080832093909416825291909152205490565b60006001600160e01b03198216637965db0b60e01b14806103f657506301ffc9a760e01b6001600160e01b03198316146103f6565b6001600160a01b03831661091e5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610560565b6001600160a01b03821661097f5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610560565b6001600160a01b0383811660008181526003602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b60006109ec848461085c565b90506000198114610a545781811015610a475760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610560565b610a5484848484036108bc565b50505050565b6001600160a01b038316610abe5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610560565b6001600160a01b038216610b205760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610560565b610b2b838383610eda565b6001600160a01b03831660009081526002602052604090205481811015610ba35760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610560565b6001600160a01b0380851660008181526002602052604080822086860390559286168082529083902080548601905591516000805160206117a583398151915290610bf19086815260200190565b60405180910390a3610a54565b6106ae8133610ee5565b610c128282610f3e565b60008281526001602052604090206104ef9082610fc2565b610c348282610fd7565b60008281526001602052604090206104ef908261103c565b610c54611051565b6007805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6001600160a01b038216610cf45760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610560565b610d0060008383610eda565b8060046000828254610d12919061165f565b90915550506001600160a01b0382166000818152600260209081526040808320805486019055518481526000805160206117a5833981519152910160405180910390a35050565b6001600160a01b038216610db95760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610560565b610dc582600083610eda565b6001600160a01b03821660009081526002602052604090205481811015610e395760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610560565b6001600160a01b03831660008181526002602090815260408083208686039055600480548790039055518581529192916000805160206117a5833981519152910160405180910390a3505050565b610e8f61109a565b6007805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610c813390565b600061075883836110e0565b60006103f6825490565b6104ef83838361110a565b610eef828261075f565b61057357610efc81611170565b610f07836020611182565b604051602001610f18929190611672565b60408051601f198184030181529082905262461bcd60e51b8252610560916004016114ae565b610f48828261075f565b610573576000828152602081815260408083206001600160a01b03851684529091529020805460ff19166001179055610f7e3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000610758836001600160a01b03841661131e565b610fe1828261075f565b15610573576000828152602081815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6000610758836001600160a01b03841661136d565b60075460ff166106155760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610560565b60075460ff16156106155760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610560565b60008260000182815481106110f7576110f76116e1565b9060005260206000200154905092915050565b60075460ff16156104ef5760405162461bcd60e51b815260206004820152602a60248201527f45524332305061757361626c653a20746f6b656e207472616e736665722077686044820152691a5b19481c185d5cd95960b21b6064820152608401610560565b60606103f66001600160a01b03831660145b606060006111918360026116f7565b61119c90600261165f565b67ffffffffffffffff8111156111b4576111b461170e565b6040519080825280601f01601f1916602001820160405280156111de576020820181803683370190505b509050600360fc1b816000815181106111f9576111f96116e1565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110611228576112286116e1565b60200101906001600160f81b031916908160001a905350600061124c8460026116f7565b61125790600161165f565b90505b60018111156112cf576f181899199a1a9b1b9c1cb0b131b232b360811b85600f166010811061128b5761128b6116e1565b1a60f81b8282815181106112a1576112a16116e1565b60200101906001600160f81b031916908160001a90535060049490941c936112c881611724565b905061125a565b5083156107585760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610560565b6000818152600183016020526040812054611365575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556103f6565b5060006103f6565b6000818152600183016020526040812054801561145657600061139160018361173b565b85549091506000906113a59060019061173b565b905081811461140a5760008660000182815481106113c5576113c56116e1565b90600052602060002001549050808760000184815481106113e8576113e86116e1565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061141b5761141b61174e565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506103f6565b60009150506103f6565b60006020828403121561147257600080fd5b81356001600160e01b03198116811461075857600080fd5b60005b838110156114a557818101518382015260200161148d565b50506000910152565b60208152600082518060208401526114cd81604085016020870161148a565b601f01601f19169190910160400192915050565b80356001600160a01b03811681146114f857600080fd5b919050565b6000806040838503121561151057600080fd5b611519836114e1565b946020939093013593505050565b60008060006060848603121561153c57600080fd5b611545846114e1565b9250611553602085016114e1565b9150604084013590509250925092565b60006020828403121561157557600080fd5b5035919050565b6000806040838503121561158f57600080fd5b8235915061159f602084016114e1565b90509250929050565b6000602082840312156115ba57600080fd5b610758826114e1565b600080604083850312156115d657600080fd5b50508035926020909101359150565b600080604083850312156115f857600080fd5b611601836114e1565b915061159f602084016114e1565b600181811c9082168061162357607f821691505b60208210810361164357634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b808201808211156103f6576103f6611649565b76020b1b1b2b9b9a1b7b73a3937b61d1030b1b1b7bab73a1604d1b8152600083516116a481601785016020880161148a565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516116d581602884016020880161148a565b01602801949350505050565b634e487b7160e01b600052603260045260246000fd5b80820281158282048414176103f6576103f6611649565b634e487b7160e01b600052604160045260246000fd5b60008161173357611733611649565b506000190190565b818103818111156103f6576103f6611649565b634e487b7160e01b600052603160045260246000fdfe45524332305072657365744d696e7465725061757365723a206d75737420686165d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862addf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220d5a22b9391b8f37e5b49e43cc1eabfcea8be6d7b5aa0a84dc5daa1b7a05730f364736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101845760003560e01c806370a08231116100d9578063a457c2d711610087578063a457c2d714610336578063a9059cbb14610349578063ca15c8731461035c578063d53913931461036f578063d547741f14610396578063dd62ed3e146103a9578063e63ab1e9146103bc57600080fd5b806370a08231146102a457806379cc6790146102cd5780638456cb59146102e05780639010d07c146102e857806391d148541461031357806395d89b4114610326578063a217fddf1461032e57600080fd5b8063313ce56711610136578063313ce5671461023657806336568abe1461024557806339509351146102585780633f4ba83a1461026b57806340c10f191461027357806342966c68146102865780635c975abb1461029957600080fd5b806301ffc9a71461018957806306fdde03146101b1578063095ea7b3146101c657806318160ddd146101d957806323b872dd146101eb578063248a9ca3146101fe5780632f2ff15d14610221575b600080fd5b61019c610197366004611460565b6103d1565b60405190151581526020015b60405180910390f35b6101b96103fc565b6040516101a891906114ae565b61019c6101d43660046114fd565b61048e565b6004545b6040519081526020016101a8565b61019c6101f9366004611527565b6104a6565b6101dd61020c366004611563565b60009081526020819052604090206001015490565b61023461022f36600461157c565b6104ca565b005b604051601281526020016101a8565b61023461025336600461157c565b6104f4565b61019c6102663660046114fd565b610577565b610234610599565b6102346102813660046114fd565b610617565b610234610294366004611563565b6106a4565b60075460ff1661019c565b6101dd6102b23660046115a8565b6001600160a01b031660009081526002602052604090205490565b6102346102db3660046114fd565b6106b1565b6102346106c6565b6102fb6102f63660046115c3565b610740565b6040516001600160a01b0390911681526020016101a8565b61019c61032136600461157c565b61075f565b6101b9610788565b6101dd600081565b61019c6103443660046114fd565b610797565b61019c6103573660046114fd565b610812565b6101dd61036a366004611563565b610820565b6101dd7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b6102346103a436600461157c565b610837565b6101dd6103b73660046115e5565b61085c565b6101dd60008051602061178583398151915281565b60006001600160e01b03198216635a05180f60e01b14806103f657506103f682610887565b92915050565b60606005805461040b9061160f565b80601f01602080910402602001604051908101604052809291908181526020018280546104379061160f565b80156104845780601f1061045957610100808354040283529160200191610484565b820191906000526020600020905b81548152906001019060200180831161046757829003601f168201915b5050505050905090565b60003361049c8185856108bc565b5060019392505050565b6000336104b48582856109e0565b6104bf858585610a5a565b506001949350505050565b6000828152602081905260409020600101546104e581610bfe565b6104ef8383610c08565b505050565b6001600160a01b03811633146105695760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b60648201526084015b60405180910390fd5b6105738282610c2a565b5050565b60003361049c81858561058a838361085c565b610594919061165f565b6108bc565b6105b16000805160206117858339815191523361075f565b61060d5760405162461bcd60e51b8152602060048201526039602482015260008051602061176583398151915260448201527876652070617573657220726f6c6520746f20756e706175736560381b6064820152608401610560565b610615610c4c565b565b6106417f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a63361075f565b61069a5760405162461bcd60e51b815260206004820152603660248201526000805160206117658339815191526044820152751d99481b5a5b9d195c881c9bdb19481d1bc81b5a5b9d60521b6064820152608401610560565b6105738282610c9e565b6106ae3382610d59565b50565b6106bc8233836109e0565b6105738282610d59565b6106de6000805160206117858339815191523361075f565b6107385760405162461bcd60e51b8152602060048201526037602482015260008051602061176583398151915260448201527676652070617573657220726f6c6520746f20706175736560481b6064820152608401610560565b610615610e87565b60008281526001602052604081206107589083610ec4565b9392505050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b60606006805461040b9061160f565b600033816107a5828661085c565b9050838110156108055760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610560565b6104bf82868684036108bc565b60003361049c818585610a5a565b60008181526001602052604081206103f690610ed0565b60008281526020819052604090206001015461085281610bfe565b6104ef8383610c2a565b6001600160a01b03918216600090815260036020908152604080832093909416825291909152205490565b60006001600160e01b03198216637965db0b60e01b14806103f657506301ffc9a760e01b6001600160e01b03198316146103f6565b6001600160a01b03831661091e5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610560565b6001600160a01b03821661097f5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610560565b6001600160a01b0383811660008181526003602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b60006109ec848461085c565b90506000198114610a545781811015610a475760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610560565b610a5484848484036108bc565b50505050565b6001600160a01b038316610abe5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610560565b6001600160a01b038216610b205760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610560565b610b2b838383610eda565b6001600160a01b03831660009081526002602052604090205481811015610ba35760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610560565b6001600160a01b0380851660008181526002602052604080822086860390559286168082529083902080548601905591516000805160206117a583398151915290610bf19086815260200190565b60405180910390a3610a54565b6106ae8133610ee5565b610c128282610f3e565b60008281526001602052604090206104ef9082610fc2565b610c348282610fd7565b60008281526001602052604090206104ef908261103c565b610c54611051565b6007805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6001600160a01b038216610cf45760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610560565b610d0060008383610eda565b8060046000828254610d12919061165f565b90915550506001600160a01b0382166000818152600260209081526040808320805486019055518481526000805160206117a5833981519152910160405180910390a35050565b6001600160a01b038216610db95760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610560565b610dc582600083610eda565b6001600160a01b03821660009081526002602052604090205481811015610e395760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610560565b6001600160a01b03831660008181526002602090815260408083208686039055600480548790039055518581529192916000805160206117a5833981519152910160405180910390a3505050565b610e8f61109a565b6007805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610c813390565b600061075883836110e0565b60006103f6825490565b6104ef83838361110a565b610eef828261075f565b61057357610efc81611170565b610f07836020611182565b604051602001610f18929190611672565b60408051601f198184030181529082905262461bcd60e51b8252610560916004016114ae565b610f48828261075f565b610573576000828152602081815260408083206001600160a01b03851684529091529020805460ff19166001179055610f7e3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000610758836001600160a01b03841661131e565b610fe1828261075f565b15610573576000828152602081815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6000610758836001600160a01b03841661136d565b60075460ff166106155760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610560565b60075460ff16156106155760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610560565b60008260000182815481106110f7576110f76116e1565b9060005260206000200154905092915050565b60075460ff16156104ef5760405162461bcd60e51b815260206004820152602a60248201527f45524332305061757361626c653a20746f6b656e207472616e736665722077686044820152691a5b19481c185d5cd95960b21b6064820152608401610560565b60606103f66001600160a01b03831660145b606060006111918360026116f7565b61119c90600261165f565b67ffffffffffffffff8111156111b4576111b461170e565b6040519080825280601f01601f1916602001820160405280156111de576020820181803683370190505b509050600360fc1b816000815181106111f9576111f96116e1565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110611228576112286116e1565b60200101906001600160f81b031916908160001a905350600061124c8460026116f7565b61125790600161165f565b90505b60018111156112cf576f181899199a1a9b1b9c1cb0b131b232b360811b85600f166010811061128b5761128b6116e1565b1a60f81b8282815181106112a1576112a16116e1565b60200101906001600160f81b031916908160001a90535060049490941c936112c881611724565b905061125a565b5083156107585760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610560565b6000818152600183016020526040812054611365575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556103f6565b5060006103f6565b6000818152600183016020526040812054801561145657600061139160018361173b565b85549091506000906113a59060019061173b565b905081811461140a5760008660000182815481106113c5576113c56116e1565b90600052602060002001549050808760000184815481106113e8576113e86116e1565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061141b5761141b61174e565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506103f6565b60009150506103f6565b60006020828403121561147257600080fd5b81356001600160e01b03198116811461075857600080fd5b60005b838110156114a557818101518382015260200161148d565b50506000910152565b60208152600082518060208401526114cd81604085016020870161148a565b601f01601f19169190910160400192915050565b80356001600160a01b03811681146114f857600080fd5b919050565b6000806040838503121561151057600080fd5b611519836114e1565b946020939093013593505050565b60008060006060848603121561153c57600080fd5b611545846114e1565b9250611553602085016114e1565b9150604084013590509250925092565b60006020828403121561157557600080fd5b5035919050565b6000806040838503121561158f57600080fd5b8235915061159f602084016114e1565b90509250929050565b6000602082840312156115ba57600080fd5b610758826114e1565b600080604083850312156115d657600080fd5b50508035926020909101359150565b600080604083850312156115f857600080fd5b611601836114e1565b915061159f602084016114e1565b600181811c9082168061162357607f821691505b60208210810361164357634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b808201808211156103f6576103f6611649565b76020b1b1b2b9b9a1b7b73a3937b61d1030b1b1b7bab73a1604d1b8152600083516116a481601785016020880161148a565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516116d581602884016020880161148a565b01602801949350505050565b634e487b7160e01b600052603260045260246000fd5b80820281158282048414176103f6576103f6611649565b634e487b7160e01b600052604160045260246000fd5b60008161173357611733611649565b506000190190565b818103818111156103f6576103f6611649565b634e487b7160e01b600052603160045260246000fdfe45524332305072657365744d696e7465725061757365723a206d75737420686165d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862addf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220d5a22b9391b8f37e5b49e43cc1eabfcea8be6d7b5aa0a84dc5daa1b7a05730f364736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RootERC20PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootERC20Predicate","sourceName":"contracts/root/RootERC20Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"TokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newChildERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"address","name":"newNativeTokenRoot","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"nativeTokenRoot","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506113f5806100206000396000f3fe608060405234801561001057600080fd5b50600436106100ca5760003560e01c8063cb10f94c1161007c578063cb10f94c146101ab578063d41f1771146101c4578063d57184e4146101eb578063f213159c146101fe578063f43cda8b14610211578063f4a120f714610224578063f64512551461023757600080fd5b80631459457a146100cf57806347e7ef24146100e45780636a00c1d7146100f75780637efab4f51461012757806395c7041c14610150578063b176806514610163578063b68ad1e414610198575b600080fd5b6100e26100dd366004610f79565b61025e565b005b6100e26100f2366004610fea565b6104dc565b60055461010a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61010a610135366004611016565b6004602052600090815260409020546001600160a01b031681565b60015461010a906001600160a01b031681565b61018a7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60405190815260200161011e565b60035461010a906001600160a01b031681565b60005461010a906201000090046001600160a01b031681565b61018a7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60025461010a906001600160a01b031681565b6100e261020c36600461103a565b6104eb565b6100e261021f36600461107b565b6104fb565b61010a610232366004611016565b610682565b61018a7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b600054610100900460ff161580801561027e5750600054600160ff909116105b806102985750303b158015610298575060005460ff166001145b6103005760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805460ff191660011790558015610323576000805461ff0019166101001790555b6001600160a01b0386161580159061034357506001600160a01b03851615155b801561035757506001600160a01b03841615155b801561036b57506001600160a01b03831615155b6103c65760405162461bcd60e51b815260206004820152602660248201527f526f6f7445524332305072656469636174653a204241445f494e495449414c496044820152652d20aa24a7a760d11b60648201526084016102f7565b6000805462010000600160b01b031916620100006001600160a01b038981169190910291909117909155600180546001600160a01b0319908116888416179091556002805482168784161790556003805490911685831617905582161561048e57600580546001600160a01b03199081166001600160a01b038581169182178455600091825260046020526040808320805461101095168517905593549351929316917f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e6179190a35b80156104d4576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b6104e7823383610a43565b5050565b6104f6838383610a43565b505050565b6001546001600160a01b031633146105615760405162461bcd60e51b8152602060048201526024808201527f526f6f7445524332305072656469636174653a204f4e4c595f455849545f4845604482015263262822a960e11b60648201526084016102f7565b6002546001600160a01b038481169116146105cf5760405162461bcd60e51b815260206004820152602860248201527f526f6f7445524332305072656469636174653a204f4e4c595f4348494c445f50604482015267524544494341544560c01b60648201526084016102f7565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696105fe602060008486611104565b6106079161112e565b036106265761062161061c8260208186611104565b610bba565b61067c565b60405162461bcd60e51b815260206004820152602560248201527f526f6f7445524332305072656469636174653a20494e56414c49445f5349474e604482015264415455524560d81b60648201526084016102f7565b50505050565b60006001600160a01b0382166106e45760405162461bcd60e51b815260206004820152602160248201527f526f6f7445524332305072656469636174653a20494e56414c49445f544f4b456044820152602760f91b60648201526084016102f7565b6001600160a01b0382811660009081526004602052604090205416156107575760405162461bcd60e51b815260206004820152602260248201527f526f6f7445524332305072656469636174653a20414c52454144595f4d415050604482015261115160f21b60648201526084016102f7565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261080592911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03858116600081815260046020819052604080832080546001600160a01b031916878716179055825481516306fdde0360e01b81529151969750620100009004909416946316f198319488947f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad948c9491936306fdde039380840193908290030181865afa1580156108a2573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526108ca9190810190611187565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610908573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526109309190810190611187565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa15801561096e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109929190611229565b6040516020016109a6959493929190611278565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016109d29291906112ca565b600060405180830381600087803b1580156109ec57600080fd5b505af1158015610a00573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a39392505050565b6001600160a01b038084166000908152600460205260409020541680610a6f57610a6c84610682565b90505b6001600160a01b038116610a8557610a856112ee565b610a9a6001600160a01b038516333085610c72565b600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f1983193610b2b9391169160c4016112ca565b600060405180830381600087803b158015610b4557600080fd5b505af1158015610b59573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f8be9001bb612c7123a1861dc0d9d94e683261f6cbbd7c7438b708975bc4908a33386604051610bac929190611304565b60405180910390a450505050565b6000808080610bcb8587018761131d565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610bfe57610bfe6112ee565b610c126001600160a01b0386168484610cdd565b826001600160a01b0316816001600160a01b0316866001600160a01b03167f9c4f744b2e971d7058a9d8f43977e0e17bf7d57a48659f0e18541b7ee3d022e48786604051610c61929190611304565b60405180910390a450505050505050565b6040516001600160a01b038085166024830152831660448201526064810182905261067c9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610cfc565b6104f68363a9059cbb60e01b8484604051602401610ca6929190611304565b6000610d51826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610dd19092919063ffffffff16565b9050805160001480610d72575080806020019051810190610d72919061136e565b6104f65760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016102f7565b6060610de08484600085610de8565b949350505050565b606082471015610e495760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016102f7565b600080866001600160a01b03168587604051610e659190611390565b60006040518083038185875af1925050503d8060008114610ea2576040519150601f19603f3d011682016040523d82523d6000602084013e610ea7565b606091505b5091509150610eb887838387610ec3565b979650505050505050565b60608315610f32578251600003610f2b576001600160a01b0385163b610f2b5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016102f7565b5081610de0565b610de08383815115610f475781518083602001fd5b8060405162461bcd60e51b81526004016102f791906113ac565b6001600160a01b0381168114610f7657600080fd5b50565b600080600080600060a08688031215610f9157600080fd5b8535610f9c81610f61565b94506020860135610fac81610f61565b93506040860135610fbc81610f61565b92506060860135610fcc81610f61565b91506080860135610fdc81610f61565b809150509295509295909350565b60008060408385031215610ffd57600080fd5b823561100881610f61565b946020939093013593505050565b60006020828403121561102857600080fd5b813561103381610f61565b9392505050565b60008060006060848603121561104f57600080fd5b833561105a81610f61565b9250602084013561106a81610f61565b929592945050506040919091013590565b6000806000806060858703121561109157600080fd5b8435935060208501356110a381610f61565b9250604085013567ffffffffffffffff808211156110c057600080fd5b818701915087601f8301126110d457600080fd5b8135818111156110e357600080fd5b8860208285010111156110f557600080fd5b95989497505060200194505050565b6000808585111561111457600080fd5b8386111561112157600080fd5b5050820193919092039150565b8035602083101561114757600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561117e578181015183820152602001611166565b50506000910152565b60006020828403121561119957600080fd5b815167ffffffffffffffff808211156111b157600080fd5b818401915084601f8301126111c557600080fd5b8151818111156111d7576111d761114d565b604051601f8201601f19908116603f011681019083821181831017156111ff576111ff61114d565b8160405282815287602084870101111561121857600080fd5b610eb8836020830160208801611163565b60006020828403121561123b57600080fd5b815160ff8116811461103357600080fd5b60008151808452611264816020860160208601611163565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a0604082018190526000906112a29083018661124c565b82810360608401526112b4818661124c565b91505060ff831660808301529695505050505050565b6001600160a01b0383168152604060208201819052600090610de09083018461124c565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b6000806000806080858703121561133357600080fd5b843561133e81610f61565b9350602085013561134e81610f61565b9250604085013561135e81610f61565b9396929550929360600135925050565b60006020828403121561138057600080fd5b8151801515811461103357600080fd5b600082516113a2818460208701611163565b9190910192915050565b602081526000611033602083018461124c56fea2646970667358221220b638ab862c775779ca46f64f41fce11a25a259733849faf11ead45e4637ff9b964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100ca5760003560e01c8063cb10f94c1161007c578063cb10f94c146101ab578063d41f1771146101c4578063d57184e4146101eb578063f213159c146101fe578063f43cda8b14610211578063f4a120f714610224578063f64512551461023757600080fd5b80631459457a146100cf57806347e7ef24146100e45780636a00c1d7146100f75780637efab4f51461012757806395c7041c14610150578063b176806514610163578063b68ad1e414610198575b600080fd5b6100e26100dd366004610f79565b61025e565b005b6100e26100f2366004610fea565b6104dc565b60055461010a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61010a610135366004611016565b6004602052600090815260409020546001600160a01b031681565b60015461010a906001600160a01b031681565b61018a7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60405190815260200161011e565b60035461010a906001600160a01b031681565b60005461010a906201000090046001600160a01b031681565b61018a7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60025461010a906001600160a01b031681565b6100e261020c36600461103a565b6104eb565b6100e261021f36600461107b565b6104fb565b61010a610232366004611016565b610682565b61018a7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b600054610100900460ff161580801561027e5750600054600160ff909116105b806102985750303b158015610298575060005460ff166001145b6103005760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805460ff191660011790558015610323576000805461ff0019166101001790555b6001600160a01b0386161580159061034357506001600160a01b03851615155b801561035757506001600160a01b03841615155b801561036b57506001600160a01b03831615155b6103c65760405162461bcd60e51b815260206004820152602660248201527f526f6f7445524332305072656469636174653a204241445f494e495449414c496044820152652d20aa24a7a760d11b60648201526084016102f7565b6000805462010000600160b01b031916620100006001600160a01b038981169190910291909117909155600180546001600160a01b0319908116888416179091556002805482168784161790556003805490911685831617905582161561048e57600580546001600160a01b03199081166001600160a01b038581169182178455600091825260046020526040808320805461101095168517905593549351929316917f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e6179190a35b80156104d4576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b6104e7823383610a43565b5050565b6104f6838383610a43565b505050565b6001546001600160a01b031633146105615760405162461bcd60e51b8152602060048201526024808201527f526f6f7445524332305072656469636174653a204f4e4c595f455849545f4845604482015263262822a960e11b60648201526084016102f7565b6002546001600160a01b038481169116146105cf5760405162461bcd60e51b815260206004820152602860248201527f526f6f7445524332305072656469636174653a204f4e4c595f4348494c445f50604482015267524544494341544560c01b60648201526084016102f7565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696105fe602060008486611104565b6106079161112e565b036106265761062161061c8260208186611104565b610bba565b61067c565b60405162461bcd60e51b815260206004820152602560248201527f526f6f7445524332305072656469636174653a20494e56414c49445f5349474e604482015264415455524560d81b60648201526084016102f7565b50505050565b60006001600160a01b0382166106e45760405162461bcd60e51b815260206004820152602160248201527f526f6f7445524332305072656469636174653a20494e56414c49445f544f4b456044820152602760f91b60648201526084016102f7565b6001600160a01b0382811660009081526004602052604090205416156107575760405162461bcd60e51b815260206004820152602260248201527f526f6f7445524332305072656469636174653a20414c52454144595f4d415050604482015261115160f21b60648201526084016102f7565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261080592911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03858116600081815260046020819052604080832080546001600160a01b031916878716179055825481516306fdde0360e01b81529151969750620100009004909416946316f198319488947f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad948c9491936306fdde039380840193908290030181865afa1580156108a2573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526108ca9190810190611187565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610908573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526109309190810190611187565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa15801561096e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109929190611229565b6040516020016109a6959493929190611278565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016109d29291906112ca565b600060405180830381600087803b1580156109ec57600080fd5b505af1158015610a00573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a39392505050565b6001600160a01b038084166000908152600460205260409020541680610a6f57610a6c84610682565b90505b6001600160a01b038116610a8557610a856112ee565b610a9a6001600160a01b038516333085610c72565b600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f1983193610b2b9391169160c4016112ca565b600060405180830381600087803b158015610b4557600080fd5b505af1158015610b59573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f8be9001bb612c7123a1861dc0d9d94e683261f6cbbd7c7438b708975bc4908a33386604051610bac929190611304565b60405180910390a450505050565b6000808080610bcb8587018761131d565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610bfe57610bfe6112ee565b610c126001600160a01b0386168484610cdd565b826001600160a01b0316816001600160a01b0316866001600160a01b03167f9c4f744b2e971d7058a9d8f43977e0e17bf7d57a48659f0e18541b7ee3d022e48786604051610c61929190611304565b60405180910390a450505050505050565b6040516001600160a01b038085166024830152831660448201526064810182905261067c9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610cfc565b6104f68363a9059cbb60e01b8484604051602401610ca6929190611304565b6000610d51826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610dd19092919063ffffffff16565b9050805160001480610d72575080806020019051810190610d72919061136e565b6104f65760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016102f7565b6060610de08484600085610de8565b949350505050565b606082471015610e495760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016102f7565b600080866001600160a01b03168587604051610e659190611390565b60006040518083038185875af1925050503d8060008114610ea2576040519150601f19603f3d011682016040523d82523d6000602084013e610ea7565b606091505b5091509150610eb887838387610ec3565b979650505050505050565b60608315610f32578251600003610f2b576001600160a01b0385163b610f2b5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016102f7565b5081610de0565b610de08383815115610f475781518083602001fd5b8060405162461bcd60e51b81526004016102f791906113ac565b6001600160a01b0381168114610f7657600080fd5b50565b600080600080600060a08688031215610f9157600080fd5b8535610f9c81610f61565b94506020860135610fac81610f61565b93506040860135610fbc81610f61565b92506060860135610fcc81610f61565b91506080860135610fdc81610f61565b809150509295509295909350565b60008060408385031215610ffd57600080fd5b823561100881610f61565b946020939093013593505050565b60006020828403121561102857600080fd5b813561103381610f61565b9392505050565b60008060006060848603121561104f57600080fd5b833561105a81610f61565b9250602084013561106a81610f61565b929592945050506040919091013590565b6000806000806060858703121561109157600080fd5b8435935060208501356110a381610f61565b9250604085013567ffffffffffffffff808211156110c057600080fd5b818701915087601f8301126110d457600080fd5b8135818111156110e357600080fd5b8860208285010111156110f557600080fd5b95989497505060200194505050565b6000808585111561111457600080fd5b8386111561112157600080fd5b5050820193919092039150565b8035602083101561114757600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561117e578181015183820152602001611166565b50506000910152565b60006020828403121561119957600080fd5b815167ffffffffffffffff808211156111b157600080fd5b818401915084601f8301126111c557600080fd5b8151818111156111d7576111d761114d565b604051601f8201601f19908116603f011681019083821181831017156111ff576111ff61114d565b8160405282815287602084870101111561121857600080fd5b610eb8836020830160208801611163565b60006020828403121561123b57600080fd5b815160ff8116811461103357600080fd5b60008151808452611264816020860160208601611163565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a0604082018190526000906112a29083018661124c565b82810360608401526112b4818661124c565b91505060ff831660808301529695505050505050565b6001600160a01b0383168152604060208201819052600090610de09083018461124c565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b6000806000806080858703121561133357600080fd5b843561133e81610f61565b9350602085013561134e81610f61565b9250604085013561135e81610f61565b9396929550929360600135925050565b60006020828403121561138057600080fd5b8151801515811461103357600080fd5b600082516113a2818460208701611163565b9190910192915050565b602081526000611033602083018461124c56fea2646970667358221220b638ab862c775779ca46f64f41fce11a25a259733849faf11ead45e4637ff9b964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildMintableERC20PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildMintableERC20Predicate","sourceName":"contracts/root/ChildMintableERC20Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MintableERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MintableERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"MintableTokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newRootERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506113c8806100206000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c8063cb10f94c11610071578063cb10f94c14610182578063d41f17711461019b578063f3fef3a3146101c2578063f43cda8b146101d5578063f6451255146101e8578063f8c8765e1461020f57600080fd5b806371cf93b7146100b95780637efab4f5146100e957806395c7041c14610112578063b176806514610125578063b68ad1e41461015a578063c3b35a7e1461016d575b600080fd5b6002546100cc906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100cc6100f7366004610ecf565b6004602052600090815260409020546001600160a01b031681565b6001546100cc906001600160a01b031681565b61014c7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b6040519081526020016100e0565b6003546100cc906001600160a01b031681565b61018061017b366004610ef3565b610222565b005b6000546100cc906201000090046001600160a01b031681565b61014c7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101806101d0366004610f34565b610232565b6101806101e3366004610f60565b610241565b61014c7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61018061021d366004610fe9565b610432565b61022d83838361054b565b505050565b61023d82338361054b565b5050565b6001546001600160a01b031633146102b95760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c6545524332305072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b60648201526084015b60405180910390fd5b6002546001600160a01b0384811691161461032f5760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c6545524332305072656469636174653a204f4e4c60448201526f595f524f4f545f50524544494341544560801b60648201526084016102b0565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82161035e602060008486611045565b6103679161106f565b036103865761038161037c8260208186611045565b6108e0565b61042c565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6103b5602060008486611045565b6103be9161106f565b036103cd576103818282610b9c565b60405162461bcd60e51b815260206004820152602e60248201527f4368696c644d696e7461626c6545524332305072656469636174653a20494e5660448201526d414c49445f5349474e415455524560901b60648201526084016102b0565b50505050565b600054610100900460ff16158080156104525750600054600160ff909116105b8061046c5750303b15801561046c575060005460ff166001145b6104cf5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016102b0565b6000805460ff1916600117905580156104f2576000805461ff0019166101001790555b6104fe85858585610d13565b8015610544576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b826001600160a01b03163b6000036105b75760405162461bcd60e51b815260206004820152602960248201527f4368696c644d696e7461626c6545524332305072656469636174653a204e4f5460448201526817d0d3d395149050d560ba1b60648201526084016102b0565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156105f7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061061b919061108d565b6001600160a01b0381811660009081526004602052604090205491925085811691161461065a5760405162461bcd60e51b81526004016102b0906110aa565b6001600160a01b038116610670576106706110f5565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156106b8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106dc919061108d565b6001600160a01b0316146106f2576106f26110f5565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610720903390869060040161110b565b6020604051808303816000875af115801561073f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107639190611124565b6107c05760405162461bcd60e51b815260206004820152602860248201527f4368696c644d696e7461626c6545524332305072656469636174653a204255526044820152671397d1905253115160c21b60648201526084016102b0565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f19831936108519391169160c40161118c565b600060405180830381600087803b15801561086b57600080fd5b505af115801561087f573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167f1da92ba31d15f9af529a2efe7acebc6c0a4ac8e9cd86a84f199a474e505d77a633866040516108d292919061110b565b60405180910390a450505050565b60008080806108f1858701876111b8565b6001600160a01b03808516600090815260046020526040902054949850929650909450925016806109345760405162461bcd60e51b81526004016102b0906110aa565b806001600160a01b03163b60000361094e5761094e6110f5565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561098e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b2919061108d565b9050856001600160a01b0316816001600160a01b0316146109d5576109d56110f5565b6001600160a01b0381166109eb576109eb6110f5565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a33573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a57919061108d565b6001600160a01b031614610a6d57610a6d6110f5565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610a9b908790879060040161110b565b6020604051808303816000875af1158015610aba573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ade9190611124565b610b3b5760405162461bcd60e51b815260206004820152602860248201527f4368696c644d696e7461626c6545524332305072656469636174653a204d494e6044820152671517d1905253115160c21b60648201526084016102b0565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fcf47ccd68b2113d6309d8d504a67c10963dc0bfbf2416e4726a316511cca27b58887604051610b8a92919061110b565b60405180910390a45050505050505050565b6000808080610bad858701876112ac565b92975090955093509150506001600160a01b038416610bce57610bce6110f5565b6001600160a01b038481166000908152600460205260409020541615610bf657610bf66110f5565b6003546040516bffffffffffffffffffffffff19606087901b166020820152600091610c46916001600160a01b039091169060340160405160208183030381529060405280519060200120610e1a565b6001600160a01b0386811660009081526004602081905260409182902080546001600160a01b03191693851693841790559051637b69774360e11b8152929350909163f6d2ee8691610ca091899189918991899101611347565b600060405180830381600087803b158015610cba57600080fd5b505af1158015610cce573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a350505050505050565b6001600160a01b03841615801590610d3357506001600160a01b03831615155b8015610d4757506001600160a01b03821615155b8015610d5b57506001600160a01b03811615155b610dbf5760405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c6545524332305072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b60648201526084016102b0565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116610eb15760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016102b0565b92915050565b6001600160a01b0381168114610ecc57600080fd5b50565b600060208284031215610ee157600080fd5b8135610eec81610eb7565b9392505050565b600080600060608486031215610f0857600080fd5b8335610f1381610eb7565b92506020840135610f2381610eb7565b929592945050506040919091013590565b60008060408385031215610f4757600080fd5b8235610f5281610eb7565b946020939093013593505050565b60008060008060608587031215610f7657600080fd5b843593506020850135610f8881610eb7565b9250604085013567ffffffffffffffff80821115610fa557600080fd5b818701915087601f830112610fb957600080fd5b813581811115610fc857600080fd5b886020828501011115610fda57600080fd5b95989497505060200194505050565b60008060008060808587031215610fff57600080fd5b843561100a81610eb7565b9350602085013561101a81610eb7565b9250604085013561102a81610eb7565b9150606085013561103a81610eb7565b939692955090935050565b6000808585111561105557600080fd5b8386111561106257600080fd5b5050820193919092039150565b80356020831015610eb157600019602084900360031b1b1692915050565b60006020828403121561109f57600080fd5b8151610eec81610eb7565b6020808252602b908201527f4368696c644d696e7461626c6545524332305072656469636174653a20554e4d60408201526a20a82822a22faa27a5a2a760a91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60006020828403121561113657600080fd5b81518015158114610eec57600080fd5b6000815180845260005b8181101561116c57602081850181015186830182015201611150565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b03831681526040602082018190526000906111b090830184611146565b949350505050565b600080600080608085870312156111ce57600080fd5b84356111d981610eb7565b935060208501356111e981610eb7565b925060408501356111f981610eb7565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261123057600080fd5b813567ffffffffffffffff8082111561124b5761124b611209565b604051601f8301601f19908116603f0116810190828211818310171561127357611273611209565b8160405283815286602085880101111561128c57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a086880312156112c457600080fd5b8535945060208601356112d681610eb7565b9350604086013567ffffffffffffffff808211156112f357600080fd5b6112ff89838a0161121f565b9450606088013591508082111561131557600080fd5b506113228882890161121f565b925050608086013560ff8116811461133957600080fd5b809150509295509295909350565b6001600160a01b038516815260806020820181905260009061136b90830186611146565b828103604084015261137d8186611146565b91505060ff831660608301529594505050505056fea264697066735822122087775fa0c83774cca5f812d4bf60fa4ef351e7b816104e4edbe586babc84517664736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100b45760003560e01c8063cb10f94c11610071578063cb10f94c14610182578063d41f17711461019b578063f3fef3a3146101c2578063f43cda8b146101d5578063f6451255146101e8578063f8c8765e1461020f57600080fd5b806371cf93b7146100b95780637efab4f5146100e957806395c7041c14610112578063b176806514610125578063b68ad1e41461015a578063c3b35a7e1461016d575b600080fd5b6002546100cc906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100cc6100f7366004610ecf565b6004602052600090815260409020546001600160a01b031681565b6001546100cc906001600160a01b031681565b61014c7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b6040519081526020016100e0565b6003546100cc906001600160a01b031681565b61018061017b366004610ef3565b610222565b005b6000546100cc906201000090046001600160a01b031681565b61014c7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101806101d0366004610f34565b610232565b6101806101e3366004610f60565b610241565b61014c7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61018061021d366004610fe9565b610432565b61022d83838361054b565b505050565b61023d82338361054b565b5050565b6001546001600160a01b031633146102b95760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c6545524332305072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b60648201526084015b60405180910390fd5b6002546001600160a01b0384811691161461032f5760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c6545524332305072656469636174653a204f4e4c60448201526f595f524f4f545f50524544494341544560801b60648201526084016102b0565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82161035e602060008486611045565b6103679161106f565b036103865761038161037c8260208186611045565b6108e0565b61042c565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6103b5602060008486611045565b6103be9161106f565b036103cd576103818282610b9c565b60405162461bcd60e51b815260206004820152602e60248201527f4368696c644d696e7461626c6545524332305072656469636174653a20494e5660448201526d414c49445f5349474e415455524560901b60648201526084016102b0565b50505050565b600054610100900460ff16158080156104525750600054600160ff909116105b8061046c5750303b15801561046c575060005460ff166001145b6104cf5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016102b0565b6000805460ff1916600117905580156104f2576000805461ff0019166101001790555b6104fe85858585610d13565b8015610544576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b826001600160a01b03163b6000036105b75760405162461bcd60e51b815260206004820152602960248201527f4368696c644d696e7461626c6545524332305072656469636174653a204e4f5460448201526817d0d3d395149050d560ba1b60648201526084016102b0565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156105f7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061061b919061108d565b6001600160a01b0381811660009081526004602052604090205491925085811691161461065a5760405162461bcd60e51b81526004016102b0906110aa565b6001600160a01b038116610670576106706110f5565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156106b8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106dc919061108d565b6001600160a01b0316146106f2576106f26110f5565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610720903390869060040161110b565b6020604051808303816000875af115801561073f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107639190611124565b6107c05760405162461bcd60e51b815260206004820152602860248201527f4368696c644d696e7461626c6545524332305072656469636174653a204255526044820152671397d1905253115160c21b60648201526084016102b0565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f19831936108519391169160c40161118c565b600060405180830381600087803b15801561086b57600080fd5b505af115801561087f573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167f1da92ba31d15f9af529a2efe7acebc6c0a4ac8e9cd86a84f199a474e505d77a633866040516108d292919061110b565b60405180910390a450505050565b60008080806108f1858701876111b8565b6001600160a01b03808516600090815260046020526040902054949850929650909450925016806109345760405162461bcd60e51b81526004016102b0906110aa565b806001600160a01b03163b60000361094e5761094e6110f5565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561098e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b2919061108d565b9050856001600160a01b0316816001600160a01b0316146109d5576109d56110f5565b6001600160a01b0381166109eb576109eb6110f5565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a33573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a57919061108d565b6001600160a01b031614610a6d57610a6d6110f5565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610a9b908790879060040161110b565b6020604051808303816000875af1158015610aba573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ade9190611124565b610b3b5760405162461bcd60e51b815260206004820152602860248201527f4368696c644d696e7461626c6545524332305072656469636174653a204d494e6044820152671517d1905253115160c21b60648201526084016102b0565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fcf47ccd68b2113d6309d8d504a67c10963dc0bfbf2416e4726a316511cca27b58887604051610b8a92919061110b565b60405180910390a45050505050505050565b6000808080610bad858701876112ac565b92975090955093509150506001600160a01b038416610bce57610bce6110f5565b6001600160a01b038481166000908152600460205260409020541615610bf657610bf66110f5565b6003546040516bffffffffffffffffffffffff19606087901b166020820152600091610c46916001600160a01b039091169060340160405160208183030381529060405280519060200120610e1a565b6001600160a01b0386811660009081526004602081905260409182902080546001600160a01b03191693851693841790559051637b69774360e11b8152929350909163f6d2ee8691610ca091899189918991899101611347565b600060405180830381600087803b158015610cba57600080fd5b505af1158015610cce573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a350505050505050565b6001600160a01b03841615801590610d3357506001600160a01b03831615155b8015610d4757506001600160a01b03821615155b8015610d5b57506001600160a01b03811615155b610dbf5760405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c6545524332305072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b60648201526084016102b0565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116610eb15760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016102b0565b92915050565b6001600160a01b0381168114610ecc57600080fd5b50565b600060208284031215610ee157600080fd5b8135610eec81610eb7565b9392505050565b600080600060608486031215610f0857600080fd5b8335610f1381610eb7565b92506020840135610f2381610eb7565b929592945050506040919091013590565b60008060408385031215610f4757600080fd5b8235610f5281610eb7565b946020939093013593505050565b60008060008060608587031215610f7657600080fd5b843593506020850135610f8881610eb7565b9250604085013567ffffffffffffffff80821115610fa557600080fd5b818701915087601f830112610fb957600080fd5b813581811115610fc857600080fd5b886020828501011115610fda57600080fd5b95989497505060200194505050565b60008060008060808587031215610fff57600080fd5b843561100a81610eb7565b9350602085013561101a81610eb7565b9250604085013561102a81610eb7565b9150606085013561103a81610eb7565b939692955090935050565b6000808585111561105557600080fd5b8386111561106257600080fd5b5050820193919092039150565b80356020831015610eb157600019602084900360031b1b1692915050565b60006020828403121561109f57600080fd5b8151610eec81610eb7565b6020808252602b908201527f4368696c644d696e7461626c6545524332305072656469636174653a20554e4d60408201526a20a82822a22faa27a5a2a760a91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60006020828403121561113657600080fd5b81518015158114610eec57600080fd5b6000815180845260005b8181101561116c57602081850181015186830182015201611150565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b03831681526040602082018190526000906111b090830184611146565b949350505050565b600080600080608085870312156111ce57600080fd5b84356111d981610eb7565b935060208501356111e981610eb7565b925060408501356111f981610eb7565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261123057600080fd5b813567ffffffffffffffff8082111561124b5761124b611209565b604051601f8301601f19908116603f0116810190828211818310171561127357611273611209565b8160405283815286602085880101111561128c57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a086880312156112c457600080fd5b8535945060208601356112d681610eb7565b9350604086013567ffffffffffffffff808211156112f357600080fd5b6112ff89838a0161121f565b9450606088013591508082111561131557600080fd5b506113228882890161121f565b925050608086013560ff8116811461133957600080fd5b809150509295509295909350565b6001600160a01b038516815260806020820181905260009061136b90830186611146565b828103604084015261137d8186611146565b91505060ff831660608301529594505050505056fea264697066735822122087775fa0c83774cca5f812d4bf60fa4ef351e7b816104e4edbe586babc84517664736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var RootERC20PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootERC20Predicate","sourceName":"contracts/bridge/RootERC20Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"TokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newChildERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"},{"internalType":"address","name":"newNativeTokenRoot","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"nativeTokenRoot","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506113f5806100206000396000f3fe608060405234801561001057600080fd5b50600436106100ca5760003560e01c8063cb10f94c1161007c578063cb10f94c146101ab578063d41f1771146101c4578063d57184e4146101eb578063f213159c146101fe578063f43cda8b14610211578063f4a120f714610224578063f64512551461023757600080fd5b80631459457a146100cf57806347e7ef24146100e45780636a00c1d7146100f75780637efab4f51461012757806395c7041c14610150578063b176806514610163578063b68ad1e414610198575b600080fd5b6100e26100dd366004610f79565b61025e565b005b6100e26100f2366004610fea565b6104dc565b60055461010a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61010a610135366004611016565b6004602052600090815260409020546001600160a01b031681565b60015461010a906001600160a01b031681565b61018a7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60405190815260200161011e565b60035461010a906001600160a01b031681565b60005461010a906201000090046001600160a01b031681565b61018a7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60025461010a906001600160a01b031681565b6100e261020c36600461103a565b6104eb565b6100e261021f36600461107b565b6104fb565b61010a610232366004611016565b610682565b61018a7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b600054610100900460ff161580801561027e5750600054600160ff909116105b806102985750303b158015610298575060005460ff166001145b6103005760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805460ff191660011790558015610323576000805461ff0019166101001790555b6001600160a01b0386161580159061034357506001600160a01b03851615155b801561035757506001600160a01b03841615155b801561036b57506001600160a01b03831615155b6103c65760405162461bcd60e51b815260206004820152602660248201527f526f6f7445524332305072656469636174653a204241445f494e495449414c496044820152652d20aa24a7a760d11b60648201526084016102f7565b6000805462010000600160b01b031916620100006001600160a01b038981169190910291909117909155600180546001600160a01b0319908116888416179091556002805482168784161790556003805490911685831617905582161561048e57600580546001600160a01b03199081166001600160a01b038581169182178455600091825260046020526040808320805461101095168517905593549351929316917f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e6179190a35b80156104d4576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b6104e7823383610a43565b5050565b6104f6838383610a43565b505050565b6001546001600160a01b031633146105615760405162461bcd60e51b8152602060048201526024808201527f526f6f7445524332305072656469636174653a204f4e4c595f455849545f4845604482015263262822a960e11b60648201526084016102f7565b6002546001600160a01b038481169116146105cf5760405162461bcd60e51b815260206004820152602860248201527f526f6f7445524332305072656469636174653a204f4e4c595f4348494c445f50604482015267524544494341544560c01b60648201526084016102f7565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696105fe602060008486611104565b6106079161112e565b036106265761062161061c8260208186611104565b610bba565b61067c565b60405162461bcd60e51b815260206004820152602560248201527f526f6f7445524332305072656469636174653a20494e56414c49445f5349474e604482015264415455524560d81b60648201526084016102f7565b50505050565b60006001600160a01b0382166106e45760405162461bcd60e51b815260206004820152602160248201527f526f6f7445524332305072656469636174653a20494e56414c49445f544f4b456044820152602760f91b60648201526084016102f7565b6001600160a01b0382811660009081526004602052604090205416156107575760405162461bcd60e51b815260206004820152602260248201527f526f6f7445524332305072656469636174653a20414c52454144595f4d415050604482015261115160f21b60648201526084016102f7565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261080592911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03858116600081815260046020819052604080832080546001600160a01b031916878716179055825481516306fdde0360e01b81529151969750620100009004909416946316f198319488947f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad948c9491936306fdde039380840193908290030181865afa1580156108a2573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526108ca9190810190611187565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610908573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526109309190810190611187565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa15801561096e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109929190611229565b6040516020016109a6959493929190611278565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016109d29291906112ca565b600060405180830381600087803b1580156109ec57600080fd5b505af1158015610a00573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a39392505050565b6001600160a01b038084166000908152600460205260409020541680610a6f57610a6c84610682565b90505b6001600160a01b038116610a8557610a856112ee565b610a9a6001600160a01b038516333085610c72565b600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f1983193610b2b9391169160c4016112ca565b600060405180830381600087803b158015610b4557600080fd5b505af1158015610b59573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f8be9001bb612c7123a1861dc0d9d94e683261f6cbbd7c7438b708975bc4908a33386604051610bac929190611304565b60405180910390a450505050565b6000808080610bcb8587018761131d565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610bfe57610bfe6112ee565b610c126001600160a01b0386168484610cdd565b826001600160a01b0316816001600160a01b0316866001600160a01b03167f9c4f744b2e971d7058a9d8f43977e0e17bf7d57a48659f0e18541b7ee3d022e48786604051610c61929190611304565b60405180910390a450505050505050565b6040516001600160a01b038085166024830152831660448201526064810182905261067c9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610cfc565b6104f68363a9059cbb60e01b8484604051602401610ca6929190611304565b6000610d51826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610dd19092919063ffffffff16565b9050805160001480610d72575080806020019051810190610d72919061136e565b6104f65760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016102f7565b6060610de08484600085610de8565b949350505050565b606082471015610e495760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016102f7565b600080866001600160a01b03168587604051610e659190611390565b60006040518083038185875af1925050503d8060008114610ea2576040519150601f19603f3d011682016040523d82523d6000602084013e610ea7565b606091505b5091509150610eb887838387610ec3565b979650505050505050565b60608315610f32578251600003610f2b576001600160a01b0385163b610f2b5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016102f7565b5081610de0565b610de08383815115610f475781518083602001fd5b8060405162461bcd60e51b81526004016102f791906113ac565b6001600160a01b0381168114610f7657600080fd5b50565b600080600080600060a08688031215610f9157600080fd5b8535610f9c81610f61565b94506020860135610fac81610f61565b93506040860135610fbc81610f61565b92506060860135610fcc81610f61565b91506080860135610fdc81610f61565b809150509295509295909350565b60008060408385031215610ffd57600080fd5b823561100881610f61565b946020939093013593505050565b60006020828403121561102857600080fd5b813561103381610f61565b9392505050565b60008060006060848603121561104f57600080fd5b833561105a81610f61565b9250602084013561106a81610f61565b929592945050506040919091013590565b6000806000806060858703121561109157600080fd5b8435935060208501356110a381610f61565b9250604085013567ffffffffffffffff808211156110c057600080fd5b818701915087601f8301126110d457600080fd5b8135818111156110e357600080fd5b8860208285010111156110f557600080fd5b95989497505060200194505050565b6000808585111561111457600080fd5b8386111561112157600080fd5b5050820193919092039150565b8035602083101561114757600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561117e578181015183820152602001611166565b50506000910152565b60006020828403121561119957600080fd5b815167ffffffffffffffff808211156111b157600080fd5b818401915084601f8301126111c557600080fd5b8151818111156111d7576111d761114d565b604051601f8201601f19908116603f011681019083821181831017156111ff576111ff61114d565b8160405282815287602084870101111561121857600080fd5b610eb8836020830160208801611163565b60006020828403121561123b57600080fd5b815160ff8116811461103357600080fd5b60008151808452611264816020860160208601611163565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a0604082018190526000906112a29083018661124c565b82810360608401526112b4818661124c565b91505060ff831660808301529695505050505050565b6001600160a01b0383168152604060208201819052600090610de09083018461124c565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b6000806000806080858703121561133357600080fd5b843561133e81610f61565b9350602085013561134e81610f61565b9250604085013561135e81610f61565b9396929550929360600135925050565b60006020828403121561138057600080fd5b8151801515811461103357600080fd5b600082516113a2818460208701611163565b9190910192915050565b602081526000611033602083018461124c56fea26469706673582212200d70a30953bd2a0c20c267af767aba1b16028f56a6b7113b2dc9327be3c60cd064736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100ca5760003560e01c8063cb10f94c1161007c578063cb10f94c146101ab578063d41f1771146101c4578063d57184e4146101eb578063f213159c146101fe578063f43cda8b14610211578063f4a120f714610224578063f64512551461023757600080fd5b80631459457a146100cf57806347e7ef24146100e45780636a00c1d7146100f75780637efab4f51461012757806395c7041c14610150578063b176806514610163578063b68ad1e414610198575b600080fd5b6100e26100dd366004610f79565b61025e565b005b6100e26100f2366004610fea565b6104dc565b60055461010a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b61010a610135366004611016565b6004602052600090815260409020546001600160a01b031681565b60015461010a906001600160a01b031681565b61018a7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60405190815260200161011e565b60035461010a906001600160a01b031681565b60005461010a906201000090046001600160a01b031681565b61018a7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b60025461010a906001600160a01b031681565b6100e261020c36600461103a565b6104eb565b6100e261021f36600461107b565b6104fb565b61010a610232366004611016565b610682565b61018a7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b600054610100900460ff161580801561027e5750600054600160ff909116105b806102985750303b158015610298575060005460ff166001145b6103005760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805460ff191660011790558015610323576000805461ff0019166101001790555b6001600160a01b0386161580159061034357506001600160a01b03851615155b801561035757506001600160a01b03841615155b801561036b57506001600160a01b03831615155b6103c65760405162461bcd60e51b815260206004820152602660248201527f526f6f7445524332305072656469636174653a204241445f494e495449414c496044820152652d20aa24a7a760d11b60648201526084016102f7565b6000805462010000600160b01b031916620100006001600160a01b038981169190910291909117909155600180546001600160a01b0319908116888416179091556002805482168784161790556003805490911685831617905582161561048e57600580546001600160a01b03199081166001600160a01b038581169182178455600091825260046020526040808320805461101095168517905593549351929316917f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e6179190a35b80156104d4576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b6104e7823383610a43565b5050565b6104f6838383610a43565b505050565b6001546001600160a01b031633146105615760405162461bcd60e51b8152602060048201526024808201527f526f6f7445524332305072656469636174653a204f4e4c595f455849545f4845604482015263262822a960e11b60648201526084016102f7565b6002546001600160a01b038481169116146105cf5760405162461bcd60e51b815260206004820152602860248201527f526f6f7445524332305072656469636174653a204f4e4c595f4348494c445f50604482015267524544494341544560c01b60648201526084016102f7565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e9828696105fe602060008486611104565b6106079161112e565b036106265761062161061c8260208186611104565b610bba565b61067c565b60405162461bcd60e51b815260206004820152602560248201527f526f6f7445524332305072656469636174653a20494e56414c49445f5349474e604482015264415455524560d81b60648201526084016102f7565b50505050565b60006001600160a01b0382166106e45760405162461bcd60e51b815260206004820152602160248201527f526f6f7445524332305072656469636174653a20494e56414c49445f544f4b456044820152602760f91b60648201526084016102f7565b6001600160a01b0382811660009081526004602052604090205416156107575760405162461bcd60e51b815260206004820152602260248201527f526f6f7445524332305072656469636174653a20414c52454144595f4d415050604482015261115160f21b60648201526084016102f7565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261080592911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03858116600081815260046020819052604080832080546001600160a01b031916878716179055825481516306fdde0360e01b81529151969750620100009004909416946316f198319488947f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad948c9491936306fdde039380840193908290030181865afa1580156108a2573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526108ca9190810190611187565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610908573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526109309190810190611187565b8a6001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa15801561096e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109929190611229565b6040516020016109a6959493929190611278565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016109d29291906112ca565b600060405180830381600087803b1580156109ec57600080fd5b505af1158015610a00573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a39392505050565b6001600160a01b038084166000908152600460205260409020541680610a6f57610a6c84610682565b90505b6001600160a01b038116610a8557610a856112ee565b610a9a6001600160a01b038516333085610c72565b600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b0388811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f1983193610b2b9391169160c4016112ca565b600060405180830381600087803b158015610b4557600080fd5b505af1158015610b59573d6000803e3d6000fd5b50505050826001600160a01b0316816001600160a01b0316856001600160a01b03167f8be9001bb612c7123a1861dc0d9d94e683261f6cbbd7c7438b708975bc4908a33386604051610bac929190611304565b60405180910390a450505050565b6000808080610bcb8587018761131d565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610bfe57610bfe6112ee565b610c126001600160a01b0386168484610cdd565b826001600160a01b0316816001600160a01b0316866001600160a01b03167f9c4f744b2e971d7058a9d8f43977e0e17bf7d57a48659f0e18541b7ee3d022e48786604051610c61929190611304565b60405180910390a450505050505050565b6040516001600160a01b038085166024830152831660448201526064810182905261067c9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610cfc565b6104f68363a9059cbb60e01b8484604051602401610ca6929190611304565b6000610d51826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610dd19092919063ffffffff16565b9050805160001480610d72575080806020019051810190610d72919061136e565b6104f65760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016102f7565b6060610de08484600085610de8565b949350505050565b606082471015610e495760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016102f7565b600080866001600160a01b03168587604051610e659190611390565b60006040518083038185875af1925050503d8060008114610ea2576040519150601f19603f3d011682016040523d82523d6000602084013e610ea7565b606091505b5091509150610eb887838387610ec3565b979650505050505050565b60608315610f32578251600003610f2b576001600160a01b0385163b610f2b5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016102f7565b5081610de0565b610de08383815115610f475781518083602001fd5b8060405162461bcd60e51b81526004016102f791906113ac565b6001600160a01b0381168114610f7657600080fd5b50565b600080600080600060a08688031215610f9157600080fd5b8535610f9c81610f61565b94506020860135610fac81610f61565b93506040860135610fbc81610f61565b92506060860135610fcc81610f61565b91506080860135610fdc81610f61565b809150509295509295909350565b60008060408385031215610ffd57600080fd5b823561100881610f61565b946020939093013593505050565b60006020828403121561102857600080fd5b813561103381610f61565b9392505050565b60008060006060848603121561104f57600080fd5b833561105a81610f61565b9250602084013561106a81610f61565b929592945050506040919091013590565b6000806000806060858703121561109157600080fd5b8435935060208501356110a381610f61565b9250604085013567ffffffffffffffff808211156110c057600080fd5b818701915087601f8301126110d457600080fd5b8135818111156110e357600080fd5b8860208285010111156110f557600080fd5b95989497505060200194505050565b6000808585111561111457600080fd5b8386111561112157600080fd5b5050820193919092039150565b8035602083101561114757600019602084900360031b1b165b92915050565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561117e578181015183820152602001611166565b50506000910152565b60006020828403121561119957600080fd5b815167ffffffffffffffff808211156111b157600080fd5b818401915084601f8301126111c557600080fd5b8151818111156111d7576111d761114d565b604051601f8201601f19908116603f011681019083821181831017156111ff576111ff61114d565b8160405282815287602084870101111561121857600080fd5b610eb8836020830160208801611163565b60006020828403121561123b57600080fd5b815160ff8116811461103357600080fd5b60008151808452611264816020860160208601611163565b601f01601f19169290920160200192915050565b8581526001600160a01b038516602082015260a0604082018190526000906112a29083018661124c565b82810360608401526112b4818661124c565b91505060ff831660808301529695505050505050565b6001600160a01b0383168152604060208201819052600090610de09083018461124c565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b6000806000806080858703121561133357600080fd5b843561133e81610f61565b9350602085013561134e81610f61565b9250604085013561135e81610f61565b9396929550929360600135925050565b60006020828403121561138057600080fd5b8151801515811461103357600080fd5b600082516113a2818460208701611163565b9190910192915050565b602081526000611033602083018461124c56fea26469706673582212200d70a30953bd2a0c20c267af767aba1b16028f56a6b7113b2dc9327be3c60cd064736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildMintableERC20PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildMintableERC20Predicate","sourceName":"contracts/bridge/ChildMintableERC20Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MintableERC20Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MintableERC20Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"MintableTokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newRootERC20Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC20Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC20","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506113c8806100206000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c8063cb10f94c11610071578063cb10f94c14610182578063d41f17711461019b578063f3fef3a3146101c2578063f43cda8b146101d5578063f6451255146101e8578063f8c8765e1461020f57600080fd5b806371cf93b7146100b95780637efab4f5146100e957806395c7041c14610112578063b176806514610125578063b68ad1e41461015a578063c3b35a7e1461016d575b600080fd5b6002546100cc906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100cc6100f7366004610ecf565b6004602052600090815260409020546001600160a01b031681565b6001546100cc906001600160a01b031681565b61014c7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b6040519081526020016100e0565b6003546100cc906001600160a01b031681565b61018061017b366004610ef3565b610222565b005b6000546100cc906201000090046001600160a01b031681565b61014c7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101806101d0366004610f34565b610232565b6101806101e3366004610f60565b610241565b61014c7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61018061021d366004610fe9565b610432565b61022d83838361054b565b505050565b61023d82338361054b565b5050565b6001546001600160a01b031633146102b95760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c6545524332305072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b60648201526084015b60405180910390fd5b6002546001600160a01b0384811691161461032f5760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c6545524332305072656469636174653a204f4e4c60448201526f595f524f4f545f50524544494341544560801b60648201526084016102b0565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82161035e602060008486611045565b6103679161106f565b036103865761038161037c8260208186611045565b6108e0565b61042c565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6103b5602060008486611045565b6103be9161106f565b036103cd576103818282610b9c565b60405162461bcd60e51b815260206004820152602e60248201527f4368696c644d696e7461626c6545524332305072656469636174653a20494e5660448201526d414c49445f5349474e415455524560901b60648201526084016102b0565b50505050565b600054610100900460ff16158080156104525750600054600160ff909116105b8061046c5750303b15801561046c575060005460ff166001145b6104cf5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016102b0565b6000805460ff1916600117905580156104f2576000805461ff0019166101001790555b6104fe85858585610d13565b8015610544576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b826001600160a01b03163b6000036105b75760405162461bcd60e51b815260206004820152602960248201527f4368696c644d696e7461626c6545524332305072656469636174653a204e4f5460448201526817d0d3d395149050d560ba1b60648201526084016102b0565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156105f7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061061b919061108d565b6001600160a01b0381811660009081526004602052604090205491925085811691161461065a5760405162461bcd60e51b81526004016102b0906110aa565b6001600160a01b038116610670576106706110f5565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156106b8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106dc919061108d565b6001600160a01b0316146106f2576106f26110f5565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610720903390869060040161110b565b6020604051808303816000875af115801561073f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107639190611124565b6107c05760405162461bcd60e51b815260206004820152602860248201527f4368696c644d696e7461626c6545524332305072656469636174653a204255526044820152671397d1905253115160c21b60648201526084016102b0565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f19831936108519391169160c40161118c565b600060405180830381600087803b15801561086b57600080fd5b505af115801561087f573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167f1da92ba31d15f9af529a2efe7acebc6c0a4ac8e9cd86a84f199a474e505d77a633866040516108d292919061110b565b60405180910390a450505050565b60008080806108f1858701876111b8565b6001600160a01b03808516600090815260046020526040902054949850929650909450925016806109345760405162461bcd60e51b81526004016102b0906110aa565b806001600160a01b03163b60000361094e5761094e6110f5565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561098e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b2919061108d565b9050856001600160a01b0316816001600160a01b0316146109d5576109d56110f5565b6001600160a01b0381166109eb576109eb6110f5565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a33573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a57919061108d565b6001600160a01b031614610a6d57610a6d6110f5565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610a9b908790879060040161110b565b6020604051808303816000875af1158015610aba573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ade9190611124565b610b3b5760405162461bcd60e51b815260206004820152602860248201527f4368696c644d696e7461626c6545524332305072656469636174653a204d494e6044820152671517d1905253115160c21b60648201526084016102b0565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fcf47ccd68b2113d6309d8d504a67c10963dc0bfbf2416e4726a316511cca27b58887604051610b8a92919061110b565b60405180910390a45050505050505050565b6000808080610bad858701876112ac565b92975090955093509150506001600160a01b038416610bce57610bce6110f5565b6001600160a01b038481166000908152600460205260409020541615610bf657610bf66110f5565b6003546040516bffffffffffffffffffffffff19606087901b166020820152600091610c46916001600160a01b039091169060340160405160208183030381529060405280519060200120610e1a565b6001600160a01b0386811660009081526004602081905260409182902080546001600160a01b03191693851693841790559051637b69774360e11b8152929350909163f6d2ee8691610ca091899189918991899101611347565b600060405180830381600087803b158015610cba57600080fd5b505af1158015610cce573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a350505050505050565b6001600160a01b03841615801590610d3357506001600160a01b03831615155b8015610d4757506001600160a01b03821615155b8015610d5b57506001600160a01b03811615155b610dbf5760405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c6545524332305072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b60648201526084016102b0565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116610eb15760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016102b0565b92915050565b6001600160a01b0381168114610ecc57600080fd5b50565b600060208284031215610ee157600080fd5b8135610eec81610eb7565b9392505050565b600080600060608486031215610f0857600080fd5b8335610f1381610eb7565b92506020840135610f2381610eb7565b929592945050506040919091013590565b60008060408385031215610f4757600080fd5b8235610f5281610eb7565b946020939093013593505050565b60008060008060608587031215610f7657600080fd5b843593506020850135610f8881610eb7565b9250604085013567ffffffffffffffff80821115610fa557600080fd5b818701915087601f830112610fb957600080fd5b813581811115610fc857600080fd5b886020828501011115610fda57600080fd5b95989497505060200194505050565b60008060008060808587031215610fff57600080fd5b843561100a81610eb7565b9350602085013561101a81610eb7565b9250604085013561102a81610eb7565b9150606085013561103a81610eb7565b939692955090935050565b6000808585111561105557600080fd5b8386111561106257600080fd5b5050820193919092039150565b80356020831015610eb157600019602084900360031b1b1692915050565b60006020828403121561109f57600080fd5b8151610eec81610eb7565b6020808252602b908201527f4368696c644d696e7461626c6545524332305072656469636174653a20554e4d60408201526a20a82822a22faa27a5a2a760a91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60006020828403121561113657600080fd5b81518015158114610eec57600080fd5b6000815180845260005b8181101561116c57602081850181015186830182015201611150565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b03831681526040602082018190526000906111b090830184611146565b949350505050565b600080600080608085870312156111ce57600080fd5b84356111d981610eb7565b935060208501356111e981610eb7565b925060408501356111f981610eb7565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261123057600080fd5b813567ffffffffffffffff8082111561124b5761124b611209565b604051601f8301601f19908116603f0116810190828211818310171561127357611273611209565b8160405283815286602085880101111561128c57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a086880312156112c457600080fd5b8535945060208601356112d681610eb7565b9350604086013567ffffffffffffffff808211156112f357600080fd5b6112ff89838a0161121f565b9450606088013591508082111561131557600080fd5b506113228882890161121f565b925050608086013560ff8116811461133957600080fd5b809150509295509295909350565b6001600160a01b038516815260806020820181905260009061136b90830186611146565b828103604084015261137d8186611146565b91505060ff831660608301529594505050505056fea264697066735822122015ca8c4b568842a7b15ce76df299ef339d41d90ef059842ca5f9aae972f76eca64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100b45760003560e01c8063cb10f94c11610071578063cb10f94c14610182578063d41f17711461019b578063f3fef3a3146101c2578063f43cda8b146101d5578063f6451255146101e8578063f8c8765e1461020f57600080fd5b806371cf93b7146100b95780637efab4f5146100e957806395c7041c14610112578063b176806514610125578063b68ad1e41461015a578063c3b35a7e1461016d575b600080fd5b6002546100cc906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100cc6100f7366004610ecf565b6004602052600090815260409020546001600160a01b031681565b6001546100cc906001600160a01b031681565b61014c7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b6040519081526020016100e0565b6003546100cc906001600160a01b031681565b61018061017b366004610ef3565b610222565b005b6000546100cc906201000090046001600160a01b031681565b61014c7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101806101d0366004610f34565b610232565b6101806101e3366004610f60565b610241565b61014c7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61018061021d366004610fe9565b610432565b61022d83838361054b565b505050565b61023d82338361054b565b5050565b6001546001600160a01b031633146102b95760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c6545524332305072656469636174653a204f4e4c60448201526f2cafa9aa20aa22afa922a1a2a4ab22a960811b60648201526084015b60405180910390fd5b6002546001600160a01b0384811691161461032f5760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c6545524332305072656469636174653a204f4e4c60448201526f595f524f4f545f50524544494341544560801b60648201526084016102b0565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82161035e602060008486611045565b6103679161106f565b036103865761038161037c8260208186611045565b6108e0565b61042c565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad6103b5602060008486611045565b6103be9161106f565b036103cd576103818282610b9c565b60405162461bcd60e51b815260206004820152602e60248201527f4368696c644d696e7461626c6545524332305072656469636174653a20494e5660448201526d414c49445f5349474e415455524560901b60648201526084016102b0565b50505050565b600054610100900460ff16158080156104525750600054600160ff909116105b8061046c5750303b15801561046c575060005460ff166001145b6104cf5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016102b0565b6000805460ff1916600117905580156104f2576000805461ff0019166101001790555b6104fe85858585610d13565b8015610544576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b826001600160a01b03163b6000036105b75760405162461bcd60e51b815260206004820152602960248201527f4368696c644d696e7461626c6545524332305072656469636174653a204e4f5460448201526817d0d3d395149050d560ba1b60648201526084016102b0565b6000836001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa1580156105f7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061061b919061108d565b6001600160a01b0381811660009081526004602052604090205491925085811691161461065a5760405162461bcd60e51b81526004016102b0906110aa565b6001600160a01b038116610670576106706110f5565b306001600160a01b0316846001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa1580156106b8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106dc919061108d565b6001600160a01b0316146106f2576106f26110f5565b604051632770a7eb60e21b81526001600160a01b03851690639dc29fac90610720903390869060040161110b565b6020604051808303816000875af115801561073f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107639190611124565b6107c05760405162461bcd60e51b815260206004820152602860248201527f4368696c644d696e7461626c6545524332305072656469636174653a204255526044820152671397d1905253115160c21b60648201526084016102b0565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152878116608083015260a08083018890528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f19831936108519391169160c40161118c565b600060405180830381600087803b15801561086b57600080fd5b505af115801561087f573d6000803e3d6000fd5b50505050826001600160a01b0316846001600160a01b0316826001600160a01b03167f1da92ba31d15f9af529a2efe7acebc6c0a4ac8e9cd86a84f199a474e505d77a633866040516108d292919061110b565b60405180910390a450505050565b60008080806108f1858701876111b8565b6001600160a01b03808516600090815260046020526040902054949850929650909450925016806109345760405162461bcd60e51b81526004016102b0906110aa565b806001600160a01b03163b60000361094e5761094e6110f5565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561098e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b2919061108d565b9050856001600160a01b0316816001600160a01b0316146109d5576109d56110f5565b6001600160a01b0381166109eb576109eb6110f5565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a33573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a57919061108d565b6001600160a01b031614610a6d57610a6d6110f5565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610a9b908790879060040161110b565b6020604051808303816000875af1158015610aba573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ade9190611124565b610b3b5760405162461bcd60e51b815260206004820152602860248201527f4368696c644d696e7461626c6545524332305072656469636174653a204d494e6044820152671517d1905253115160c21b60648201526084016102b0565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fcf47ccd68b2113d6309d8d504a67c10963dc0bfbf2416e4726a316511cca27b58887604051610b8a92919061110b565b60405180910390a45050505050505050565b6000808080610bad858701876112ac565b92975090955093509150506001600160a01b038416610bce57610bce6110f5565b6001600160a01b038481166000908152600460205260409020541615610bf657610bf66110f5565b6003546040516bffffffffffffffffffffffff19606087901b166020820152600091610c46916001600160a01b039091169060340160405160208183030381529060405280519060200120610e1a565b6001600160a01b0386811660009081526004602081905260409182902080546001600160a01b03191693851693841790559051637b69774360e11b8152929350909163f6d2ee8691610ca091899189918991899101611347565b600060405180830381600087803b158015610cba57600080fd5b505af1158015610cce573d6000803e3d6000fd5b50506040516001600160a01b038085169350881691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a350505050505050565b6001600160a01b03841615801590610d3357506001600160a01b03831615155b8015610d4757506001600160a01b03821615155b8015610d5b57506001600160a01b03811615155b610dbf5760405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c6545524332305072656469636174653a2042414460448201526e2fa4a724aa24a0a624ad20aa24a7a760891b60648201526084016102b0565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b038116610eb15760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b60448201526064016102b0565b92915050565b6001600160a01b0381168114610ecc57600080fd5b50565b600060208284031215610ee157600080fd5b8135610eec81610eb7565b9392505050565b600080600060608486031215610f0857600080fd5b8335610f1381610eb7565b92506020840135610f2381610eb7565b929592945050506040919091013590565b60008060408385031215610f4757600080fd5b8235610f5281610eb7565b946020939093013593505050565b60008060008060608587031215610f7657600080fd5b843593506020850135610f8881610eb7565b9250604085013567ffffffffffffffff80821115610fa557600080fd5b818701915087601f830112610fb957600080fd5b813581811115610fc857600080fd5b886020828501011115610fda57600080fd5b95989497505060200194505050565b60008060008060808587031215610fff57600080fd5b843561100a81610eb7565b9350602085013561101a81610eb7565b9250604085013561102a81610eb7565b9150606085013561103a81610eb7565b939692955090935050565b6000808585111561105557600080fd5b8386111561106257600080fd5b5050820193919092039150565b80356020831015610eb157600019602084900360031b1b1692915050565b60006020828403121561109f57600080fd5b8151610eec81610eb7565b6020808252602b908201527f4368696c644d696e7461626c6545524332305072656469636174653a20554e4d60408201526a20a82822a22faa27a5a2a760a91b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b6001600160a01b03929092168252602082015260400190565b60006020828403121561113657600080fd5b81518015158114610eec57600080fd5b6000815180845260005b8181101561116c57602081850181015186830182015201611150565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b03831681526040602082018190526000906111b090830184611146565b949350505050565b600080600080608085870312156111ce57600080fd5b84356111d981610eb7565b935060208501356111e981610eb7565b925060408501356111f981610eb7565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261123057600080fd5b813567ffffffffffffffff8082111561124b5761124b611209565b604051601f8301601f19908116603f0116810190828211818310171561127357611273611209565b8160405283815286602085880101111561128c57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600080600080600060a086880312156112c457600080fd5b8535945060208601356112d681610eb7565b9350604086013567ffffffffffffffff808211156112f357600080fd5b6112ff89838a0161121f565b9450606088013591508082111561131557600080fd5b506113228882890161121f565b925050608086013560ff8116811461133957600080fd5b809150509295509295909350565b6001600160a01b038516815260806020820181905260009061136b90830186611146565b828103604084015261137d8186611146565b91505060ff831660608301529594505050505056fea264697066735822122015ca8c4b568842a7b15ce76df299ef339d41d90ef059842ca5f9aae972f76eca64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` var MockERC721Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"MockERC721","sourceName":"contracts/mocks/MockERC721.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PAUSER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getRoleMember","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleMemberCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x60806040523480156200001157600080fd5b5060405180604001604052806004815260200163151154d560e21b81525060405180604001604052806004815260200163151154d560e21b815250604051806040016040528060058152602001646c6f72656d60d81b815250828281600290816200007d919062000307565b5060036200008c828262000307565b5050600c805460ff1916905550600e620000a7828262000307565b50620000b560003362000116565b620000e17f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a63362000116565b6200010d7f65d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862a3362000116565b505050620003d3565b62000122828262000126565b5050565b62000132828262000151565b60008281526001602052604090206200014c9082620001f1565b505050565b6000828152602081815260408083206001600160a01b038516845290915290205460ff1662000122576000828152602081815260408083206001600160a01b03851684529091529020805460ff19166001179055620001ad3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b600062000208836001600160a01b03841662000211565b90505b92915050565b60008181526001830160205260408120546200025a575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556200020b565b5060006200020b565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200028e57607f821691505b602082108103620002af57634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200014c57600081815260208120601f850160051c81016020861015620002de5750805b601f850160051c820191505b81811015620002ff57828155600101620002ea565b505050505050565b81516001600160401b0381111562000323576200032362000263565b6200033b8162000334845462000279565b84620002b5565b602080601f8311600181146200037357600084156200035a5750858301515b600019600386901b1c1916600185901b178555620002ff565b600085815260208120601f198616915b82811015620003a45788860151825594840194600190910190840162000383565b5085821015620003c35787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b61244180620003e36000396000f3fe608060405234801561001057600080fd5b50600436106101a55760003560e01c80636352211e116100ef578063a22cb46511610092578063a22cb4651461036b578063b88d4fde1461037e578063c87b56dd14610391578063ca15c873146103a4578063d5391393146103b7578063d547741f146103de578063e63ab1e9146103f1578063e985e9c51461040657600080fd5b80636352211e146102f45780636a6278421461030757806370a082311461031a5780638456cb591461032d5780639010d07c1461033557806391d148541461034857806395d89b411461035b578063a217fddf1461036357600080fd5b80632f2ff15d116101575780632f2ff15d1461026f5780632f745c591461028257806336568abe146102955780633f4ba83a146102a857806342842e0e146102b057806342966c68146102c35780634f6ccce7146102d65780635c975abb146102e957600080fd5b806301ffc9a7146101aa57806306fdde03146101d2578063081812fc146101e7578063095ea7b31461021257806318160ddd1461022757806323b872dd14610239578063248a9ca31461024c575b600080fd5b6101bd6101b8366004611dba565b610419565b60405190151581526020015b60405180910390f35b6101da61042a565b6040516101c99190611e27565b6101fa6101f5366004611e3a565b6104bc565b6040516001600160a01b0390911681526020016101c9565b610225610220366004611e6f565b6104e3565b005b600a545b6040519081526020016101c9565b610225610247366004611e99565b6105fd565b61022b61025a366004611e3a565b60009081526020819052604090206001015490565b61022561027d366004611ed5565b61062f565b61022b610290366004611e6f565b610654565b6102256102a3366004611ed5565b6106ea565b610225610768565b6102256102be366004611e99565b6107ec565b6102256102d1366004611e3a565b610807565b61022b6102e4366004611e3a565b610838565b600c5460ff166101bd565b6101fa610302366004611e3a565b6108cb565b610225610315366004611f01565b610900565b61022b610328366004611f01565b6109aa565b610225610a30565b6101fa610343366004611f1c565b610ab0565b6101bd610356366004611ed5565b610acf565b6101da610af8565b61022b600081565b610225610379366004611f3e565b610b07565b61022561038c366004611f90565b610b12565b6101da61039f366004611e3a565b610b4a565b61022b6103b2366004611e3a565b610bb0565b61022b7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b6102256103ec366004611ed5565b610bc7565b61022b6000805160206123ac83398151915281565b6101bd61041436600461206c565b610bec565b600061042482610c1a565b92915050565b60606002805461043990612096565b80601f016020809104026020016040519081016040528092919081815260200182805461046590612096565b80156104b25780601f10610487576101008083540402835291602001916104b2565b820191906000526020600020905b81548152906001019060200180831161049557829003601f168201915b5050505050905090565b60006104c782610c3f565b506000908152600660205260409020546001600160a01b031690565b60006104ee826108cb565b9050806001600160a01b0316836001600160a01b0316036105605760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b038216148061057c575061057c8133610bec565b6105ee5760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c0000006064820152608401610557565b6105f88383610c64565b505050565b610608335b82610cd2565b6106245760405162461bcd60e51b8152600401610557906120d0565b6105f8838383610d31565b60008281526020819052604090206001015461064a81610e90565b6105f88383610e9a565b600061065f836109aa565b82106106c15760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610557565b506001600160a01b03919091166000908152600860209081526040808320938352929052205490565b6001600160a01b038116331461075a5760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610557565b6107648282610ebc565b5050565b6107806000805160206123ac83398151915233610acf565b6107e2576040805162461bcd60e51b81526020600482015260248101919091526000805160206123ec83398151915260448201527f6d75737420686176652070617573657220726f6c6520746f20756e70617573656064820152608401610557565b6107ea610ede565b565b6105f883838360405180602001604052806000815250610b12565b61081033610602565b61082c5760405162461bcd60e51b8152600401610557906120d0565b61083581610f30565b50565b6000610843600a5490565b82106108a65760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610557565b600a82815481106108b9576108b961211d565b90600052602060002001549050919050565b6000818152600460205260408120546001600160a01b0316806104245760405162461bcd60e51b815260040161055790612133565b61092a7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a633610acf565b61098a5760405162461bcd60e51b815260206004820152603d60248201526000805160206123ec83398151915260448201527f6d7573742068617665206d696e74657220726f6c6520746f206d696e740000006064820152608401610557565b61099c81610997600d5490565b610fc1565b610835600d80546001019055565b60006001600160a01b038216610a145760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b6064820152608401610557565b506001600160a01b031660009081526005602052604090205490565b610a486000805160206123ac83398151915233610acf565b610aa85760405162461bcd60e51b815260206004820152603e60248201526000805160206123ec83398151915260448201527f6d75737420686176652070617573657220726f6c6520746f20706175736500006064820152608401610557565b6107ea6110ca565b6000828152600160205260408120610ac89083611107565b9392505050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b60606003805461043990612096565b610764338383611113565b610b1c3383610cd2565b610b385760405162461bcd60e51b8152600401610557906120d0565b610b44848484846111dd565b50505050565b6060610b5582610c3f565b6000610b5f611210565b90506000815111610b7f5760405180602001604052806000815250610ac8565b80610b898461121f565b604051602001610b9a929190612165565b6040516020818303038152906040529392505050565b6000818152600160205260408120610424906112b2565b600082815260208190526040902060010154610be281610e90565b6105f88383610ebc565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b60006001600160e01b0319821663780e9d6360e01b14806104245750610424826112bc565b610c48816112fc565b6108355760405162461bcd60e51b815260040161055790612133565b600081815260066020526040902080546001600160a01b0319166001600160a01b0384169081179091558190610c99826108cb565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b600080610cde836108cb565b9050806001600160a01b0316846001600160a01b03161480610d055750610d058185610bec565b80610d295750836001600160a01b0316610d1e846104bc565b6001600160a01b0316145b949350505050565b826001600160a01b0316610d44826108cb565b6001600160a01b031614610d6a5760405162461bcd60e51b815260040161055790612194565b6001600160a01b038216610dcc5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610557565b610dd98383836001611319565b826001600160a01b0316610dec826108cb565b6001600160a01b031614610e125760405162461bcd60e51b815260040161055790612194565b600081815260066020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260058552838620805460001901905590871680865283862080546001019055868652600490945282852080549092168417909155905184936000805160206123cc83398151915291a4505050565b6108358133611325565b610ea4828261137e565b60008281526001602052604090206105f89082611402565b610ec68282611417565b60008281526001602052604090206105f8908261147c565b610ee6611491565b600c805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6000610f3b826108cb565b9050610f4b816000846001611319565b610f54826108cb565b600083815260066020908152604080832080546001600160a01b03199081169091556001600160a01b0385168085526005845282852080546000190190558785526004909352818420805490911690555192935084926000805160206123cc833981519152908390a45050565b6001600160a01b0382166110175760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610557565b611020816112fc565b1561103d5760405162461bcd60e51b8152600401610557906121d9565b61104b600083836001611319565b611054816112fc565b156110715760405162461bcd60e51b8152600401610557906121d9565b6001600160a01b038216600081815260056020908152604080832080546001019055848352600490915280822080546001600160a01b0319168417905551839291906000805160206123cc833981519152908290a45050565b6110d26114da565b600c805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610f133390565b6000610ac88383611520565b816001600160a01b0316836001600160a01b0316036111705760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b6044820152606401610557565b6001600160a01b03838116600081815260076020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6111e8848484610d31565b6111f48484848461154a565b610b445760405162461bcd60e51b815260040161055790612210565b6060600e805461043990612096565b6060600061122c8361164b565b600101905060008167ffffffffffffffff81111561124c5761124c611f7a565b6040519080825280601f01601f191660200182016040528015611276576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a850494508461128057509392505050565b6000610424825490565b60006001600160e01b031982166380ac58cd60e01b14806112ed57506001600160e01b03198216635b5e139f60e01b145b80610424575061042482611723565b6000908152600460205260409020546001600160a01b0316151590565b610b4484848484611748565b61132f8282610acf565b6107645761133c816117bb565b6113478360206117cd565b604051602001611358929190612262565b60408051601f198184030181529082905262461bcd60e51b825261055791600401611e27565b6113888282610acf565b610764576000828152602081815260408083206001600160a01b03851684529091529020805460ff191660011790556113be3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000610ac8836001600160a01b038416611969565b6114218282610acf565b15610764576000828152602081815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6000610ac8836001600160a01b0384166119b8565b600c5460ff166107ea5760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610557565b600c5460ff16156107ea5760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610557565b60008260000182815481106115375761153761211d565b9060005260206000200154905092915050565b60006001600160a01b0384163b1561164057604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061158e9033908990889088906004016122d1565b6020604051808303816000875af19250505080156115c9575060408051601f3d908101601f191682019092526115c69181019061230e565b60015b611626573d8080156115f7576040519150601f19603f3d011682016040523d82523d6000602084013e6115fc565b606091505b50805160000361161e5760405162461bcd60e51b815260040161055790612210565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610d29565b506001949350505050565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b831061168a5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef810000000083106116b6576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106116d457662386f26fc10000830492506010015b6305f5e10083106116ec576305f5e100830492506008015b612710831061170057612710830492506004015b60648310611712576064830492506002015b600a83106104245760010192915050565b60006001600160e01b03198216635a05180f60e01b1480610424575061042482611aab565b61175484848484611ae0565b600c5460ff1615610b445760405162461bcd60e51b815260206004820152602b60248201527f4552433732315061757361626c653a20746f6b656e207472616e73666572207760448201526a1a1a5b19481c185d5cd95960aa1b6064820152608401610557565b60606104246001600160a01b03831660145b606060006117dc836002612341565b6117e7906002612358565b67ffffffffffffffff8111156117ff576117ff611f7a565b6040519080825280601f01601f191660200182016040528015611829576020820181803683370190505b509050600360fc1b816000815181106118445761184461211d565b60200101906001600160f81b031916908160001a905350600f60fb1b816001815181106118735761187361211d565b60200101906001600160f81b031916908160001a9053506000611897846002612341565b6118a2906001612358565b90505b600181111561191a576f181899199a1a9b1b9c1cb0b131b232b360811b85600f16601081106118d6576118d661211d565b1a60f81b8282815181106118ec576118ec61211d565b60200101906001600160f81b031916908160001a90535060049490941c936119138161236b565b90506118a5565b508315610ac85760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610557565b60008181526001830160205260408120546119b057508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610424565b506000610424565b60008181526001830160205260408120548015611aa15760006119dc600183612382565b85549091506000906119f090600190612382565b9050818114611a55576000866000018281548110611a1057611a1061211d565b9060005260206000200154905080876000018481548110611a3357611a3361211d565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080611a6657611a66612395565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610424565b6000915050610424565b60006001600160e01b03198216637965db0b60e01b148061042457506301ffc9a760e01b6001600160e01b0319831614610424565b6001811115611b4f5760405162461bcd60e51b815260206004820152603560248201527f455243373231456e756d657261626c653a20636f6e7365637574697665207472604482015274185b9cd9995c9cc81b9bdd081cdd5c1c1bdc9d1959605a1b6064820152608401610557565b816001600160a01b038516611bab57611ba681600a80546000838152600b60205260408120829055600182018355919091527fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a80155565b611bce565b836001600160a01b0316856001600160a01b031614611bce57611bce8582611c14565b6001600160a01b038416611bea57611be581611cb1565b611c0d565b846001600160a01b0316846001600160a01b031614611c0d57611c0d8482611d60565b5050505050565b60006001611c21846109aa565b611c2b9190612382565b600083815260096020526040902054909150808214611c7e576001600160a01b03841660009081526008602090815260408083208584528252808320548484528184208190558352600990915290208190555b5060009182526009602090815260408084208490556001600160a01b039094168352600881528383209183525290812055565b600a54600090611cc390600190612382565b6000838152600b6020526040812054600a8054939450909284908110611ceb57611ceb61211d565b9060005260206000200154905080600a8381548110611d0c57611d0c61211d565b6000918252602080832090910192909255828152600b9091526040808220849055858252812055600a805480611d4457611d44612395565b6001900381819060005260206000200160009055905550505050565b6000611d6b836109aa565b6001600160a01b039093166000908152600860209081526040808320868452825280832085905593825260099052919091209190915550565b6001600160e01b03198116811461083557600080fd5b600060208284031215611dcc57600080fd5b8135610ac881611da4565b60005b83811015611df2578181015183820152602001611dda565b50506000910152565b60008151808452611e13816020860160208601611dd7565b601f01601f19169290920160200192915050565b602081526000610ac86020830184611dfb565b600060208284031215611e4c57600080fd5b5035919050565b80356001600160a01b0381168114611e6a57600080fd5b919050565b60008060408385031215611e8257600080fd5b611e8b83611e53565b946020939093013593505050565b600080600060608486031215611eae57600080fd5b611eb784611e53565b9250611ec560208501611e53565b9150604084013590509250925092565b60008060408385031215611ee857600080fd5b82359150611ef860208401611e53565b90509250929050565b600060208284031215611f1357600080fd5b610ac882611e53565b60008060408385031215611f2f57600080fd5b50508035926020909101359150565b60008060408385031215611f5157600080fd5b611f5a83611e53565b915060208301358015158114611f6f57600080fd5b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215611fa657600080fd5b611faf85611e53565b9350611fbd60208601611e53565b925060408501359150606085013567ffffffffffffffff80821115611fe157600080fd5b818701915087601f830112611ff557600080fd5b81358181111561200757612007611f7a565b604051601f8201601f19908116603f0116810190838211818310171561202f5761202f611f7a565b816040528281528a602084870101111561204857600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b6000806040838503121561207f57600080fd5b61208883611e53565b9150611ef860208401611e53565b600181811c908216806120aa57607f821691505b6020821081036120ca57634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b602080825260189082015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b604082015260600190565b60008351612177818460208801611dd7565b83519083019061218b818360208801611dd7565b01949350505050565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b6020808252601c908201527f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000604082015260600190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b76020b1b1b2b9b9a1b7b73a3937b61d1030b1b1b7bab73a1604d1b815260008351612294816017850160208801611dd7565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516122c5816028840160208801611dd7565b01602801949350505050565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061230490830184611dfb565b9695505050505050565b60006020828403121561232057600080fd5b8151610ac881611da4565b634e487b7160e01b600052601160045260246000fd5b80820281158282048414176104245761042461232b565b808201808211156104245761042461232b565b60008161237a5761237a61232b565b506000190190565b818103818111156104245761042461232b565b634e487b7160e01b600052603160045260246000fdfe65d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862addf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef4552433732315072657365744d696e7465725061757365724175746f49643a20a2646970667358221220f586c29d0cbd3e2cee9bd99a648a34864226f46f9a05471902f3728b4f230c2864736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101a55760003560e01c80636352211e116100ef578063a22cb46511610092578063a22cb4651461036b578063b88d4fde1461037e578063c87b56dd14610391578063ca15c873146103a4578063d5391393146103b7578063d547741f146103de578063e63ab1e9146103f1578063e985e9c51461040657600080fd5b80636352211e146102f45780636a6278421461030757806370a082311461031a5780638456cb591461032d5780639010d07c1461033557806391d148541461034857806395d89b411461035b578063a217fddf1461036357600080fd5b80632f2ff15d116101575780632f2ff15d1461026f5780632f745c591461028257806336568abe146102955780633f4ba83a146102a857806342842e0e146102b057806342966c68146102c35780634f6ccce7146102d65780635c975abb146102e957600080fd5b806301ffc9a7146101aa57806306fdde03146101d2578063081812fc146101e7578063095ea7b31461021257806318160ddd1461022757806323b872dd14610239578063248a9ca31461024c575b600080fd5b6101bd6101b8366004611dba565b610419565b60405190151581526020015b60405180910390f35b6101da61042a565b6040516101c99190611e27565b6101fa6101f5366004611e3a565b6104bc565b6040516001600160a01b0390911681526020016101c9565b610225610220366004611e6f565b6104e3565b005b600a545b6040519081526020016101c9565b610225610247366004611e99565b6105fd565b61022b61025a366004611e3a565b60009081526020819052604090206001015490565b61022561027d366004611ed5565b61062f565b61022b610290366004611e6f565b610654565b6102256102a3366004611ed5565b6106ea565b610225610768565b6102256102be366004611e99565b6107ec565b6102256102d1366004611e3a565b610807565b61022b6102e4366004611e3a565b610838565b600c5460ff166101bd565b6101fa610302366004611e3a565b6108cb565b610225610315366004611f01565b610900565b61022b610328366004611f01565b6109aa565b610225610a30565b6101fa610343366004611f1c565b610ab0565b6101bd610356366004611ed5565b610acf565b6101da610af8565b61022b600081565b610225610379366004611f3e565b610b07565b61022561038c366004611f90565b610b12565b6101da61039f366004611e3a565b610b4a565b61022b6103b2366004611e3a565b610bb0565b61022b7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b6102256103ec366004611ed5565b610bc7565b61022b6000805160206123ac83398151915281565b6101bd61041436600461206c565b610bec565b600061042482610c1a565b92915050565b60606002805461043990612096565b80601f016020809104026020016040519081016040528092919081815260200182805461046590612096565b80156104b25780601f10610487576101008083540402835291602001916104b2565b820191906000526020600020905b81548152906001019060200180831161049557829003601f168201915b5050505050905090565b60006104c782610c3f565b506000908152600660205260409020546001600160a01b031690565b60006104ee826108cb565b9050806001600160a01b0316836001600160a01b0316036105605760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b038216148061057c575061057c8133610bec565b6105ee5760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c0000006064820152608401610557565b6105f88383610c64565b505050565b610608335b82610cd2565b6106245760405162461bcd60e51b8152600401610557906120d0565b6105f8838383610d31565b60008281526020819052604090206001015461064a81610e90565b6105f88383610e9a565b600061065f836109aa565b82106106c15760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610557565b506001600160a01b03919091166000908152600860209081526040808320938352929052205490565b6001600160a01b038116331461075a5760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610557565b6107648282610ebc565b5050565b6107806000805160206123ac83398151915233610acf565b6107e2576040805162461bcd60e51b81526020600482015260248101919091526000805160206123ec83398151915260448201527f6d75737420686176652070617573657220726f6c6520746f20756e70617573656064820152608401610557565b6107ea610ede565b565b6105f883838360405180602001604052806000815250610b12565b61081033610602565b61082c5760405162461bcd60e51b8152600401610557906120d0565b61083581610f30565b50565b6000610843600a5490565b82106108a65760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610557565b600a82815481106108b9576108b961211d565b90600052602060002001549050919050565b6000818152600460205260408120546001600160a01b0316806104245760405162461bcd60e51b815260040161055790612133565b61092a7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a633610acf565b61098a5760405162461bcd60e51b815260206004820152603d60248201526000805160206123ec83398151915260448201527f6d7573742068617665206d696e74657220726f6c6520746f206d696e740000006064820152608401610557565b61099c81610997600d5490565b610fc1565b610835600d80546001019055565b60006001600160a01b038216610a145760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b6064820152608401610557565b506001600160a01b031660009081526005602052604090205490565b610a486000805160206123ac83398151915233610acf565b610aa85760405162461bcd60e51b815260206004820152603e60248201526000805160206123ec83398151915260448201527f6d75737420686176652070617573657220726f6c6520746f20706175736500006064820152608401610557565b6107ea6110ca565b6000828152600160205260408120610ac89083611107565b9392505050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b60606003805461043990612096565b610764338383611113565b610b1c3383610cd2565b610b385760405162461bcd60e51b8152600401610557906120d0565b610b44848484846111dd565b50505050565b6060610b5582610c3f565b6000610b5f611210565b90506000815111610b7f5760405180602001604052806000815250610ac8565b80610b898461121f565b604051602001610b9a929190612165565b6040516020818303038152906040529392505050565b6000818152600160205260408120610424906112b2565b600082815260208190526040902060010154610be281610e90565b6105f88383610ebc565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b60006001600160e01b0319821663780e9d6360e01b14806104245750610424826112bc565b610c48816112fc565b6108355760405162461bcd60e51b815260040161055790612133565b600081815260066020526040902080546001600160a01b0319166001600160a01b0384169081179091558190610c99826108cb565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b600080610cde836108cb565b9050806001600160a01b0316846001600160a01b03161480610d055750610d058185610bec565b80610d295750836001600160a01b0316610d1e846104bc565b6001600160a01b0316145b949350505050565b826001600160a01b0316610d44826108cb565b6001600160a01b031614610d6a5760405162461bcd60e51b815260040161055790612194565b6001600160a01b038216610dcc5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610557565b610dd98383836001611319565b826001600160a01b0316610dec826108cb565b6001600160a01b031614610e125760405162461bcd60e51b815260040161055790612194565b600081815260066020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260058552838620805460001901905590871680865283862080546001019055868652600490945282852080549092168417909155905184936000805160206123cc83398151915291a4505050565b6108358133611325565b610ea4828261137e565b60008281526001602052604090206105f89082611402565b610ec68282611417565b60008281526001602052604090206105f8908261147c565b610ee6611491565b600c805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6000610f3b826108cb565b9050610f4b816000846001611319565b610f54826108cb565b600083815260066020908152604080832080546001600160a01b03199081169091556001600160a01b0385168085526005845282852080546000190190558785526004909352818420805490911690555192935084926000805160206123cc833981519152908390a45050565b6001600160a01b0382166110175760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610557565b611020816112fc565b1561103d5760405162461bcd60e51b8152600401610557906121d9565b61104b600083836001611319565b611054816112fc565b156110715760405162461bcd60e51b8152600401610557906121d9565b6001600160a01b038216600081815260056020908152604080832080546001019055848352600490915280822080546001600160a01b0319168417905551839291906000805160206123cc833981519152908290a45050565b6110d26114da565b600c805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610f133390565b6000610ac88383611520565b816001600160a01b0316836001600160a01b0316036111705760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b6044820152606401610557565b6001600160a01b03838116600081815260076020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6111e8848484610d31565b6111f48484848461154a565b610b445760405162461bcd60e51b815260040161055790612210565b6060600e805461043990612096565b6060600061122c8361164b565b600101905060008167ffffffffffffffff81111561124c5761124c611f7a565b6040519080825280601f01601f191660200182016040528015611276576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a850494508461128057509392505050565b6000610424825490565b60006001600160e01b031982166380ac58cd60e01b14806112ed57506001600160e01b03198216635b5e139f60e01b145b80610424575061042482611723565b6000908152600460205260409020546001600160a01b0316151590565b610b4484848484611748565b61132f8282610acf565b6107645761133c816117bb565b6113478360206117cd565b604051602001611358929190612262565b60408051601f198184030181529082905262461bcd60e51b825261055791600401611e27565b6113888282610acf565b610764576000828152602081815260408083206001600160a01b03851684529091529020805460ff191660011790556113be3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000610ac8836001600160a01b038416611969565b6114218282610acf565b15610764576000828152602081815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6000610ac8836001600160a01b0384166119b8565b600c5460ff166107ea5760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610557565b600c5460ff16156107ea5760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610557565b60008260000182815481106115375761153761211d565b9060005260206000200154905092915050565b60006001600160a01b0384163b1561164057604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061158e9033908990889088906004016122d1565b6020604051808303816000875af19250505080156115c9575060408051601f3d908101601f191682019092526115c69181019061230e565b60015b611626573d8080156115f7576040519150601f19603f3d011682016040523d82523d6000602084013e6115fc565b606091505b50805160000361161e5760405162461bcd60e51b815260040161055790612210565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610d29565b506001949350505050565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b831061168a5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef810000000083106116b6576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106116d457662386f26fc10000830492506010015b6305f5e10083106116ec576305f5e100830492506008015b612710831061170057612710830492506004015b60648310611712576064830492506002015b600a83106104245760010192915050565b60006001600160e01b03198216635a05180f60e01b1480610424575061042482611aab565b61175484848484611ae0565b600c5460ff1615610b445760405162461bcd60e51b815260206004820152602b60248201527f4552433732315061757361626c653a20746f6b656e207472616e73666572207760448201526a1a1a5b19481c185d5cd95960aa1b6064820152608401610557565b60606104246001600160a01b03831660145b606060006117dc836002612341565b6117e7906002612358565b67ffffffffffffffff8111156117ff576117ff611f7a565b6040519080825280601f01601f191660200182016040528015611829576020820181803683370190505b509050600360fc1b816000815181106118445761184461211d565b60200101906001600160f81b031916908160001a905350600f60fb1b816001815181106118735761187361211d565b60200101906001600160f81b031916908160001a9053506000611897846002612341565b6118a2906001612358565b90505b600181111561191a576f181899199a1a9b1b9c1cb0b131b232b360811b85600f16601081106118d6576118d661211d565b1a60f81b8282815181106118ec576118ec61211d565b60200101906001600160f81b031916908160001a90535060049490941c936119138161236b565b90506118a5565b508315610ac85760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610557565b60008181526001830160205260408120546119b057508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610424565b506000610424565b60008181526001830160205260408120548015611aa15760006119dc600183612382565b85549091506000906119f090600190612382565b9050818114611a55576000866000018281548110611a1057611a1061211d565b9060005260206000200154905080876000018481548110611a3357611a3361211d565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080611a6657611a66612395565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610424565b6000915050610424565b60006001600160e01b03198216637965db0b60e01b148061042457506301ffc9a760e01b6001600160e01b0319831614610424565b6001811115611b4f5760405162461bcd60e51b815260206004820152603560248201527f455243373231456e756d657261626c653a20636f6e7365637574697665207472604482015274185b9cd9995c9cc81b9bdd081cdd5c1c1bdc9d1959605a1b6064820152608401610557565b816001600160a01b038516611bab57611ba681600a80546000838152600b60205260408120829055600182018355919091527fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a80155565b611bce565b836001600160a01b0316856001600160a01b031614611bce57611bce8582611c14565b6001600160a01b038416611bea57611be581611cb1565b611c0d565b846001600160a01b0316846001600160a01b031614611c0d57611c0d8482611d60565b5050505050565b60006001611c21846109aa565b611c2b9190612382565b600083815260096020526040902054909150808214611c7e576001600160a01b03841660009081526008602090815260408083208584528252808320548484528184208190558352600990915290208190555b5060009182526009602090815260408084208490556001600160a01b039094168352600881528383209183525290812055565b600a54600090611cc390600190612382565b6000838152600b6020526040812054600a8054939450909284908110611ceb57611ceb61211d565b9060005260206000200154905080600a8381548110611d0c57611d0c61211d565b6000918252602080832090910192909255828152600b9091526040808220849055858252812055600a805480611d4457611d44612395565b6001900381819060005260206000200160009055905550505050565b6000611d6b836109aa565b6001600160a01b039093166000908152600860209081526040808320868452825280832085905593825260099052919091209190915550565b6001600160e01b03198116811461083557600080fd5b600060208284031215611dcc57600080fd5b8135610ac881611da4565b60005b83811015611df2578181015183820152602001611dda565b50506000910152565b60008151808452611e13816020860160208601611dd7565b601f01601f19169290920160200192915050565b602081526000610ac86020830184611dfb565b600060208284031215611e4c57600080fd5b5035919050565b80356001600160a01b0381168114611e6a57600080fd5b919050565b60008060408385031215611e8257600080fd5b611e8b83611e53565b946020939093013593505050565b600080600060608486031215611eae57600080fd5b611eb784611e53565b9250611ec560208501611e53565b9150604084013590509250925092565b60008060408385031215611ee857600080fd5b82359150611ef860208401611e53565b90509250929050565b600060208284031215611f1357600080fd5b610ac882611e53565b60008060408385031215611f2f57600080fd5b50508035926020909101359150565b60008060408385031215611f5157600080fd5b611f5a83611e53565b915060208301358015158114611f6f57600080fd5b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215611fa657600080fd5b611faf85611e53565b9350611fbd60208601611e53565b925060408501359150606085013567ffffffffffffffff80821115611fe157600080fd5b818701915087601f830112611ff557600080fd5b81358181111561200757612007611f7a565b604051601f8201601f19908116603f0116810190838211818310171561202f5761202f611f7a565b816040528281528a602084870101111561204857600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b6000806040838503121561207f57600080fd5b61208883611e53565b9150611ef860208401611e53565b600181811c908216806120aa57607f821691505b6020821081036120ca57634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b602080825260189082015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b604082015260600190565b60008351612177818460208801611dd7565b83519083019061218b818360208801611dd7565b01949350505050565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b6020808252601c908201527f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000604082015260600190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b76020b1b1b2b9b9a1b7b73a3937b61d1030b1b1b7bab73a1604d1b815260008351612294816017850160208801611dd7565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516122c5816028840160208801611dd7565b01602801949350505050565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061230490830184611dfb565b9695505050505050565b60006020828403121561232057600080fd5b8151610ac881611da4565b634e487b7160e01b600052601160045260246000fd5b80820281158282048414176104245761042461232b565b808201808211156104245761042461232b565b60008161237a5761237a61232b565b506000190190565b818103818111156104245761042461232b565b634e487b7160e01b600052603160045260246000fdfe65d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862addf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef4552433732315072657365744d696e7465725061757365724175746f49643a20a2646970667358221220f586c29d0cbd3e2cee9bd99a648a34864226f46f9a05471902f3728b4f230c2864736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RootERC721PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootERC721Predicate","sourceName":"contracts/root/RootERC721Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"ERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"ERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"TokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newChildERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061196b806100206000396000f3fe608060405234801561001057600080fd5b50600436106100fb5760003560e01c8063cb10f94c116100a2578063f43cda8b11610071578063f43cda8b146102a1578063f4a120f7146102b4578063f6451255146102c7578063f8c8765e146102ee578063ff6f870c1461030157600080fd5b8063cb10f94c14610227578063d41f177114610240578063d7c9e3ec14610267578063f213159c1461028e57600080fd5b8063150b7a021461010057806347e7ef241461013c5780634fdca69d146101515780637efab4f51461017c57806395c7041c146101a5578063b1768065146101b8578063b68ad1e4146101ed578063c5ac2b1c14610200575b600080fd5b61011e61010e36600461112d565b630a85bd0160e11b949350505050565b6040516001600160e01b031990911681526020015b60405180910390f35b61014f61014a3660046111db565b610314565b005b600254610164906001600160a01b031681565b6040516001600160a01b039091168152602001610133565b61016461018a366004611207565b6004602052600090815260409020546001600160a01b031681565b600154610164906001600160a01b031681565b6101df7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610133565b600354610164906001600160a01b031681565b6101df7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610164906201000090046001600160a01b031681565b6101df7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101df7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61014f61029c36600461122b565b610323565b61014f6102af36600461126c565b610333565b6101646102c2366004611207565b61050a565b6101df7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61014f6102fc3660046112f4565b61086a565b61014f61030f36600461139b565b610a78565b61031f823383610ae0565b5050565b61032e838383610ae0565b505050565b6001546001600160a01b031633146103a05760405162461bcd60e51b815260206004820152602560248201527f526f6f744552433732315072656469636174653a204f4e4c595f455849545f4860448201526422a62822a960d91b60648201526084015b60405180910390fd5b6002546001600160a01b0384811691161461040f5760405162461bcd60e51b815260206004820152602960248201527f526f6f744552433732315072656469636174653a204f4e4c595f4348494c445f60448201526850524544494341544560b81b6064820152608401610397565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961043e60206000848661141d565b61044791611447565b036104665761046161045c826020818661141d565b610c66565b610504565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed261049560206000848661141d565b61049e91611447565b036104ad576104618282610d64565b60405162461bcd60e51b815260206004820152602660248201527f526f6f744552433732315072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b6064820152608401610397565b50505050565b60006001600160a01b03821661056d5760405162461bcd60e51b815260206004820152602260248201527f526f6f744552433732315072656469636174653a20494e56414c49445f544f4b60448201526122a760f11b6064820152608401610397565b6001600160a01b0382811660009081526004602052604090205416156105e15760405162461bcd60e51b815260206004820152602360248201527f526f6f744552433732315072656469636174653a20414c52454144595f4d415060448201526214115160ea1b6064820152608401610397565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261068f92911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03858116600081815260046020819052604080832080546001600160a01b031916878716179055825481516306fdde0360e01b81529151969750620100009004909416946316f198319488947f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad948c9491936306fdde039380840193908290030181865afa15801561072c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610754919081019061148a565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610792573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526107ba919081019061148a565b6040516020016107cd949392919061152c565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016107f9929190611573565b600060405180830381600087803b15801561081357600080fd5b505af1158015610827573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a39392505050565b600054610100900460ff161580801561088a5750600054600160ff909116105b806108a45750303b1580156108a4575060005460ff166001145b6109075760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610397565b6000805460ff19166001179055801561092a576000805461ff0019166101001790555b6001600160a01b0385161580159061094a57506001600160a01b03841615155b801561095e57506001600160a01b03831615155b801561097257506001600160a01b03821615155b6109ce5760405162461bcd60e51b815260206004820152602760248201527f526f6f744552433732315072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b6064820152608401610397565b6000805462010000600160b01b031916620100006001600160a01b038881169190910291909117909155600180546001600160a01b031990811687841617909155600280548216868416179055600380549091169184169190911790558015610a71576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610ad35760405162461bcd60e51b815260206004820152602360248201527f526f6f744552433732315072656469636174653a20494e56414c49445f4c454e60448201526208ea8960eb1b6064820152608401610397565b610a718585858585610ea5565b6000610aeb84611061565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610b1e9033903090879060040161159f565b600060405180830381600087803b158015610b3857600080fd5b505af1158015610b4c573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935262010000909404841695506316f198319450610be2939092169160c401611573565b600060405180830381600087803b158015610bfc57600080fd5b505af1158015610c10573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917f40e242710be14b7d61d3b93e9d56b40df89cc4dbad8bb88da38c8e0c23809ba7910160405180910390a450505050565b6000808080610c77858701876115c3565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610caa57610caa611614565b604051632142170760e11b81526001600160a01b038616906342842e0e90610cda9030908790879060040161159f565b600060405180830381600087803b158015610cf457600080fd5b505af1158015610d08573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f8194f168e6e9e449d05a46936e071a710c0f22634eaadeb5b85a86540123931991015b60405180910390a450505050505050565b6000808080610d75858701876116b3565b6001600160a01b03808516600090815260046020526040902054949950929750909550935016905080610daa57610daa611614565b60005b8251811015610e5557856001600160a01b03166342842e0e30868481518110610dd857610dd86117a5565b6020026020010151868581518110610df257610df26117a5565b60200260200101516040518463ffffffff1660e01b8152600401610e189392919061159f565b600060405180830381600087803b158015610e3257600080fd5b505af1158015610e46573d6000803e3d6000fd5b50505050806001019050610dad565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167f1b7b9713fdef5dfadf92f6d6e998eb1fc4763cee62a194a095d76349f7dce20c8686604051610d539291906117bb565b6000610eb086611061565b905060005b82811015610f4257866001600160a01b03166342842e0e3330878786818110610ee057610ee06117a5565b905060200201356040518463ffffffff1660e01b8152600401610f059392919061159f565b600060405180830381600087803b158015610f1f57600080fd5b505af1158015610f33573d6000803e3d6000fd5b50505050806001019050610eb5565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610fa0907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c906020016118ba565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610fcc929190611573565b600060405180830381600087803b158015610fe657600080fd5b505af1158015610ffa573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f02c575a943105cda454293b7ac636c87c94ff1bfcfac968aa5423e6b9b312ee988888888604051611051949392919061190e565b60405180910390a4505050505050565b6001600160a01b03808216600090815260046020526040902054168061108d5761108a8261050a565b90505b6001600160a01b0381166110a3576110a3611614565b919050565b6001600160a01b03811681146110bd57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156110fe576110fe6110c0565b604052919050565b60006001600160401b0382111561111f5761111f6110c0565b50601f01601f191660200190565b6000806000806080858703121561114357600080fd5b843561114e816110a8565b9350602085013561115e816110a8565b92506040850135915060608501356001600160401b0381111561118057600080fd5b8501601f8101871361119157600080fd5b80356111a461119f82611106565b6110d6565b8181528860208385010111156111b957600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b600080604083850312156111ee57600080fd5b82356111f9816110a8565b946020939093013593505050565b60006020828403121561121957600080fd5b8135611224816110a8565b9392505050565b60008060006060848603121561124057600080fd5b833561124b816110a8565b9250602084013561125b816110a8565b929592945050506040919091013590565b6000806000806060858703121561128257600080fd5b843593506020850135611294816110a8565b925060408501356001600160401b03808211156112b057600080fd5b818701915087601f8301126112c457600080fd5b8135818111156112d357600080fd5b8860208285010111156112e557600080fd5b95989497505060200194505050565b6000806000806080858703121561130a57600080fd5b8435611315816110a8565b93506020850135611325816110a8565b92506040850135611335816110a8565b91506060850135611345816110a8565b939692955090935050565b60008083601f84011261136257600080fd5b5081356001600160401b0381111561137957600080fd5b6020830191508360208260051b850101111561139457600080fd5b9250929050565b6000806000806000606086880312156113b357600080fd5b85356113be816110a8565b945060208601356001600160401b03808211156113da57600080fd5b6113e689838a01611350565b909650945060408801359150808211156113ff57600080fd5b5061140c88828901611350565b969995985093965092949392505050565b6000808585111561142d57600080fd5b8386111561143a57600080fd5b5050820193919092039150565b8035602083101561146057600019602084900360031b1b165b92915050565b60005b83811015611481578181015183820152602001611469565b50506000910152565b60006020828403121561149c57600080fd5b81516001600160401b038111156114b257600080fd5b8201601f810184136114c357600080fd5b80516114d161119f82611106565b8181528560208385010111156114e657600080fd5b6114f7826020830160208601611466565b95945050505050565b60008151808452611518816020860160208601611466565b601f01601f19169290920160200192915050565b8481526001600160a01b038416602082015260806040820181905260009061155690830185611500565b82810360608401526115688185611500565b979650505050505050565b6001600160a01b038316815260406020820181905260009061159790830184611500565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600080600080608085870312156115d957600080fd5b84356115e4816110a8565b935060208501356115f4816110a8565b92506040850135611604816110a8565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611643576116436110c0565b5060051b60200190565b600082601f83011261165e57600080fd5b8135602061166e61119f8361162a565b82815260059290921b8401810191818101908684111561168d57600080fd5b8286015b848110156116a85780358352918301918301611691565b509695505050505050565b600080600080600060a086880312156116cb57600080fd5b853594506020808701356116de816110a8565b945060408701356116ee816110a8565b935060608701356001600160401b038082111561170a57600080fd5b818901915089601f83011261171e57600080fd5b813561172c61119f8261162a565b81815260059190911b8301840190848101908c83111561174b57600080fd5b938501935b82851015611772578435611763816110a8565b82529385019390850190611750565b96505050608089013592508083111561178a57600080fd5b50506117988882890161164d565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b828110156117fd5781516001600160a01b0316845292840192908401906001016117d8565b5050508381038285015284518082528583019183019060005b8181101561183257835183529284019291840191600101611816565b5090979650505050505050565b8183526000602080850194508260005b8581101561187d578135611862816110a8565b6001600160a01b03168752958201959082019060010161184f565b509495945050505050565b81835260006001600160fb1b038311156118a157600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906118ed908301868861183f565b8281036080840152611900818587611888565b9a9950505050505050505050565b60408152600061192260408301868861183f565b828103602084015261156881858761188856fea26469706673582212203621718a3c2b1847a958c6d88f320b8bf9fde1113c6a705bddbeec4f2127ab7364736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100fb5760003560e01c8063cb10f94c116100a2578063f43cda8b11610071578063f43cda8b146102a1578063f4a120f7146102b4578063f6451255146102c7578063f8c8765e146102ee578063ff6f870c1461030157600080fd5b8063cb10f94c14610227578063d41f177114610240578063d7c9e3ec14610267578063f213159c1461028e57600080fd5b8063150b7a021461010057806347e7ef241461013c5780634fdca69d146101515780637efab4f51461017c57806395c7041c146101a5578063b1768065146101b8578063b68ad1e4146101ed578063c5ac2b1c14610200575b600080fd5b61011e61010e36600461112d565b630a85bd0160e11b949350505050565b6040516001600160e01b031990911681526020015b60405180910390f35b61014f61014a3660046111db565b610314565b005b600254610164906001600160a01b031681565b6040516001600160a01b039091168152602001610133565b61016461018a366004611207565b6004602052600090815260409020546001600160a01b031681565b600154610164906001600160a01b031681565b6101df7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610133565b600354610164906001600160a01b031681565b6101df7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610164906201000090046001600160a01b031681565b6101df7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101df7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61014f61029c36600461122b565b610323565b61014f6102af36600461126c565b610333565b6101646102c2366004611207565b61050a565b6101df7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61014f6102fc3660046112f4565b61086a565b61014f61030f36600461139b565b610a78565b61031f823383610ae0565b5050565b61032e838383610ae0565b505050565b6001546001600160a01b031633146103a05760405162461bcd60e51b815260206004820152602560248201527f526f6f744552433732315072656469636174653a204f4e4c595f455849545f4860448201526422a62822a960d91b60648201526084015b60405180910390fd5b6002546001600160a01b0384811691161461040f5760405162461bcd60e51b815260206004820152602960248201527f526f6f744552433732315072656469636174653a204f4e4c595f4348494c445f60448201526850524544494341544560b81b6064820152608401610397565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961043e60206000848661141d565b61044791611447565b036104665761046161045c826020818661141d565b610c66565b610504565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed261049560206000848661141d565b61049e91611447565b036104ad576104618282610d64565b60405162461bcd60e51b815260206004820152602660248201527f526f6f744552433732315072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b6064820152608401610397565b50505050565b60006001600160a01b03821661056d5760405162461bcd60e51b815260206004820152602260248201527f526f6f744552433732315072656469636174653a20494e56414c49445f544f4b60448201526122a760f11b6064820152608401610397565b6001600160a01b0382811660009081526004602052604090205416156105e15760405162461bcd60e51b815260206004820152602360248201527f526f6f744552433732315072656469636174653a20414c52454144595f4d415060448201526214115160ea1b6064820152608401610397565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261068f92911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03858116600081815260046020819052604080832080546001600160a01b031916878716179055825481516306fdde0360e01b81529151969750620100009004909416946316f198319488947f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad948c9491936306fdde039380840193908290030181865afa15801561072c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610754919081019061148a565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610792573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526107ba919081019061148a565b6040516020016107cd949392919061152c565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016107f9929190611573565b600060405180830381600087803b15801561081357600080fd5b505af1158015610827573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a39392505050565b600054610100900460ff161580801561088a5750600054600160ff909116105b806108a45750303b1580156108a4575060005460ff166001145b6109075760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610397565b6000805460ff19166001179055801561092a576000805461ff0019166101001790555b6001600160a01b0385161580159061094a57506001600160a01b03841615155b801561095e57506001600160a01b03831615155b801561097257506001600160a01b03821615155b6109ce5760405162461bcd60e51b815260206004820152602760248201527f526f6f744552433732315072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b6064820152608401610397565b6000805462010000600160b01b031916620100006001600160a01b038881169190910291909117909155600180546001600160a01b031990811687841617909155600280548216868416179055600380549091169184169190911790558015610a71576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610ad35760405162461bcd60e51b815260206004820152602360248201527f526f6f744552433732315072656469636174653a20494e56414c49445f4c454e60448201526208ea8960eb1b6064820152608401610397565b610a718585858585610ea5565b6000610aeb84611061565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610b1e9033903090879060040161159f565b600060405180830381600087803b158015610b3857600080fd5b505af1158015610b4c573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935262010000909404841695506316f198319450610be2939092169160c401611573565b600060405180830381600087803b158015610bfc57600080fd5b505af1158015610c10573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917f40e242710be14b7d61d3b93e9d56b40df89cc4dbad8bb88da38c8e0c23809ba7910160405180910390a450505050565b6000808080610c77858701876115c3565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610caa57610caa611614565b604051632142170760e11b81526001600160a01b038616906342842e0e90610cda9030908790879060040161159f565b600060405180830381600087803b158015610cf457600080fd5b505af1158015610d08573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f8194f168e6e9e449d05a46936e071a710c0f22634eaadeb5b85a86540123931991015b60405180910390a450505050505050565b6000808080610d75858701876116b3565b6001600160a01b03808516600090815260046020526040902054949950929750909550935016905080610daa57610daa611614565b60005b8251811015610e5557856001600160a01b03166342842e0e30868481518110610dd857610dd86117a5565b6020026020010151868581518110610df257610df26117a5565b60200260200101516040518463ffffffff1660e01b8152600401610e189392919061159f565b600060405180830381600087803b158015610e3257600080fd5b505af1158015610e46573d6000803e3d6000fd5b50505050806001019050610dad565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167f1b7b9713fdef5dfadf92f6d6e998eb1fc4763cee62a194a095d76349f7dce20c8686604051610d539291906117bb565b6000610eb086611061565b905060005b82811015610f4257866001600160a01b03166342842e0e3330878786818110610ee057610ee06117a5565b905060200201356040518463ffffffff1660e01b8152600401610f059392919061159f565b600060405180830381600087803b158015610f1f57600080fd5b505af1158015610f33573d6000803e3d6000fd5b50505050806001019050610eb5565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610fa0907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c906020016118ba565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610fcc929190611573565b600060405180830381600087803b158015610fe657600080fd5b505af1158015610ffa573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f02c575a943105cda454293b7ac636c87c94ff1bfcfac968aa5423e6b9b312ee988888888604051611051949392919061190e565b60405180910390a4505050505050565b6001600160a01b03808216600090815260046020526040902054168061108d5761108a8261050a565b90505b6001600160a01b0381166110a3576110a3611614565b919050565b6001600160a01b03811681146110bd57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156110fe576110fe6110c0565b604052919050565b60006001600160401b0382111561111f5761111f6110c0565b50601f01601f191660200190565b6000806000806080858703121561114357600080fd5b843561114e816110a8565b9350602085013561115e816110a8565b92506040850135915060608501356001600160401b0381111561118057600080fd5b8501601f8101871361119157600080fd5b80356111a461119f82611106565b6110d6565b8181528860208385010111156111b957600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b600080604083850312156111ee57600080fd5b82356111f9816110a8565b946020939093013593505050565b60006020828403121561121957600080fd5b8135611224816110a8565b9392505050565b60008060006060848603121561124057600080fd5b833561124b816110a8565b9250602084013561125b816110a8565b929592945050506040919091013590565b6000806000806060858703121561128257600080fd5b843593506020850135611294816110a8565b925060408501356001600160401b03808211156112b057600080fd5b818701915087601f8301126112c457600080fd5b8135818111156112d357600080fd5b8860208285010111156112e557600080fd5b95989497505060200194505050565b6000806000806080858703121561130a57600080fd5b8435611315816110a8565b93506020850135611325816110a8565b92506040850135611335816110a8565b91506060850135611345816110a8565b939692955090935050565b60008083601f84011261136257600080fd5b5081356001600160401b0381111561137957600080fd5b6020830191508360208260051b850101111561139457600080fd5b9250929050565b6000806000806000606086880312156113b357600080fd5b85356113be816110a8565b945060208601356001600160401b03808211156113da57600080fd5b6113e689838a01611350565b909650945060408801359150808211156113ff57600080fd5b5061140c88828901611350565b969995985093965092949392505050565b6000808585111561142d57600080fd5b8386111561143a57600080fd5b5050820193919092039150565b8035602083101561146057600019602084900360031b1b165b92915050565b60005b83811015611481578181015183820152602001611469565b50506000910152565b60006020828403121561149c57600080fd5b81516001600160401b038111156114b257600080fd5b8201601f810184136114c357600080fd5b80516114d161119f82611106565b8181528560208385010111156114e657600080fd5b6114f7826020830160208601611466565b95945050505050565b60008151808452611518816020860160208601611466565b601f01601f19169290920160200192915050565b8481526001600160a01b038416602082015260806040820181905260009061155690830185611500565b82810360608401526115688185611500565b979650505050505050565b6001600160a01b038316815260406020820181905260009061159790830184611500565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600080600080608085870312156115d957600080fd5b84356115e4816110a8565b935060208501356115f4816110a8565b92506040850135611604816110a8565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611643576116436110c0565b5060051b60200190565b600082601f83011261165e57600080fd5b8135602061166e61119f8361162a565b82815260059290921b8401810191818101908684111561168d57600080fd5b8286015b848110156116a85780358352918301918301611691565b509695505050505050565b600080600080600060a086880312156116cb57600080fd5b853594506020808701356116de816110a8565b945060408701356116ee816110a8565b935060608701356001600160401b038082111561170a57600080fd5b818901915089601f83011261171e57600080fd5b813561172c61119f8261162a565b81815260059190911b8301840190848101908c83111561174b57600080fd5b938501935b82851015611772578435611763816110a8565b82529385019390850190611750565b96505050608089013592508083111561178a57600080fd5b50506117988882890161164d565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b828110156117fd5781516001600160a01b0316845292840192908401906001016117d8565b5050508381038285015284518082528583019183019060005b8181101561183257835183529284019291840191600101611816565b5090979650505050505050565b8183526000602080850194508260005b8581101561187d578135611862816110a8565b6001600160a01b03168752958201959082019060010161184f565b509495945050505050565b81835260006001600160fb1b038311156118a157600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906118ed908301868861183f565b8281036080840152611900818587611888565b9a9950505050505050505050565b60408152600061192260408301868861183f565b828103602084015261156881858761188856fea26469706673582212203621718a3c2b1847a958c6d88f320b8bf9fde1113c6a705bddbeec4f2127ab7364736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildMintableERC721PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildMintableERC721Predicate","sourceName":"contracts/root/ChildMintableERC721Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"MintableERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"MintableERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"MintableERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"MintableERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"MintableTokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newRootERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611f01806100206000396000f3fe608060405234801561001057600080fd5b50600436106100d55760003560e01c8063cb10f94c11610087578063cb10f94c146101ca578063d41f1771146101e3578063d7c9e3ec1461020a578063f3fef3a314610231578063f43cda8b14610244578063f645125514610257578063f691325c1461027e578063f8c8765e1461029157600080fd5b80636f33e695146100da5780637efab4f5146100ef57806395c7041c14610135578063b176806514610148578063b68ad1e41461017d578063c3b35a7e14610190578063c5ac2b1c146101a3575b600080fd5b6100ed6100e836600461158c565b6102a4565b005b6101186100fd36600461160e565b6004602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b600154610118906001600160a01b031681565b61016f7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60405190815260200161012c565b600354610118906001600160a01b031681565b6100ed61019e366004611632565b6102b8565b61016f7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610118906201000090046001600160a01b031681565b61016f7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61016f7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6100ed61023f366004611673565b6102c8565b6100ed61025236600461169f565b6102d7565b61016f7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b600254610118906001600160a01b031681565b6100ed61029f366004611727565b61050f565b6102b18585858585610627565b5050505050565b6102c383838361099a565b505050565b6102d382338361099a565b5050565b6001546001600160a01b0316331461034d5760405162461bcd60e51b815260206004820152602e60248201527f4368696c644d696e7461626c654552433732315072656469636174653a204f4e60448201526d262cafa2ac24aa2fa422a62822a960911b60648201526084015b60405180910390fd5b6002546001600160a01b038481169116146103c45760405162461bcd60e51b815260206004820152603160248201527f4368696c644d696e7461626c654552433732315072656469636174653a204f4e6044820152704c595f524f4f545f50524544494341544560781b6064820152608401610344565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216103f3602060008486611783565b6103fc916117ad565b0361041b576104166104118260208186611783565b610ca9565b610509565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1861044a602060008486611783565b610453916117ad565b03610462576104168282610f1f565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad610491602060008486611783565b61049a916117ad565b036104a9576104168282611185565b60405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c654552433732315072656469636174653a20494e60448201526e56414c49445f5349474e415455524560881b6064820152608401610344565b50505050565b600054610100900460ff161580801561052f5750600054600160ff909116105b806105495750303b158015610549575060005460ff166001145b6105ac5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610344565b6000805460ff1916600117905580156105cf576000805461ff0019166101001790555b6105db858585856112f5565b80156102b1576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b84610631816113fd565b61064d5760405162461bcd60e51b8152600401610344906117cb565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561068d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b19190611815565b6001600160a01b038181166000908152600460205260409020549192508881169116146106f05760405162461bcd60e51b815260040161034490611832565b6001600160a01b0381166107065761070661187e565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561074e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107729190611815565b6001600160a01b0316146107885761078861187e565b8483146107ec5760405162461bcd60e51b815260206004820152602c60248201527f4368696c644d696e7461626c654552433732315072656469636174653a20494e60448201526b0ac82989288be988a9c8ea8960a31b6064820152608401610344565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc39061081c903390889088906004016118c6565b6020604051808303816000875af115801561083b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061085f91906118f4565b61087b5760405162461bcd60e51b815260040161034490611916565b6000546002546040516001600160a01b03620100009093048316926316f198319216906108d8907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d906020016119a8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610904929190611a42565b600060405180830381600087803b15801561091e57600080fd5b505af1158015610932573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167f5faed28924bb6c5b0d3eea1cc028b4814f49c39eac622b81ef17035d794ac774898989896040516109899493929190611a6e565b60405180910390a450505050505050565b826109a4816113fd565b6109c05760405162461bcd60e51b8152600401610344906117cb565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a00573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a249190611815565b6001600160a01b03818116600090815260046020526040902054919250868116911614610a635760405162461bcd60e51b815260040161034490611832565b6001600160a01b038116610a7957610a7961187e565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ac1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ae59190611815565b6001600160a01b031614610afb57610afb61187e565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610b299033908790600401611aa0565b6020604051808303816000875af1158015610b48573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b6c91906118f4565b610b885760405162461bcd60e51b815260040161034490611916565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f1983193610c199391169160c401611a42565b600060405180830381600087803b158015610c3357600080fd5b505af1158015610c47573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f85b3d9b3b871daf1d10c7ba1016854e371ab931adef5569172f0289515a9a6de3387604051610c9a929190611aa0565b60405180910390a45050505050565b6000808080610cba85870187611ab9565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610cfd5760405162461bcd60e51b815260040161034490611832565b610d06816113fd565b610d1257610d1261187e565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d52573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d769190611815565b9050856001600160a01b0316816001600160a01b031614610d9957610d9961187e565b6001600160a01b038116610daf57610daf61187e565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610df7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e1b9190611815565b6001600160a01b031614610e3157610e3161187e565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610e5f9087908790600401611aa0565b6020604051808303816000875af1158015610e7e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ea291906118f4565b610ebe5760405162461bcd60e51b815260040161034490611b0a565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fb26f02b79335e4b2c506d9e5ae02e042b464a7556419bbc42522fc92833aff528887604051610f0d929190611aa0565b60405180910390a45050505050505050565b6000808080610f3085870187611c27565b6001600160a01b03808516600090815260046020526040902054949950929750909550935016905080610f755760405162461bcd60e51b815260040161034490611832565b610f7e816113fd565b610f8a57610f8a61187e565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fca573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fee9190611815565b9050856001600160a01b0316816001600160a01b0316146110115761101161187e565b6001600160a01b0381166110275761102761187e565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561106f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110939190611815565b6001600160a01b0316146110a9576110a961187e565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d9906110d79087908790600401611d19565b6020604051808303816000875af11580156110f6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061111a91906118f4565b6111365760405162461bcd60e51b815260040161034490611b0a565b846001600160a01b0316826001600160a01b0316876001600160a01b03167f7f51e520a281df2deae2754a9232b5a78c8cfeae79568668a0a97a116e1401b88787604051610f0d929190611d19565b6000808061119584860186611e0c565b91955093509150506001600160a01b0383166111b3576111b361187e565b6001600160a01b0383811660009081526004602052604090205416156111db576111db61187e565b6003546040516bffffffffffffffffffffffff19606086901b16602082015260009161122b916001600160a01b039091169060340160405160208183030381529060405280519060200120611492565b6001600160a01b0385811660009081526004602081905260409182902080546001600160a01b03191693851693841790559051639065714760e01b815292935090916390657147916112839188918891889101611e8b565b600060405180830381600087803b15801561129d57600080fd5b505af11580156112b1573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a3505050505050565b6001600160a01b0384161580159061131557506001600160a01b03831615155b801561132957506001600160a01b03821615155b801561133d57506001600160a01b03811615155b6113a25760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c654552433732315072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b6064820152608401610344565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000816001600160a01b03163b60000361141957506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611480575060408051601f3d908101601f1916820190925261147d918101906118f4565b60015b61148c57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b03811661148c5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610344565b6001600160a01b038116811461153e57600080fd5b50565b60008083601f84011261155357600080fd5b5081356001600160401b0381111561156a57600080fd5b6020830191508360208260051b850101111561158557600080fd5b9250929050565b6000806000806000606086880312156115a457600080fd5b85356115af81611529565b945060208601356001600160401b03808211156115cb57600080fd5b6115d789838a01611541565b909650945060408801359150808211156115f057600080fd5b506115fd88828901611541565b969995985093965092949392505050565b60006020828403121561162057600080fd5b813561162b81611529565b9392505050565b60008060006060848603121561164757600080fd5b833561165281611529565b9250602084013561166281611529565b929592945050506040919091013590565b6000806040838503121561168657600080fd5b823561169181611529565b946020939093013593505050565b600080600080606085870312156116b557600080fd5b8435935060208501356116c781611529565b925060408501356001600160401b03808211156116e357600080fd5b818701915087601f8301126116f757600080fd5b81358181111561170657600080fd5b88602082850101111561171857600080fd5b95989497505060200194505050565b6000806000806080858703121561173d57600080fd5b843561174881611529565b9350602085013561175881611529565b9250604085013561176881611529565b9150606085013561177881611529565b939692955090935050565b6000808585111561179357600080fd5b838611156117a057600080fd5b5050820193919092039150565b8035602083101561148c57600019602084900360031b1b1692915050565b6020808252602a908201527f4368696c644d696e7461626c654552433732315072656469636174653a204e4f6040820152691517d0d3d395149050d560b21b606082015260800190565b60006020828403121561182757600080fd5b815161162b81611529565b6020808252602c908201527f4368696c644d696e7461626c654552433732315072656469636174653a20554e60408201526b26a0a82822a22faa27a5a2a760a11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156118ad57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b03841681526040602082018190526000906118eb9083018486611894565b95945050505050565b60006020828403121561190657600080fd5b8151801515811461162b57600080fd5b60208082526029908201527f4368696c644d696e7461626c654552433732315072656469636174653a204255604082015268149397d1905253115160ba1b606082015260800190565b8183526000602080850194508260005b8581101561199d57813561198281611529565b6001600160a01b03168752958201959082019060010161196f565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906119db908301868861195f565b82810360808401526119ee818587611894565b9a9950505050505050505050565b6000815180845260005b81811015611a2257602081850181015186830182015201611a06565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611a66908301846119fc565b949350505050565b604081526000611a8260408301868861195f565b8281036020840152611a95818587611894565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611acf57600080fd5b8435611ada81611529565b93506020850135611aea81611529565b92506040850135611afa81611529565b9396929550929360600135925050565b60208082526029908201527f4368696c644d696e7461626c654552433732315072656469636174653a204d49604082015268139517d1905253115160ba1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611b9157611b91611b53565b604052919050565b60006001600160401b03821115611bb257611bb2611b53565b5060051b60200190565b600082601f830112611bcd57600080fd5b81356020611be2611bdd83611b99565b611b69565b82815260059290921b84018101918181019086841115611c0157600080fd5b8286015b84811015611c1c5780358352918301918301611c05565b509695505050505050565b600080600080600060a08688031215611c3f57600080fd5b85359450602080870135611c5281611529565b94506040870135611c6281611529565b935060608701356001600160401b0380821115611c7e57600080fd5b818901915089601f830112611c9257600080fd5b8135611ca0611bdd82611b99565b81815260059190911b8301840190848101908c831115611cbf57600080fd5b938501935b82851015611ce6578435611cd781611529565b82529385019390850190611cc4565b965050506080890135925080831115611cfe57600080fd5b5050611d0c88828901611bbc565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b82811015611d5b5781516001600160a01b031684529284019290840190600101611d36565b5050508381038285015284518082528583019183019060005b81811015611d9057835183529284019291840191600101611d74565b5090979650505050505050565b600082601f830112611dae57600080fd5b81356001600160401b03811115611dc757611dc7611b53565b611dda601f8201601f1916602001611b69565b818152846020838601011115611def57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611e2257600080fd5b843593506020850135611e3481611529565b925060408501356001600160401b0380821115611e5057600080fd5b611e5c88838901611d9d565b93506060870135915080821115611e7257600080fd5b50611e7f87828801611d9d565b91505092959194509250565b6001600160a01b0384168152606060208201819052600090611eaf908301856119fc565b8281036040840152611ec181856119fc565b969550505050505056fea264697066735822122033e4a7fc99de8d907b46e0e352c2feaea0b43d47f4a2303e6d491ab60c6afeed64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100d55760003560e01c8063cb10f94c11610087578063cb10f94c146101ca578063d41f1771146101e3578063d7c9e3ec1461020a578063f3fef3a314610231578063f43cda8b14610244578063f645125514610257578063f691325c1461027e578063f8c8765e1461029157600080fd5b80636f33e695146100da5780637efab4f5146100ef57806395c7041c14610135578063b176806514610148578063b68ad1e41461017d578063c3b35a7e14610190578063c5ac2b1c146101a3575b600080fd5b6100ed6100e836600461158c565b6102a4565b005b6101186100fd36600461160e565b6004602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b600154610118906001600160a01b031681565b61016f7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60405190815260200161012c565b600354610118906001600160a01b031681565b6100ed61019e366004611632565b6102b8565b61016f7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610118906201000090046001600160a01b031681565b61016f7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61016f7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6100ed61023f366004611673565b6102c8565b6100ed61025236600461169f565b6102d7565b61016f7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b600254610118906001600160a01b031681565b6100ed61029f366004611727565b61050f565b6102b18585858585610627565b5050505050565b6102c383838361099a565b505050565b6102d382338361099a565b5050565b6001546001600160a01b0316331461034d5760405162461bcd60e51b815260206004820152602e60248201527f4368696c644d696e7461626c654552433732315072656469636174653a204f4e60448201526d262cafa2ac24aa2fa422a62822a960911b60648201526084015b60405180910390fd5b6002546001600160a01b038481169116146103c45760405162461bcd60e51b815260206004820152603160248201527f4368696c644d696e7461626c654552433732315072656469636174653a204f4e6044820152704c595f524f4f545f50524544494341544560781b6064820152608401610344565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216103f3602060008486611783565b6103fc916117ad565b0361041b576104166104118260208186611783565b610ca9565b610509565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1861044a602060008486611783565b610453916117ad565b03610462576104168282610f1f565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad610491602060008486611783565b61049a916117ad565b036104a9576104168282611185565b60405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c654552433732315072656469636174653a20494e60448201526e56414c49445f5349474e415455524560881b6064820152608401610344565b50505050565b600054610100900460ff161580801561052f5750600054600160ff909116105b806105495750303b158015610549575060005460ff166001145b6105ac5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610344565b6000805460ff1916600117905580156105cf576000805461ff0019166101001790555b6105db858585856112f5565b80156102b1576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b84610631816113fd565b61064d5760405162461bcd60e51b8152600401610344906117cb565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561068d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b19190611815565b6001600160a01b038181166000908152600460205260409020549192508881169116146106f05760405162461bcd60e51b815260040161034490611832565b6001600160a01b0381166107065761070661187e565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561074e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107729190611815565b6001600160a01b0316146107885761078861187e565b8483146107ec5760405162461bcd60e51b815260206004820152602c60248201527f4368696c644d696e7461626c654552433732315072656469636174653a20494e60448201526b0ac82989288be988a9c8ea8960a31b6064820152608401610344565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc39061081c903390889088906004016118c6565b6020604051808303816000875af115801561083b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061085f91906118f4565b61087b5760405162461bcd60e51b815260040161034490611916565b6000546002546040516001600160a01b03620100009093048316926316f198319216906108d8907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d906020016119a8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610904929190611a42565b600060405180830381600087803b15801561091e57600080fd5b505af1158015610932573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167f5faed28924bb6c5b0d3eea1cc028b4814f49c39eac622b81ef17035d794ac774898989896040516109899493929190611a6e565b60405180910390a450505050505050565b826109a4816113fd565b6109c05760405162461bcd60e51b8152600401610344906117cb565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a00573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a249190611815565b6001600160a01b03818116600090815260046020526040902054919250868116911614610a635760405162461bcd60e51b815260040161034490611832565b6001600160a01b038116610a7957610a7961187e565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ac1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ae59190611815565b6001600160a01b031614610afb57610afb61187e565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610b299033908790600401611aa0565b6020604051808303816000875af1158015610b48573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b6c91906118f4565b610b885760405162461bcd60e51b815260040161034490611916565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f1983193610c199391169160c401611a42565b600060405180830381600087803b158015610c3357600080fd5b505af1158015610c47573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f85b3d9b3b871daf1d10c7ba1016854e371ab931adef5569172f0289515a9a6de3387604051610c9a929190611aa0565b60405180910390a45050505050565b6000808080610cba85870187611ab9565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610cfd5760405162461bcd60e51b815260040161034490611832565b610d06816113fd565b610d1257610d1261187e565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d52573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d769190611815565b9050856001600160a01b0316816001600160a01b031614610d9957610d9961187e565b6001600160a01b038116610daf57610daf61187e565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610df7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e1b9190611815565b6001600160a01b031614610e3157610e3161187e565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610e5f9087908790600401611aa0565b6020604051808303816000875af1158015610e7e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ea291906118f4565b610ebe5760405162461bcd60e51b815260040161034490611b0a565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fb26f02b79335e4b2c506d9e5ae02e042b464a7556419bbc42522fc92833aff528887604051610f0d929190611aa0565b60405180910390a45050505050505050565b6000808080610f3085870187611c27565b6001600160a01b03808516600090815260046020526040902054949950929750909550935016905080610f755760405162461bcd60e51b815260040161034490611832565b610f7e816113fd565b610f8a57610f8a61187e565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fca573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fee9190611815565b9050856001600160a01b0316816001600160a01b0316146110115761101161187e565b6001600160a01b0381166110275761102761187e565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561106f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110939190611815565b6001600160a01b0316146110a9576110a961187e565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d9906110d79087908790600401611d19565b6020604051808303816000875af11580156110f6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061111a91906118f4565b6111365760405162461bcd60e51b815260040161034490611b0a565b846001600160a01b0316826001600160a01b0316876001600160a01b03167f7f51e520a281df2deae2754a9232b5a78c8cfeae79568668a0a97a116e1401b88787604051610f0d929190611d19565b6000808061119584860186611e0c565b91955093509150506001600160a01b0383166111b3576111b361187e565b6001600160a01b0383811660009081526004602052604090205416156111db576111db61187e565b6003546040516bffffffffffffffffffffffff19606086901b16602082015260009161122b916001600160a01b039091169060340160405160208183030381529060405280519060200120611492565b6001600160a01b0385811660009081526004602081905260409182902080546001600160a01b03191693851693841790559051639065714760e01b815292935090916390657147916112839188918891889101611e8b565b600060405180830381600087803b15801561129d57600080fd5b505af11580156112b1573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a3505050505050565b6001600160a01b0384161580159061131557506001600160a01b03831615155b801561132957506001600160a01b03821615155b801561133d57506001600160a01b03811615155b6113a25760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c654552433732315072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b6064820152608401610344565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000816001600160a01b03163b60000361141957506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611480575060408051601f3d908101601f1916820190925261147d918101906118f4565b60015b61148c57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b03811661148c5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610344565b6001600160a01b038116811461153e57600080fd5b50565b60008083601f84011261155357600080fd5b5081356001600160401b0381111561156a57600080fd5b6020830191508360208260051b850101111561158557600080fd5b9250929050565b6000806000806000606086880312156115a457600080fd5b85356115af81611529565b945060208601356001600160401b03808211156115cb57600080fd5b6115d789838a01611541565b909650945060408801359150808211156115f057600080fd5b506115fd88828901611541565b969995985093965092949392505050565b60006020828403121561162057600080fd5b813561162b81611529565b9392505050565b60008060006060848603121561164757600080fd5b833561165281611529565b9250602084013561166281611529565b929592945050506040919091013590565b6000806040838503121561168657600080fd5b823561169181611529565b946020939093013593505050565b600080600080606085870312156116b557600080fd5b8435935060208501356116c781611529565b925060408501356001600160401b03808211156116e357600080fd5b818701915087601f8301126116f757600080fd5b81358181111561170657600080fd5b88602082850101111561171857600080fd5b95989497505060200194505050565b6000806000806080858703121561173d57600080fd5b843561174881611529565b9350602085013561175881611529565b9250604085013561176881611529565b9150606085013561177881611529565b939692955090935050565b6000808585111561179357600080fd5b838611156117a057600080fd5b5050820193919092039150565b8035602083101561148c57600019602084900360031b1b1692915050565b6020808252602a908201527f4368696c644d696e7461626c654552433732315072656469636174653a204e4f6040820152691517d0d3d395149050d560b21b606082015260800190565b60006020828403121561182757600080fd5b815161162b81611529565b6020808252602c908201527f4368696c644d696e7461626c654552433732315072656469636174653a20554e60408201526b26a0a82822a22faa27a5a2a760a11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156118ad57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b03841681526040602082018190526000906118eb9083018486611894565b95945050505050565b60006020828403121561190657600080fd5b8151801515811461162b57600080fd5b60208082526029908201527f4368696c644d696e7461626c654552433732315072656469636174653a204255604082015268149397d1905253115160ba1b606082015260800190565b8183526000602080850194508260005b8581101561199d57813561198281611529565b6001600160a01b03168752958201959082019060010161196f565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906119db908301868861195f565b82810360808401526119ee818587611894565b9a9950505050505050505050565b6000815180845260005b81811015611a2257602081850181015186830182015201611a06565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611a66908301846119fc565b949350505050565b604081526000611a8260408301868861195f565b8281036020840152611a95818587611894565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611acf57600080fd5b8435611ada81611529565b93506020850135611aea81611529565b92506040850135611afa81611529565b9396929550929360600135925050565b60208082526029908201527f4368696c644d696e7461626c654552433732315072656469636174653a204d49604082015268139517d1905253115160ba1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611b9157611b91611b53565b604052919050565b60006001600160401b03821115611bb257611bb2611b53565b5060051b60200190565b600082601f830112611bcd57600080fd5b81356020611be2611bdd83611b99565b611b69565b82815260059290921b84018101918181019086841115611c0157600080fd5b8286015b84811015611c1c5780358352918301918301611c05565b509695505050505050565b600080600080600060a08688031215611c3f57600080fd5b85359450602080870135611c5281611529565b94506040870135611c6281611529565b935060608701356001600160401b0380821115611c7e57600080fd5b818901915089601f830112611c9257600080fd5b8135611ca0611bdd82611b99565b81815260059190911b8301840190848101908c831115611cbf57600080fd5b938501935b82851015611ce6578435611cd781611529565b82529385019390850190611cc4565b965050506080890135925080831115611cfe57600080fd5b5050611d0c88828901611bbc565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b82811015611d5b5781516001600160a01b031684529284019290840190600101611d36565b5050508381038285015284518082528583019183019060005b81811015611d9057835183529284019291840191600101611d74565b5090979650505050505050565b600082601f830112611dae57600080fd5b81356001600160401b03811115611dc757611dc7611b53565b611dda601f8201601f1916602001611b69565b818152846020838601011115611def57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611e2257600080fd5b843593506020850135611e3481611529565b925060408501356001600160401b0380821115611e5057600080fd5b611e5c88838901611d9d565b93506060870135915080821115611e7257600080fd5b50611e7f87828801611d9d565b91505092959194509250565b6001600160a01b0384168152606060208201819052600090611eaf908301856119fc565b8281036040840152611ec181856119fc565b969550505050505056fea264697066735822122033e4a7fc99de8d907b46e0e352c2feaea0b43d47f4a2303e6d491ab60c6afeed64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var RootERC721PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootERC721Predicate","sourceName":"contracts/bridge/RootERC721Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"ERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"ERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"TokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newChildERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061196b806100206000396000f3fe608060405234801561001057600080fd5b50600436106100fb5760003560e01c8063cb10f94c116100a2578063f43cda8b11610071578063f43cda8b146102a1578063f4a120f7146102b4578063f6451255146102c7578063f8c8765e146102ee578063ff6f870c1461030157600080fd5b8063cb10f94c14610227578063d41f177114610240578063d7c9e3ec14610267578063f213159c1461028e57600080fd5b8063150b7a021461010057806347e7ef241461013c5780634fdca69d146101515780637efab4f51461017c57806395c7041c146101a5578063b1768065146101b8578063b68ad1e4146101ed578063c5ac2b1c14610200575b600080fd5b61011e61010e36600461112d565b630a85bd0160e11b949350505050565b6040516001600160e01b031990911681526020015b60405180910390f35b61014f61014a3660046111db565b610314565b005b600254610164906001600160a01b031681565b6040516001600160a01b039091168152602001610133565b61016461018a366004611207565b6004602052600090815260409020546001600160a01b031681565b600154610164906001600160a01b031681565b6101df7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610133565b600354610164906001600160a01b031681565b6101df7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610164906201000090046001600160a01b031681565b6101df7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101df7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61014f61029c36600461122b565b610323565b61014f6102af36600461126c565b610333565b6101646102c2366004611207565b61050a565b6101df7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61014f6102fc3660046112f4565b61086a565b61014f61030f36600461139b565b610a78565b61031f823383610ae0565b5050565b61032e838383610ae0565b505050565b6001546001600160a01b031633146103a05760405162461bcd60e51b815260206004820152602560248201527f526f6f744552433732315072656469636174653a204f4e4c595f455849545f4860448201526422a62822a960d91b60648201526084015b60405180910390fd5b6002546001600160a01b0384811691161461040f5760405162461bcd60e51b815260206004820152602960248201527f526f6f744552433732315072656469636174653a204f4e4c595f4348494c445f60448201526850524544494341544560b81b6064820152608401610397565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961043e60206000848661141d565b61044791611447565b036104665761046161045c826020818661141d565b610c66565b610504565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed261049560206000848661141d565b61049e91611447565b036104ad576104618282610d64565b60405162461bcd60e51b815260206004820152602660248201527f526f6f744552433732315072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b6064820152608401610397565b50505050565b60006001600160a01b03821661056d5760405162461bcd60e51b815260206004820152602260248201527f526f6f744552433732315072656469636174653a20494e56414c49445f544f4b60448201526122a760f11b6064820152608401610397565b6001600160a01b0382811660009081526004602052604090205416156105e15760405162461bcd60e51b815260206004820152602360248201527f526f6f744552433732315072656469636174653a20414c52454144595f4d415060448201526214115160ea1b6064820152608401610397565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261068f92911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03858116600081815260046020819052604080832080546001600160a01b031916878716179055825481516306fdde0360e01b81529151969750620100009004909416946316f198319488947f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad948c9491936306fdde039380840193908290030181865afa15801561072c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610754919081019061148a565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610792573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526107ba919081019061148a565b6040516020016107cd949392919061152c565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016107f9929190611573565b600060405180830381600087803b15801561081357600080fd5b505af1158015610827573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a39392505050565b600054610100900460ff161580801561088a5750600054600160ff909116105b806108a45750303b1580156108a4575060005460ff166001145b6109075760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610397565b6000805460ff19166001179055801561092a576000805461ff0019166101001790555b6001600160a01b0385161580159061094a57506001600160a01b03841615155b801561095e57506001600160a01b03831615155b801561097257506001600160a01b03821615155b6109ce5760405162461bcd60e51b815260206004820152602760248201527f526f6f744552433732315072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b6064820152608401610397565b6000805462010000600160b01b031916620100006001600160a01b038881169190910291909117909155600180546001600160a01b031990811687841617909155600280548216868416179055600380549091169184169190911790558015610a71576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610ad35760405162461bcd60e51b815260206004820152602360248201527f526f6f744552433732315072656469636174653a20494e56414c49445f4c454e60448201526208ea8960eb1b6064820152608401610397565b610a718585858585610ea5565b6000610aeb84611061565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610b1e9033903090879060040161159f565b600060405180830381600087803b158015610b3857600080fd5b505af1158015610b4c573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935262010000909404841695506316f198319450610be2939092169160c401611573565b600060405180830381600087803b158015610bfc57600080fd5b505af1158015610c10573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917f40e242710be14b7d61d3b93e9d56b40df89cc4dbad8bb88da38c8e0c23809ba7910160405180910390a450505050565b6000808080610c77858701876115c3565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610caa57610caa611614565b604051632142170760e11b81526001600160a01b038616906342842e0e90610cda9030908790879060040161159f565b600060405180830381600087803b158015610cf457600080fd5b505af1158015610d08573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f8194f168e6e9e449d05a46936e071a710c0f22634eaadeb5b85a86540123931991015b60405180910390a450505050505050565b6000808080610d75858701876116b3565b6001600160a01b03808516600090815260046020526040902054949950929750909550935016905080610daa57610daa611614565b60005b8251811015610e5557856001600160a01b03166342842e0e30868481518110610dd857610dd86117a5565b6020026020010151868581518110610df257610df26117a5565b60200260200101516040518463ffffffff1660e01b8152600401610e189392919061159f565b600060405180830381600087803b158015610e3257600080fd5b505af1158015610e46573d6000803e3d6000fd5b50505050806001019050610dad565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167f1b7b9713fdef5dfadf92f6d6e998eb1fc4763cee62a194a095d76349f7dce20c8686604051610d539291906117bb565b6000610eb086611061565b905060005b82811015610f4257866001600160a01b03166342842e0e3330878786818110610ee057610ee06117a5565b905060200201356040518463ffffffff1660e01b8152600401610f059392919061159f565b600060405180830381600087803b158015610f1f57600080fd5b505af1158015610f33573d6000803e3d6000fd5b50505050806001019050610eb5565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610fa0907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c906020016118ba565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610fcc929190611573565b600060405180830381600087803b158015610fe657600080fd5b505af1158015610ffa573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f02c575a943105cda454293b7ac636c87c94ff1bfcfac968aa5423e6b9b312ee988888888604051611051949392919061190e565b60405180910390a4505050505050565b6001600160a01b03808216600090815260046020526040902054168061108d5761108a8261050a565b90505b6001600160a01b0381166110a3576110a3611614565b919050565b6001600160a01b03811681146110bd57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156110fe576110fe6110c0565b604052919050565b60006001600160401b0382111561111f5761111f6110c0565b50601f01601f191660200190565b6000806000806080858703121561114357600080fd5b843561114e816110a8565b9350602085013561115e816110a8565b92506040850135915060608501356001600160401b0381111561118057600080fd5b8501601f8101871361119157600080fd5b80356111a461119f82611106565b6110d6565b8181528860208385010111156111b957600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b600080604083850312156111ee57600080fd5b82356111f9816110a8565b946020939093013593505050565b60006020828403121561121957600080fd5b8135611224816110a8565b9392505050565b60008060006060848603121561124057600080fd5b833561124b816110a8565b9250602084013561125b816110a8565b929592945050506040919091013590565b6000806000806060858703121561128257600080fd5b843593506020850135611294816110a8565b925060408501356001600160401b03808211156112b057600080fd5b818701915087601f8301126112c457600080fd5b8135818111156112d357600080fd5b8860208285010111156112e557600080fd5b95989497505060200194505050565b6000806000806080858703121561130a57600080fd5b8435611315816110a8565b93506020850135611325816110a8565b92506040850135611335816110a8565b91506060850135611345816110a8565b939692955090935050565b60008083601f84011261136257600080fd5b5081356001600160401b0381111561137957600080fd5b6020830191508360208260051b850101111561139457600080fd5b9250929050565b6000806000806000606086880312156113b357600080fd5b85356113be816110a8565b945060208601356001600160401b03808211156113da57600080fd5b6113e689838a01611350565b909650945060408801359150808211156113ff57600080fd5b5061140c88828901611350565b969995985093965092949392505050565b6000808585111561142d57600080fd5b8386111561143a57600080fd5b5050820193919092039150565b8035602083101561146057600019602084900360031b1b165b92915050565b60005b83811015611481578181015183820152602001611469565b50506000910152565b60006020828403121561149c57600080fd5b81516001600160401b038111156114b257600080fd5b8201601f810184136114c357600080fd5b80516114d161119f82611106565b8181528560208385010111156114e657600080fd5b6114f7826020830160208601611466565b95945050505050565b60008151808452611518816020860160208601611466565b601f01601f19169290920160200192915050565b8481526001600160a01b038416602082015260806040820181905260009061155690830185611500565b82810360608401526115688185611500565b979650505050505050565b6001600160a01b038316815260406020820181905260009061159790830184611500565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600080600080608085870312156115d957600080fd5b84356115e4816110a8565b935060208501356115f4816110a8565b92506040850135611604816110a8565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611643576116436110c0565b5060051b60200190565b600082601f83011261165e57600080fd5b8135602061166e61119f8361162a565b82815260059290921b8401810191818101908684111561168d57600080fd5b8286015b848110156116a85780358352918301918301611691565b509695505050505050565b600080600080600060a086880312156116cb57600080fd5b853594506020808701356116de816110a8565b945060408701356116ee816110a8565b935060608701356001600160401b038082111561170a57600080fd5b818901915089601f83011261171e57600080fd5b813561172c61119f8261162a565b81815260059190911b8301840190848101908c83111561174b57600080fd5b938501935b82851015611772578435611763816110a8565b82529385019390850190611750565b96505050608089013592508083111561178a57600080fd5b50506117988882890161164d565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b828110156117fd5781516001600160a01b0316845292840192908401906001016117d8565b5050508381038285015284518082528583019183019060005b8181101561183257835183529284019291840191600101611816565b5090979650505050505050565b8183526000602080850194508260005b8581101561187d578135611862816110a8565b6001600160a01b03168752958201959082019060010161184f565b509495945050505050565b81835260006001600160fb1b038311156118a157600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906118ed908301868861183f565b8281036080840152611900818587611888565b9a9950505050505050505050565b60408152600061192260408301868861183f565b828103602084015261156881858761188856fea26469706673582212203c6084a9d9ff8f62cc545fe47a6101a4baacc1785aa62523a70495dc8ed4fb2f64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100fb5760003560e01c8063cb10f94c116100a2578063f43cda8b11610071578063f43cda8b146102a1578063f4a120f7146102b4578063f6451255146102c7578063f8c8765e146102ee578063ff6f870c1461030157600080fd5b8063cb10f94c14610227578063d41f177114610240578063d7c9e3ec14610267578063f213159c1461028e57600080fd5b8063150b7a021461010057806347e7ef241461013c5780634fdca69d146101515780637efab4f51461017c57806395c7041c146101a5578063b1768065146101b8578063b68ad1e4146101ed578063c5ac2b1c14610200575b600080fd5b61011e61010e36600461112d565b630a85bd0160e11b949350505050565b6040516001600160e01b031990911681526020015b60405180910390f35b61014f61014a3660046111db565b610314565b005b600254610164906001600160a01b031681565b6040516001600160a01b039091168152602001610133565b61016461018a366004611207565b6004602052600090815260409020546001600160a01b031681565b600154610164906001600160a01b031681565b6101df7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610133565b600354610164906001600160a01b031681565b6101df7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610164906201000090046001600160a01b031681565b6101df7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101df7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61014f61029c36600461122b565b610323565b61014f6102af36600461126c565b610333565b6101646102c2366004611207565b61050a565b6101df7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61014f6102fc3660046112f4565b61086a565b61014f61030f36600461139b565b610a78565b61031f823383610ae0565b5050565b61032e838383610ae0565b505050565b6001546001600160a01b031633146103a05760405162461bcd60e51b815260206004820152602560248201527f526f6f744552433732315072656469636174653a204f4e4c595f455849545f4860448201526422a62822a960d91b60648201526084015b60405180910390fd5b6002546001600160a01b0384811691161461040f5760405162461bcd60e51b815260206004820152602960248201527f526f6f744552433732315072656469636174653a204f4e4c595f4348494c445f60448201526850524544494341544560b81b6064820152608401610397565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286961043e60206000848661141d565b61044791611447565b036104665761046161045c826020818661141d565b610c66565b610504565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed261049560206000848661141d565b61049e91611447565b036104ad576104618282610d64565b60405162461bcd60e51b815260206004820152602660248201527f526f6f744552433732315072656469636174653a20494e56414c49445f5349476044820152654e415455524560d01b6064820152608401610397565b50505050565b60006001600160a01b03821661056d5760405162461bcd60e51b815260206004820152602260248201527f526f6f744552433732315072656469636174653a20494e56414c49445f544f4b60448201526122a760f11b6064820152608401610397565b6001600160a01b0382811660009081526004602052604090205416156105e15760405162461bcd60e51b815260206004820152602360248201527f526f6f744552433732315072656469636174653a20414c52454144595f4d415060448201526214115160ea1b6064820152608401610397565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b039283169260009261068f92911690603401604051602081830303815290604052805190602001208460405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03858116600081815260046020819052604080832080546001600160a01b031916878716179055825481516306fdde0360e01b81529151969750620100009004909416946316f198319488947f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad948c9491936306fdde039380840193908290030181865afa15801561072c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610754919081019061148a565b896001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610792573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526107ba919081019061148a565b6040516020016107cd949392919061152c565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016107f9929190611573565b600060405180830381600087803b15801561081357600080fd5b505af1158015610827573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a39392505050565b600054610100900460ff161580801561088a5750600054600160ff909116105b806108a45750303b1580156108a4575060005460ff166001145b6109075760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610397565b6000805460ff19166001179055801561092a576000805461ff0019166101001790555b6001600160a01b0385161580159061094a57506001600160a01b03841615155b801561095e57506001600160a01b03831615155b801561097257506001600160a01b03821615155b6109ce5760405162461bcd60e51b815260206004820152602760248201527f526f6f744552433732315072656469636174653a204241445f494e495449414c60448201526624ad20aa24a7a760c91b6064820152608401610397565b6000805462010000600160b01b031916620100006001600160a01b038881169190910291909117909155600180546001600160a01b031990811687841617909155600280548216868416179055600380549091169184169190911790558015610a71576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b828114610ad35760405162461bcd60e51b815260206004820152602360248201527f526f6f744552433732315072656469636174653a20494e56414c49445f4c454e60448201526208ea8960eb1b6064820152608401610397565b610a718585858585610ea5565b6000610aeb84611061565b604051632142170760e11b81529091506001600160a01b038516906342842e0e90610b1e9033903090879060040161159f565b600060405180830381600087803b158015610b3857600080fd5b505af1158015610b4c573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038a811682840152336060830152898116608083015260a08083018a90528351808403909101815260c08301938490526316f1983160e01b90935262010000909404841695506316f198319450610be2939092169160c401611573565b600060405180830381600087803b158015610bfc57600080fd5b505af1158015610c10573d6000803e3d6000fd5b505060408051338152602081018690526001600160a01b03808816945085811693508816917f40e242710be14b7d61d3b93e9d56b40df89cc4dbad8bb88da38c8e0c23809ba7910160405180910390a450505050565b6000808080610c77858701876115c3565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610caa57610caa611614565b604051632142170760e11b81526001600160a01b038616906342842e0e90610cda9030908790879060040161159f565b600060405180830381600087803b158015610cf457600080fd5b505af1158015610d08573d6000803e3d6000fd5b5050604080516001600160a01b03888116825260208201879052808816945085811693508916917f8194f168e6e9e449d05a46936e071a710c0f22634eaadeb5b85a86540123931991015b60405180910390a450505050505050565b6000808080610d75858701876116b3565b6001600160a01b03808516600090815260046020526040902054949950929750909550935016905080610daa57610daa611614565b60005b8251811015610e5557856001600160a01b03166342842e0e30868481518110610dd857610dd86117a5565b6020026020010151868581518110610df257610df26117a5565b60200260200101516040518463ffffffff1660e01b8152600401610e189392919061159f565b600060405180830381600087803b158015610e3257600080fd5b505af1158015610e46573d6000803e3d6000fd5b50505050806001019050610dad565b50836001600160a01b0316816001600160a01b0316866001600160a01b03167f1b7b9713fdef5dfadf92f6d6e998eb1fc4763cee62a194a095d76349f7dce20c8686604051610d539291906117bb565b6000610eb086611061565b905060005b82811015610f4257866001600160a01b03166342842e0e3330878786818110610ee057610ee06117a5565b905060200201356040518463ffffffff1660e01b8152600401610f059392919061159f565b600060405180830381600087803b158015610f1f57600080fd5b505af1158015610f33573d6000803e3d6000fd5b50505050806001019050610eb5565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610fa0907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908b9033908c908c908c908c906020016118ba565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610fcc929190611573565b600060405180830381600087803b158015610fe657600080fd5b505af1158015610ffa573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316876001600160a01b03167f02c575a943105cda454293b7ac636c87c94ff1bfcfac968aa5423e6b9b312ee988888888604051611051949392919061190e565b60405180910390a4505050505050565b6001600160a01b03808216600090815260046020526040902054168061108d5761108a8261050a565b90505b6001600160a01b0381166110a3576110a3611614565b919050565b6001600160a01b03811681146110bd57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156110fe576110fe6110c0565b604052919050565b60006001600160401b0382111561111f5761111f6110c0565b50601f01601f191660200190565b6000806000806080858703121561114357600080fd5b843561114e816110a8565b9350602085013561115e816110a8565b92506040850135915060608501356001600160401b0381111561118057600080fd5b8501601f8101871361119157600080fd5b80356111a461119f82611106565b6110d6565b8181528860208385010111156111b957600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b600080604083850312156111ee57600080fd5b82356111f9816110a8565b946020939093013593505050565b60006020828403121561121957600080fd5b8135611224816110a8565b9392505050565b60008060006060848603121561124057600080fd5b833561124b816110a8565b9250602084013561125b816110a8565b929592945050506040919091013590565b6000806000806060858703121561128257600080fd5b843593506020850135611294816110a8565b925060408501356001600160401b03808211156112b057600080fd5b818701915087601f8301126112c457600080fd5b8135818111156112d357600080fd5b8860208285010111156112e557600080fd5b95989497505060200194505050565b6000806000806080858703121561130a57600080fd5b8435611315816110a8565b93506020850135611325816110a8565b92506040850135611335816110a8565b91506060850135611345816110a8565b939692955090935050565b60008083601f84011261136257600080fd5b5081356001600160401b0381111561137957600080fd5b6020830191508360208260051b850101111561139457600080fd5b9250929050565b6000806000806000606086880312156113b357600080fd5b85356113be816110a8565b945060208601356001600160401b03808211156113da57600080fd5b6113e689838a01611350565b909650945060408801359150808211156113ff57600080fd5b5061140c88828901611350565b969995985093965092949392505050565b6000808585111561142d57600080fd5b8386111561143a57600080fd5b5050820193919092039150565b8035602083101561146057600019602084900360031b1b165b92915050565b60005b83811015611481578181015183820152602001611469565b50506000910152565b60006020828403121561149c57600080fd5b81516001600160401b038111156114b257600080fd5b8201601f810184136114c357600080fd5b80516114d161119f82611106565b8181528560208385010111156114e657600080fd5b6114f7826020830160208601611466565b95945050505050565b60008151808452611518816020860160208601611466565b601f01601f19169290920160200192915050565b8481526001600160a01b038416602082015260806040820181905260009061155690830185611500565b82810360608401526115688185611500565b979650505050505050565b6001600160a01b038316815260406020820181905260009061159790830184611500565b949350505050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600080600080608085870312156115d957600080fd5b84356115e4816110a8565b935060208501356115f4816110a8565b92506040850135611604816110a8565b9396929550929360600135925050565b634e487b7160e01b600052600160045260246000fd5b60006001600160401b03821115611643576116436110c0565b5060051b60200190565b600082601f83011261165e57600080fd5b8135602061166e61119f8361162a565b82815260059290921b8401810191818101908684111561168d57600080fd5b8286015b848110156116a85780358352918301918301611691565b509695505050505050565b600080600080600060a086880312156116cb57600080fd5b853594506020808701356116de816110a8565b945060408701356116ee816110a8565b935060608701356001600160401b038082111561170a57600080fd5b818901915089601f83011261171e57600080fd5b813561172c61119f8261162a565b81815260059190911b8301840190848101908c83111561174b57600080fd5b938501935b82851015611772578435611763816110a8565b82529385019390850190611750565b96505050608089013592508083111561178a57600080fd5b50506117988882890161164d565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b604080825283519082018190526000906020906060840190828701845b828110156117fd5781516001600160a01b0316845292840192908401906001016117d8565b5050508381038285015284518082528583019183019060005b8181101561183257835183529284019291840191600101611816565b5090979650505050505050565b8183526000602080850194508260005b8581101561187d578135611862816110a8565b6001600160a01b03168752958201959082019060010161184f565b509495945050505050565b81835260006001600160fb1b038311156118a157600080fd5b8260051b80836020870137939093016020019392505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906118ed908301868861183f565b8281036080840152611900818587611888565b9a9950505050505050505050565b60408152600061192260408301868861183f565b828103602084015261156881858761188856fea26469706673582212203c6084a9d9ff8f62cc545fe47a6101a4baacc1785aa62523a70495dc8ed4fb2f64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildMintableERC721PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildMintableERC721Predicate","sourceName":"contracts/bridge/ChildMintableERC721Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"MintableERC721Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"MintableERC721DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"MintableERC721Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"MintableERC721WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"MintableTokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newRootERC721Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC721Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC721","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611f01806100206000396000f3fe608060405234801561001057600080fd5b50600436106100d55760003560e01c8063cb10f94c11610087578063cb10f94c146101ca578063d41f1771146101e3578063d7c9e3ec1461020a578063f3fef3a314610231578063f43cda8b14610244578063f645125514610257578063f691325c1461027e578063f8c8765e1461029157600080fd5b80636f33e695146100da5780637efab4f5146100ef57806395c7041c14610135578063b176806514610148578063b68ad1e41461017d578063c3b35a7e14610190578063c5ac2b1c146101a3575b600080fd5b6100ed6100e836600461158c565b6102a4565b005b6101186100fd36600461160e565b6004602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b600154610118906001600160a01b031681565b61016f7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60405190815260200161012c565b600354610118906001600160a01b031681565b6100ed61019e366004611632565b6102b8565b61016f7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610118906201000090046001600160a01b031681565b61016f7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61016f7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6100ed61023f366004611673565b6102c8565b6100ed61025236600461169f565b6102d7565b61016f7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b600254610118906001600160a01b031681565b6100ed61029f366004611727565b61050f565b6102b18585858585610627565b5050505050565b6102c383838361099a565b505050565b6102d382338361099a565b5050565b6001546001600160a01b0316331461034d5760405162461bcd60e51b815260206004820152602e60248201527f4368696c644d696e7461626c654552433732315072656469636174653a204f4e60448201526d262cafa2ac24aa2fa422a62822a960911b60648201526084015b60405180910390fd5b6002546001600160a01b038481169116146103c45760405162461bcd60e51b815260206004820152603160248201527f4368696c644d696e7461626c654552433732315072656469636174653a204f4e6044820152704c595f524f4f545f50524544494341544560781b6064820152608401610344565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216103f3602060008486611783565b6103fc916117ad565b0361041b576104166104118260208186611783565b610ca9565b610509565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1861044a602060008486611783565b610453916117ad565b03610462576104168282610f1f565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad610491602060008486611783565b61049a916117ad565b036104a9576104168282611185565b60405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c654552433732315072656469636174653a20494e60448201526e56414c49445f5349474e415455524560881b6064820152608401610344565b50505050565b600054610100900460ff161580801561052f5750600054600160ff909116105b806105495750303b158015610549575060005460ff166001145b6105ac5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610344565b6000805460ff1916600117905580156105cf576000805461ff0019166101001790555b6105db858585856112f5565b80156102b1576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b84610631816113fd565b61064d5760405162461bcd60e51b8152600401610344906117cb565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561068d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b19190611815565b6001600160a01b038181166000908152600460205260409020549192508881169116146106f05760405162461bcd60e51b815260040161034490611832565b6001600160a01b0381166107065761070661187e565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561074e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107729190611815565b6001600160a01b0316146107885761078861187e565b8483146107ec5760405162461bcd60e51b815260206004820152602c60248201527f4368696c644d696e7461626c654552433732315072656469636174653a20494e60448201526b0ac82989288be988a9c8ea8960a31b6064820152608401610344565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc39061081c903390889088906004016118c6565b6020604051808303816000875af115801561083b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061085f91906118f4565b61087b5760405162461bcd60e51b815260040161034490611916565b6000546002546040516001600160a01b03620100009093048316926316f198319216906108d8907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d906020016119a8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610904929190611a42565b600060405180830381600087803b15801561091e57600080fd5b505af1158015610932573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167f5faed28924bb6c5b0d3eea1cc028b4814f49c39eac622b81ef17035d794ac774898989896040516109899493929190611a6e565b60405180910390a450505050505050565b826109a4816113fd565b6109c05760405162461bcd60e51b8152600401610344906117cb565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a00573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a249190611815565b6001600160a01b03818116600090815260046020526040902054919250868116911614610a635760405162461bcd60e51b815260040161034490611832565b6001600160a01b038116610a7957610a7961187e565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ac1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ae59190611815565b6001600160a01b031614610afb57610afb61187e565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610b299033908790600401611aa0565b6020604051808303816000875af1158015610b48573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b6c91906118f4565b610b885760405162461bcd60e51b815260040161034490611916565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f1983193610c199391169160c401611a42565b600060405180830381600087803b158015610c3357600080fd5b505af1158015610c47573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f85b3d9b3b871daf1d10c7ba1016854e371ab931adef5569172f0289515a9a6de3387604051610c9a929190611aa0565b60405180910390a45050505050565b6000808080610cba85870187611ab9565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610cfd5760405162461bcd60e51b815260040161034490611832565b610d06816113fd565b610d1257610d1261187e565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d52573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d769190611815565b9050856001600160a01b0316816001600160a01b031614610d9957610d9961187e565b6001600160a01b038116610daf57610daf61187e565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610df7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e1b9190611815565b6001600160a01b031614610e3157610e3161187e565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610e5f9087908790600401611aa0565b6020604051808303816000875af1158015610e7e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ea291906118f4565b610ebe5760405162461bcd60e51b815260040161034490611b0a565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fb26f02b79335e4b2c506d9e5ae02e042b464a7556419bbc42522fc92833aff528887604051610f0d929190611aa0565b60405180910390a45050505050505050565b6000808080610f3085870187611c27565b6001600160a01b03808516600090815260046020526040902054949950929750909550935016905080610f755760405162461bcd60e51b815260040161034490611832565b610f7e816113fd565b610f8a57610f8a61187e565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fca573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fee9190611815565b9050856001600160a01b0316816001600160a01b0316146110115761101161187e565b6001600160a01b0381166110275761102761187e565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561106f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110939190611815565b6001600160a01b0316146110a9576110a961187e565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d9906110d79087908790600401611d19565b6020604051808303816000875af11580156110f6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061111a91906118f4565b6111365760405162461bcd60e51b815260040161034490611b0a565b846001600160a01b0316826001600160a01b0316876001600160a01b03167f7f51e520a281df2deae2754a9232b5a78c8cfeae79568668a0a97a116e1401b88787604051610f0d929190611d19565b6000808061119584860186611e0c565b91955093509150506001600160a01b0383166111b3576111b361187e565b6001600160a01b0383811660009081526004602052604090205416156111db576111db61187e565b6003546040516bffffffffffffffffffffffff19606086901b16602082015260009161122b916001600160a01b039091169060340160405160208183030381529060405280519060200120611492565b6001600160a01b0385811660009081526004602081905260409182902080546001600160a01b03191693851693841790559051639065714760e01b815292935090916390657147916112839188918891889101611e8b565b600060405180830381600087803b15801561129d57600080fd5b505af11580156112b1573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a3505050505050565b6001600160a01b0384161580159061131557506001600160a01b03831615155b801561132957506001600160a01b03821615155b801561133d57506001600160a01b03811615155b6113a25760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c654552433732315072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b6064820152608401610344565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000816001600160a01b03163b60000361141957506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611480575060408051601f3d908101601f1916820190925261147d918101906118f4565b60015b61148c57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b03811661148c5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610344565b6001600160a01b038116811461153e57600080fd5b50565b60008083601f84011261155357600080fd5b5081356001600160401b0381111561156a57600080fd5b6020830191508360208260051b850101111561158557600080fd5b9250929050565b6000806000806000606086880312156115a457600080fd5b85356115af81611529565b945060208601356001600160401b03808211156115cb57600080fd5b6115d789838a01611541565b909650945060408801359150808211156115f057600080fd5b506115fd88828901611541565b969995985093965092949392505050565b60006020828403121561162057600080fd5b813561162b81611529565b9392505050565b60008060006060848603121561164757600080fd5b833561165281611529565b9250602084013561166281611529565b929592945050506040919091013590565b6000806040838503121561168657600080fd5b823561169181611529565b946020939093013593505050565b600080600080606085870312156116b557600080fd5b8435935060208501356116c781611529565b925060408501356001600160401b03808211156116e357600080fd5b818701915087601f8301126116f757600080fd5b81358181111561170657600080fd5b88602082850101111561171857600080fd5b95989497505060200194505050565b6000806000806080858703121561173d57600080fd5b843561174881611529565b9350602085013561175881611529565b9250604085013561176881611529565b9150606085013561177881611529565b939692955090935050565b6000808585111561179357600080fd5b838611156117a057600080fd5b5050820193919092039150565b8035602083101561148c57600019602084900360031b1b1692915050565b6020808252602a908201527f4368696c644d696e7461626c654552433732315072656469636174653a204e4f6040820152691517d0d3d395149050d560b21b606082015260800190565b60006020828403121561182757600080fd5b815161162b81611529565b6020808252602c908201527f4368696c644d696e7461626c654552433732315072656469636174653a20554e60408201526b26a0a82822a22faa27a5a2a760a11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156118ad57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b03841681526040602082018190526000906118eb9083018486611894565b95945050505050565b60006020828403121561190657600080fd5b8151801515811461162b57600080fd5b60208082526029908201527f4368696c644d696e7461626c654552433732315072656469636174653a204255604082015268149397d1905253115160ba1b606082015260800190565b8183526000602080850194508260005b8581101561199d57813561198281611529565b6001600160a01b03168752958201959082019060010161196f565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906119db908301868861195f565b82810360808401526119ee818587611894565b9a9950505050505050505050565b6000815180845260005b81811015611a2257602081850181015186830182015201611a06565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611a66908301846119fc565b949350505050565b604081526000611a8260408301868861195f565b8281036020840152611a95818587611894565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611acf57600080fd5b8435611ada81611529565b93506020850135611aea81611529565b92506040850135611afa81611529565b9396929550929360600135925050565b60208082526029908201527f4368696c644d696e7461626c654552433732315072656469636174653a204d49604082015268139517d1905253115160ba1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611b9157611b91611b53565b604052919050565b60006001600160401b03821115611bb257611bb2611b53565b5060051b60200190565b600082601f830112611bcd57600080fd5b81356020611be2611bdd83611b99565b611b69565b82815260059290921b84018101918181019086841115611c0157600080fd5b8286015b84811015611c1c5780358352918301918301611c05565b509695505050505050565b600080600080600060a08688031215611c3f57600080fd5b85359450602080870135611c5281611529565b94506040870135611c6281611529565b935060608701356001600160401b0380821115611c7e57600080fd5b818901915089601f830112611c9257600080fd5b8135611ca0611bdd82611b99565b81815260059190911b8301840190848101908c831115611cbf57600080fd5b938501935b82851015611ce6578435611cd781611529565b82529385019390850190611cc4565b965050506080890135925080831115611cfe57600080fd5b5050611d0c88828901611bbc565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b82811015611d5b5781516001600160a01b031684529284019290840190600101611d36565b5050508381038285015284518082528583019183019060005b81811015611d9057835183529284019291840191600101611d74565b5090979650505050505050565b600082601f830112611dae57600080fd5b81356001600160401b03811115611dc757611dc7611b53565b611dda601f8201601f1916602001611b69565b818152846020838601011115611def57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611e2257600080fd5b843593506020850135611e3481611529565b925060408501356001600160401b0380821115611e5057600080fd5b611e5c88838901611d9d565b93506060870135915080821115611e7257600080fd5b50611e7f87828801611d9d565b91505092959194509250565b6001600160a01b0384168152606060208201819052600090611eaf908301856119fc565b8281036040840152611ec181856119fc565b969550505050505056fea2646970667358221220a3c5bc8d89d41f194f25c3ff6ce294b9df5c24e384c7b3e65754714eea570b3a64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100d55760003560e01c8063cb10f94c11610087578063cb10f94c146101ca578063d41f1771146101e3578063d7c9e3ec1461020a578063f3fef3a314610231578063f43cda8b14610244578063f645125514610257578063f691325c1461027e578063f8c8765e1461029157600080fd5b80636f33e695146100da5780637efab4f5146100ef57806395c7041c14610135578063b176806514610148578063b68ad1e41461017d578063c3b35a7e14610190578063c5ac2b1c146101a3575b600080fd5b6100ed6100e836600461158c565b6102a4565b005b6101186100fd36600461160e565b6004602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b600154610118906001600160a01b031681565b61016f7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b60405190815260200161012c565b600354610118906001600160a01b031681565b6100ed61019e366004611632565b6102b8565b61016f7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610118906201000090046001600160a01b031681565b61016f7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b61016f7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6100ed61023f366004611673565b6102c8565b6100ed61025236600461169f565b6102d7565b61016f7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b600254610118906001600160a01b031681565b6100ed61029f366004611727565b61050f565b6102b18585858585610627565b5050505050565b6102c383838361099a565b505050565b6102d382338361099a565b5050565b6001546001600160a01b0316331461034d5760405162461bcd60e51b815260206004820152602e60248201527f4368696c644d696e7461626c654552433732315072656469636174653a204f4e60448201526d262cafa2ac24aa2fa422a62822a960911b60648201526084015b60405180910390fd5b6002546001600160a01b038481169116146103c45760405162461bcd60e51b815260206004820152603160248201527f4368696c644d696e7461626c654552433732315072656469636174653a204f4e6044820152704c595f524f4f545f50524544494341544560781b6064820152608401610344565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216103f3602060008486611783565b6103fc916117ad565b0361041b576104166104118260208186611783565b610ca9565b610509565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1861044a602060008486611783565b610453916117ad565b03610462576104168282610f1f565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad610491602060008486611783565b61049a916117ad565b036104a9576104168282611185565b60405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c654552433732315072656469636174653a20494e60448201526e56414c49445f5349474e415455524560881b6064820152608401610344565b50505050565b600054610100900460ff161580801561052f5750600054600160ff909116105b806105495750303b158015610549575060005460ff166001145b6105ac5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610344565b6000805460ff1916600117905580156105cf576000805461ff0019166101001790555b6105db858585856112f5565b80156102b1576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050505050565b84610631816113fd565b61064d5760405162461bcd60e51b8152600401610344906117cb565b6000866001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa15801561068d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b19190611815565b6001600160a01b038181166000908152600460205260409020549192508881169116146106f05760405162461bcd60e51b815260040161034490611832565b6001600160a01b0381166107065761070661187e565b306001600160a01b0316876001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561074e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107729190611815565b6001600160a01b0316146107885761078861187e565b8483146107ec5760405162461bcd60e51b815260206004820152602c60248201527f4368696c644d696e7461626c654552433732315072656469636174653a20494e60448201526b0ac82989288be988a9c8ea8960a31b6064820152608401610344565b60405163b2dc5dc360e01b81526001600160a01b0388169063b2dc5dc39061081c903390889088906004016118c6565b6020604051808303816000875af115801561083b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061085f91906118f4565b61087b5760405162461bcd60e51b815260040161034490611916565b6000546002546040516001600160a01b03620100009093048316926316f198319216906108d8907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908d908d908d908d906020016119a8565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610904929190611a42565b600060405180830381600087803b15801561091e57600080fd5b505af1158015610932573d6000803e3d6000fd5b50505050336001600160a01b0316876001600160a01b0316826001600160a01b03167f5faed28924bb6c5b0d3eea1cc028b4814f49c39eac622b81ef17035d794ac774898989896040516109899493929190611a6e565b60405180910390a450505050505050565b826109a4816113fd565b6109c05760405162461bcd60e51b8152600401610344906117cb565b6000846001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a00573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a249190611815565b6001600160a01b03818116600090815260046020526040902054919250868116911614610a635760405162461bcd60e51b815260040161034490611832565b6001600160a01b038116610a7957610a7961187e565b306001600160a01b0316856001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ac1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ae59190611815565b6001600160a01b031614610afb57610afb61187e565b604051632770a7eb60e21b81526001600160a01b03861690639dc29fac90610b299033908790600401611aa0565b6020604051808303816000875af1158015610b48573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b6c91906118f4565b610b885760405162461bcd60e51b815260040161034490611916565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152888116608083015260a08083018990528351808403909101815260c08301938490526316f1983160e01b909352620100009094048416936316f1983193610c199391169160c401611a42565b600060405180830381600087803b158015610c3357600080fd5b505af1158015610c47573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b0316826001600160a01b03167f85b3d9b3b871daf1d10c7ba1016854e371ab931adef5569172f0289515a9a6de3387604051610c9a929190611aa0565b60405180910390a45050505050565b6000808080610cba85870187611ab9565b6001600160a01b0380851660009081526004602052604090205494985092965090945092501680610cfd5760405162461bcd60e51b815260040161034490611832565b610d06816113fd565b610d1257610d1261187e565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d52573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d769190611815565b9050856001600160a01b0316816001600160a01b031614610d9957610d9961187e565b6001600160a01b038116610daf57610daf61187e565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610df7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e1b9190611815565b6001600160a01b031614610e3157610e3161187e565b6040516340c10f1960e01b81526001600160a01b038316906340c10f1990610e5f9087908790600401611aa0565b6020604051808303816000875af1158015610e7e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ea291906118f4565b610ebe5760405162461bcd60e51b815260040161034490611b0a565b836001600160a01b0316826001600160a01b0316876001600160a01b03167fb26f02b79335e4b2c506d9e5ae02e042b464a7556419bbc42522fc92833aff528887604051610f0d929190611aa0565b60405180910390a45050505050505050565b6000808080610f3085870187611c27565b6001600160a01b03808516600090815260046020526040902054949950929750909550935016905080610f755760405162461bcd60e51b815260040161034490611832565b610f7e816113fd565b610f8a57610f8a61187e565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fca573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fee9190611815565b9050856001600160a01b0316816001600160a01b0316146110115761101161187e565b6001600160a01b0381166110275761102761187e565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa15801561106f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110939190611815565b6001600160a01b0316146110a9576110a961187e565b604051637c88e3d960e01b81526001600160a01b03831690637c88e3d9906110d79087908790600401611d19565b6020604051808303816000875af11580156110f6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061111a91906118f4565b6111365760405162461bcd60e51b815260040161034490611b0a565b846001600160a01b0316826001600160a01b0316876001600160a01b03167f7f51e520a281df2deae2754a9232b5a78c8cfeae79568668a0a97a116e1401b88787604051610f0d929190611d19565b6000808061119584860186611e0c565b91955093509150506001600160a01b0383166111b3576111b361187e565b6001600160a01b0383811660009081526004602052604090205416156111db576111db61187e565b6003546040516bffffffffffffffffffffffff19606086901b16602082015260009161122b916001600160a01b039091169060340160405160208183030381529060405280519060200120611492565b6001600160a01b0385811660009081526004602081905260409182902080546001600160a01b03191693851693841790559051639065714760e01b815292935090916390657147916112839188918891889101611e8b565b600060405180830381600087803b15801561129d57600080fd5b505af11580156112b1573d6000803e3d6000fd5b50506040516001600160a01b038085169350871691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a3505050505050565b6001600160a01b0384161580159061131557506001600160a01b03831615155b801561132957506001600160a01b03821615155b801561133d57506001600160a01b03811615155b6113a25760405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c654552433732315072656469636174653a20424160448201526f222fa4a724aa24a0a624ad20aa24a7a760811b6064820152608401610344565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000816001600160a01b03163b60000361141957506000919050565b6040516301ffc9a760e01b81526380ac58cd60e01b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa925050508015611480575060408051601f3d908101601f1916820190925261147d918101906118f4565b60015b61148c57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b03811661148c5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b6044820152606401610344565b6001600160a01b038116811461153e57600080fd5b50565b60008083601f84011261155357600080fd5b5081356001600160401b0381111561156a57600080fd5b6020830191508360208260051b850101111561158557600080fd5b9250929050565b6000806000806000606086880312156115a457600080fd5b85356115af81611529565b945060208601356001600160401b03808211156115cb57600080fd5b6115d789838a01611541565b909650945060408801359150808211156115f057600080fd5b506115fd88828901611541565b969995985093965092949392505050565b60006020828403121561162057600080fd5b813561162b81611529565b9392505050565b60008060006060848603121561164757600080fd5b833561165281611529565b9250602084013561166281611529565b929592945050506040919091013590565b6000806040838503121561168657600080fd5b823561169181611529565b946020939093013593505050565b600080600080606085870312156116b557600080fd5b8435935060208501356116c781611529565b925060408501356001600160401b03808211156116e357600080fd5b818701915087601f8301126116f757600080fd5b81358181111561170657600080fd5b88602082850101111561171857600080fd5b95989497505060200194505050565b6000806000806080858703121561173d57600080fd5b843561174881611529565b9350602085013561175881611529565b9250604085013561176881611529565b9150606085013561177881611529565b939692955090935050565b6000808585111561179357600080fd5b838611156117a057600080fd5b5050820193919092039150565b8035602083101561148c57600019602084900360031b1b1692915050565b6020808252602a908201527f4368696c644d696e7461626c654552433732315072656469636174653a204e4f6040820152691517d0d3d395149050d560b21b606082015260800190565b60006020828403121561182757600080fd5b815161162b81611529565b6020808252602c908201527f4368696c644d696e7461626c654552433732315072656469636174653a20554e60408201526b26a0a82822a22faa27a5a2a760a11b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b038311156118ad57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b03841681526040602082018190526000906118eb9083018486611894565b95945050505050565b60006020828403121561190657600080fd5b8151801515811461162b57600080fd5b60208082526029908201527f4368696c644d696e7461626c654552433732315072656469636174653a204255604082015268149397d1905253115160ba1b606082015260800190565b8183526000602080850194508260005b8581101561199d57813561198281611529565b6001600160a01b03168752958201959082019060010161196f565b509495945050505050565b8781526001600160a01b0387811660208301528616604082015260a0606082018190526000906119db908301868861195f565b82810360808401526119ee818587611894565b9a9950505050505050505050565b6000815180845260005b81811015611a2257602081850181015186830182015201611a06565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611a66908301846119fc565b949350505050565b604081526000611a8260408301868861195f565b8281036020840152611a95818587611894565b979650505050505050565b6001600160a01b03929092168252602082015260400190565b60008060008060808587031215611acf57600080fd5b8435611ada81611529565b93506020850135611aea81611529565b92506040850135611afa81611529565b9396929550929360600135925050565b60208082526029908201527f4368696c644d696e7461626c654552433732315072656469636174653a204d49604082015268139517d1905253115160ba1b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611b9157611b91611b53565b604052919050565b60006001600160401b03821115611bb257611bb2611b53565b5060051b60200190565b600082601f830112611bcd57600080fd5b81356020611be2611bdd83611b99565b611b69565b82815260059290921b84018101918181019086841115611c0157600080fd5b8286015b84811015611c1c5780358352918301918301611c05565b509695505050505050565b600080600080600060a08688031215611c3f57600080fd5b85359450602080870135611c5281611529565b94506040870135611c6281611529565b935060608701356001600160401b0380821115611c7e57600080fd5b818901915089601f830112611c9257600080fd5b8135611ca0611bdd82611b99565b81815260059190911b8301840190848101908c831115611cbf57600080fd5b938501935b82851015611ce6578435611cd781611529565b82529385019390850190611cc4565b965050506080890135925080831115611cfe57600080fd5b5050611d0c88828901611bbc565b9150509295509295909350565b604080825283519082018190526000906020906060840190828701845b82811015611d5b5781516001600160a01b031684529284019290840190600101611d36565b5050508381038285015284518082528583019183019060005b81811015611d9057835183529284019291840191600101611d74565b5090979650505050505050565b600082601f830112611dae57600080fd5b81356001600160401b03811115611dc757611dc7611b53565b611dda601f8201601f1916602001611b69565b818152846020838601011115611def57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611e2257600080fd5b843593506020850135611e3481611529565b925060408501356001600160401b0380821115611e5057600080fd5b611e5c88838901611d9d565b93506060870135915080821115611e7257600080fd5b50611e7f87828801611d9d565b91505092959194509250565b6001600160a01b0384168152606060208201819052600090611eaf908301856119fc565b8281036040840152611ec181856119fc565b969550505050505056fea2646970667358221220a3c5bc8d89d41f194f25c3ff6ce294b9df5c24e384c7b3e65754714eea570b3a64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` var MockERC1155Artifact string = `{"_format":"hh-sol-artifact-1","contractName":"MockERC1155","sourceName":"contracts/mocks/MockERC1155.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"TransferBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferSingle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"value","type":"string"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"URI","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PAUSER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"balanceOfBatch","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"burnBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getRoleMember","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleMemberCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"mintBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeBatchTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"uri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"}],"bytecode":"0x60806040523480156200001157600080fd5b506040805180820190915260058152646c6f72656d60d81b6020820152806200003a81620000b1565b506005805460ff1916905562000052600033620000c3565b6200007e7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a633620000c3565b620000aa7f65d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862a33620000c3565b5062000376565b6004620000bf8282620002aa565b5050565b620000bf8282620000d58282620000f4565b6000828152600160205260409020620000ef908262000194565b505050565b6000828152602081815260408083206001600160a01b038516845290915290205460ff16620000bf576000828152602081815260408083206001600160a01b03851684529091529020805460ff19166001179055620001503390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000620001ab836001600160a01b038416620001b4565b90505b92915050565b6000818152600183016020526040812054620001fd57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155620001ae565b506000620001ae565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200023157607f821691505b6020821081036200025257634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620000ef57600081815260208120601f850160051c81016020861015620002815750805b601f850160051c820191505b81811015620002a2578281556001016200028d565b505050505050565b81516001600160401b03811115620002c657620002c662000206565b620002de81620002d784546200021c565b8462000258565b602080601f831160018114620003165760008415620002fd5750858301515b600019600386901b1c1916600185901b178555620002a2565b600085815260208120601f198616915b82811015620003475788860151825594840194600190910190840162000326565b5085821015620003665787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6128a080620003866000396000f3fe608060405234801561001057600080fd5b50600436106101625760003560e01c8063731133e9116100ce578063ca15c87311610087578063ca15c873146102fb578063d53913931461030e578063d547741f14610323578063e63ab1e914610336578063e985e9c51461034b578063f242432a14610387578063f5298aca1461039a57600080fd5b8063731133e9146102875780638456cb591461029a5780639010d07c146102a257806391d14854146102cd578063a217fddf146102e0578063a22cb465146102e857600080fd5b80632f2ff15d116101205780632f2ff15d1461021b57806336568abe1461022e5780633f4ba83a146102415780634e1273f4146102495780635c975abb146102695780636b20c4541461027457600080fd5b8062fdd58e1461016757806301ffc9a71461018d5780630e89341c146101b05780631f7fdffa146101d0578063248a9ca3146101e55780632eb2c2d614610208575b600080fd5b61017a610175366004611bd7565b6103ad565b6040519081526020015b60405180910390f35b6101a061019b366004611c17565b610448565b6040519015158152602001610184565b6101c36101be366004611c34565b610453565b6040516101849190611c9d565b6101e36101de366004611df9565b6104e7565b005b61017a6101f3366004611c34565b60009081526020819052604090206001015490565b6101e3610216366004611e91565b61052d565b6101e3610229366004611f3a565b610579565b6101e361023c366004611f3a565b6105a3565b6101e3610621565b61025c610257366004611f66565b6106a3565b604051610184919061206b565b60055460ff166101a0565b6101e361028236600461207e565b6107cc565b6101e36102953660046120f1565b61080f565b6101e361084f565b6102b56102b0366004612145565b6108cb565b6040516001600160a01b039091168152602001610184565b6101a06102db366004611f3a565b6108ea565b61017a600081565b6101e36102f6366004612167565b610913565b61017a610309366004611c34565b61091e565b61017a60008051602061284b83398151915281565b6101e3610331366004611f3a565b610935565b61017a60008051602061282b83398151915281565b6101a06103593660046121a3565b6001600160a01b03918216600090815260036020908152604080832093909416825291909152205460ff1690565b6101e36103953660046121cd565b61095a565b6101e36103a8366004612231565b61099f565b60006001600160a01b03831661041d5760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b5060008181526002602090815260408083206001600160a01b03861684529091529020545b92915050565b6000610442826109e2565b60606004805461046290612264565b80601f016020809104026020016040519081016040528092919081815260200182805461048e90612264565b80156104db5780601f106104b0576101008083540402835291602001916104db565b820191906000526020600020905b8154815290600101906020018083116104be57829003601f168201915b50505050509050919050565b6104ff60008051602061284b833981519152336108ea565b61051b5760405162461bcd60e51b81526004016104149061229e565b61052784848484610a22565b50505050565b6001600160a01b03851633148061054957506105498533610359565b6105655760405162461bcd60e51b8152600401610414906122e4565b6105728585858585610b6b565b5050505050565b60008281526020819052604090206001015461059481610d06565b61059e8383610d13565b505050565b6001600160a01b03811633146106135760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610414565b61061d8282610d35565b5050565b61063960008051602061282b833981519152336108ea565b6106995760405162461bcd60e51b815260206004820152603b60248201526000805160206127eb83398151915260448201527f686176652070617573657220726f6c6520746f20756e706175736500000000006064820152608401610414565b6106a1610d57565b565b606081518351146107085760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610414565b600083516001600160401b0381111561072357610723611cb0565b60405190808252806020026020018201604052801561074c578160200160208202803683370190505b50905060005b84518110156107c45761079785828151811061077057610770612332565b602002602001015185838151811061078a5761078a612332565b60200260200101516103ad565b8282815181106107a9576107a9612332565b60209081029190910101526107bd8161235e565b9050610752565b509392505050565b6001600160a01b0383163314806107e857506107e88333610359565b6108045760405162461bcd60e51b8152600401610414906122e4565b61059e838383610da9565b61082760008051602061284b833981519152336108ea565b6108435760405162461bcd60e51b81526004016104149061229e565b61052784848484610f36565b61086760008051602061282b833981519152336108ea565b6108c35760405162461bcd60e51b815260206004820152603960248201526000805160206127eb833981519152604482015278686176652070617573657220726f6c6520746f20706175736560381b6064820152608401610414565b6106a161100f565b60008281526001602052604081206108e3908361104c565b9392505050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b61061d338383611058565b600081815260016020526040812061044290611138565b60008281526020819052604090206001015461095081610d06565b61059e8383610d35565b6001600160a01b03851633148061097657506109768533610359565b6109925760405162461bcd60e51b8152600401610414906122e4565b6105728585858585611142565b6001600160a01b0383163314806109bb57506109bb8333610359565b6109d75760405162461bcd60e51b8152600401610414906122e4565b61059e83838361126c565b60006001600160e01b03198216636cdb3d1360e11b1480610a1357506001600160e01b031982166303a24d0760e21b145b80610442575061044282611376565b6001600160a01b038416610a485760405162461bcd60e51b815260040161041490612377565b8151835114610a695760405162461bcd60e51b8152600401610414906123b8565b33610a798160008787878761139b565b60005b8451811015610b1557838181518110610a9757610a97612332565b602002602001015160026000878481518110610ab557610ab5612332565b602002602001015181526020019081526020016000206000886001600160a01b03166001600160a01b031681526020019081526020016000206000828254610afd9190612400565b90915550819050610b0d8161235e565b915050610a7c565b50846001600160a01b031660006001600160a01b0316826001600160a01b03166000805160206127cb8339815191528787604051610b54929190612413565b60405180910390a4610572816000878787876113a9565b8151835114610b8c5760405162461bcd60e51b8152600401610414906123b8565b6001600160a01b038416610bb25760405162461bcd60e51b815260040161041490612441565b33610bc181878787878761139b565b60005b8451811015610caa576000858281518110610be157610be1612332565b602002602001015190506000858381518110610bff57610bff612332565b60209081029190910181015160008481526002835260408082206001600160a01b038e168352909352919091205490915081811015610c505760405162461bcd60e51b815260040161041490612486565b60008381526002602090815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290610c8f908490612400565b9250508190555050505080610ca39061235e565b9050610bc4565b50846001600160a01b0316866001600160a01b0316826001600160a01b03166000805160206127cb8339815191528787604051610ce8929190612413565b60405180910390a4610cfe8187878787876113a9565b505050505050565b610d108133611504565b50565b610d1d828261155d565b600082815260016020526040902061059e90826115e1565b610d3f82826115f6565b600082815260016020526040902061059e908261165b565b610d5f611670565b6005805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6001600160a01b038316610dcf5760405162461bcd60e51b8152600401610414906124d0565b8051825114610df05760405162461bcd60e51b8152600401610414906123b8565b6000339050610e138185600086866040518060200160405280600081525061139b565b60005b8351811015610edb576000848281518110610e3357610e33612332565b602002602001015190506000848381518110610e5157610e51612332565b60209081029190910181015160008481526002835260408082206001600160a01b038c168352909352919091205490915081811015610ea25760405162461bcd60e51b815260040161041490612513565b60009283526002602090815260408085206001600160a01b038b1686529091529092209103905580610ed38161235e565b915050610e16565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03166000805160206127cb8339815191528686604051610f1a929190612413565b60405180910390a4604080516020810190915260009052610527565b6001600160a01b038416610f5c5760405162461bcd60e51b815260040161041490612377565b336000610f68856116b9565b90506000610f75856116b9565b9050610f868360008985858961139b565b60008681526002602090815260408083206001600160a01b038b16845290915281208054879290610fb8908490612400565b909155505060408051878152602081018790526001600160a01b03808a16926000929187169160008051602061280b833981519152910160405180910390a461100683600089898989611704565b50505050505050565b6110176117bf565b6005805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610d8c3390565b60006108e38383611805565b816001600160a01b0316836001600160a01b0316036110cb5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610414565b6001600160a01b03838116600081815260036020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6000610442825490565b6001600160a01b0384166111685760405162461bcd60e51b815260040161041490612441565b336000611174856116b9565b90506000611181856116b9565b905061119183898985858961139b565b60008681526002602090815260408083206001600160a01b038c168452909152902054858110156111d45760405162461bcd60e51b815260040161041490612486565b60008781526002602090815260408083206001600160a01b038d8116855292528083208985039055908a16825281208054889290611213908490612400565b909155505060408051888152602081018890526001600160a01b03808b16928c8216929188169160008051602061280b833981519152910160405180910390a4611261848a8a8a8a8a611704565b505050505050505050565b6001600160a01b0383166112925760405162461bcd60e51b8152600401610414906124d0565b33600061129e846116b9565b905060006112ab846116b9565b90506112cb8387600085856040518060200160405280600081525061139b565b60008581526002602090815260408083206001600160a01b038a1684529091529020548481101561130e5760405162461bcd60e51b815260040161041490612513565b60008681526002602090815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a905290929088169160008051602061280b833981519152910160405180910390a4604080516020810190915260009052611006565b60006001600160e01b03198216635a05180f60e01b148061044257506104428261182f565b610cfe868686868686611864565b6001600160a01b0384163b15610cfe5760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906113ed9089908990889088908890600401612557565b6020604051808303816000875af1925050508015611428575060408051601f3d908101601f19168201909252611425918101906125b5565b60015b6114d4576114346125d2565b806308c379a00361146d57506114486125ee565b80611453575061146f565b8060405162461bcd60e51b81526004016104149190611c9d565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e2d455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610414565b6001600160e01b0319811663bc197c8160e01b146110065760405162461bcd60e51b815260040161041490612677565b61150e82826108ea565b61061d5761151b816118cc565b6115268360206118de565b6040516020016115379291906126bf565b60408051601f198184030181529082905262461bcd60e51b825261041491600401611c9d565b61156782826108ea565b61061d576000828152602081815260408083206001600160a01b03851684529091529020805460ff1916600117905561159d3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b60006108e3836001600160a01b038416611a79565b61160082826108ea565b1561061d576000828152602081815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b60006108e3836001600160a01b038416611ac8565b60055460ff166106a15760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610414565b604080516001808252818301909252606091600091906020808301908036833701905050905082816000815181106116f3576116f3612332565b602090810291909101015292915050565b6001600160a01b0384163b15610cfe5760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190611748908990899088908890889060040161272e565b6020604051808303816000875af1925050508015611783575060408051601f3d908101601f19168201909252611780918101906125b5565b60015b61178f576114346125d2565b6001600160e01b0319811663f23a6e6160e01b146110065760405162461bcd60e51b815260040161041490612677565b60055460ff16156106a15760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610414565b600082600001828154811061181c5761181c612332565b9060005260206000200154905092915050565b60006001600160e01b03198216637965db0b60e01b148061044257506301ffc9a760e01b6001600160e01b0319831614610442565b60055460ff1615610cfe5760405162461bcd60e51b815260206004820152602c60248201527f455243313135355061757361626c653a20746f6b656e207472616e736665722060448201526b1dda1a5b19481c185d5cd95960a21b6064820152608401610414565b60606104426001600160a01b03831660145b606060006118ed836002612773565b6118f8906002612400565b6001600160401b0381111561190f5761190f611cb0565b6040519080825280601f01601f191660200182016040528015611939576020820181803683370190505b509050600360fc1b8160008151811061195457611954612332565b60200101906001600160f81b031916908160001a905350600f60fb1b8160018151811061198357611983612332565b60200101906001600160f81b031916908160001a90535060006119a7846002612773565b6119b2906001612400565b90505b6001811115611a2a576f181899199a1a9b1b9c1cb0b131b232b360811b85600f16601081106119e6576119e6612332565b1a60f81b8282815181106119fc576119fc612332565b60200101906001600160f81b031916908160001a90535060049490941c93611a238161278a565b90506119b5565b5083156108e35760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610414565b6000818152600183016020526040812054611ac057508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610442565b506000610442565b60008181526001830160205260408120548015611bb1576000611aec6001836127a1565b8554909150600090611b00906001906127a1565b9050818114611b65576000866000018281548110611b2057611b20612332565b9060005260206000200154905080876000018481548110611b4357611b43612332565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080611b7657611b766127b4565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610442565b6000915050610442565b80356001600160a01b0381168114611bd257600080fd5b919050565b60008060408385031215611bea57600080fd5b611bf383611bbb565b946020939093013593505050565b6001600160e01b031981168114610d1057600080fd5b600060208284031215611c2957600080fd5b81356108e381611c01565b600060208284031215611c4657600080fd5b5035919050565b60005b83811015611c68578181015183820152602001611c50565b50506000910152565b60008151808452611c89816020860160208601611c4d565b601f01601f19169290920160200192915050565b6020815260006108e36020830184611c71565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b0381118282101715611ceb57611ceb611cb0565b6040525050565b60006001600160401b03821115611d0b57611d0b611cb0565b5060051b60200190565b600082601f830112611d2657600080fd5b81356020611d3382611cf2565b604051611d408282611cc6565b83815260059390931b8501820192828101915086841115611d6057600080fd5b8286015b84811015611d7b5780358352918301918301611d64565b509695505050505050565b600082601f830112611d9757600080fd5b81356001600160401b03811115611db057611db0611cb0565b604051611dc7601f8301601f191660200182611cc6565b818152846020838601011115611ddc57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611e0f57600080fd5b611e1885611bbb565b935060208501356001600160401b0380821115611e3457600080fd5b611e4088838901611d15565b94506040870135915080821115611e5657600080fd5b611e6288838901611d15565b93506060870135915080821115611e7857600080fd5b50611e8587828801611d86565b91505092959194509250565b600080600080600060a08688031215611ea957600080fd5b611eb286611bbb565b9450611ec060208701611bbb565b935060408601356001600160401b0380821115611edc57600080fd5b611ee889838a01611d15565b94506060880135915080821115611efe57600080fd5b611f0a89838a01611d15565b93506080880135915080821115611f2057600080fd5b50611f2d88828901611d86565b9150509295509295909350565b60008060408385031215611f4d57600080fd5b82359150611f5d60208401611bbb565b90509250929050565b60008060408385031215611f7957600080fd5b82356001600160401b0380821115611f9057600080fd5b818501915085601f830112611fa457600080fd5b81356020611fb182611cf2565b604051611fbe8282611cc6565b83815260059390931b8501820192828101915089841115611fde57600080fd5b948201945b8386101561200357611ff486611bbb565b82529482019490820190611fe3565b9650508601359250508082111561201957600080fd5b5061202685828601611d15565b9150509250929050565b600081518084526020808501945080840160005b8381101561206057815187529582019590820190600101612044565b509495945050505050565b6020815260006108e36020830184612030565b60008060006060848603121561209357600080fd5b61209c84611bbb565b925060208401356001600160401b03808211156120b857600080fd5b6120c487838801611d15565b935060408601359150808211156120da57600080fd5b506120e786828701611d15565b9150509250925092565b6000806000806080858703121561210757600080fd5b61211085611bbb565b9350602085013592506040850135915060608501356001600160401b0381111561213957600080fd5b611e8587828801611d86565b6000806040838503121561215857600080fd5b50508035926020909101359150565b6000806040838503121561217a57600080fd5b61218383611bbb565b91506020830135801515811461219857600080fd5b809150509250929050565b600080604083850312156121b657600080fd5b6121bf83611bbb565b9150611f5d60208401611bbb565b600080600080600060a086880312156121e557600080fd5b6121ee86611bbb565b94506121fc60208701611bbb565b9350604086013592506060860135915060808601356001600160401b0381111561222557600080fd5b611f2d88828901611d86565b60008060006060848603121561224657600080fd5b61224f84611bbb565b95602085013595506040909401359392505050565b600181811c9082168061227857607f821691505b60208210810361229857634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526038908201526000805160206127eb8339815191526040820152771a185d99481b5a5b9d195c881c9bdb19481d1bc81b5a5b9d60421b606082015260800190565b6020808252602e908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526d195c881bdc88185c1c1c9bdd995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b60006001820161237057612370612348565b5060010190565b60208082526021908201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736040820152607360f81b606082015260800190565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b8082018082111561044257610442612348565b6040815260006124266040830185612030565b82810360208401526124388185612030565b95945050505050565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b60208082526023908201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260408201526265737360e81b606082015260800190565b60208082526024908201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604082015263616e636560e01b606082015260800190565b6001600160a01b0386811682528516602082015260a06040820181905260009061258390830186612030565b82810360608401526125958186612030565b905082810360808401526125a98185611c71565b98975050505050505050565b6000602082840312156125c757600080fd5b81516108e381611c01565b600060033d11156125eb5760046000803e5060005160e01c5b90565b600060443d10156125fc5790565b6040516003193d81016004833e81513d6001600160401b03816024840111818411171561262b57505050505090565b82850191508151818111156126435750505050505090565b843d870101602082850101111561265d5750505050505090565b61266c60208286010187611cc6565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b76020b1b1b2b9b9a1b7b73a3937b61d1030b1b1b7bab73a1604d1b8152600083516126f1816017850160208801611c4d565b7001034b99036b4b9b9b4b733903937b6329607d1b6017918401918201528351612722816028840160208801611c4d565b01602801949350505050565b6001600160a01b03868116825285166020820152604081018490526060810183905260a06080820181905260009061276890830184611c71565b979650505050505050565b808202811582820484141761044257610442612348565b60008161279957612799612348565b506000190190565b8181038181111561044257610442612348565b634e487b7160e01b600052603160045260246000fdfe4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb455243313135355072657365744d696e7465725061757365723a206d75737420c3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f6265d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862a9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a6a2646970667358221220294efe154e549198ff0c6b7ab7e9846223d9e8fe7ae7de1938f6eb7d0f5e66a664736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101625760003560e01c8063731133e9116100ce578063ca15c87311610087578063ca15c873146102fb578063d53913931461030e578063d547741f14610323578063e63ab1e914610336578063e985e9c51461034b578063f242432a14610387578063f5298aca1461039a57600080fd5b8063731133e9146102875780638456cb591461029a5780639010d07c146102a257806391d14854146102cd578063a217fddf146102e0578063a22cb465146102e857600080fd5b80632f2ff15d116101205780632f2ff15d1461021b57806336568abe1461022e5780633f4ba83a146102415780634e1273f4146102495780635c975abb146102695780636b20c4541461027457600080fd5b8062fdd58e1461016757806301ffc9a71461018d5780630e89341c146101b05780631f7fdffa146101d0578063248a9ca3146101e55780632eb2c2d614610208575b600080fd5b61017a610175366004611bd7565b6103ad565b6040519081526020015b60405180910390f35b6101a061019b366004611c17565b610448565b6040519015158152602001610184565b6101c36101be366004611c34565b610453565b6040516101849190611c9d565b6101e36101de366004611df9565b6104e7565b005b61017a6101f3366004611c34565b60009081526020819052604090206001015490565b6101e3610216366004611e91565b61052d565b6101e3610229366004611f3a565b610579565b6101e361023c366004611f3a565b6105a3565b6101e3610621565b61025c610257366004611f66565b6106a3565b604051610184919061206b565b60055460ff166101a0565b6101e361028236600461207e565b6107cc565b6101e36102953660046120f1565b61080f565b6101e361084f565b6102b56102b0366004612145565b6108cb565b6040516001600160a01b039091168152602001610184565b6101a06102db366004611f3a565b6108ea565b61017a600081565b6101e36102f6366004612167565b610913565b61017a610309366004611c34565b61091e565b61017a60008051602061284b83398151915281565b6101e3610331366004611f3a565b610935565b61017a60008051602061282b83398151915281565b6101a06103593660046121a3565b6001600160a01b03918216600090815260036020908152604080832093909416825291909152205460ff1690565b6101e36103953660046121cd565b61095a565b6101e36103a8366004612231565b61099f565b60006001600160a01b03831661041d5760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b5060008181526002602090815260408083206001600160a01b03861684529091529020545b92915050565b6000610442826109e2565b60606004805461046290612264565b80601f016020809104026020016040519081016040528092919081815260200182805461048e90612264565b80156104db5780601f106104b0576101008083540402835291602001916104db565b820191906000526020600020905b8154815290600101906020018083116104be57829003601f168201915b50505050509050919050565b6104ff60008051602061284b833981519152336108ea565b61051b5760405162461bcd60e51b81526004016104149061229e565b61052784848484610a22565b50505050565b6001600160a01b03851633148061054957506105498533610359565b6105655760405162461bcd60e51b8152600401610414906122e4565b6105728585858585610b6b565b5050505050565b60008281526020819052604090206001015461059481610d06565b61059e8383610d13565b505050565b6001600160a01b03811633146106135760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610414565b61061d8282610d35565b5050565b61063960008051602061282b833981519152336108ea565b6106995760405162461bcd60e51b815260206004820152603b60248201526000805160206127eb83398151915260448201527f686176652070617573657220726f6c6520746f20756e706175736500000000006064820152608401610414565b6106a1610d57565b565b606081518351146107085760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610414565b600083516001600160401b0381111561072357610723611cb0565b60405190808252806020026020018201604052801561074c578160200160208202803683370190505b50905060005b84518110156107c45761079785828151811061077057610770612332565b602002602001015185838151811061078a5761078a612332565b60200260200101516103ad565b8282815181106107a9576107a9612332565b60209081029190910101526107bd8161235e565b9050610752565b509392505050565b6001600160a01b0383163314806107e857506107e88333610359565b6108045760405162461bcd60e51b8152600401610414906122e4565b61059e838383610da9565b61082760008051602061284b833981519152336108ea565b6108435760405162461bcd60e51b81526004016104149061229e565b61052784848484610f36565b61086760008051602061282b833981519152336108ea565b6108c35760405162461bcd60e51b815260206004820152603960248201526000805160206127eb833981519152604482015278686176652070617573657220726f6c6520746f20706175736560381b6064820152608401610414565b6106a161100f565b60008281526001602052604081206108e3908361104c565b9392505050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b61061d338383611058565b600081815260016020526040812061044290611138565b60008281526020819052604090206001015461095081610d06565b61059e8383610d35565b6001600160a01b03851633148061097657506109768533610359565b6109925760405162461bcd60e51b8152600401610414906122e4565b6105728585858585611142565b6001600160a01b0383163314806109bb57506109bb8333610359565b6109d75760405162461bcd60e51b8152600401610414906122e4565b61059e83838361126c565b60006001600160e01b03198216636cdb3d1360e11b1480610a1357506001600160e01b031982166303a24d0760e21b145b80610442575061044282611376565b6001600160a01b038416610a485760405162461bcd60e51b815260040161041490612377565b8151835114610a695760405162461bcd60e51b8152600401610414906123b8565b33610a798160008787878761139b565b60005b8451811015610b1557838181518110610a9757610a97612332565b602002602001015160026000878481518110610ab557610ab5612332565b602002602001015181526020019081526020016000206000886001600160a01b03166001600160a01b031681526020019081526020016000206000828254610afd9190612400565b90915550819050610b0d8161235e565b915050610a7c565b50846001600160a01b031660006001600160a01b0316826001600160a01b03166000805160206127cb8339815191528787604051610b54929190612413565b60405180910390a4610572816000878787876113a9565b8151835114610b8c5760405162461bcd60e51b8152600401610414906123b8565b6001600160a01b038416610bb25760405162461bcd60e51b815260040161041490612441565b33610bc181878787878761139b565b60005b8451811015610caa576000858281518110610be157610be1612332565b602002602001015190506000858381518110610bff57610bff612332565b60209081029190910181015160008481526002835260408082206001600160a01b038e168352909352919091205490915081811015610c505760405162461bcd60e51b815260040161041490612486565b60008381526002602090815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290610c8f908490612400565b9250508190555050505080610ca39061235e565b9050610bc4565b50846001600160a01b0316866001600160a01b0316826001600160a01b03166000805160206127cb8339815191528787604051610ce8929190612413565b60405180910390a4610cfe8187878787876113a9565b505050505050565b610d108133611504565b50565b610d1d828261155d565b600082815260016020526040902061059e90826115e1565b610d3f82826115f6565b600082815260016020526040902061059e908261165b565b610d5f611670565b6005805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6001600160a01b038316610dcf5760405162461bcd60e51b8152600401610414906124d0565b8051825114610df05760405162461bcd60e51b8152600401610414906123b8565b6000339050610e138185600086866040518060200160405280600081525061139b565b60005b8351811015610edb576000848281518110610e3357610e33612332565b602002602001015190506000848381518110610e5157610e51612332565b60209081029190910181015160008481526002835260408082206001600160a01b038c168352909352919091205490915081811015610ea25760405162461bcd60e51b815260040161041490612513565b60009283526002602090815260408085206001600160a01b038b1686529091529092209103905580610ed38161235e565b915050610e16565b5060006001600160a01b0316846001600160a01b0316826001600160a01b03166000805160206127cb8339815191528686604051610f1a929190612413565b60405180910390a4604080516020810190915260009052610527565b6001600160a01b038416610f5c5760405162461bcd60e51b815260040161041490612377565b336000610f68856116b9565b90506000610f75856116b9565b9050610f868360008985858961139b565b60008681526002602090815260408083206001600160a01b038b16845290915281208054879290610fb8908490612400565b909155505060408051878152602081018790526001600160a01b03808a16926000929187169160008051602061280b833981519152910160405180910390a461100683600089898989611704565b50505050505050565b6110176117bf565b6005805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610d8c3390565b60006108e38383611805565b816001600160a01b0316836001600160a01b0316036110cb5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610414565b6001600160a01b03838116600081815260036020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6000610442825490565b6001600160a01b0384166111685760405162461bcd60e51b815260040161041490612441565b336000611174856116b9565b90506000611181856116b9565b905061119183898985858961139b565b60008681526002602090815260408083206001600160a01b038c168452909152902054858110156111d45760405162461bcd60e51b815260040161041490612486565b60008781526002602090815260408083206001600160a01b038d8116855292528083208985039055908a16825281208054889290611213908490612400565b909155505060408051888152602081018890526001600160a01b03808b16928c8216929188169160008051602061280b833981519152910160405180910390a4611261848a8a8a8a8a611704565b505050505050505050565b6001600160a01b0383166112925760405162461bcd60e51b8152600401610414906124d0565b33600061129e846116b9565b905060006112ab846116b9565b90506112cb8387600085856040518060200160405280600081525061139b565b60008581526002602090815260408083206001600160a01b038a1684529091529020548481101561130e5760405162461bcd60e51b815260040161041490612513565b60008681526002602090815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a905290929088169160008051602061280b833981519152910160405180910390a4604080516020810190915260009052611006565b60006001600160e01b03198216635a05180f60e01b148061044257506104428261182f565b610cfe868686868686611864565b6001600160a01b0384163b15610cfe5760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906113ed9089908990889088908890600401612557565b6020604051808303816000875af1925050508015611428575060408051601f3d908101601f19168201909252611425918101906125b5565b60015b6114d4576114346125d2565b806308c379a00361146d57506114486125ee565b80611453575061146f565b8060405162461bcd60e51b81526004016104149190611c9d565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e2d455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610414565b6001600160e01b0319811663bc197c8160e01b146110065760405162461bcd60e51b815260040161041490612677565b61150e82826108ea565b61061d5761151b816118cc565b6115268360206118de565b6040516020016115379291906126bf565b60408051601f198184030181529082905262461bcd60e51b825261041491600401611c9d565b61156782826108ea565b61061d576000828152602081815260408083206001600160a01b03851684529091529020805460ff1916600117905561159d3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b60006108e3836001600160a01b038416611a79565b61160082826108ea565b1561061d576000828152602081815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b60006108e3836001600160a01b038416611ac8565b60055460ff166106a15760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610414565b604080516001808252818301909252606091600091906020808301908036833701905050905082816000815181106116f3576116f3612332565b602090810291909101015292915050565b6001600160a01b0384163b15610cfe5760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190611748908990899088908890889060040161272e565b6020604051808303816000875af1925050508015611783575060408051601f3d908101601f19168201909252611780918101906125b5565b60015b61178f576114346125d2565b6001600160e01b0319811663f23a6e6160e01b146110065760405162461bcd60e51b815260040161041490612677565b60055460ff16156106a15760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610414565b600082600001828154811061181c5761181c612332565b9060005260206000200154905092915050565b60006001600160e01b03198216637965db0b60e01b148061044257506301ffc9a760e01b6001600160e01b0319831614610442565b60055460ff1615610cfe5760405162461bcd60e51b815260206004820152602c60248201527f455243313135355061757361626c653a20746f6b656e207472616e736665722060448201526b1dda1a5b19481c185d5cd95960a21b6064820152608401610414565b60606104426001600160a01b03831660145b606060006118ed836002612773565b6118f8906002612400565b6001600160401b0381111561190f5761190f611cb0565b6040519080825280601f01601f191660200182016040528015611939576020820181803683370190505b509050600360fc1b8160008151811061195457611954612332565b60200101906001600160f81b031916908160001a905350600f60fb1b8160018151811061198357611983612332565b60200101906001600160f81b031916908160001a90535060006119a7846002612773565b6119b2906001612400565b90505b6001811115611a2a576f181899199a1a9b1b9c1cb0b131b232b360811b85600f16601081106119e6576119e6612332565b1a60f81b8282815181106119fc576119fc612332565b60200101906001600160f81b031916908160001a90535060049490941c93611a238161278a565b90506119b5565b5083156108e35760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610414565b6000818152600183016020526040812054611ac057508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610442565b506000610442565b60008181526001830160205260408120548015611bb1576000611aec6001836127a1565b8554909150600090611b00906001906127a1565b9050818114611b65576000866000018281548110611b2057611b20612332565b9060005260206000200154905080876000018481548110611b4357611b43612332565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080611b7657611b766127b4565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610442565b6000915050610442565b80356001600160a01b0381168114611bd257600080fd5b919050565b60008060408385031215611bea57600080fd5b611bf383611bbb565b946020939093013593505050565b6001600160e01b031981168114610d1057600080fd5b600060208284031215611c2957600080fd5b81356108e381611c01565b600060208284031215611c4657600080fd5b5035919050565b60005b83811015611c68578181015183820152602001611c50565b50506000910152565b60008151808452611c89816020860160208601611c4d565b601f01601f19169290920160200192915050565b6020815260006108e36020830184611c71565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b0381118282101715611ceb57611ceb611cb0565b6040525050565b60006001600160401b03821115611d0b57611d0b611cb0565b5060051b60200190565b600082601f830112611d2657600080fd5b81356020611d3382611cf2565b604051611d408282611cc6565b83815260059390931b8501820192828101915086841115611d6057600080fd5b8286015b84811015611d7b5780358352918301918301611d64565b509695505050505050565b600082601f830112611d9757600080fd5b81356001600160401b03811115611db057611db0611cb0565b604051611dc7601f8301601f191660200182611cc6565b818152846020838601011115611ddc57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611e0f57600080fd5b611e1885611bbb565b935060208501356001600160401b0380821115611e3457600080fd5b611e4088838901611d15565b94506040870135915080821115611e5657600080fd5b611e6288838901611d15565b93506060870135915080821115611e7857600080fd5b50611e8587828801611d86565b91505092959194509250565b600080600080600060a08688031215611ea957600080fd5b611eb286611bbb565b9450611ec060208701611bbb565b935060408601356001600160401b0380821115611edc57600080fd5b611ee889838a01611d15565b94506060880135915080821115611efe57600080fd5b611f0a89838a01611d15565b93506080880135915080821115611f2057600080fd5b50611f2d88828901611d86565b9150509295509295909350565b60008060408385031215611f4d57600080fd5b82359150611f5d60208401611bbb565b90509250929050565b60008060408385031215611f7957600080fd5b82356001600160401b0380821115611f9057600080fd5b818501915085601f830112611fa457600080fd5b81356020611fb182611cf2565b604051611fbe8282611cc6565b83815260059390931b8501820192828101915089841115611fde57600080fd5b948201945b8386101561200357611ff486611bbb565b82529482019490820190611fe3565b9650508601359250508082111561201957600080fd5b5061202685828601611d15565b9150509250929050565b600081518084526020808501945080840160005b8381101561206057815187529582019590820190600101612044565b509495945050505050565b6020815260006108e36020830184612030565b60008060006060848603121561209357600080fd5b61209c84611bbb565b925060208401356001600160401b03808211156120b857600080fd5b6120c487838801611d15565b935060408601359150808211156120da57600080fd5b506120e786828701611d15565b9150509250925092565b6000806000806080858703121561210757600080fd5b61211085611bbb565b9350602085013592506040850135915060608501356001600160401b0381111561213957600080fd5b611e8587828801611d86565b6000806040838503121561215857600080fd5b50508035926020909101359150565b6000806040838503121561217a57600080fd5b61218383611bbb565b91506020830135801515811461219857600080fd5b809150509250929050565b600080604083850312156121b657600080fd5b6121bf83611bbb565b9150611f5d60208401611bbb565b600080600080600060a086880312156121e557600080fd5b6121ee86611bbb565b94506121fc60208701611bbb565b9350604086013592506060860135915060808601356001600160401b0381111561222557600080fd5b611f2d88828901611d86565b60008060006060848603121561224657600080fd5b61224f84611bbb565b95602085013595506040909401359392505050565b600181811c9082168061227857607f821691505b60208210810361229857634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526038908201526000805160206127eb8339815191526040820152771a185d99481b5a5b9d195c881c9bdb19481d1bc81b5a5b9d60421b606082015260800190565b6020808252602e908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526d195c881bdc88185c1c1c9bdd995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b60006001820161237057612370612348565b5060010190565b60208082526021908201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736040820152607360f81b606082015260800190565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b8082018082111561044257610442612348565b6040815260006124266040830185612030565b82810360208401526124388185612030565b95945050505050565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b60208082526023908201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260408201526265737360e81b606082015260800190565b60208082526024908201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604082015263616e636560e01b606082015260800190565b6001600160a01b0386811682528516602082015260a06040820181905260009061258390830186612030565b82810360608401526125958186612030565b905082810360808401526125a98185611c71565b98975050505050505050565b6000602082840312156125c757600080fd5b81516108e381611c01565b600060033d11156125eb5760046000803e5060005160e01c5b90565b600060443d10156125fc5790565b6040516003193d81016004833e81513d6001600160401b03816024840111818411171561262b57505050505090565b82850191508151818111156126435750505050505090565b843d870101602082850101111561265d5750505050505090565b61266c60208286010187611cc6565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b76020b1b1b2b9b9a1b7b73a3937b61d1030b1b1b7bab73a1604d1b8152600083516126f1816017850160208801611c4d565b7001034b99036b4b9b9b4b733903937b6329607d1b6017918401918201528351612722816028840160208801611c4d565b01602801949350505050565b6001600160a01b03868116825285166020820152604081018490526060810183905260a06080820181905260009061276890830184611c71565b979650505050505050565b808202811582820484141761044257610442612348565b60008161279957612799612348565b506000190190565b8181038181111561044257610442612348565b634e487b7160e01b600052603160045260246000fdfe4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb455243313135355072657365744d696e7465725061757365723a206d75737420c3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f6265d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862a9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a6a2646970667358221220294efe154e549198ff0c6b7ab7e9846223d9e8fe7ae7de1938f6eb7d0f5e66a664736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RootERC1155PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootERC1155Predicate","sourceName":"contracts/root/RootERC1155Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"ERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"ERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"TokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newChildERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"childToken","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155BatchReceived","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611bd2806100206000396000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c8063bc197c81116100ad578063f23a6e6111610071578063f23a6e61146102fe578063f43cda8b1461031d578063f4a120f714610330578063f645125514610343578063f8c8765e1461036a57600080fd5b8063bc197c8114610238578063c5ac2b1c14610270578063cb10f94c14610297578063d41f1771146102b0578063d7c9e3ec146102d757600080fd5b80637efab4f5116100f45780637efab4f5146101a157806395c7041c146101ca578063a78e111c146101dd578063b1768065146101f0578063b68ad1e41461022557600080fd5b806301ffc9a7146101265780630efe6a8b1461014e5780634c4c45de14610163578063654715e614610176575b600080fd5b610139610134366004611173565b61037d565b60405190151581526020015b60405180910390f35b61016161015c3660046111bc565b6103b4565b005b61016161017136600461123c565b6103c5565b600254610189906001600160a01b031681565b6040516001600160a01b039091168152602001610145565b6101896101af3660046112e8565b6004602052600090815260409020546001600160a01b031681565b600154610189906001600160a01b031681565b6101616101eb366004611305565b610448565b6102177f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610145565b600354610189906001600160a01b031681565b610257610246366004611497565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610145565b6102177faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610189906201000090046001600160a01b031681565b6102177f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102177f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61025761030c366004611544565b63f23a6e6160e01b95945050505050565b61016161032b3660046115ac565b61045a565b61018961033e3660046112e8565b610629565b6102177f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b610161610378366004611634565b610945565b60006001600160e01b03198216630271189760e51b14806103ae57506301ffc9a760e01b6001600160e01b03198316145b92915050565b6103c083338484610b54565b505050565b84831480156103d357508481145b6104305760405162461bcd60e51b8152602060048201526024808201527f526f6f74455243313135355072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b60648201526084015b60405180910390fd5b61043f87878787878787610cec565b50505050505050565b61045484848484610b54565b50505050565b6001546001600160a01b031633146104c35760405162461bcd60e51b815260206004820152602660248201527f526f6f74455243313135355072656469636174653a204f4e4c595f455849545f6044820152652422a62822a960d11b6064820152608401610427565b6002546001600160a01b038481169116146105335760405162461bcd60e51b815260206004820152602a60248201527f526f6f74455243313135355072656469636174653a204f4e4c595f4348494c446044820152695f50524544494341544560b01b6064820152608401610427565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e982869610562602060008486611690565b61056b916116ba565b0361058a576105856105808260208186611690565b610ecc565b610454565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26105b9602060008486611690565b6105c2916116ba565b036105d1576105858282610fcb565b60405162461bcd60e51b815260206004820152602760248201527f526f6f74455243313135355072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b6064820152608401610427565b60006001600160a01b03821661068d5760405162461bcd60e51b815260206004820152602360248201527f526f6f74455243313135355072656469636174653a20494e56414c49445f544f60448201526225a2a760e91b6064820152608401610427565b6001600160a01b0382811660009081526004602052604090205416156107015760405162461bcd60e51b8152602060048201526024808201527f526f6f74455243313135355072656469636174653a20414c52454144595f4d416044820152631414115160e21b6064820152608401610427565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b03928316926107ab921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03848116600081815260046020818152604080842080546001600160a01b031916968816969096179095558451908101855282815293516303a24d0760e21b8152908101919091529294509091630e89341c90602401600060405180830381865afa92505050801561084657506040513d6000823e601f3d908101601f1916820160405261084391908101906116fc565b60015b1561084e5790505b600060029054906101000a90046001600160a01b03166001600160a01b03166316f19831837f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad87856040516020016108a89392919061179e565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108d49291906117c8565b600060405180830381600087803b1580156108ee57600080fd5b505af1158015610902573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a35050919050565b600054610100900460ff16158080156109655750600054600160ff909116105b8061097f5750303b15801561097f575060005460ff166001145b6109e25760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610427565b6000805460ff191660011790558015610a05576000805461ff0019166101001790555b6001600160a01b03851615801590610a2557506001600160a01b03841615155b8015610a3957506001600160a01b03831615155b8015610a4d57506001600160a01b03821615155b610aaa5760405162461bcd60e51b815260206004820152602860248201527f526f6f74455243313135355072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b6064820152608401610427565b6000805462010000600160b01b031916620100006001600160a01b038881169190910291909117909155600180546001600160a01b031990811687841617909155600280548216868416179055600380549091169184169190911790558015610b4d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6000610b5f8561112c565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610b949033903090889088906004016117f4565b600060405180830381600087803b158015610bae57600080fd5b505af1158015610bc2573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935262010000909404841695506316f198319450610c5f939092169160e4016117c8565b600060405180830381600087803b158015610c7957600080fd5b505af1158015610c8d573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fbcbdf0c69f975f2a4085544938b054f02e77e87cbd055146d388c0be7120e04f9060600160405180910390a45050505050565b6000610cf78861112c565b905060005b84811015610da357886001600160a01b031663f242432a3330898986818110610d2757610d2761182c565b90506020020135888887818110610d4057610d4061182c565b905060200201356040518563ffffffff1660e01b8152600401610d6694939291906117f4565b600060405180830381600087803b158015610d8057600080fd5b505af1158015610d94573d6000803e3d6000fd5b50505050806001019050610cfc565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610e05907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e906020016118bd565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610e319291906117c8565b600060405180830381600087803b158015610e4b57600080fd5b505af1158015610e5f573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167f7e8ab6f25cb177d65db49b7a2197bb2a7df5757434857d411e2523b332a913e68a8a8a8a8a8a604051610eba96959493929190611928565b60405180910390a45050505050505050565b600080808080610ede86880188611971565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610f1357610f136119cc565b604051637921219560e11b81526001600160a01b0387169063f242432a90610f459030908890889088906004016117f4565b600060405180830381600087803b158015610f5f57600080fd5b505af1158015610f73573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907fc42752949ca07109e6f25adcde4a9407be23e084b1d32ca2bce8aa55bf3dd62590606001610eba565b600080808080610fdd868801886119e2565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080611014576110146119cc565b60005b83518110156110da57866001600160a01b031663f242432a308784815181106110425761104261182c565b602002602001015187858151811061105c5761105c61182c565b60200260200101518786815181106110765761107661182c565b60200260200101516040518563ffffffff1660e01b815260040161109d94939291906117f4565b600060405180830381600087803b1580156110b757600080fd5b505af11580156110cb573d6000803e3d6000fd5b50505050806001019050611017565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167fce612e98b81c726375e7c2395409e74ee0a29b22f7641ea5a8ce8508616448c0878787604051610eba93929190611b27565b6001600160a01b0380821660009081526004602052604090205416806111585761115582610629565b90505b6001600160a01b03811661116e5761116e6119cc565b919050565b60006020828403121561118557600080fd5b81356001600160e01b03198116811461119d57600080fd5b9392505050565b6001600160a01b03811681146111b957600080fd5b50565b6000806000606084860312156111d157600080fd5b83356111dc816111a4565b95602085013595506040909401359392505050565b60008083601f84011261120357600080fd5b5081356001600160401b0381111561121a57600080fd5b6020830191508360208260051b850101111561123557600080fd5b9250929050565b60008060008060008060006080888a03121561125757600080fd5b8735611262816111a4565b965060208801356001600160401b038082111561127e57600080fd5b61128a8b838c016111f1565b909850965060408a01359150808211156112a357600080fd5b6112af8b838c016111f1565b909650945060608a01359150808211156112c857600080fd5b506112d58a828b016111f1565b989b979a50959850939692959293505050565b6000602082840312156112fa57600080fd5b813561119d816111a4565b6000806000806080858703121561131b57600080fd5b8435611326816111a4565b93506020850135611336816111a4565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156113895761138961134b565b604052919050565b60006001600160401b038211156113aa576113aa61134b565b5060051b60200190565b600082601f8301126113c557600080fd5b813560206113da6113d583611391565b611361565b82815260059290921b840181019181810190868411156113f957600080fd5b8286015b8481101561141457803583529183019183016113fd565b509695505050505050565b60006001600160401b038211156114385761143861134b565b50601f01601f191660200190565b600082601f83011261145757600080fd5b81356114656113d58261141f565b81815284602083860101111561147a57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156114af57600080fd5b85356114ba816111a4565b945060208601356114ca816111a4565b935060408601356001600160401b03808211156114e657600080fd5b6114f289838a016113b4565b9450606088013591508082111561150857600080fd5b61151489838a016113b4565b9350608088013591508082111561152a57600080fd5b5061153788828901611446565b9150509295509295909350565b600080600080600060a0868803121561155c57600080fd5b8535611567816111a4565b94506020860135611577816111a4565b9350604086013592506060860135915060808601356001600160401b038111156115a057600080fd5b61153788828901611446565b600080600080606085870312156115c257600080fd5b8435935060208501356115d4816111a4565b925060408501356001600160401b03808211156115f057600080fd5b818701915087601f83011261160457600080fd5b81358181111561161357600080fd5b88602082850101111561162557600080fd5b95989497505060200194505050565b6000806000806080858703121561164a57600080fd5b8435611655816111a4565b93506020850135611665816111a4565b92506040850135611675816111a4565b91506060850135611685816111a4565b939692955090935050565b600080858511156116a057600080fd5b838611156116ad57600080fd5b5050820193919092039150565b803560208310156103ae57600019602084900360031b1b1692915050565b60005b838110156116f35781810151838201526020016116db565b50506000910152565b60006020828403121561170e57600080fd5b81516001600160401b0381111561172457600080fd5b8201601f8101841361173557600080fd5b80516117436113d58261141f565b81815285602083850101111561175857600080fd5b6117698260208301602086016116d8565b95945050505050565b6000815180845261178a8160208601602086016116d8565b601f01601f19169290920160200192915050565b8381526001600160a01b038316602082015260606040820181905260009061176990830184611772565b6001600160a01b03831681526040602082018190526000906117ec90830184611772565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b85811015611880578135611865816111a4565b6001600160a01b031687529582019590820190600101611852565b509495945050505050565b81835260006001600160fb1b038311156118a457600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c0606082018190526000906118f0908301888a611842565b828103608084015261190381878961188b565b905082810360a084015261191881858761188b565b9c9b505050505050505050505050565b60608152600061193c60608301888a611842565b828103602084015261194f81878961188b565b9050828103604084015261196481858761188b565b9998505050505050505050565b600080600080600060a0868803121561198957600080fd5b8535611994816111a4565b945060208601356119a4816111a4565b935060408601356119b4816111a4565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c087890312156119fb57600080fd5b86359550602080880135611a0e816111a4565b95506040880135611a1e816111a4565b945060608801356001600160401b0380821115611a3a57600080fd5b818a0191508a601f830112611a4e57600080fd5b8135611a5c6113d582611391565b81815260059190911b8301840190848101908d831115611a7b57600080fd5b938501935b82851015611aa2578435611a93816111a4565b82529385019390850190611a80565b9750505060808a0135925080831115611aba57600080fd5b611ac68b848c016113b4565b945060a08a0135925080831115611adc57600080fd5b5050611aea89828a016113b4565b9150509295509295509295565b600081518084526020808501945080840160005b8381101561188057815187529582019590820190600101611b0b565b606080825284519082018190526000906020906080840190828801845b82811015611b695781516001600160a01b031684529284019290840190600101611b44565b50505083810382850152611b7d8187611af7565b9150508281036040840152611b928185611af7565b969550505050505056fea2646970667358221220fca09c260114445d76ac4a1ec1efcbdba6ac7f99d1bccd257e90ed39dcea400d64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101215760003560e01c8063bc197c81116100ad578063f23a6e6111610071578063f23a6e61146102fe578063f43cda8b1461031d578063f4a120f714610330578063f645125514610343578063f8c8765e1461036a57600080fd5b8063bc197c8114610238578063c5ac2b1c14610270578063cb10f94c14610297578063d41f1771146102b0578063d7c9e3ec146102d757600080fd5b80637efab4f5116100f45780637efab4f5146101a157806395c7041c146101ca578063a78e111c146101dd578063b1768065146101f0578063b68ad1e41461022557600080fd5b806301ffc9a7146101265780630efe6a8b1461014e5780634c4c45de14610163578063654715e614610176575b600080fd5b610139610134366004611173565b61037d565b60405190151581526020015b60405180910390f35b61016161015c3660046111bc565b6103b4565b005b61016161017136600461123c565b6103c5565b600254610189906001600160a01b031681565b6040516001600160a01b039091168152602001610145565b6101896101af3660046112e8565b6004602052600090815260409020546001600160a01b031681565b600154610189906001600160a01b031681565b6101616101eb366004611305565b610448565b6102177f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610145565b600354610189906001600160a01b031681565b610257610246366004611497565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610145565b6102177faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610189906201000090046001600160a01b031681565b6102177f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102177f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61025761030c366004611544565b63f23a6e6160e01b95945050505050565b61016161032b3660046115ac565b61045a565b61018961033e3660046112e8565b610629565b6102177f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b610161610378366004611634565b610945565b60006001600160e01b03198216630271189760e51b14806103ae57506301ffc9a760e01b6001600160e01b03198316145b92915050565b6103c083338484610b54565b505050565b84831480156103d357508481145b6104305760405162461bcd60e51b8152602060048201526024808201527f526f6f74455243313135355072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b60648201526084015b60405180910390fd5b61043f87878787878787610cec565b50505050505050565b61045484848484610b54565b50505050565b6001546001600160a01b031633146104c35760405162461bcd60e51b815260206004820152602660248201527f526f6f74455243313135355072656469636174653a204f4e4c595f455849545f6044820152652422a62822a960d11b6064820152608401610427565b6002546001600160a01b038481169116146105335760405162461bcd60e51b815260206004820152602a60248201527f526f6f74455243313135355072656469636174653a204f4e4c595f4348494c446044820152695f50524544494341544560b01b6064820152608401610427565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e982869610562602060008486611690565b61056b916116ba565b0361058a576105856105808260208186611690565b610ecc565b610454565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26105b9602060008486611690565b6105c2916116ba565b036105d1576105858282610fcb565b60405162461bcd60e51b815260206004820152602760248201527f526f6f74455243313135355072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b6064820152608401610427565b60006001600160a01b03821661068d5760405162461bcd60e51b815260206004820152602360248201527f526f6f74455243313135355072656469636174653a20494e56414c49445f544f60448201526225a2a760e91b6064820152608401610427565b6001600160a01b0382811660009081526004602052604090205416156107015760405162461bcd60e51b8152602060048201526024808201527f526f6f74455243313135355072656469636174653a20414c52454144595f4d416044820152631414115160e21b6064820152608401610427565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b03928316926107ab921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03848116600081815260046020818152604080842080546001600160a01b031916968816969096179095558451908101855282815293516303a24d0760e21b8152908101919091529294509091630e89341c90602401600060405180830381865afa92505050801561084657506040513d6000823e601f3d908101601f1916820160405261084391908101906116fc565b60015b1561084e5790505b600060029054906101000a90046001600160a01b03166001600160a01b03166316f19831837f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad87856040516020016108a89392919061179e565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108d49291906117c8565b600060405180830381600087803b1580156108ee57600080fd5b505af1158015610902573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a35050919050565b600054610100900460ff16158080156109655750600054600160ff909116105b8061097f5750303b15801561097f575060005460ff166001145b6109e25760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610427565b6000805460ff191660011790558015610a05576000805461ff0019166101001790555b6001600160a01b03851615801590610a2557506001600160a01b03841615155b8015610a3957506001600160a01b03831615155b8015610a4d57506001600160a01b03821615155b610aaa5760405162461bcd60e51b815260206004820152602860248201527f526f6f74455243313135355072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b6064820152608401610427565b6000805462010000600160b01b031916620100006001600160a01b038881169190910291909117909155600180546001600160a01b031990811687841617909155600280548216868416179055600380549091169184169190911790558015610b4d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6000610b5f8561112c565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610b949033903090889088906004016117f4565b600060405180830381600087803b158015610bae57600080fd5b505af1158015610bc2573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935262010000909404841695506316f198319450610c5f939092169160e4016117c8565b600060405180830381600087803b158015610c7957600080fd5b505af1158015610c8d573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fbcbdf0c69f975f2a4085544938b054f02e77e87cbd055146d388c0be7120e04f9060600160405180910390a45050505050565b6000610cf78861112c565b905060005b84811015610da357886001600160a01b031663f242432a3330898986818110610d2757610d2761182c565b90506020020135888887818110610d4057610d4061182c565b905060200201356040518563ffffffff1660e01b8152600401610d6694939291906117f4565b600060405180830381600087803b158015610d8057600080fd5b505af1158015610d94573d6000803e3d6000fd5b50505050806001019050610cfc565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610e05907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e906020016118bd565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610e319291906117c8565b600060405180830381600087803b158015610e4b57600080fd5b505af1158015610e5f573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167f7e8ab6f25cb177d65db49b7a2197bb2a7df5757434857d411e2523b332a913e68a8a8a8a8a8a604051610eba96959493929190611928565b60405180910390a45050505050505050565b600080808080610ede86880188611971565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610f1357610f136119cc565b604051637921219560e11b81526001600160a01b0387169063f242432a90610f459030908890889088906004016117f4565b600060405180830381600087803b158015610f5f57600080fd5b505af1158015610f73573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907fc42752949ca07109e6f25adcde4a9407be23e084b1d32ca2bce8aa55bf3dd62590606001610eba565b600080808080610fdd868801886119e2565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080611014576110146119cc565b60005b83518110156110da57866001600160a01b031663f242432a308784815181106110425761104261182c565b602002602001015187858151811061105c5761105c61182c565b60200260200101518786815181106110765761107661182c565b60200260200101516040518563ffffffff1660e01b815260040161109d94939291906117f4565b600060405180830381600087803b1580156110b757600080fd5b505af11580156110cb573d6000803e3d6000fd5b50505050806001019050611017565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167fce612e98b81c726375e7c2395409e74ee0a29b22f7641ea5a8ce8508616448c0878787604051610eba93929190611b27565b6001600160a01b0380821660009081526004602052604090205416806111585761115582610629565b90505b6001600160a01b03811661116e5761116e6119cc565b919050565b60006020828403121561118557600080fd5b81356001600160e01b03198116811461119d57600080fd5b9392505050565b6001600160a01b03811681146111b957600080fd5b50565b6000806000606084860312156111d157600080fd5b83356111dc816111a4565b95602085013595506040909401359392505050565b60008083601f84011261120357600080fd5b5081356001600160401b0381111561121a57600080fd5b6020830191508360208260051b850101111561123557600080fd5b9250929050565b60008060008060008060006080888a03121561125757600080fd5b8735611262816111a4565b965060208801356001600160401b038082111561127e57600080fd5b61128a8b838c016111f1565b909850965060408a01359150808211156112a357600080fd5b6112af8b838c016111f1565b909650945060608a01359150808211156112c857600080fd5b506112d58a828b016111f1565b989b979a50959850939692959293505050565b6000602082840312156112fa57600080fd5b813561119d816111a4565b6000806000806080858703121561131b57600080fd5b8435611326816111a4565b93506020850135611336816111a4565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156113895761138961134b565b604052919050565b60006001600160401b038211156113aa576113aa61134b565b5060051b60200190565b600082601f8301126113c557600080fd5b813560206113da6113d583611391565b611361565b82815260059290921b840181019181810190868411156113f957600080fd5b8286015b8481101561141457803583529183019183016113fd565b509695505050505050565b60006001600160401b038211156114385761143861134b565b50601f01601f191660200190565b600082601f83011261145757600080fd5b81356114656113d58261141f565b81815284602083860101111561147a57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156114af57600080fd5b85356114ba816111a4565b945060208601356114ca816111a4565b935060408601356001600160401b03808211156114e657600080fd5b6114f289838a016113b4565b9450606088013591508082111561150857600080fd5b61151489838a016113b4565b9350608088013591508082111561152a57600080fd5b5061153788828901611446565b9150509295509295909350565b600080600080600060a0868803121561155c57600080fd5b8535611567816111a4565b94506020860135611577816111a4565b9350604086013592506060860135915060808601356001600160401b038111156115a057600080fd5b61153788828901611446565b600080600080606085870312156115c257600080fd5b8435935060208501356115d4816111a4565b925060408501356001600160401b03808211156115f057600080fd5b818701915087601f83011261160457600080fd5b81358181111561161357600080fd5b88602082850101111561162557600080fd5b95989497505060200194505050565b6000806000806080858703121561164a57600080fd5b8435611655816111a4565b93506020850135611665816111a4565b92506040850135611675816111a4565b91506060850135611685816111a4565b939692955090935050565b600080858511156116a057600080fd5b838611156116ad57600080fd5b5050820193919092039150565b803560208310156103ae57600019602084900360031b1b1692915050565b60005b838110156116f35781810151838201526020016116db565b50506000910152565b60006020828403121561170e57600080fd5b81516001600160401b0381111561172457600080fd5b8201601f8101841361173557600080fd5b80516117436113d58261141f565b81815285602083850101111561175857600080fd5b6117698260208301602086016116d8565b95945050505050565b6000815180845261178a8160208601602086016116d8565b601f01601f19169290920160200192915050565b8381526001600160a01b038316602082015260606040820181905260009061176990830184611772565b6001600160a01b03831681526040602082018190526000906117ec90830184611772565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b85811015611880578135611865816111a4565b6001600160a01b031687529582019590820190600101611852565b509495945050505050565b81835260006001600160fb1b038311156118a457600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c0606082018190526000906118f0908301888a611842565b828103608084015261190381878961188b565b905082810360a084015261191881858761188b565b9c9b505050505050505050505050565b60608152600061193c60608301888a611842565b828103602084015261194f81878961188b565b9050828103604084015261196481858761188b565b9998505050505050505050565b600080600080600060a0868803121561198957600080fd5b8535611994816111a4565b945060208601356119a4816111a4565b935060408601356119b4816111a4565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c087890312156119fb57600080fd5b86359550602080880135611a0e816111a4565b95506040880135611a1e816111a4565b945060608801356001600160401b0380821115611a3a57600080fd5b818a0191508a601f830112611a4e57600080fd5b8135611a5c6113d582611391565b81815260059190911b8301840190848101908d831115611a7b57600080fd5b938501935b82851015611aa2578435611a93816111a4565b82529385019390850190611a80565b9750505060808a0135925080831115611aba57600080fd5b611ac68b848c016113b4565b945060a08a0135925080831115611adc57600080fd5b5050611aea89828a016113b4565b9150509295509295509295565b600081518084526020808501945080840160005b8381101561188057815187529582019590820190600101611b0b565b606080825284519082018190526000906020906080840190828801845b82811015611b695781516001600160a01b031684529284019290840190600101611b44565b50505083810382850152611b7d8187611af7565b9150508281036040840152611b928185611af7565b969550505050505056fea2646970667358221220fca09c260114445d76ac4a1ec1efcbdba6ac7f99d1bccd257e90ed39dcea400d64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ChildMintableERC1155PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildMintableERC1155Predicate","sourceName":"contracts/root/ChildMintableERC1155Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MintableERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"MintableERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MintableERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"MintableERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"MintableTokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newRootERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611f7c806100206000396000f3fe608060405234801561001057600080fd5b50600436106100d55760003560e01c8063b8cd3ec011610087578063b8cd3ec0146101b6578063c5ac2b1c146101c9578063cb10f94c146101f0578063d41f177114610209578063d7c9e3ec14610230578063f43cda8b14610257578063f64512551461026a578063f8c8765e1461029157600080fd5b8063051eb2e2146100da5780637efab4f51461010a57806386937eb41461013357806395c7041c14610148578063b17680651461015b578063b5c5f67214610190578063b68ad1e4146101a3575b600080fd5b6002546100ed906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100ed610118366004611564565b6004602052600090815260409020546001600160a01b031681565b6101466101413660046115d3565b6102a4565b005b6001546100ed906001600160a01b031681565b6101827f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610101565b61014661019e36600461167f565b6102bc565b6003546100ed906001600160a01b031681565b6101466101c43660046116b4565b6102cd565b6101827faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6000546100ed906201000090046001600160a01b031681565b6101827f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101827f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6101466102653660046116fa565b6102df565b6101827f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61014661029f366004611782565b610514565b6102b38787878787878761062d565b50505050505050565b6102c8833384846109ba565b505050565b6102d9848484846109ba565b50505050565b6001546001600160a01b031633146103565760405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204f60448201526e27262cafa2ac24aa2fa422a62822a960891b60648201526084015b60405180910390fd5b6002546001600160a01b038481169116146103ce5760405162461bcd60e51b815260206004820152603260248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204f6044820152714e4c595f524f4f545f50524544494341544560701b606482015260840161034d565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216103fd6020600084866117de565b61040691611808565b036104255761042061041b82602081866117de565b610cd5565b6102d9565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d186104546020600084866117de565b61045d91611808565b0361046c576104208282610f40565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61049b6020600084866117de565b6104a491611808565b036104b35761042082826111ad565b60405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204960448201526f4e56414c49445f5349474e415455524560801b606482015260840161034d565b600054610100900460ff16158080156105345750600054600160ff909116105b8061054e5750303b15801561054e575060005460ff166001145b6105b15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161034d565b6000805460ff1916600117905580156105d4576000805461ff0019166101001790555b6105e085858585611317565b8015610626576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b8661063781611420565b6106535760405162461bcd60e51b815260040161034d90611826565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610693573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b79190611871565b6001600160a01b038181166000908152600460205260409020549192508a81169116146106f65760405162461bcd60e51b815260040161034d9061188e565b6001600160a01b03811661070c5761070c6118db565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610754573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107789190611871565b6001600160a01b03161461078e5761078e6118db565b868514801561079c57508483145b6107fe5760405162461bcd60e51b815260206004820152602d60248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204960448201526c09cac82989288be988a9c8ea89609b1b606482015260840161034d565b604051631ac8311560e21b81526001600160a01b038a1690636b20c454906108329033908a908a908a908a90600401611923565b6020604051808303816000875af1158015610851573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108759190611967565b6108915760405162461bcd60e51b815260040161034d90611989565b6000546002546040516001600160a01b03620100009093048316926316f198319216906108f2907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001611a1c565b6040516020818303038152906040526040518363ffffffff1660e01b815260040161091e929190611acd565b600060405180830381600087803b15801561093857600080fd5b505af115801561094c573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167fdd47868997765508c515e1f8ca079846dafbdfd8f98f6e76bca0891810b9f9d18b8b8b8b8b8b6040516109a796959493929190611af9565b60405180910390a4505050505050505050565b836109c481611420565b6109e05760405162461bcd60e51b815260040161034d90611826565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a20573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a449190611871565b6001600160a01b03818116600090815260046020526040902054919250878116911614610a835760405162461bcd60e51b815260040161034d9061188e565b6001600160a01b038116610a9957610a996118db565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ae1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b059190611871565b6001600160a01b031614610b1b57610b1b6118db565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca90610b4b90339088908890600401611b42565b6020604051808303816000875af1158015610b6a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8e9190611967565b610baa5760405162461bcd60e51b815260040161034d90611989565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352620100009094048416936316f1983193610c429391169160e401611acd565b600060405180830381600087803b158015610c5c57600080fd5b505af1158015610c70573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167fda58d73e08ba3c7767de904e68d208be8291494a9faaf70a6d4f736d24ec1f0f338888604051610cc593929190611b42565b60405180910390a4505050505050565b600080808080610ce786880188611b63565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610d2c5760405162461bcd60e51b815260040161034d9061188e565b610d3581611420565b610d4157610d416118db565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610da59190611871565b9050866001600160a01b0316816001600160a01b031614610dc857610dc86118db565b6001600160a01b038116610dde57610dde6118db565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e26573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e4a9190611871565b6001600160a01b031614610e6057610e606118db565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f690610e9090889088908890600401611b42565b6020604051808303816000875af1158015610eaf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ed39190611967565b610eef5760405162461bcd60e51b815260040161034d90611bbe565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f76a4cd47013e7e58abe817eedbb692d1614d71080b527412ebfb3f91a085a6de8988886040516109a793929190611b42565b600080808080610f5286880188611cdc565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080610f995760405162461bcd60e51b815260040161034d9061188e565b610fa281611420565b610fae57610fae6118db565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fee573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110129190611871565b9050866001600160a01b0316816001600160a01b031614611035576110356118db565b6001600160a01b03811661104b5761104b6118db565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611093573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110b79190611871565b6001600160a01b0316146110cd576110cd6118db565b604051635712868360e01b81526001600160a01b038316906357128683906110fd90889088908890600401611e21565b6020604051808303816000875af115801561111c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111409190611967565b61115c5760405162461bcd60e51b815260040161034d90611bbe565b856001600160a01b0316826001600160a01b0316886001600160a01b03167fc244cac13e0edc863dc5a2c3bd2b935f605b2ed225fb052eaef869bc24b76fde8888886040516109a793929190611e21565b6000806111bc83850185611e96565b9093509150506001600160a01b0382166111d8576111d86118db565b6001600160a01b038281166000908152600460205260409020541615611200576112006118db565b6003546040516bffffffffffffffffffffffff19606085901b166020820152600091611250916001600160a01b0390911690603401604051602081830303815290604052805190602001206114b5565b6001600160a01b0384811660009081526004602081905260409182902080546001600160a01b031916938516938417905590516379ccf11760e11b8152929350909163f399e22e916112a6918791879101611acd565b600060405180830381600087803b1580156112c057600080fd5b505af11580156112d4573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a35050505050565b6001600160a01b0384161580159061133757506001600160a01b03831615155b801561134b57506001600160a01b03821615155b801561135f57506001600160a01b03811615155b6113c55760405162461bcd60e51b815260206004820152603160248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204260448201527020a22fa4a724aa24a0a624ad20aa24a7a760791b606482015260840161034d565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000816001600160a01b03163b60000361143c57506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa9250505080156114a3575060408051601f3d908101601f191682019092526114a091810190611967565b60015b6114af57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166114af5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b604482015260640161034d565b6001600160a01b038116811461156157600080fd5b50565b60006020828403121561157657600080fd5b81356115818161154c565b9392505050565b60008083601f84011261159a57600080fd5b5081356001600160401b038111156115b157600080fd5b6020830191508360208260051b85010111156115cc57600080fd5b9250929050565b60008060008060008060006080888a0312156115ee57600080fd5b87356115f98161154c565b965060208801356001600160401b038082111561161557600080fd5b6116218b838c01611588565b909850965060408a013591508082111561163a57600080fd5b6116468b838c01611588565b909650945060608a013591508082111561165f57600080fd5b5061166c8a828b01611588565b989b979a50959850939692959293505050565b60008060006060848603121561169457600080fd5b833561169f8161154c565b95602085013595506040909401359392505050565b600080600080608085870312156116ca57600080fd5b84356116d58161154c565b935060208501356116e58161154c565b93969395505050506040820135916060013590565b6000806000806060858703121561171057600080fd5b8435935060208501356117228161154c565b925060408501356001600160401b038082111561173e57600080fd5b818701915087601f83011261175257600080fd5b81358181111561176157600080fd5b88602082850101111561177357600080fd5b95989497505060200194505050565b6000806000806080858703121561179857600080fd5b84356117a38161154c565b935060208501356117b38161154c565b925060408501356117c38161154c565b915060608501356117d38161154c565b939692955090935050565b600080858511156117ee57600080fd5b838611156117fb57600080fd5b5050820193919092039150565b803560208310156114af57600019602084900360031b1b1692915050565b6020808252602b908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204e60408201526a13d517d0d3d395149050d560aa1b606082015260800190565b60006020828403121561188357600080fd5b81516115818161154c565b6020808252602d908201527f4368696c644d696e7461626c65455243313135355072656469636174653a205560408201526c2726a0a82822a22faa27a5a2a760991b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561190a57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038616815260606020820181905260009061194890830186886118f1565b828103604084015261195b8185876118f1565b98975050505050505050565b60006020828403121561197957600080fd5b8151801515811461158157600080fd5b6020808252602a908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204260408201526915549397d1905253115160b21b606082015260800190565b8183526000602080850194508260005b85811015611a115781356119f68161154c565b6001600160a01b0316875295820195908201906001016119e3565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090611a4f908301888a6119d3565b8281036080840152611a628187896118f1565b905082810360a0840152611a778185876118f1565b9c9b505050505050505050505050565b6000815180845260005b81811015611aad57602081850181015186830182015201611a91565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611af190830184611a87565b949350505050565b606081526000611b0d60608301888a6119d3565b8281036020840152611b208187896118f1565b90508281036040840152611b358185876118f1565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a08688031215611b7b57600080fd5b8535611b868161154c565b94506020860135611b968161154c565b93506040860135611ba68161154c565b94979396509394606081013594506080013592915050565b6020808252602a908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204d60408201526912539517d1905253115160b21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611c4657611c46611c08565b604052919050565b60006001600160401b03821115611c6757611c67611c08565b5060051b60200190565b600082601f830112611c8257600080fd5b81356020611c97611c9283611c4e565b611c1e565b82815260059290921b84018101918181019086841115611cb657600080fd5b8286015b84811015611cd15780358352918301918301611cba565b509695505050505050565b60008060008060008060c08789031215611cf557600080fd5b86359550602080880135611d088161154c565b95506040880135611d188161154c565b945060608801356001600160401b0380821115611d3457600080fd5b818a0191508a601f830112611d4857600080fd5b8135611d56611c9282611c4e565b81815260059190911b8301840190848101908d831115611d7557600080fd5b938501935b82851015611d9c578435611d8d8161154c565b82529385019390850190611d7a565b9750505060808a0135925080831115611db457600080fd5b611dc08b848c01611c71565b945060a08a0135925080831115611dd657600080fd5b5050611de489828a01611c71565b9150509295509295509295565b600081518084526020808501945080840160005b83811015611a1157815187529582019590820190600101611e05565b606080825284519082018190526000906020906080840190828801845b82811015611e635781516001600160a01b031684529284019290840190600101611e3e565b50505083810382850152611e778187611df1565b9150508281036040840152611e8c8185611df1565b9695505050505050565b600080600060608486031215611eab57600080fd5b83359250602080850135611ebe8161154c565b925060408501356001600160401b0380821115611eda57600080fd5b818701915087601f830112611eee57600080fd5b813581811115611f0057611f00611c08565b611f12601f8201601f19168501611c1e565b91508082528884828501011115611f2857600080fd5b8084840185840137600084828401015250809350505050925092509256fea26469706673582212202548c33121341dfe54a3591ddfb48a0522912106419666b488c71144be4fd23264736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100d55760003560e01c8063b8cd3ec011610087578063b8cd3ec0146101b6578063c5ac2b1c146101c9578063cb10f94c146101f0578063d41f177114610209578063d7c9e3ec14610230578063f43cda8b14610257578063f64512551461026a578063f8c8765e1461029157600080fd5b8063051eb2e2146100da5780637efab4f51461010a57806386937eb41461013357806395c7041c14610148578063b17680651461015b578063b5c5f67214610190578063b68ad1e4146101a3575b600080fd5b6002546100ed906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100ed610118366004611564565b6004602052600090815260409020546001600160a01b031681565b6101466101413660046115d3565b6102a4565b005b6001546100ed906001600160a01b031681565b6101827f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610101565b61014661019e36600461167f565b6102bc565b6003546100ed906001600160a01b031681565b6101466101c43660046116b4565b6102cd565b6101827faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6000546100ed906201000090046001600160a01b031681565b6101827f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101827f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6101466102653660046116fa565b6102df565b6101827f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61014661029f366004611782565b610514565b6102b38787878787878761062d565b50505050505050565b6102c8833384846109ba565b505050565b6102d9848484846109ba565b50505050565b6001546001600160a01b031633146103565760405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204f60448201526e27262cafa2ac24aa2fa422a62822a960891b60648201526084015b60405180910390fd5b6002546001600160a01b038481169116146103ce5760405162461bcd60e51b815260206004820152603260248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204f6044820152714e4c595f524f4f545f50524544494341544560701b606482015260840161034d565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216103fd6020600084866117de565b61040691611808565b036104255761042061041b82602081866117de565b610cd5565b6102d9565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d186104546020600084866117de565b61045d91611808565b0361046c576104208282610f40565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61049b6020600084866117de565b6104a491611808565b036104b35761042082826111ad565b60405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204960448201526f4e56414c49445f5349474e415455524560801b606482015260840161034d565b600054610100900460ff16158080156105345750600054600160ff909116105b8061054e5750303b15801561054e575060005460ff166001145b6105b15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161034d565b6000805460ff1916600117905580156105d4576000805461ff0019166101001790555b6105e085858585611317565b8015610626576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b8661063781611420565b6106535760405162461bcd60e51b815260040161034d90611826565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610693573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b79190611871565b6001600160a01b038181166000908152600460205260409020549192508a81169116146106f65760405162461bcd60e51b815260040161034d9061188e565b6001600160a01b03811661070c5761070c6118db565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610754573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107789190611871565b6001600160a01b03161461078e5761078e6118db565b868514801561079c57508483145b6107fe5760405162461bcd60e51b815260206004820152602d60248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204960448201526c09cac82989288be988a9c8ea89609b1b606482015260840161034d565b604051631ac8311560e21b81526001600160a01b038a1690636b20c454906108329033908a908a908a908a90600401611923565b6020604051808303816000875af1158015610851573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108759190611967565b6108915760405162461bcd60e51b815260040161034d90611989565b6000546002546040516001600160a01b03620100009093048316926316f198319216906108f2907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001611a1c565b6040516020818303038152906040526040518363ffffffff1660e01b815260040161091e929190611acd565b600060405180830381600087803b15801561093857600080fd5b505af115801561094c573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167fdd47868997765508c515e1f8ca079846dafbdfd8f98f6e76bca0891810b9f9d18b8b8b8b8b8b6040516109a796959493929190611af9565b60405180910390a4505050505050505050565b836109c481611420565b6109e05760405162461bcd60e51b815260040161034d90611826565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a20573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a449190611871565b6001600160a01b03818116600090815260046020526040902054919250878116911614610a835760405162461bcd60e51b815260040161034d9061188e565b6001600160a01b038116610a9957610a996118db565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ae1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b059190611871565b6001600160a01b031614610b1b57610b1b6118db565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca90610b4b90339088908890600401611b42565b6020604051808303816000875af1158015610b6a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8e9190611967565b610baa5760405162461bcd60e51b815260040161034d90611989565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352620100009094048416936316f1983193610c429391169160e401611acd565b600060405180830381600087803b158015610c5c57600080fd5b505af1158015610c70573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167fda58d73e08ba3c7767de904e68d208be8291494a9faaf70a6d4f736d24ec1f0f338888604051610cc593929190611b42565b60405180910390a4505050505050565b600080808080610ce786880188611b63565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610d2c5760405162461bcd60e51b815260040161034d9061188e565b610d3581611420565b610d4157610d416118db565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610da59190611871565b9050866001600160a01b0316816001600160a01b031614610dc857610dc86118db565b6001600160a01b038116610dde57610dde6118db565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e26573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e4a9190611871565b6001600160a01b031614610e6057610e606118db565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f690610e9090889088908890600401611b42565b6020604051808303816000875af1158015610eaf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ed39190611967565b610eef5760405162461bcd60e51b815260040161034d90611bbe565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f76a4cd47013e7e58abe817eedbb692d1614d71080b527412ebfb3f91a085a6de8988886040516109a793929190611b42565b600080808080610f5286880188611cdc565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080610f995760405162461bcd60e51b815260040161034d9061188e565b610fa281611420565b610fae57610fae6118db565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fee573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110129190611871565b9050866001600160a01b0316816001600160a01b031614611035576110356118db565b6001600160a01b03811661104b5761104b6118db565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611093573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110b79190611871565b6001600160a01b0316146110cd576110cd6118db565b604051635712868360e01b81526001600160a01b038316906357128683906110fd90889088908890600401611e21565b6020604051808303816000875af115801561111c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111409190611967565b61115c5760405162461bcd60e51b815260040161034d90611bbe565b856001600160a01b0316826001600160a01b0316886001600160a01b03167fc244cac13e0edc863dc5a2c3bd2b935f605b2ed225fb052eaef869bc24b76fde8888886040516109a793929190611e21565b6000806111bc83850185611e96565b9093509150506001600160a01b0382166111d8576111d86118db565b6001600160a01b038281166000908152600460205260409020541615611200576112006118db565b6003546040516bffffffffffffffffffffffff19606085901b166020820152600091611250916001600160a01b0390911690603401604051602081830303815290604052805190602001206114b5565b6001600160a01b0384811660009081526004602081905260409182902080546001600160a01b031916938516938417905590516379ccf11760e11b8152929350909163f399e22e916112a6918791879101611acd565b600060405180830381600087803b1580156112c057600080fd5b505af11580156112d4573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a35050505050565b6001600160a01b0384161580159061133757506001600160a01b03831615155b801561134b57506001600160a01b03821615155b801561135f57506001600160a01b03811615155b6113c55760405162461bcd60e51b815260206004820152603160248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204260448201527020a22fa4a724aa24a0a624ad20aa24a7a760791b606482015260840161034d565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000816001600160a01b03163b60000361143c57506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa9250505080156114a3575060408051601f3d908101601f191682019092526114a091810190611967565b60015b6114af57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166114af5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b604482015260640161034d565b6001600160a01b038116811461156157600080fd5b50565b60006020828403121561157657600080fd5b81356115818161154c565b9392505050565b60008083601f84011261159a57600080fd5b5081356001600160401b038111156115b157600080fd5b6020830191508360208260051b85010111156115cc57600080fd5b9250929050565b60008060008060008060006080888a0312156115ee57600080fd5b87356115f98161154c565b965060208801356001600160401b038082111561161557600080fd5b6116218b838c01611588565b909850965060408a013591508082111561163a57600080fd5b6116468b838c01611588565b909650945060608a013591508082111561165f57600080fd5b5061166c8a828b01611588565b989b979a50959850939692959293505050565b60008060006060848603121561169457600080fd5b833561169f8161154c565b95602085013595506040909401359392505050565b600080600080608085870312156116ca57600080fd5b84356116d58161154c565b935060208501356116e58161154c565b93969395505050506040820135916060013590565b6000806000806060858703121561171057600080fd5b8435935060208501356117228161154c565b925060408501356001600160401b038082111561173e57600080fd5b818701915087601f83011261175257600080fd5b81358181111561176157600080fd5b88602082850101111561177357600080fd5b95989497505060200194505050565b6000806000806080858703121561179857600080fd5b84356117a38161154c565b935060208501356117b38161154c565b925060408501356117c38161154c565b915060608501356117d38161154c565b939692955090935050565b600080858511156117ee57600080fd5b838611156117fb57600080fd5b5050820193919092039150565b803560208310156114af57600019602084900360031b1b1692915050565b6020808252602b908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204e60408201526a13d517d0d3d395149050d560aa1b606082015260800190565b60006020828403121561188357600080fd5b81516115818161154c565b6020808252602d908201527f4368696c644d696e7461626c65455243313135355072656469636174653a205560408201526c2726a0a82822a22faa27a5a2a760991b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561190a57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038616815260606020820181905260009061194890830186886118f1565b828103604084015261195b8185876118f1565b98975050505050505050565b60006020828403121561197957600080fd5b8151801515811461158157600080fd5b6020808252602a908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204260408201526915549397d1905253115160b21b606082015260800190565b8183526000602080850194508260005b85811015611a115781356119f68161154c565b6001600160a01b0316875295820195908201906001016119e3565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090611a4f908301888a6119d3565b8281036080840152611a628187896118f1565b905082810360a0840152611a778185876118f1565b9c9b505050505050505050505050565b6000815180845260005b81811015611aad57602081850181015186830182015201611a91565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611af190830184611a87565b949350505050565b606081526000611b0d60608301888a6119d3565b8281036020840152611b208187896118f1565b90508281036040840152611b358185876118f1565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a08688031215611b7b57600080fd5b8535611b868161154c565b94506020860135611b968161154c565b93506040860135611ba68161154c565b94979396509394606081013594506080013592915050565b6020808252602a908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204d60408201526912539517d1905253115160b21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611c4657611c46611c08565b604052919050565b60006001600160401b03821115611c6757611c67611c08565b5060051b60200190565b600082601f830112611c8257600080fd5b81356020611c97611c9283611c4e565b611c1e565b82815260059290921b84018101918181019086841115611cb657600080fd5b8286015b84811015611cd15780358352918301918301611cba565b509695505050505050565b60008060008060008060c08789031215611cf557600080fd5b86359550602080880135611d088161154c565b95506040880135611d188161154c565b945060608801356001600160401b0380821115611d3457600080fd5b818a0191508a601f830112611d4857600080fd5b8135611d56611c9282611c4e565b81815260059190911b8301840190848101908d831115611d7557600080fd5b938501935b82851015611d9c578435611d8d8161154c565b82529385019390850190611d7a565b9750505060808a0135925080831115611db457600080fd5b611dc08b848c01611c71565b945060a08a0135925080831115611dd657600080fd5b5050611de489828a01611c71565b9150509295509295509295565b600081518084526020808501945080840160005b83811015611a1157815187529582019590820190600101611e05565b606080825284519082018190526000906020906080840190828801845b82811015611e635781516001600160a01b031684529284019290840190600101611e3e565b50505083810382850152611e778187611df1565b9150508281036040840152611e8c8185611df1565b9695505050505050565b600080600060608486031215611eab57600080fd5b83359250602080850135611ebe8161154c565b925060408501356001600160401b0380821115611eda57600080fd5b818701915087601f830112611eee57600080fd5b813581811115611f0057611f00611c08565b611f12601f8201601f19168501611c1e565b91508082528884828501011115611f2857600080fd5b8084840185840137600084828401015250809350505050925092509256fea26469706673582212202548c33121341dfe54a3591ddfb48a0522912106419666b488c71144be4fd23264736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var CustomSupernetManagerArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"CustomSupernetManager","sourceName":"contracts/root/staking/CustomSupernetManager.sol","abi":[{"inputs":[{"internalType":"address","name":"validator","type":"address"}],"name":"InvalidSignature","type":"error"},{"inputs":[{"internalType":"string","name":"message","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"}],"name":"AddedToWhitelist","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"GenesisBalanceAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"amountValidators","type":"uint256"}],"name":"GenesisFinalized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"}],"name":"RemovedFromWhitelist","type":"event"},{"anonymous":false,"inputs":[],"name":"StakingEnabled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"}],"name":"ValidatorDeactivated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"},{"indexed":false,"internalType":"uint256[4]","name":"blsKey","type":"uint256[4]"}],"name":"ValidatorRegistered","type":"event"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"addGenesisBalance","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"domain","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"enableStaking","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"finalizeGenesis","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"genesisBalances","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"genesisSet","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"initialStake","type":"uint256"}],"internalType":"struct GenesisValidator[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"validator_","type":"address"}],"name":"getValidator","outputs":[{"components":[{"internalType":"uint256[4]","name":"blsKey","type":"uint256[4]"},{"internalType":"uint256","name":"stake","type":"uint256"},{"internalType":"bool","name":"isWhitelisted","type":"bool"},{"internalType":"bool","name":"isActive","type":"bool"}],"internalType":"struct Validator","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"id","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStakeManager","type":"address"},{"internalType":"address","name":"newBls","type":"address"},{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newMatic","type":"address"},{"internalType":"address","name":"newChildValidatorSet","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newRootERC20Predicate","type":"address"},{"internalType":"string","name":"newDomain","type":"string"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id_","type":"uint256"}],"name":"onInit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"validator","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"onStake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[2]","name":"signature","type":"uint256[2]"},{"internalType":"uint256[4]","name":"pubkey","type":"uint256[4]"}],"name":"register","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"validators","outputs":[{"internalType":"uint256","name":"stake","type":"uint256"},{"internalType":"bool","name":"isWhitelisted","type":"bool"},{"internalType":"bool","name":"isActive","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"validators_","type":"address[]"}],"name":"whitelistValidators","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506121a0806100206000396000f3fe608060405234801561001057600080fd5b506004361061012c5760003560e01c80638da5cb5b116100ad578063e30c397811610071578063e30c397814610248578063e53b87a814610259578063f2fde38b14610279578063f43cda8b1461028c578063fa52c7d81461029f57600080fd5b80638da5cb5b146101e65780639e19e9c11461020b578063af640d0f14610220578063c2fb26a614610237578063d11aca621461024057600080fd5b806379ba5097116100f457806379ba50971461019d578063819dc9fb146101a557806385758cc7146101b857806386202194146101c05780638c087b1c146101d357600080fd5b80631904bb2e146101315780631f6590b81461015a578063344a5e641461016f578063542c85f214610182578063715018a614610195575b600080fd5b61014461013f366004611a3d565b6102f2565b6040516101519190611a5a565b60405180910390f35b61016d610168366004611aae565b61037c565b005b61016d61017d366004611af0565b610449565b61016d610190366004611b09565b6104c8565b61016d610523565b61016d610537565b61016d6101b3366004611b94565b6105b1565b61016d610819565b61016d6101ce366004611af0565b61086a565b61016d6101e1366004611cc8565b610b17565b6033546001600160a01b03165b6040516001600160a01b039091168152602001610151565b610213610b4f565b6040516101519190611cf4565b61022960985481565b604051908152602001610151565b61022960d05481565b61016d610b60565b6065546001600160a01b03166101f3565b610229610267366004611a3d565b60d66020526000908152604090205481565b61016d610287366004611a3d565b610b9d565b61016d61029a366004611d4c565b610c0e565b6102d56102ad366004611a3d565b60d4602052600090815260409020600481015460059091015460ff8082169161010090041683565b604080519384529115156020840152151590820152606001610151565b6102fa61196b565b6001600160a01b038216600090815260d46020526040908190208151610100810190925281608081018260048282826020028201915b8154815260200190600101908083116103305750505091835250506004820154602082015260059091015460ff8082161515604084015261010090910416151560609091015292915050565b33600090815260d460205260409020600581015460ff166103d15760405163973d02cb60e01b815260206004820152600960248201526815d2125511531254d560ba1b60448201526064015b60405180910390fd5b6103dc338484610ce2565b6103e881836004611999565b5060058101805461ff00191661010017905561040333610dda565b336001600160a01b03167f110ae3ae039a4632f836a35dc9b1282df88780883fb28779f22c2f7ccde8dd0a8360405161043c9190611dd5565b60405180910390a2505050565b6097546001600160a01b031633146104735760405162461bcd60e51b81526004016103c890611de4565b609854156104c35760405162461bcd60e51b815260206004820152601f60248201527f53757065726e65744d616e616765723a2049445f414c52454144595f5345540060448201526064016103c8565b609855565b6104d0610e26565b8060005b8181101561051d5761050b8484838181106104f1576104f1611e27565b90506020020160208101906105069190611a3d565b610e80565b8061051581611e53565b9150506104d4565b50505050565b61052b610e26565b6105356000610ecf565b565b60655433906001600160a01b031681146105a55760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016103c8565b6105ae81610ecf565b50565b600054610100900460ff16158080156105d15750600054600160ff909116105b806105eb5750303b1580156105eb575060005460ff166001145b61064e5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016103c8565b6000805460ff191660011790558015610671576000805461ff0019166101001790555b6001600160a01b0389161580159061069157506001600160a01b03881615155b80156106a557506001600160a01b03871615155b80156106b957506001600160a01b03861615155b80156106cd57506001600160a01b03851615155b80156106e157506001600160a01b03841615155b80156106ed5750815115155b6107295760405162461bcd60e51b815260206004820152600d60248201526c1253959053125117d253941555609a1b60448201526064016103c8565b61073289610ee8565b60cb80546001600160a01b03199081166001600160a01b038b81169190911790925560cc805482168a841617905560cd8054821689841617905560ce8054821688841617905560cf8054821687841617905560d580549091169185169190911790556040516107a5908390602001611e90565b60408051601f19818403018152919052805160209091012060d0556107c8610f31565b801561080e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050505050565b610821610e26565b61082b60d1610f60565b7f87f41ee3facb6317b1c2811e539539ac1693525b4460699b4245e8aac9f590cb61085660d1610fda565b5160405190815260200160405180910390a1565b600081116108c85760405162461bcd60e51b815260206004820152602560248201527f437573746f6d53757065726e65744d616e616765723a20494e56414c49445f416044820152641353d5539560da1b60648201526084016103c8565b60d5546001600160a01b031661093f5760405163973d02cb60e01b815260206004820152603560248201527f437573746f6d53757065726e65744d616e616765723a20554e444546494e45446044820152745f524f4f545f45524332305f50524544494341544560581b60648201526084016103c8565b60d55460408051636a00c1d760e01b815290516000926001600160a01b031691636a00c1d7916004808301926020929190829003018187875af115801561098a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109ae9190611eac565b90506001600160a01b038116610a225760405163973d02cb60e01b815260206004820152603260248201527f437573746f6d53757065726e65744d616e616765723a20554e444546494e454460448201527117d3905512559157d513d2d15397d493d3d560721b60648201526084016103c8565b610a2c60d1611053565b15610a995760405162461bcd60e51b815260206004820152603760248201527f437573746f6d53757065726e65744d616e616765723a2047454e455349535f53604482015276115517d254d7d053149150511657d19253905312569151604a1b60648201526084016103c8565b610aa660d1336000611078565b33600090815260d6602052604081208054849290610ac5908490611ec9565b909155505060d554610ae6906001600160a01b038381169133911685611193565b604051829033907f1706c887e0f7786a7e97fed7b6f19bd6b31854c47c2012b072b44fdbd652623990600090a35050565b6097546001600160a01b03163314610b415760405162461bcd60e51b81526004016103c890611de4565b610b4b82826111ed565b5050565b6060610b5b60d1610fda565b905090565b610b68610e26565b610b7260d161136b565b6040517fda917aeab736a19e4ba54207413dbe4f8c7d558fde2c14d7e66fc8f7186ea8a390600090a1565b610ba5610e26565b606580546001600160a01b0383166001600160a01b03199091168117909155610bd66033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60cf546001600160a01b031633141580610c36575060ce546001600160a01b03848116911614155b15610c725760405163973d02cb60e01b815260206004820152600b60248201526a2fb2bc34ba2432b63832b960a91b60448201526064016103c8565b7f8ca9a95e41b5eece253c93f5b31eed1253aed6b145d8a6e14d913fdf8e732293610ca1602060008486611edc565b610caa91611f06565b0361051d57600080610cbf8360208187611edc565b810190610ccc9190611cc8565b91509150610cda8282611442565b505050505050565b8135158015610cf357506020820135155b15610d1c57604051633615713d60e21b81526001600160a01b03841660048201526024016103c8565b60cb5460009081906001600160a01b031663ebbdac918585610d3d896114b1565b6040518463ffffffff1660e01b8152600401610d5b93929190611f24565b6040805180830381865afa158015610d77573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d9b9190611f7d565b91509150801580610daa575081155b15610dd357604051633615713d60e21b81526001600160a01b03861660048201526024016103c8565b5050505050565b6001600160a01b038116600081815260d46020526040808220600501805460ff19169055517fcdd2e9b91a56913d370075169cefa1602ba36be5301664f752192bb1709df7579190a250565b6033546001600160a01b031633146105355760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103c8565b6001600160a01b038116600081815260d46020526040808220600501805460ff19166001179055517fa850ae9193f515cbae8d35e8925bd2be26627fc91bce650b8652ed254e9cab039190a250565b606580546001600160a01b03191690556105ae81611573565b600054610100900460ff16610f0f5760405162461bcd60e51b81526004016103c890611fb0565b609780546001600160a01b0319166001600160a01b0392909216919091179055565b600054610100900460ff16610f585760405162461bcd60e51b81526004016103c890611fb0565b6105356115c5565b6000600182015460ff166002811115610f7b57610f7b611ffb565b14610fc85760405162461bcd60e51b815260206004820152601d60248201527f47656e657369734c69623a20616c72656164792066696e616c697a656400000060448201526064016103c8565b6001908101805460ff19169091179055565b606081600001805480602002602001604051908101604052809291908181526020016000905b82821015611048576000848152602090819020604080518082019091526002850290910180546001600160a01b03168252600190810154828401529083529092019101611000565b505050509050919050565b600060025b600183015460ff16600281111561107157611071611ffb565b1492915050565b6000600184015460ff16600281111561109357611093611ffb565b146110a0576110a0612011565b6001600160a01b03821660009081526002840160205260408120549081900361113d5783546110d0906001611ec9565b6001600160a01b03848116600081815260028881016020908152604080842087905580518082019091529384528381018881528a5460018082018d558c86529290942094519390920290930180546001600160a01b0319169290941691909117835551910155905061051d565b600061114985856115f5565b9050600085600001828154811061116257611162611e27565b90600052602060002090600202019050838160010160008282546111869190611ec9565b9091555050505050505050565b604080516001600160a01b0385811660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b17905261051d908590611632565b6001600160a01b038216600090815260d460205260409020600501548290610100900460ff1661124c5760405163973d02cb60e01b81526020600482015260096024820152682b20a624a220aa27a960b91b60448201526064016103c8565b61125660d1611707565b1561126c5761126760d18484611078565b505050565b61127660d1611053565b1561132f5760cc5460ce54604080517f1bcc0f4c3fad314e585165815f94ecca9b96690a26d6417d7876448a9a867a6960208201526001600160a01b038781168284015260608083018890528351808403909101815260808301938490526316f1983160e01b909352938416936316f19831936112f893911691608401612053565b600060405180830381600087803b15801561131257600080fd5b505af1158015611326573d6000803e3d6000fd5b50505050505050565b60405163973d02cb60e01b815260206004820152601060248201526f5761697420666f722067656e6573697360801b60448201526064016103c8565b600181015460ff16600081600281111561138757611387611ffb565b036113d05760405162461bcd60e51b815260206004820152601960248201527811d95b995cda5cd31a588e881b9bdd08199a5b985b1a5e9959603a1b60448201526064016103c8565b60028160028111156113e4576113e4611ffb565b036114315760405162461bcd60e51b815260206004820152601b60248201527f47656e657369734c69623a20616c726561647920656e61626c6564000000000060448201526064016103c8565b50600101805460ff19166002179055565b609754604051633651bb1d60e01b81526001600160a01b0384811660048301526024820184905290911690633651bb1d90604401600060405180830381600087803b15801561149057600080fd5b505af11580156114a4573d6000803e3d6000fd5b50505050610b4b8261170f565b6114b96119d7565b60cb5460d0546040516bffffffffffffffffffffffff19606086811b8216602084015230901b1660348201524660488201526001600160a01b039092169163a850a90991906068016040516020818303038152906040526040518363ffffffff1660e01b815260040161152d929190612077565b6040805180830381865afa158015611549573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061156d9190612090565b92915050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff166115ec5760405162461bcd60e51b81526004016103c890611fb0565b61053533610ecf565b6001600160a01b03811660009081526002830160205260408120549081900361162057611620612011565b61162b600182612110565b9392505050565b6000611687826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166117db9092919063ffffffff16565b90508051600014806116a85750808060200190518101906116a89190612123565b6112675760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016103c8565b600080611058565b609754609854604051633b61c5a760e21b81526001600160a01b038481166004830152602482019290925291169063ed87169c90604401602060405180830381865afa158015611763573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611787919061213e565b6000036105ae576001600160a01b038116600081815260d46020526040808220600501805461ff0019169055517f23d934bfe7f1275bc6fd70432159c9cc1c0075d069f89da6a40f43bfe7a94ed39190a250565b60606117ea84846000856117f2565b949350505050565b6060824710156118535760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016103c8565b600080866001600160a01b0316858760405161186f9190611e90565b60006040518083038185875af1925050503d80600081146118ac576040519150601f19603f3d011682016040523d82523d6000602084013e6118b1565b606091505b50915091506118c2878383876118cd565b979650505050505050565b6060831561193c578251600003611935576001600160a01b0385163b6119355760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016103c8565b50816117ea565b6117ea83838151156119515781518083602001fd5b8060405162461bcd60e51b81526004016103c89190612157565b604051806080016040528061197e6119f5565b81526000602082018190526040820181905260609091015290565b82600481019282156119c7579160200282015b828111156119c75782358255916020019190600101906119ac565b506119d3929150611a13565b5090565b60405180604001604052806002906020820280368337509192915050565b60405180608001604052806004906020820280368337509192915050565b5b808211156119d35760008155600101611a14565b6001600160a01b03811681146105ae57600080fd5b600060208284031215611a4f57600080fd5b813561162b81611a28565b815160e08201908260005b6004811015611a84578251825260209283019290910190600101611a65565b505050602083015160808301526040830151151560a0830152606090920151151560c09091015290565b60008060c08385031215611ac157600080fd5b6040830184811115611ad257600080fd5b8392508460c085011115611ae557600080fd5b809150509250929050565b600060208284031215611b0257600080fd5b5035919050565b60008060208385031215611b1c57600080fd5b823567ffffffffffffffff80821115611b3457600080fd5b818501915085601f830112611b4857600080fd5b813581811115611b5757600080fd5b8660208260051b8501011115611b6c57600080fd5b60209290920196919550909350505050565b634e487b7160e01b600052604160045260246000fd5b600080600080600080600080610100898b031215611bb157600080fd5b8835611bbc81611a28565b97506020890135611bcc81611a28565b96506040890135611bdc81611a28565b95506060890135611bec81611a28565b94506080890135611bfc81611a28565b935060a0890135611c0c81611a28565b925060c0890135611c1c81611a28565b915060e089013567ffffffffffffffff80821115611c3957600080fd5b818b0191508b601f830112611c4d57600080fd5b813581811115611c5f57611c5f611b7e565b604051601f8201601f19908116603f01168101908382118183101715611c8757611c87611b7e565b816040528281528e6020848701011115611ca057600080fd5b8260208601602083013760006020848301015280955050505050509295985092959890939650565b60008060408385031215611cdb57600080fd5b8235611ce681611a28565b946020939093013593505050565b602080825282518282018190526000919060409081850190868401855b82811015611d3f57815180516001600160a01b03168552860151868501529284019290850190600101611d11565b5091979650505050505050565b60008060008060608587031215611d6257600080fd5b843593506020850135611d7481611a28565b9250604085013567ffffffffffffffff80821115611d9157600080fd5b818701915087601f830112611da557600080fd5b813581811115611db457600080fd5b886020828501011115611dc657600080fd5b95989497505060200194505050565b60808181019083833792915050565b60208082526023908201527f53757065726e65744d616e616765723a204f4e4c595f5354414b455f4d414e4160408201526223a2a960e91b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060018201611e6557611e65611e3d565b5060010190565b60005b83811015611e87578181015183820152602001611e6f565b50506000910152565b60008251611ea2818460208701611e6c565b9190910192915050565b600060208284031215611ebe57600080fd5b815161162b81611a28565b8082018082111561156d5761156d611e3d565b60008085851115611eec57600080fd5b83861115611ef957600080fd5b5050820193919092039150565b8035602083101561156d57600019602084900360031b1b1692915050565b61010081016040858337608084604084013760c082018360005b6002811015611f5d578151835260209283019290910190600101611f3e565b505050949350505050565b80518015158114611f7857600080fd5b919050565b60008060408385031215611f9057600080fd5b611f9983611f68565b9150611fa760208401611f68565b90509250929050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052600160045260246000fd5b6000815180845261203f816020860160208601611e6c565b601f01601f19169290920160200192915050565b6001600160a01b03831681526040602082018190526000906117ea90830184612027565b8281526040602082015260006117ea6040830184612027565b6000604082840312156120a257600080fd5b82601f8301126120b157600080fd5b6040516040810181811067ffffffffffffffff821117156120d4576120d4611b7e565b80604052508060408401858111156120eb57600080fd5b845b818110156121055780518352602092830192016120ed565b509195945050505050565b8181038181111561156d5761156d611e3d565b60006020828403121561213557600080fd5b61162b82611f68565b60006020828403121561215057600080fd5b5051919050565b60208152600061162b602083018461202756fea2646970667358221220c854c4bd92b5e40db8e0e9b90d5bc01c31cbec4f50c64ece828835f89a96927664736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b506004361061012c5760003560e01c80638da5cb5b116100ad578063e30c397811610071578063e30c397814610248578063e53b87a814610259578063f2fde38b14610279578063f43cda8b1461028c578063fa52c7d81461029f57600080fd5b80638da5cb5b146101e65780639e19e9c11461020b578063af640d0f14610220578063c2fb26a614610237578063d11aca621461024057600080fd5b806379ba5097116100f457806379ba50971461019d578063819dc9fb146101a557806385758cc7146101b857806386202194146101c05780638c087b1c146101d357600080fd5b80631904bb2e146101315780631f6590b81461015a578063344a5e641461016f578063542c85f214610182578063715018a614610195575b600080fd5b61014461013f366004611a3d565b6102f2565b6040516101519190611a5a565b60405180910390f35b61016d610168366004611aae565b61037c565b005b61016d61017d366004611af0565b610449565b61016d610190366004611b09565b6104c8565b61016d610523565b61016d610537565b61016d6101b3366004611b94565b6105b1565b61016d610819565b61016d6101ce366004611af0565b61086a565b61016d6101e1366004611cc8565b610b17565b6033546001600160a01b03165b6040516001600160a01b039091168152602001610151565b610213610b4f565b6040516101519190611cf4565b61022960985481565b604051908152602001610151565b61022960d05481565b61016d610b60565b6065546001600160a01b03166101f3565b610229610267366004611a3d565b60d66020526000908152604090205481565b61016d610287366004611a3d565b610b9d565b61016d61029a366004611d4c565b610c0e565b6102d56102ad366004611a3d565b60d4602052600090815260409020600481015460059091015460ff8082169161010090041683565b604080519384529115156020840152151590820152606001610151565b6102fa61196b565b6001600160a01b038216600090815260d46020526040908190208151610100810190925281608081018260048282826020028201915b8154815260200190600101908083116103305750505091835250506004820154602082015260059091015460ff8082161515604084015261010090910416151560609091015292915050565b33600090815260d460205260409020600581015460ff166103d15760405163973d02cb60e01b815260206004820152600960248201526815d2125511531254d560ba1b60448201526064015b60405180910390fd5b6103dc338484610ce2565b6103e881836004611999565b5060058101805461ff00191661010017905561040333610dda565b336001600160a01b03167f110ae3ae039a4632f836a35dc9b1282df88780883fb28779f22c2f7ccde8dd0a8360405161043c9190611dd5565b60405180910390a2505050565b6097546001600160a01b031633146104735760405162461bcd60e51b81526004016103c890611de4565b609854156104c35760405162461bcd60e51b815260206004820152601f60248201527f53757065726e65744d616e616765723a2049445f414c52454144595f5345540060448201526064016103c8565b609855565b6104d0610e26565b8060005b8181101561051d5761050b8484838181106104f1576104f1611e27565b90506020020160208101906105069190611a3d565b610e80565b8061051581611e53565b9150506104d4565b50505050565b61052b610e26565b6105356000610ecf565b565b60655433906001600160a01b031681146105a55760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016103c8565b6105ae81610ecf565b50565b600054610100900460ff16158080156105d15750600054600160ff909116105b806105eb5750303b1580156105eb575060005460ff166001145b61064e5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016103c8565b6000805460ff191660011790558015610671576000805461ff0019166101001790555b6001600160a01b0389161580159061069157506001600160a01b03881615155b80156106a557506001600160a01b03871615155b80156106b957506001600160a01b03861615155b80156106cd57506001600160a01b03851615155b80156106e157506001600160a01b03841615155b80156106ed5750815115155b6107295760405162461bcd60e51b815260206004820152600d60248201526c1253959053125117d253941555609a1b60448201526064016103c8565b61073289610ee8565b60cb80546001600160a01b03199081166001600160a01b038b81169190911790925560cc805482168a841617905560cd8054821689841617905560ce8054821688841617905560cf8054821687841617905560d580549091169185169190911790556040516107a5908390602001611e90565b60408051601f19818403018152919052805160209091012060d0556107c8610f31565b801561080e576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050505050565b610821610e26565b61082b60d1610f60565b7f87f41ee3facb6317b1c2811e539539ac1693525b4460699b4245e8aac9f590cb61085660d1610fda565b5160405190815260200160405180910390a1565b600081116108c85760405162461bcd60e51b815260206004820152602560248201527f437573746f6d53757065726e65744d616e616765723a20494e56414c49445f416044820152641353d5539560da1b60648201526084016103c8565b60d5546001600160a01b031661093f5760405163973d02cb60e01b815260206004820152603560248201527f437573746f6d53757065726e65744d616e616765723a20554e444546494e45446044820152745f524f4f545f45524332305f50524544494341544560581b60648201526084016103c8565b60d55460408051636a00c1d760e01b815290516000926001600160a01b031691636a00c1d7916004808301926020929190829003018187875af115801561098a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109ae9190611eac565b90506001600160a01b038116610a225760405163973d02cb60e01b815260206004820152603260248201527f437573746f6d53757065726e65744d616e616765723a20554e444546494e454460448201527117d3905512559157d513d2d15397d493d3d560721b60648201526084016103c8565b610a2c60d1611053565b15610a995760405162461bcd60e51b815260206004820152603760248201527f437573746f6d53757065726e65744d616e616765723a2047454e455349535f53604482015276115517d254d7d053149150511657d19253905312569151604a1b60648201526084016103c8565b610aa660d1336000611078565b33600090815260d6602052604081208054849290610ac5908490611ec9565b909155505060d554610ae6906001600160a01b038381169133911685611193565b604051829033907f1706c887e0f7786a7e97fed7b6f19bd6b31854c47c2012b072b44fdbd652623990600090a35050565b6097546001600160a01b03163314610b415760405162461bcd60e51b81526004016103c890611de4565b610b4b82826111ed565b5050565b6060610b5b60d1610fda565b905090565b610b68610e26565b610b7260d161136b565b6040517fda917aeab736a19e4ba54207413dbe4f8c7d558fde2c14d7e66fc8f7186ea8a390600090a1565b610ba5610e26565b606580546001600160a01b0383166001600160a01b03199091168117909155610bd66033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60cf546001600160a01b031633141580610c36575060ce546001600160a01b03848116911614155b15610c725760405163973d02cb60e01b815260206004820152600b60248201526a2fb2bc34ba2432b63832b960a91b60448201526064016103c8565b7f8ca9a95e41b5eece253c93f5b31eed1253aed6b145d8a6e14d913fdf8e732293610ca1602060008486611edc565b610caa91611f06565b0361051d57600080610cbf8360208187611edc565b810190610ccc9190611cc8565b91509150610cda8282611442565b505050505050565b8135158015610cf357506020820135155b15610d1c57604051633615713d60e21b81526001600160a01b03841660048201526024016103c8565b60cb5460009081906001600160a01b031663ebbdac918585610d3d896114b1565b6040518463ffffffff1660e01b8152600401610d5b93929190611f24565b6040805180830381865afa158015610d77573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d9b9190611f7d565b91509150801580610daa575081155b15610dd357604051633615713d60e21b81526001600160a01b03861660048201526024016103c8565b5050505050565b6001600160a01b038116600081815260d46020526040808220600501805460ff19169055517fcdd2e9b91a56913d370075169cefa1602ba36be5301664f752192bb1709df7579190a250565b6033546001600160a01b031633146105355760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103c8565b6001600160a01b038116600081815260d46020526040808220600501805460ff19166001179055517fa850ae9193f515cbae8d35e8925bd2be26627fc91bce650b8652ed254e9cab039190a250565b606580546001600160a01b03191690556105ae81611573565b600054610100900460ff16610f0f5760405162461bcd60e51b81526004016103c890611fb0565b609780546001600160a01b0319166001600160a01b0392909216919091179055565b600054610100900460ff16610f585760405162461bcd60e51b81526004016103c890611fb0565b6105356115c5565b6000600182015460ff166002811115610f7b57610f7b611ffb565b14610fc85760405162461bcd60e51b815260206004820152601d60248201527f47656e657369734c69623a20616c72656164792066696e616c697a656400000060448201526064016103c8565b6001908101805460ff19169091179055565b606081600001805480602002602001604051908101604052809291908181526020016000905b82821015611048576000848152602090819020604080518082019091526002850290910180546001600160a01b03168252600190810154828401529083529092019101611000565b505050509050919050565b600060025b600183015460ff16600281111561107157611071611ffb565b1492915050565b6000600184015460ff16600281111561109357611093611ffb565b146110a0576110a0612011565b6001600160a01b03821660009081526002840160205260408120549081900361113d5783546110d0906001611ec9565b6001600160a01b03848116600081815260028881016020908152604080842087905580518082019091529384528381018881528a5460018082018d558c86529290942094519390920290930180546001600160a01b0319169290941691909117835551910155905061051d565b600061114985856115f5565b9050600085600001828154811061116257611162611e27565b90600052602060002090600202019050838160010160008282546111869190611ec9565b9091555050505050505050565b604080516001600160a01b0385811660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b17905261051d908590611632565b6001600160a01b038216600090815260d460205260409020600501548290610100900460ff1661124c5760405163973d02cb60e01b81526020600482015260096024820152682b20a624a220aa27a960b91b60448201526064016103c8565b61125660d1611707565b1561126c5761126760d18484611078565b505050565b61127660d1611053565b1561132f5760cc5460ce54604080517f1bcc0f4c3fad314e585165815f94ecca9b96690a26d6417d7876448a9a867a6960208201526001600160a01b038781168284015260608083018890528351808403909101815260808301938490526316f1983160e01b909352938416936316f19831936112f893911691608401612053565b600060405180830381600087803b15801561131257600080fd5b505af1158015611326573d6000803e3d6000fd5b50505050505050565b60405163973d02cb60e01b815260206004820152601060248201526f5761697420666f722067656e6573697360801b60448201526064016103c8565b600181015460ff16600081600281111561138757611387611ffb565b036113d05760405162461bcd60e51b815260206004820152601960248201527811d95b995cda5cd31a588e881b9bdd08199a5b985b1a5e9959603a1b60448201526064016103c8565b60028160028111156113e4576113e4611ffb565b036114315760405162461bcd60e51b815260206004820152601b60248201527f47656e657369734c69623a20616c726561647920656e61626c6564000000000060448201526064016103c8565b50600101805460ff19166002179055565b609754604051633651bb1d60e01b81526001600160a01b0384811660048301526024820184905290911690633651bb1d90604401600060405180830381600087803b15801561149057600080fd5b505af11580156114a4573d6000803e3d6000fd5b50505050610b4b8261170f565b6114b96119d7565b60cb5460d0546040516bffffffffffffffffffffffff19606086811b8216602084015230901b1660348201524660488201526001600160a01b039092169163a850a90991906068016040516020818303038152906040526040518363ffffffff1660e01b815260040161152d929190612077565b6040805180830381865afa158015611549573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061156d9190612090565b92915050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff166115ec5760405162461bcd60e51b81526004016103c890611fb0565b61053533610ecf565b6001600160a01b03811660009081526002830160205260408120549081900361162057611620612011565b61162b600182612110565b9392505050565b6000611687826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166117db9092919063ffffffff16565b90508051600014806116a85750808060200190518101906116a89190612123565b6112675760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016103c8565b600080611058565b609754609854604051633b61c5a760e21b81526001600160a01b038481166004830152602482019290925291169063ed87169c90604401602060405180830381865afa158015611763573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611787919061213e565b6000036105ae576001600160a01b038116600081815260d46020526040808220600501805461ff0019169055517f23d934bfe7f1275bc6fd70432159c9cc1c0075d069f89da6a40f43bfe7a94ed39190a250565b60606117ea84846000856117f2565b949350505050565b6060824710156118535760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016103c8565b600080866001600160a01b0316858760405161186f9190611e90565b60006040518083038185875af1925050503d80600081146118ac576040519150601f19603f3d011682016040523d82523d6000602084013e6118b1565b606091505b50915091506118c2878383876118cd565b979650505050505050565b6060831561193c578251600003611935576001600160a01b0385163b6119355760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016103c8565b50816117ea565b6117ea83838151156119515781518083602001fd5b8060405162461bcd60e51b81526004016103c89190612157565b604051806080016040528061197e6119f5565b81526000602082018190526040820181905260609091015290565b82600481019282156119c7579160200282015b828111156119c75782358255916020019190600101906119ac565b506119d3929150611a13565b5090565b60405180604001604052806002906020820280368337509192915050565b60405180608001604052806004906020820280368337509192915050565b5b808211156119d35760008155600101611a14565b6001600160a01b03811681146105ae57600080fd5b600060208284031215611a4f57600080fd5b813561162b81611a28565b815160e08201908260005b6004811015611a84578251825260209283019290910190600101611a65565b505050602083015160808301526040830151151560a0830152606090920151151560c09091015290565b60008060c08385031215611ac157600080fd5b6040830184811115611ad257600080fd5b8392508460c085011115611ae557600080fd5b809150509250929050565b600060208284031215611b0257600080fd5b5035919050565b60008060208385031215611b1c57600080fd5b823567ffffffffffffffff80821115611b3457600080fd5b818501915085601f830112611b4857600080fd5b813581811115611b5757600080fd5b8660208260051b8501011115611b6c57600080fd5b60209290920196919550909350505050565b634e487b7160e01b600052604160045260246000fd5b600080600080600080600080610100898b031215611bb157600080fd5b8835611bbc81611a28565b97506020890135611bcc81611a28565b96506040890135611bdc81611a28565b95506060890135611bec81611a28565b94506080890135611bfc81611a28565b935060a0890135611c0c81611a28565b925060c0890135611c1c81611a28565b915060e089013567ffffffffffffffff80821115611c3957600080fd5b818b0191508b601f830112611c4d57600080fd5b813581811115611c5f57611c5f611b7e565b604051601f8201601f19908116603f01168101908382118183101715611c8757611c87611b7e565b816040528281528e6020848701011115611ca057600080fd5b8260208601602083013760006020848301015280955050505050509295985092959890939650565b60008060408385031215611cdb57600080fd5b8235611ce681611a28565b946020939093013593505050565b602080825282518282018190526000919060409081850190868401855b82811015611d3f57815180516001600160a01b03168552860151868501529284019290850190600101611d11565b5091979650505050505050565b60008060008060608587031215611d6257600080fd5b843593506020850135611d7481611a28565b9250604085013567ffffffffffffffff80821115611d9157600080fd5b818701915087601f830112611da557600080fd5b813581811115611db457600080fd5b886020828501011115611dc657600080fd5b95989497505060200194505050565b60808181019083833792915050565b60208082526023908201527f53757065726e65744d616e616765723a204f4e4c595f5354414b455f4d414e4160408201526223a2a960e91b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060018201611e6557611e65611e3d565b5060010190565b60005b83811015611e87578181015183820152602001611e6f565b50506000910152565b60008251611ea2818460208701611e6c565b9190910192915050565b600060208284031215611ebe57600080fd5b815161162b81611a28565b8082018082111561156d5761156d611e3d565b60008085851115611eec57600080fd5b83861115611ef957600080fd5b5050820193919092039150565b8035602083101561156d57600019602084900360031b1b1692915050565b61010081016040858337608084604084013760c082018360005b6002811015611f5d578151835260209283019290910190600101611f3e565b505050949350505050565b80518015158114611f7857600080fd5b919050565b60008060408385031215611f9057600080fd5b611f9983611f68565b9150611fa760208401611f68565b90509250929050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052600160045260246000fd5b6000815180845261203f816020860160208601611e6c565b601f01601f19169290920160200192915050565b6001600160a01b03831681526040602082018190526000906117ea90830184612027565b8281526040602082015260006117ea6040830184612027565b6000604082840312156120a257600080fd5b82601f8301126120b157600080fd5b6040516040810181811067ffffffffffffffff821117156120d4576120d4611b7e565b80604052508060408401858111156120eb57600080fd5b845b818110156121055780518352602092830192016120ed565b509195945050505050565b8181038181111561156d5761156d611e3d565b60006020828403121561213557600080fd5b61162b82611f68565b60006020828403121561215057600080fd5b5051919050565b60208152600061162b602083018461202756fea2646970667358221220c854c4bd92b5e40db8e0e9b90d5bc01c31cbec4f50c64ece828835f89a96927664736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var StakeManagerArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"StakeManager","sourceName":"contracts/root/staking/StakeManager.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"manager","type":"address"}],"name":"ChildManagerRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"validator","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"StakeAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"validator","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"StakeRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"},{"indexed":true,"internalType":"address","name":"recipient","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"StakeWithdrawn","type":"event"},{"inputs":[{"internalType":"address","name":"manager","type":"address"}],"name":"idFor","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStakingToken","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"managerOf","outputs":[{"internalType":"contract ISupernetManager","name":"manager","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"manager","type":"address"}],"name":"registerChildChain","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"validator","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"releaseStakeOf","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"stakeFor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"validator","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"stakeOf","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalStake","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"validator","type":"address"}],"name":"totalStakeOf","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"totalStakeOfChild","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawStake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"validator","type":"address"}],"name":"withdrawableStake","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50610e59806100206000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c8063c73a7a1f11610071578063c73a7a1f14610135578063d5364bbf14610148578063d7fbee3d1461015b578063e3f56eaa14610186578063ed87169c14610199578063f90423fe146101ac57600080fd5b80633651bb1d146100b957806339ed8c90146100ce5780638b0e9f3f146100f4578063b64ddbf6146100fc578063c4d66de81461010f578063c606627214610122575b600080fd5b6100cc6100c7366004610cd2565b6101bf565b005b6100e16100dc366004610cfc565b610220565b6040519081526020015b60405180910390f35b6036546100e1565b6100e161010a366004610d15565b610236565b6100cc61011d366004610d15565b610342565b6100cc610130366004610cd2565b610467565b6100cc610143366004610d30565b610472565b6100e1610156366004610d15565b61058f565b61016e610169366004610cfc565b6105ad565b6040516001600160a01b0390911681526020016100eb565b6100e1610194366004610d15565b6105b8565b6100e16101a7366004610cd2565b6105d6565b6100e16101ba366004610d15565b610602565b60006101ca33610602565b90506101d783828461060d565b826001600160a01b0316817fcbc2141407acdf7a77731afda2c1369f3c46e04194b90a9d527385c17608eb0d8460405161021391815260200190565b60405180910390a3505050565b6000818152603860205260408120545b92915050565b6001600160a01b038116600090815260036020526040812054156102a15760405162461bcd60e51b815260206004820152601c60248201527f5374616b654d616e616765723a2049445f414c52454144595f5345540000000060448201526064015b60405180910390fd5b6102aa826106e0565b604051630d12979960e21b8152600481018290529091506001600160a01b0383169063344a5e6490602401600060405180830381600087803b1580156102ef57600080fd5b505af1158015610303573d6000803e3d6000fd5b50506040516001600160a01b03851692508391507f64566eaf28160aee8cce7464dbf8eb54939f81ac929a8ebeea66865ff57963c490600090a3919050565b600054610100900460ff16158080156103625750600054600160ff909116105b8061037c5750303b15801561037c575060005460ff166001145b6103df5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610298565b6000805460ff191660011790558015610402576000805461ff0019166101001790555b606d80546001600160a01b0319166001600160a01b0384161790558015610463576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b610463338383610791565b811580159061048357506001548211155b6104ca5760405162461bcd60e51b815260206004820152601860248201527714dd185ad953585b9859d95c8e881253959053125117d25160421b6044820152606401610298565b606d546104e2906001600160a01b03163330846107f7565b6104ed338383610868565b60006104f8836105ad565b6040516323021ec760e21b8152336004820152602481018490529091506001600160a01b03821690638c087b1c90604401600060405180830381600087803b15801561054357600080fd5b505af1158015610557573d6000803e3d6000fd5b50506040518481523392508591507fc1d3c31619aec7561f6fa519052617aed252a25edaddc5d7428681180516837a90602001610213565b6001600160a01b0381166000908152603a6020526040812054610230565b600061023082610904565b6001600160a01b038116600090815260396020526040812054610230565b6001600160a01b03821660009081526037602090815260408083208484529091528120545b9392505050565b600061023082610978565b6001600160a01b038316600090815260376020908152604080832085845290915281208054839290610640908490610d68565b909155505060008281526038602052604081208054839290610663908490610d68565b90915550506001600160a01b03831660009081526039602052604081208054839290610690908490610d68565b9250508190555080603660008282546106a99190610d68565b90915550506001600160a01b0383166000908152603a6020526040812080548392906106d6908490610d7b565b9091555050505050565b60006001600160a01b0382166107475760405162461bcd60e51b815260206004820152602660248201527f5374616b654d616e616765724368696c64446174613a20494e56414c49445f4160448201526544445245535360d01b6064820152608401610298565b5060018054810190819055600081815260026020908152604080832080546001600160a01b039096166001600160a01b031990961686179055938252600390529190912081905590565b61079b83826109f0565b606d546107b2906001600160a01b03168383610a21565b816001600160a01b0316836001600160a01b03167fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda38360405161021391815260200190565b6040516001600160a01b03808516602483015283166044820152606481018290526108629085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610a56565b50505050565b6001600160a01b03831660009081526037602090815260408083208584529091528120805483929061089b908490610d7b565b9091555050600082815260386020526040812080548392906108be908490610d7b565b90915550506001600160a01b038316600090815260396020526040812080548392906108eb908490610d7b565b9250508190555080603660008282546106d69190610d7b565b6000818152600260205260409020546001600160a01b0316806109735760405162461bcd60e51b815260206004820152602160248201527f5374616b654d616e616765724368696c64446174613a20494e56414c49445f496044820152601160fa1b6064820152608401610298565b919050565b6001600160a01b038116600090815260036020526040812054908190036109735760405162461bcd60e51b815260206004820152602660248201527f5374616b654d616e616765724368696c64446174613a20494e56414c49445f4d60448201526520a720a3a2a960d11b6064820152608401610298565b6001600160a01b0382166000908152603a602052604081208054839290610a18908490610d68565b90915550505050565b6040516001600160a01b038316602482015260448101829052610a5190849063a9059cbb60e01b9060640161082b565b505050565b6000610aab826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610b2b9092919063ffffffff16565b9050805160001480610acc575080806020019051810190610acc9190610d8e565b610a515760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610298565b6060610b3a8484600085610b42565b949350505050565b606082471015610ba35760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610298565b600080866001600160a01b03168587604051610bbf9190610dd4565b60006040518083038185875af1925050503d8060008114610bfc576040519150601f19603f3d011682016040523d82523d6000602084013e610c01565b606091505b5091509150610c1287838387610c1d565b979650505050505050565b60608315610c8c578251600003610c85576001600160a01b0385163b610c855760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610298565b5081610b3a565b610b3a8383815115610ca15781518083602001fd5b8060405162461bcd60e51b81526004016102989190610df0565b80356001600160a01b038116811461097357600080fd5b60008060408385031215610ce557600080fd5b610cee83610cbb565b946020939093013593505050565b600060208284031215610d0e57600080fd5b5035919050565b600060208284031215610d2757600080fd5b6105fb82610cbb565b60008060408385031215610d4357600080fd5b50508035926020909101359150565b634e487b7160e01b600052601160045260246000fd5b8181038181111561023057610230610d52565b8082018082111561023057610230610d52565b600060208284031215610da057600080fd5b815180151581146105fb57600080fd5b60005b83811015610dcb578181015183820152602001610db3565b50506000910152565b60008251610de6818460208701610db0565b9190910192915050565b6020815260008251806020840152610e0f816040850160208701610db0565b601f01601f1916919091016040019291505056fea26469706673582212207f5dfe1cb46bc115076fa23b9ffb2421ed989feee340cc0546c7e357469d57e864736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100b45760003560e01c8063c73a7a1f11610071578063c73a7a1f14610135578063d5364bbf14610148578063d7fbee3d1461015b578063e3f56eaa14610186578063ed87169c14610199578063f90423fe146101ac57600080fd5b80633651bb1d146100b957806339ed8c90146100ce5780638b0e9f3f146100f4578063b64ddbf6146100fc578063c4d66de81461010f578063c606627214610122575b600080fd5b6100cc6100c7366004610cd2565b6101bf565b005b6100e16100dc366004610cfc565b610220565b6040519081526020015b60405180910390f35b6036546100e1565b6100e161010a366004610d15565b610236565b6100cc61011d366004610d15565b610342565b6100cc610130366004610cd2565b610467565b6100cc610143366004610d30565b610472565b6100e1610156366004610d15565b61058f565b61016e610169366004610cfc565b6105ad565b6040516001600160a01b0390911681526020016100eb565b6100e1610194366004610d15565b6105b8565b6100e16101a7366004610cd2565b6105d6565b6100e16101ba366004610d15565b610602565b60006101ca33610602565b90506101d783828461060d565b826001600160a01b0316817fcbc2141407acdf7a77731afda2c1369f3c46e04194b90a9d527385c17608eb0d8460405161021391815260200190565b60405180910390a3505050565b6000818152603860205260408120545b92915050565b6001600160a01b038116600090815260036020526040812054156102a15760405162461bcd60e51b815260206004820152601c60248201527f5374616b654d616e616765723a2049445f414c52454144595f5345540000000060448201526064015b60405180910390fd5b6102aa826106e0565b604051630d12979960e21b8152600481018290529091506001600160a01b0383169063344a5e6490602401600060405180830381600087803b1580156102ef57600080fd5b505af1158015610303573d6000803e3d6000fd5b50506040516001600160a01b03851692508391507f64566eaf28160aee8cce7464dbf8eb54939f81ac929a8ebeea66865ff57963c490600090a3919050565b600054610100900460ff16158080156103625750600054600160ff909116105b8061037c5750303b15801561037c575060005460ff166001145b6103df5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610298565b6000805460ff191660011790558015610402576000805461ff0019166101001790555b606d80546001600160a01b0319166001600160a01b0384161790558015610463576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b610463338383610791565b811580159061048357506001548211155b6104ca5760405162461bcd60e51b815260206004820152601860248201527714dd185ad953585b9859d95c8e881253959053125117d25160421b6044820152606401610298565b606d546104e2906001600160a01b03163330846107f7565b6104ed338383610868565b60006104f8836105ad565b6040516323021ec760e21b8152336004820152602481018490529091506001600160a01b03821690638c087b1c90604401600060405180830381600087803b15801561054357600080fd5b505af1158015610557573d6000803e3d6000fd5b50506040518481523392508591507fc1d3c31619aec7561f6fa519052617aed252a25edaddc5d7428681180516837a90602001610213565b6001600160a01b0381166000908152603a6020526040812054610230565b600061023082610904565b6001600160a01b038116600090815260396020526040812054610230565b6001600160a01b03821660009081526037602090815260408083208484529091528120545b9392505050565b600061023082610978565b6001600160a01b038316600090815260376020908152604080832085845290915281208054839290610640908490610d68565b909155505060008281526038602052604081208054839290610663908490610d68565b90915550506001600160a01b03831660009081526039602052604081208054839290610690908490610d68565b9250508190555080603660008282546106a99190610d68565b90915550506001600160a01b0383166000908152603a6020526040812080548392906106d6908490610d7b565b9091555050505050565b60006001600160a01b0382166107475760405162461bcd60e51b815260206004820152602660248201527f5374616b654d616e616765724368696c64446174613a20494e56414c49445f4160448201526544445245535360d01b6064820152608401610298565b5060018054810190819055600081815260026020908152604080832080546001600160a01b039096166001600160a01b031990961686179055938252600390529190912081905590565b61079b83826109f0565b606d546107b2906001600160a01b03168383610a21565b816001600160a01b0316836001600160a01b03167fb7c918e0e249f999e965cafeb6c664271b3f4317d296461500e71da39f0cbda38360405161021391815260200190565b6040516001600160a01b03808516602483015283166044820152606481018290526108629085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610a56565b50505050565b6001600160a01b03831660009081526037602090815260408083208584529091528120805483929061089b908490610d7b565b9091555050600082815260386020526040812080548392906108be908490610d7b565b90915550506001600160a01b038316600090815260396020526040812080548392906108eb908490610d7b565b9250508190555080603660008282546106d69190610d7b565b6000818152600260205260409020546001600160a01b0316806109735760405162461bcd60e51b815260206004820152602160248201527f5374616b654d616e616765724368696c64446174613a20494e56414c49445f496044820152601160fa1b6064820152608401610298565b919050565b6001600160a01b038116600090815260036020526040812054908190036109735760405162461bcd60e51b815260206004820152602660248201527f5374616b654d616e616765724368696c64446174613a20494e56414c49445f4d60448201526520a720a3a2a960d11b6064820152608401610298565b6001600160a01b0382166000908152603a602052604081208054839290610a18908490610d68565b90915550505050565b6040516001600160a01b038316602482015260448101829052610a5190849063a9059cbb60e01b9060640161082b565b505050565b6000610aab826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610b2b9092919063ffffffff16565b9050805160001480610acc575080806020019051810190610acc9190610d8e565b610a515760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610298565b6060610b3a8484600085610b42565b949350505050565b606082471015610ba35760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610298565b600080866001600160a01b03168587604051610bbf9190610dd4565b60006040518083038185875af1925050503d8060008114610bfc576040519150601f19603f3d011682016040523d82523d6000602084013e610c01565b606091505b5091509150610c1287838387610c1d565b979650505050505050565b60608315610c8c578251600003610c85576001600160a01b0385163b610c855760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610298565b5081610b3a565b610b3a8383815115610ca15781518083602001fd5b8060405162461bcd60e51b81526004016102989190610df0565b80356001600160a01b038116811461097357600080fd5b60008060408385031215610ce557600080fd5b610cee83610cbb565b946020939093013593505050565b600060208284031215610d0e57600080fd5b5035919050565b600060208284031215610d2757600080fd5b6105fb82610cbb565b60008060408385031215610d4357600080fd5b50508035926020909101359150565b634e487b7160e01b600052601160045260246000fd5b8181038181111561023057610230610d52565b8082018082111561023057610230610d52565b600060208284031215610da057600080fd5b815180151581146105fb57600080fd5b60005b83811015610dcb578181015183820152602001610db3565b50506000910152565b60008251610de6818460208701610db0565b9190910192915050565b6020815260008251806020840152610e0f816040850160208701610db0565b601f01601f1916919091016040019291505056fea26469706673582212207f5dfe1cb46bc115076fa23b9ffb2421ed989feee340cc0546c7e357469d57e864736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var RewardPoolArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RewardPool","sourceName":"contracts/child/validator/RewardPool.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"epochId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"totalReward","type":"uint256"}],"name":"RewardDistributed","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseReward","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"epochId","type":"uint256"},{"components":[{"internalType":"address","name":"validator","type":"address"},{"internalType":"uint256","name":"signedBlocks","type":"uint256"}],"internalType":"struct Uptime[]","name":"uptime","type":"tuple[]"}],"name":"distributeRewardFor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newRewardToken","type":"address"},{"internalType":"address","name":"newRewardWallet","type":"address"},{"internalType":"address","name":"newValidatorSet","type":"address"},{"internalType":"uint256","name":"newBaseReward","type":"uint256"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"paidRewardPerEpoch","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"pendingRewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardToken","outputs":[{"internalType":"contract IERC20Upgradeable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardWallet","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"validatorSet","outputs":[{"internalType":"contract IValidatorSet","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdrawReward","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50610ee1806100206000396000f3fe608060405234801561001057600080fd5b50600436106101165760003560e01c80638a9cd82d116100a2578063c885bc5811610071578063c885bc581461020f578063cf756fdf14610217578063e0563ab11461022a578063f7c618c114610233578063fb75b2c71461024c57600080fd5b80638a9cd82d146101d45780639426e226146101e9578063947287cf146101fc57806397e5230d1461020557600080fd5b80633b878c22116100e95780633b878c221461019d57806351351d53146101a657806355b01e4d146101b45780635ea5df79146101c257806376ad03bc146101cb57600080fd5b806307358b991461011b57806307b3e2521461014e578063284017f51461017457806331d7a2621461017d575b600080fd5b61013b610129366004610be0565b60366020526000908152604090205481565b6040519081526020015b60405180910390f35b61015c6004600360981b0181565b6040516001600160a01b039091168152602001610145565b61015c61202081565b61013b61018b366004610c15565b60376020526000908152604090205481565b61015c61101081565b61015c6002600160a01b0381565b61015c6004600160991b0181565b61013b61138881565b61013b60355481565b6101e76101e2366004610c37565b61025f565b005b60345461015c906001600160a01b031681565b61013b61520881565b61013b620249f081565b6101e76106a9565b6101e7610225366004610cb6565b6106df565b61015c61203081565b60325461015c906201000090046001600160a01b031681565b60335461015c906001600160a01b031681565b336002600160a01b03146102a85760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064015b60405180910390fd5b600083815260366020526040902054156103045760405162461bcd60e51b815260206004820152601a60248201527f5245574152445f414c52454144595f4449535452494255544544000000000000604482015260640161029f565b603454604051633f490b0560e21b8152600481018590526000916001600160a01b03169063fd242c1490602401602060405180830381865afa15801561034e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103729190610d01565b9050806000036103ba5760405162461bcd60e51b8152602060048201526013602482015272115413d0d217d393d517d0d3d3535255151151606a1b604482015260640161029f565b60345460408051636265600360e01b815290516000926001600160a01b03169163626560039160048083019260209291908290030181865afa158015610404573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104289190610d01565b90506000818360355461043b9190610d30565b6104459190610d4d565b603454604051630981b24d60e41b8152600481018990529192506000916001600160a01b039091169063981b24d090602401602060405180830381865afa158015610494573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104b89190610d01565b9050846000805b828110156106495760008989838181106104db576104db610d6f565b9050604002018036038101906104f19190610d85565b905087816020015111156105475760405162461bcd60e51b815260206004820152601b60248201527f5349474e45445f424c4f434b535f455843454544535f544f54414c0000000000604482015260640161029f565b603454815160405163277166bf60e11b81526001600160a01b039182166004820152602481018e90526000929190911690634ee2cd7e90604401602060405180830381865afa15801561059e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105c29190610d01565b905060006105d08a88610d30565b60208401516105df848b610d30565b6105e99190610d30565b6105f39190610d4d565b83516001600160a01b0316600090815260376020526040812080549293508392909190610621908490610dea565b9091555061063190508186610dea565b9450505050808061064190610dfd565b9150506104bf565b506000898152603660205260409020819055610664816108b1565b887feaf3d57629d9b1ce95715ccd98d6f5bf48023be1d5a06e09f64ab7f6d8be01d58260405161069691815260200190565b60405180910390a2505050505050505050565b336000818152603760205260408120805491905560325490916106dc916201000090046001600160a01b031690836108d5565b50565b603254610100900460ff16158080156106ff5750603254600160ff909116105b806107195750303b158015610719575060325460ff166001145b61077c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161029f565b6032805460ff19166001179055801561079f576032805461ff0019166101001790555b6001600160a01b038516158015906107bf57506001600160a01b03841615155b80156107d357506001600160a01b03831615155b61080e5760405162461bcd60e51b815260206004820152600c60248201526b5a45524f5f4144445245535360a01b604482015260640161029f565b603280546001600160a01b03808816620100000262010000600160b01b031990921691909117909155603380548683166001600160a01b0319918216179091556034805492861692909116919091179055603582905580156108aa576032805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6033546032546106dc916001600160a01b036201000090920482169116308461093d565b6040516001600160a01b03831660248201526044810182905261093890849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b03199093169290921790915261097b565b505050565b6040516001600160a01b03808516602483015283166044820152606481018290526109759085906323b872dd60e01b90608401610901565b50505050565b60006109d0826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610a509092919063ffffffff16565b90508051600014806109f15750808060200190518101906109f19190610e16565b6109385760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b606482015260840161029f565b6060610a5f8484600085610a67565b949350505050565b606082471015610ac85760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b606482015260840161029f565b600080866001600160a01b03168587604051610ae49190610e5c565b60006040518083038185875af1925050503d8060008114610b21576040519150601f19603f3d011682016040523d82523d6000602084013e610b26565b606091505b5091509150610b3787838387610b42565b979650505050505050565b60608315610bb1578251600003610baa576001600160a01b0385163b610baa5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161029f565b5081610a5f565b610a5f8383815115610bc65781518083602001fd5b8060405162461bcd60e51b815260040161029f9190610e78565b600060208284031215610bf257600080fd5b5035919050565b80356001600160a01b0381168114610c1057600080fd5b919050565b600060208284031215610c2757600080fd5b610c3082610bf9565b9392505050565b600080600060408486031215610c4c57600080fd5b83359250602084013567ffffffffffffffff80821115610c6b57600080fd5b818601915086601f830112610c7f57600080fd5b813581811115610c8e57600080fd5b8760208260061b8501011115610ca357600080fd5b6020830194508093505050509250925092565b60008060008060808587031215610ccc57600080fd5b610cd585610bf9565b9350610ce360208601610bf9565b9250610cf160408601610bf9565b9396929550929360600135925050565b600060208284031215610d1357600080fd5b5051919050565b634e487b7160e01b600052601160045260246000fd5b8082028115828204841417610d4757610d47610d1a565b92915050565b600082610d6a57634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052603260045260246000fd5b600060408284031215610d9757600080fd5b6040516040810181811067ffffffffffffffff82111715610dc857634e487b7160e01b600052604160045260246000fd5b604052610dd483610bf9565b8152602083013560208201528091505092915050565b80820180821115610d4757610d47610d1a565b600060018201610e0f57610e0f610d1a565b5060010190565b600060208284031215610e2857600080fd5b81518015158114610c3057600080fd5b60005b83811015610e53578181015183820152602001610e3b565b50506000910152565b60008251610e6e818460208701610e38565b9190910192915050565b6020815260008251806020840152610e97816040850160208701610e38565b601f01601f1916919091016040019291505056fea26469706673582212200c9fa9211b5f5937d8516e90589d94c68470826588820f396136e3f3ed465c6c64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101165760003560e01c80638a9cd82d116100a2578063c885bc5811610071578063c885bc581461020f578063cf756fdf14610217578063e0563ab11461022a578063f7c618c114610233578063fb75b2c71461024c57600080fd5b80638a9cd82d146101d45780639426e226146101e9578063947287cf146101fc57806397e5230d1461020557600080fd5b80633b878c22116100e95780633b878c221461019d57806351351d53146101a657806355b01e4d146101b45780635ea5df79146101c257806376ad03bc146101cb57600080fd5b806307358b991461011b57806307b3e2521461014e578063284017f51461017457806331d7a2621461017d575b600080fd5b61013b610129366004610be0565b60366020526000908152604090205481565b6040519081526020015b60405180910390f35b61015c6004600360981b0181565b6040516001600160a01b039091168152602001610145565b61015c61202081565b61013b61018b366004610c15565b60376020526000908152604090205481565b61015c61101081565b61015c6002600160a01b0381565b61015c6004600160991b0181565b61013b61138881565b61013b60355481565b6101e76101e2366004610c37565b61025f565b005b60345461015c906001600160a01b031681565b61013b61520881565b61013b620249f081565b6101e76106a9565b6101e7610225366004610cb6565b6106df565b61015c61203081565b60325461015c906201000090046001600160a01b031681565b60335461015c906001600160a01b031681565b336002600160a01b03146102a85760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064015b60405180910390fd5b600083815260366020526040902054156103045760405162461bcd60e51b815260206004820152601a60248201527f5245574152445f414c52454144595f4449535452494255544544000000000000604482015260640161029f565b603454604051633f490b0560e21b8152600481018590526000916001600160a01b03169063fd242c1490602401602060405180830381865afa15801561034e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103729190610d01565b9050806000036103ba5760405162461bcd60e51b8152602060048201526013602482015272115413d0d217d393d517d0d3d3535255151151606a1b604482015260640161029f565b60345460408051636265600360e01b815290516000926001600160a01b03169163626560039160048083019260209291908290030181865afa158015610404573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104289190610d01565b90506000818360355461043b9190610d30565b6104459190610d4d565b603454604051630981b24d60e41b8152600481018990529192506000916001600160a01b039091169063981b24d090602401602060405180830381865afa158015610494573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104b89190610d01565b9050846000805b828110156106495760008989838181106104db576104db610d6f565b9050604002018036038101906104f19190610d85565b905087816020015111156105475760405162461bcd60e51b815260206004820152601b60248201527f5349474e45445f424c4f434b535f455843454544535f544f54414c0000000000604482015260640161029f565b603454815160405163277166bf60e11b81526001600160a01b039182166004820152602481018e90526000929190911690634ee2cd7e90604401602060405180830381865afa15801561059e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105c29190610d01565b905060006105d08a88610d30565b60208401516105df848b610d30565b6105e99190610d30565b6105f39190610d4d565b83516001600160a01b0316600090815260376020526040812080549293508392909190610621908490610dea565b9091555061063190508186610dea565b9450505050808061064190610dfd565b9150506104bf565b506000898152603660205260409020819055610664816108b1565b887feaf3d57629d9b1ce95715ccd98d6f5bf48023be1d5a06e09f64ab7f6d8be01d58260405161069691815260200190565b60405180910390a2505050505050505050565b336000818152603760205260408120805491905560325490916106dc916201000090046001600160a01b031690836108d5565b50565b603254610100900460ff16158080156106ff5750603254600160ff909116105b806107195750303b158015610719575060325460ff166001145b61077c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161029f565b6032805460ff19166001179055801561079f576032805461ff0019166101001790555b6001600160a01b038516158015906107bf57506001600160a01b03841615155b80156107d357506001600160a01b03831615155b61080e5760405162461bcd60e51b815260206004820152600c60248201526b5a45524f5f4144445245535360a01b604482015260640161029f565b603280546001600160a01b03808816620100000262010000600160b01b031990921691909117909155603380548683166001600160a01b0319918216179091556034805492861692909116919091179055603582905580156108aa576032805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6033546032546106dc916001600160a01b036201000090920482169116308461093d565b6040516001600160a01b03831660248201526044810182905261093890849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b03199093169290921790915261097b565b505050565b6040516001600160a01b03808516602483015283166044820152606481018290526109759085906323b872dd60e01b90608401610901565b50505050565b60006109d0826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610a509092919063ffffffff16565b90508051600014806109f15750808060200190518101906109f19190610e16565b6109385760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b606482015260840161029f565b6060610a5f8484600085610a67565b949350505050565b606082471015610ac85760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b606482015260840161029f565b600080866001600160a01b03168587604051610ae49190610e5c565b60006040518083038185875af1925050503d8060008114610b21576040519150601f19603f3d011682016040523d82523d6000602084013e610b26565b606091505b5091509150610b3787838387610b42565b979650505050505050565b60608315610bb1578251600003610baa576001600160a01b0385163b610baa5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161029f565b5081610a5f565b610a5f8383815115610bc65781518083602001fd5b8060405162461bcd60e51b815260040161029f9190610e78565b600060208284031215610bf257600080fd5b5035919050565b80356001600160a01b0381168114610c1057600080fd5b919050565b600060208284031215610c2757600080fd5b610c3082610bf9565b9392505050565b600080600060408486031215610c4c57600080fd5b83359250602084013567ffffffffffffffff80821115610c6b57600080fd5b818601915086601f830112610c7f57600080fd5b813581811115610c8e57600080fd5b8760208260061b8501011115610ca357600080fd5b6020830194508093505050509250925092565b60008060008060808587031215610ccc57600080fd5b610cd585610bf9565b9350610ce360208601610bf9565b9250610cf160408601610bf9565b9396929550929360600135925050565b600060208284031215610d1357600080fd5b5051919050565b634e487b7160e01b600052601160045260246000fd5b8082028115828204841417610d4757610d47610d1a565b92915050565b600082610d6a57634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052603260045260246000fd5b600060408284031215610d9757600080fd5b6040516040810181811067ffffffffffffffff82111715610dc857634e487b7160e01b600052604160045260246000fd5b604052610dd483610bf9565b8152602083013560208201528091505092915050565b80820180821115610d4757610d47610d1a565b600060018201610e0f57610e0f610d1a565b5060010190565b600060208284031215610e2857600080fd5b81518015158114610c3057600080fd5b60005b83811015610e53578181015183820152602001610e3b565b50506000910152565b60008251610e6e818460208701610e38565b9190910192915050565b6020815260008251806020840152610e97816040850160208701610e38565b601f01601f1916919091016040019291505056fea26469706673582212200c9fa9211b5f5937d8516e90589d94c68470826588820f396136e3f3ed465c6c64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var ValidatorSetArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ValidatorSet","sourceName":"contracts/child/validator/ValidatorSet.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"startBlock","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"endBlock","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"epochRoot","type":"bytes32"}],"name":"NewEpoch","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"}],"name":"Snapshot","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdrawal","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"WithdrawalRegistered","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EPOCH_SIZE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAWAL_WAIT_PERIOD","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"epochNumber","type":"uint256"}],"name":"balanceOfAt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"components":[{"internalType":"uint256","name":"startBlock","type":"uint256"},{"internalType":"uint256","name":"endBlock","type":"uint256"},{"internalType":"bytes32","name":"epochRoot","type":"bytes32"}],"internalType":"struct Epoch","name":"epoch","type":"tuple"}],"name":"commitEpoch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"currentEpochId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"epochEndBlocks","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"epochs","outputs":[{"internalType":"uint256","name":"startBlock","type":"uint256"},{"internalType":"uint256","name":"endBlock","type":"uint256"},{"internalType":"bytes32","name":"epochRoot","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newStateReceiver","type":"address"},{"internalType":"address","name":"newRootChainManager","type":"address"},{"internalType":"uint256","name":"newEpochSize","type":"uint256"},{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"stake","type":"uint256"}],"internalType":"struct ValidatorInit[]","name":"initialValidators","type":"tuple[]"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onStateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"pendingWithdrawals","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"epochId","type":"uint256"}],"name":"totalBlocks","outputs":[{"internalType":"uint256","name":"length","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"epochNumber","type":"uint256"}],"name":"totalSupplyAt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"unstake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"withdrawable","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b5061215c806100206000396000f3fe608060405234801561001057600080fd5b50600436106102015760003560e01c806361cc276311610125578063c6b61e4c116100ad578063ea0fee4f1161007c578063ea0fee4f1461043d578063eacdc5ff14610445578063eeb499451461044e578063f3f4370314610461578063fd242c141461047457600080fd5b8063c6b61e4c146103c4578063ce513b6f1461040e578063dd62ed3e14610421578063e0563ab11461043457600080fd5b806395d89b41116100f457806395d89b411461037957806397e5230d14610381578063981b24d01461038b578063a457c2d71461039e578063a9059cbb146103b157600080fd5b806361cc276314610341578063626560031461035457806370a082311461035d578063947287cf1461037057600080fd5b8063313ce567116101a85780633fd50001116101775780633fd50001146102f65780634ee2cd7e1461030957806351351d531461031c57806355b01e4d1461032a5780635ea5df791461033857600080fd5b8063313ce567146102c357806339509351146102d25780633b878c22146102e55780633ccfd60b146102ee57600080fd5b806306fdde031461020657806307b3e25214610224578063095ea7b31461024a5780630f50287c1461026d57806318160ddd1461028257806323b872dd14610294578063284017f5146102a75780632e17de78146102b0575b600080fd5b61020e610487565b60405161021b9190611aeb565b60405180910390f35b6102326004600360981b0181565b6040516001600160a01b03909116815260200161021b565b61025d610258366004611b13565b610519565b604051901515815260200161021b565b61028061027b366004611b3f565b610533565b005b6035545b60405190815260200161021b565b61025d6102a2366004611b77565b6107c5565b61023261202081565b6102806102be366004611bb8565b6107e9565b6040516012815260200161021b565b61025d6102e0366004611b13565b610800565b61023261101081565b610280610822565b610286610304366004611bb8565b610933565b610286610317366004611b13565b610954565b6102326002600160a01b0381565b6102326004600160991b0181565b61028661138881565b61028061034f366004611c41565b610967565b61028660cc5481565b61028661036b366004611d5a565b610c05565b61028661520881565b61020e610c20565b610286620249f081565b610286610399366004611bb8565b610c2f565b61025d6103ac366004611b13565b610c3a565b61025d6103bf366004611b13565b610cb5565b6103f36103d2366004611bb8565b60ce6020526000908152604090208054600182015460029092015490919083565b6040805193845260208401929092529082015260600161021b565b61028661041c366004611d5a565b610cc3565b61028661042f366004611d77565b610cf1565b61023261203081565b610286600181565b61028660cd5481565b61028061045c366004611db0565b610d1c565b61028661046f366004611d5a565b610dee565b610286610482366004611bb8565b610e15565b60606036805461049690611e39565b80601f01602080910402602001604051908101604052809291908181526020018280546104c290611e39565b801561050f5780601f106104e45761010080835404028352916020019161050f565b820191906000526020600020905b8154815290600101906020018083116104f257829003601f168201915b5050505050905090565b600033610527818585610e5f565b60019150505b92915050565b336002600160a01b031461057c5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064015b60405180910390fd5b60cd80546000918261058d83611e89565b9190505590508083146105d85760405162461bcd60e51b815260206004820152601360248201527215539156141150d5115117d15413d0d217d251606a1b6044820152606401610573565b81356020830135116106225760405162461bcd60e51b81526020600482015260136024820152721393d7d09313d0d2d4d7d0d3d3535255151151606a1b6044820152606401610573565b60cc5461063483356020850135611ea2565b61063f906001611eb5565b6106499190611ede565b156106a45760405162461bcd60e51b815260206004820152602560248201527f45504f43485f4d5553545f42455f444956495349424c455f42595f45504f43486044820152645f53495a4560d81b6064820152608401610573565b813560ce60006106b5600185611ea2565b81526020019081526020016000206001015460016106d39190611eb5565b146107165760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f53544152545f424c4f434b60681b6044820152606401610573565b600081815260ce60205260409020829061074782828135815560208201356001820155604082013560028201555050565b505060cf80546001810182556000919091526020838101357facb8d954e2cfef495862221e91bd7523613cf8808827cb33edfe4904cc51bf299092018290556040805190850135815284359186917f0ce8712c4dee4bd5a691f0bc1c39594671591e77395f8ebf6a3fb5f63fbea66a910160405180910390a4505050565b6000336107d3858285610f84565b6107de858585610ff8565b506001949350505050565b6107f3338261119c565b6107fd33826112c7565b50565b6000336105278185856108138383610cf1565b61081d9190611eb5565b610e5f565b33600090815260d06020526040812060cd549091908190610844908490611340565b808555604051828152919350915033907f7fcf532c15f0a6db0bd6d0e038bea71d30d808c7d98cb3bf7268a95bf5081b659060200160405180910390a260c95460cb54604080517f8ca9a95e41b5eece253c93f5b31eed1253aed6b145d8a6e14d913fdf8e7322936020820152338183015260608082018790528251808303909101815260808201928390526316f1983160e01b9092526001600160a01b03938416936316f19831936108fc93911691608401611ef2565b600060405180830381600087803b15801561091657600080fd5b505af115801561092a573d6000803e3d6000fd5b50505050505050565b60cf818154811061094357600080fd5b600091825260209091200154905081565b600061096083836113b2565b9392505050565b600054610100900460ff16158080156109875750600054600160ff909116105b806109a15750303b1580156109a1575060005460ff166001145b610a045760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610573565b6000805460ff191660011790558015610a27576000805461ff0019166101001790555b6001600160a01b03861615801590610a4757506001600160a01b03851615155b8015610a5b57506001600160a01b03841615155b610a975760405162461bcd60e51b815260206004820152600d60248201526c1253959053125117d253941555609a1b6044820152606401610573565b610ae16040518060400160405280600c81526020016b15985b1a59185d1bdc94d95d60a21b815250604051806040016040528060048152602001631594d15560e21b8152506113fb565b60c980546001600160a01b038089166001600160a01b03199283161790925560ca805488841690831617905560cb80549287169290911691909117905560cc83905560005b8251811015610b7b57610b73838281518110610b4457610b44611f16565b602002602001015160000151848381518110610b6257610b62611f16565b602002602001015160200151611430565b600101610b26565b5060cf80546001818101835560009283527facb8d954e2cfef495862221e91bd7523613cf8808827cb33edfe4904cc51bf299091019190915560cd558015610bfd576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b6001600160a01b031660009081526033602052604090205490565b60606037805461049690611e39565b600061052d8261143a565b60003381610c488286610cf1565b905083811015610ca85760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610573565b6107de8286868403610e5f565b600033610527818585610ff8565b60cd546001600160a01b038216600090815260d0602052604081209091610cea9190611340565b5092915050565b6001600160a01b03918216600090815260346020908152604080832093909416825291909152205490565b60ca546001600160a01b031633148015610d43575060cb546001600160a01b038481169116145b610d805760405162461bcd60e51b815260206004820152600e60248201526d24a72b20a624a22fa9a2a72222a960911b6044820152606401610573565b7f1bcc0f4c3fad314e585165815f94ecca9b96690a26d6417d7876448a9a867a69610daf602060008486611f2c565b610db891611f56565b03610de857600080610dcd8360208187611f2c565b810190610dda9190611b13565b91509150610bfd8282611430565b50505050565b60cd546001600160a01b038216600090815260d060205260408120909161052d9190611465565b600081815260ce60205260408120600101548015610e5657600083815260ce6020526040902054610e469082611ea2565b610e51906001611eb5565b610960565b60009392505050565b6001600160a01b038316610ec15760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610573565b6001600160a01b038216610f225760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610573565b6001600160a01b0383811660008181526034602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b6000610f908484610cf1565b90506000198114610de85781811015610feb5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610573565b610de88484848403610e5f565b6001600160a01b03831661105c5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610573565b6001600160a01b0382166110be5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610573565b6110c9838383611503565b6001600160a01b038316600090815260336020526040902054818110156111415760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610573565b6001600160a01b0380851660008181526033602052604080822086860390559286168082529083902080548601905591516000805160206121078339815191529061118f9086815260200190565b60405180910390a3610de8565b6001600160a01b0382166111fc5760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610573565b61120882600083611503565b6001600160a01b0382166000908152603360205260409020548181101561127c5760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610573565b6001600160a01b03831660008181526033602090815260408083208686039055603580548790039055518581529192916000805160206121078339815191529101610f77565b505050565b6112f981600160cd546112da9190611eb5565b6001600160a01b038516600090815260d060205260409020919061156c565b816001600160a01b03167f655c1cd0236fb6dc4916f34c8ff10e3b18fcaea5b344dfc16c36fbb1bdfc5df28260405161133491815260200190565b60405180910390a25050565b81546000905b83600101548110156113ab5760008181526002850160209081526040918290208251808401909352805483526001015490820181905284101561138957506113ab565b80516113959084611eb5565b92505080806113a390611e89565b915050611346565b9250929050565b6001600160a01b0382166000908152606560205260408120819081906113d99085906116e2565b91509150816113f0576113eb85610c05565b6113f2565b805b95945050505050565b600054610100900460ff166114225760405162461bcd60e51b815260040161057390611f74565b61142c82826117d0565b5050565b61142c8282611810565b600080600061144a8460666116e2565b915091508161145b5760355461145d565b805b949350505050565b600182015460009080820361147e57600091505061052d565b600061148b600183611ea2565b90505b845481106114fb5760008181526002860160209081526040918290208251808401909352805483526001015490820181905285106114cc57506114fb565b80516114d89085611eb5565b9350816000036114e857506114fb565b50806114f381611fbf565b91505061148e565b505092915050565b6001600160a01b038316158061152057506001600160a01b038216155b6115615760405162461bcd60e51b81526020600482015260126024820152712a2920a729a322a92fa327a92124a22222a760711b6044820152606401610573565b6112c28383836118cb565b816000036115c75760405162461bcd60e51b815260206004820152602260248201527f5769746864726177616c51756575654c69623a20494e56414c49445f414d4f55604482015261139560f21b6064820152608401610573565b8254600184015481810361161e576040805180820182528581526020808201868152600085815260028a01909252928120915182559151600191820155860180549161161283611e89565b91905055505050505050565b60006002860181611630600185611ea2565b81526020019081526020016000206001015490508084101561165457611654611fd6565b838110156116a3576040805180820182528681526020808201878152600086815260028b01909252928120915182559151600191820155870180549161169983611e89565b9190505550610bfd565b846002870160006116b5600186611ea2565b815260200190815260200160002060000160008282546116d59190611eb5565b9091555050505050505050565b6000806000841161172e5760405162461bcd60e51b815260206004820152601660248201527504552433230536e617073686f743a20696420697320360541b6044820152606401610573565b60cd548411156117805760405162461bcd60e51b815260206004820152601d60248201527f4552433230536e617073686f743a206e6f6e6578697374656e742069640000006044820152606401610573565b600061178c8486611913565b845490915081036117a45760008092509250506113ab565b60018460010182815481106117bb576117bb611f16565b906000526020600020015492509250506113ab565b600054610100900460ff166117f75760405162461bcd60e51b815260040161057390611f74565b60366118038382612032565b5060376112c28282612032565b6001600160a01b0382166118665760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610573565b61187260008383611503565b80603560008282546118849190611eb5565b90915550506001600160a01b038216600081815260336020908152604080832080548601905551848152600080516020612107833981519152910160405180910390a35050565b6001600160a01b0383166118ea576118e2826119c0565b6112c26119ea565b6001600160a01b038216611901576118e2836119c0565b61190a836119c0565b6112c2826119c0565b815460009081036119265750600061052d565b82546000905b8082101561197357600061194083836119fa565b6000878152602090209091508590820154111561195f5780915061196d565b61196a816001611eb5565b92505b5061192c565b60008211801561199f57508361199c8661198e600186611ea2565b600091825260209091200190565b54145b156119b8576119af600183611ea2565b9250505061052d565b50905061052d565b6001600160a01b03811660009081526065602052604090206107fd906119e583610c05565b611a15565b6119f860666119e560355490565b565b6000611a0960028484186120f2565b61096090848416611eb5565b6000611a2060cd5490565b905080611a2c84611a60565b10156112c2578254600180820185556000858152602080822090930193909355938401805494850181558252902090910155565b80546000908103611a7357506000919050565b81548290611a8390600190611ea2565b81548110611a9357611a93611f16565b90600052602060002001549050919050565b6000815180845260005b81811015611acb57602081850181015186830182015201611aaf565b506000602082860101526020601f19601f83011685010191505092915050565b6020815260006109606020830184611aa5565b6001600160a01b03811681146107fd57600080fd5b60008060408385031215611b2657600080fd5b8235611b3181611afe565b946020939093013593505050565b6000808284036080811215611b5357600080fd5b833592506060601f1982011215611b6957600080fd5b506020830190509250929050565b600080600060608486031215611b8c57600080fd5b8335611b9781611afe565b92506020840135611ba781611afe565b929592945050506040919091013590565b600060208284031215611bca57600080fd5b5035919050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715611c0a57611c0a611bd1565b60405290565b604051601f8201601f1916810167ffffffffffffffff81118282101715611c3957611c39611bd1565b604052919050565b600080600080600060a08688031215611c5957600080fd5b8535611c6481611afe565b9450602086810135611c7581611afe565b9450604087810135611c8681611afe565b945060608801359350608088013567ffffffffffffffff80821115611caa57600080fd5b818a0191508a601f830112611cbe57600080fd5b813581811115611cd057611cd0611bd1565b611cde858260051b01611c10565b818152858101925060069190911b83018501908c821115611cfe57600080fd5b928501925b81841015611d475784848e031215611d1b5760008081fd5b611d23611be7565b8435611d2e81611afe565b8152848701358782015283529284019291850191611d03565b8096505050505050509295509295909350565b600060208284031215611d6c57600080fd5b813561096081611afe565b60008060408385031215611d8a57600080fd5b8235611d9581611afe565b91506020830135611da581611afe565b809150509250929050565b60008060008060608587031215611dc657600080fd5b843593506020850135611dd881611afe565b9250604085013567ffffffffffffffff80821115611df557600080fd5b818701915087601f830112611e0957600080fd5b813581811115611e1857600080fd5b886020828501011115611e2a57600080fd5b95989497505060200194505050565b600181811c90821680611e4d57607f821691505b602082108103611e6d57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b600060018201611e9b57611e9b611e73565b5060010190565b8181038181111561052d5761052d611e73565b8082018082111561052d5761052d611e73565b634e487b7160e01b600052601260045260246000fd5b600082611eed57611eed611ec8565b500690565b6001600160a01b038316815260406020820181905260009061145d90830184611aa5565b634e487b7160e01b600052603260045260246000fd5b60008085851115611f3c57600080fd5b83861115611f4957600080fd5b5050820193919092039150565b8035602083101561052d57600019602084900360031b1b1692915050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b600081611fce57611fce611e73565b506000190190565b634e487b7160e01b600052600160045260246000fd5b601f8211156112c257600081815260208120601f850160051c810160208610156120135750805b601f850160051c820191505b81811015610bfd5782815560010161201f565b815167ffffffffffffffff81111561204c5761204c611bd1565b6120608161205a8454611e39565b84611fec565b602080601f831160018114612095576000841561207d5750858301515b600019600386901b1c1916600185901b178555610bfd565b600085815260208120601f198616915b828110156120c4578886015182559484019460019091019084016120a5565b50858210156120e25787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008261210157612101611ec8565b50049056feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220a7f49f3b74e4ac0e9fc814278d95b8601a69f04a86da95d921d3e639218e2b7264736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106102015760003560e01c806361cc276311610125578063c6b61e4c116100ad578063ea0fee4f1161007c578063ea0fee4f1461043d578063eacdc5ff14610445578063eeb499451461044e578063f3f4370314610461578063fd242c141461047457600080fd5b8063c6b61e4c146103c4578063ce513b6f1461040e578063dd62ed3e14610421578063e0563ab11461043457600080fd5b806395d89b41116100f457806395d89b411461037957806397e5230d14610381578063981b24d01461038b578063a457c2d71461039e578063a9059cbb146103b157600080fd5b806361cc276314610341578063626560031461035457806370a082311461035d578063947287cf1461037057600080fd5b8063313ce567116101a85780633fd50001116101775780633fd50001146102f65780634ee2cd7e1461030957806351351d531461031c57806355b01e4d1461032a5780635ea5df791461033857600080fd5b8063313ce567146102c357806339509351146102d25780633b878c22146102e55780633ccfd60b146102ee57600080fd5b806306fdde031461020657806307b3e25214610224578063095ea7b31461024a5780630f50287c1461026d57806318160ddd1461028257806323b872dd14610294578063284017f5146102a75780632e17de78146102b0575b600080fd5b61020e610487565b60405161021b9190611aeb565b60405180910390f35b6102326004600360981b0181565b6040516001600160a01b03909116815260200161021b565b61025d610258366004611b13565b610519565b604051901515815260200161021b565b61028061027b366004611b3f565b610533565b005b6035545b60405190815260200161021b565b61025d6102a2366004611b77565b6107c5565b61023261202081565b6102806102be366004611bb8565b6107e9565b6040516012815260200161021b565b61025d6102e0366004611b13565b610800565b61023261101081565b610280610822565b610286610304366004611bb8565b610933565b610286610317366004611b13565b610954565b6102326002600160a01b0381565b6102326004600160991b0181565b61028661138881565b61028061034f366004611c41565b610967565b61028660cc5481565b61028661036b366004611d5a565b610c05565b61028661520881565b61020e610c20565b610286620249f081565b610286610399366004611bb8565b610c2f565b61025d6103ac366004611b13565b610c3a565b61025d6103bf366004611b13565b610cb5565b6103f36103d2366004611bb8565b60ce6020526000908152604090208054600182015460029092015490919083565b6040805193845260208401929092529082015260600161021b565b61028661041c366004611d5a565b610cc3565b61028661042f366004611d77565b610cf1565b61023261203081565b610286600181565b61028660cd5481565b61028061045c366004611db0565b610d1c565b61028661046f366004611d5a565b610dee565b610286610482366004611bb8565b610e15565b60606036805461049690611e39565b80601f01602080910402602001604051908101604052809291908181526020018280546104c290611e39565b801561050f5780601f106104e45761010080835404028352916020019161050f565b820191906000526020600020905b8154815290600101906020018083116104f257829003601f168201915b5050505050905090565b600033610527818585610e5f565b60019150505b92915050565b336002600160a01b031461057c5760405163973d02cb60e01b815260206004820152600a60248201526914d654d5115350d0531360b21b60448201526064015b60405180910390fd5b60cd80546000918261058d83611e89565b9190505590508083146105d85760405162461bcd60e51b815260206004820152601360248201527215539156141150d5115117d15413d0d217d251606a1b6044820152606401610573565b81356020830135116106225760405162461bcd60e51b81526020600482015260136024820152721393d7d09313d0d2d4d7d0d3d3535255151151606a1b6044820152606401610573565b60cc5461063483356020850135611ea2565b61063f906001611eb5565b6106499190611ede565b156106a45760405162461bcd60e51b815260206004820152602560248201527f45504f43485f4d5553545f42455f444956495349424c455f42595f45504f43486044820152645f53495a4560d81b6064820152608401610573565b813560ce60006106b5600185611ea2565b81526020019081526020016000206001015460016106d39190611eb5565b146107165760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f53544152545f424c4f434b60681b6044820152606401610573565b600081815260ce60205260409020829061074782828135815560208201356001820155604082013560028201555050565b505060cf80546001810182556000919091526020838101357facb8d954e2cfef495862221e91bd7523613cf8808827cb33edfe4904cc51bf299092018290556040805190850135815284359186917f0ce8712c4dee4bd5a691f0bc1c39594671591e77395f8ebf6a3fb5f63fbea66a910160405180910390a4505050565b6000336107d3858285610f84565b6107de858585610ff8565b506001949350505050565b6107f3338261119c565b6107fd33826112c7565b50565b6000336105278185856108138383610cf1565b61081d9190611eb5565b610e5f565b33600090815260d06020526040812060cd549091908190610844908490611340565b808555604051828152919350915033907f7fcf532c15f0a6db0bd6d0e038bea71d30d808c7d98cb3bf7268a95bf5081b659060200160405180910390a260c95460cb54604080517f8ca9a95e41b5eece253c93f5b31eed1253aed6b145d8a6e14d913fdf8e7322936020820152338183015260608082018790528251808303909101815260808201928390526316f1983160e01b9092526001600160a01b03938416936316f19831936108fc93911691608401611ef2565b600060405180830381600087803b15801561091657600080fd5b505af115801561092a573d6000803e3d6000fd5b50505050505050565b60cf818154811061094357600080fd5b600091825260209091200154905081565b600061096083836113b2565b9392505050565b600054610100900460ff16158080156109875750600054600160ff909116105b806109a15750303b1580156109a1575060005460ff166001145b610a045760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610573565b6000805460ff191660011790558015610a27576000805461ff0019166101001790555b6001600160a01b03861615801590610a4757506001600160a01b03851615155b8015610a5b57506001600160a01b03841615155b610a975760405162461bcd60e51b815260206004820152600d60248201526c1253959053125117d253941555609a1b6044820152606401610573565b610ae16040518060400160405280600c81526020016b15985b1a59185d1bdc94d95d60a21b815250604051806040016040528060048152602001631594d15560e21b8152506113fb565b60c980546001600160a01b038089166001600160a01b03199283161790925560ca805488841690831617905560cb80549287169290911691909117905560cc83905560005b8251811015610b7b57610b73838281518110610b4457610b44611f16565b602002602001015160000151848381518110610b6257610b62611f16565b602002602001015160200151611430565b600101610b26565b5060cf80546001818101835560009283527facb8d954e2cfef495862221e91bd7523613cf8808827cb33edfe4904cc51bf299091019190915560cd558015610bfd576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b6001600160a01b031660009081526033602052604090205490565b60606037805461049690611e39565b600061052d8261143a565b60003381610c488286610cf1565b905083811015610ca85760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610573565b6107de8286868403610e5f565b600033610527818585610ff8565b60cd546001600160a01b038216600090815260d0602052604081209091610cea9190611340565b5092915050565b6001600160a01b03918216600090815260346020908152604080832093909416825291909152205490565b60ca546001600160a01b031633148015610d43575060cb546001600160a01b038481169116145b610d805760405162461bcd60e51b815260206004820152600e60248201526d24a72b20a624a22fa9a2a72222a960911b6044820152606401610573565b7f1bcc0f4c3fad314e585165815f94ecca9b96690a26d6417d7876448a9a867a69610daf602060008486611f2c565b610db891611f56565b03610de857600080610dcd8360208187611f2c565b810190610dda9190611b13565b91509150610bfd8282611430565b50505050565b60cd546001600160a01b038216600090815260d060205260408120909161052d9190611465565b600081815260ce60205260408120600101548015610e5657600083815260ce6020526040902054610e469082611ea2565b610e51906001611eb5565b610960565b60009392505050565b6001600160a01b038316610ec15760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610573565b6001600160a01b038216610f225760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610573565b6001600160a01b0383811660008181526034602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b6000610f908484610cf1565b90506000198114610de85781811015610feb5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610573565b610de88484848403610e5f565b6001600160a01b03831661105c5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610573565b6001600160a01b0382166110be5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610573565b6110c9838383611503565b6001600160a01b038316600090815260336020526040902054818110156111415760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610573565b6001600160a01b0380851660008181526033602052604080822086860390559286168082529083902080548601905591516000805160206121078339815191529061118f9086815260200190565b60405180910390a3610de8565b6001600160a01b0382166111fc5760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610573565b61120882600083611503565b6001600160a01b0382166000908152603360205260409020548181101561127c5760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610573565b6001600160a01b03831660008181526033602090815260408083208686039055603580548790039055518581529192916000805160206121078339815191529101610f77565b505050565b6112f981600160cd546112da9190611eb5565b6001600160a01b038516600090815260d060205260409020919061156c565b816001600160a01b03167f655c1cd0236fb6dc4916f34c8ff10e3b18fcaea5b344dfc16c36fbb1bdfc5df28260405161133491815260200190565b60405180910390a25050565b81546000905b83600101548110156113ab5760008181526002850160209081526040918290208251808401909352805483526001015490820181905284101561138957506113ab565b80516113959084611eb5565b92505080806113a390611e89565b915050611346565b9250929050565b6001600160a01b0382166000908152606560205260408120819081906113d99085906116e2565b91509150816113f0576113eb85610c05565b6113f2565b805b95945050505050565b600054610100900460ff166114225760405162461bcd60e51b815260040161057390611f74565b61142c82826117d0565b5050565b61142c8282611810565b600080600061144a8460666116e2565b915091508161145b5760355461145d565b805b949350505050565b600182015460009080820361147e57600091505061052d565b600061148b600183611ea2565b90505b845481106114fb5760008181526002860160209081526040918290208251808401909352805483526001015490820181905285106114cc57506114fb565b80516114d89085611eb5565b9350816000036114e857506114fb565b50806114f381611fbf565b91505061148e565b505092915050565b6001600160a01b038316158061152057506001600160a01b038216155b6115615760405162461bcd60e51b81526020600482015260126024820152712a2920a729a322a92fa327a92124a22222a760711b6044820152606401610573565b6112c28383836118cb565b816000036115c75760405162461bcd60e51b815260206004820152602260248201527f5769746864726177616c51756575654c69623a20494e56414c49445f414d4f55604482015261139560f21b6064820152608401610573565b8254600184015481810361161e576040805180820182528581526020808201868152600085815260028a01909252928120915182559151600191820155860180549161161283611e89565b91905055505050505050565b60006002860181611630600185611ea2565b81526020019081526020016000206001015490508084101561165457611654611fd6565b838110156116a3576040805180820182528681526020808201878152600086815260028b01909252928120915182559151600191820155870180549161169983611e89565b9190505550610bfd565b846002870160006116b5600186611ea2565b815260200190815260200160002060000160008282546116d59190611eb5565b9091555050505050505050565b6000806000841161172e5760405162461bcd60e51b815260206004820152601660248201527504552433230536e617073686f743a20696420697320360541b6044820152606401610573565b60cd548411156117805760405162461bcd60e51b815260206004820152601d60248201527f4552433230536e617073686f743a206e6f6e6578697374656e742069640000006044820152606401610573565b600061178c8486611913565b845490915081036117a45760008092509250506113ab565b60018460010182815481106117bb576117bb611f16565b906000526020600020015492509250506113ab565b600054610100900460ff166117f75760405162461bcd60e51b815260040161057390611f74565b60366118038382612032565b5060376112c28282612032565b6001600160a01b0382166118665760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610573565b61187260008383611503565b80603560008282546118849190611eb5565b90915550506001600160a01b038216600081815260336020908152604080832080548601905551848152600080516020612107833981519152910160405180910390a35050565b6001600160a01b0383166118ea576118e2826119c0565b6112c26119ea565b6001600160a01b038216611901576118e2836119c0565b61190a836119c0565b6112c2826119c0565b815460009081036119265750600061052d565b82546000905b8082101561197357600061194083836119fa565b6000878152602090209091508590820154111561195f5780915061196d565b61196a816001611eb5565b92505b5061192c565b60008211801561199f57508361199c8661198e600186611ea2565b600091825260209091200190565b54145b156119b8576119af600183611ea2565b9250505061052d565b50905061052d565b6001600160a01b03811660009081526065602052604090206107fd906119e583610c05565b611a15565b6119f860666119e560355490565b565b6000611a0960028484186120f2565b61096090848416611eb5565b6000611a2060cd5490565b905080611a2c84611a60565b10156112c2578254600180820185556000858152602080822090930193909355938401805494850181558252902090910155565b80546000908103611a7357506000919050565b81548290611a8390600190611ea2565b81548110611a9357611a93611f16565b90600052602060002001549050919050565b6000815180845260005b81811015611acb57602081850181015186830182015201611aaf565b506000602082860101526020601f19601f83011685010191505092915050565b6020815260006109606020830184611aa5565b6001600160a01b03811681146107fd57600080fd5b60008060408385031215611b2657600080fd5b8235611b3181611afe565b946020939093013593505050565b6000808284036080811215611b5357600080fd5b833592506060601f1982011215611b6957600080fd5b506020830190509250929050565b600080600060608486031215611b8c57600080fd5b8335611b9781611afe565b92506020840135611ba781611afe565b929592945050506040919091013590565b600060208284031215611bca57600080fd5b5035919050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715611c0a57611c0a611bd1565b60405290565b604051601f8201601f1916810167ffffffffffffffff81118282101715611c3957611c39611bd1565b604052919050565b600080600080600060a08688031215611c5957600080fd5b8535611c6481611afe565b9450602086810135611c7581611afe565b9450604087810135611c8681611afe565b945060608801359350608088013567ffffffffffffffff80821115611caa57600080fd5b818a0191508a601f830112611cbe57600080fd5b813581811115611cd057611cd0611bd1565b611cde858260051b01611c10565b818152858101925060069190911b83018501908c821115611cfe57600080fd5b928501925b81841015611d475784848e031215611d1b5760008081fd5b611d23611be7565b8435611d2e81611afe565b8152848701358782015283529284019291850191611d03565b8096505050505050509295509295909350565b600060208284031215611d6c57600080fd5b813561096081611afe565b60008060408385031215611d8a57600080fd5b8235611d9581611afe565b91506020830135611da581611afe565b809150509250929050565b60008060008060608587031215611dc657600080fd5b843593506020850135611dd881611afe565b9250604085013567ffffffffffffffff80821115611df557600080fd5b818701915087601f830112611e0957600080fd5b813581811115611e1857600080fd5b886020828501011115611e2a57600080fd5b95989497505060200194505050565b600181811c90821680611e4d57607f821691505b602082108103611e6d57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b600060018201611e9b57611e9b611e73565b5060010190565b8181038181111561052d5761052d611e73565b8082018082111561052d5761052d611e73565b634e487b7160e01b600052601260045260246000fd5b600082611eed57611eed611ec8565b500690565b6001600160a01b038316815260406020820181905260009061145d90830184611aa5565b634e487b7160e01b600052603260045260246000fd5b60008085851115611f3c57600080fd5b83861115611f4957600080fd5b5050820193919092039150565b8035602083101561052d57600019602084900360031b1b1692915050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b600081611fce57611fce611e73565b506000190190565b634e487b7160e01b600052600160045260246000fd5b601f8211156112c257600081815260208120601f850160051c810160208610156120135750805b601f850160051c820191505b81811015610bfd5782815560010161201f565b815167ffffffffffffffff81111561204c5761204c611bd1565b6120608161205a8454611e39565b84611fec565b602080601f831160018114612095576000841561207d5750858301515b600019600386901b1c1916600185901b178555610bfd565b600085815260208120601f198616915b828110156120c4578886015182559484019460019091019084016120a5565b50858210156120e25787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008261210157612101611ec8565b50049056feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220a7f49f3b74e4ac0e9fc814278d95b8601a69f04a86da95d921d3e639218e2b7264736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` -var EIP1559BurnArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"EIP1559Burn","sourceName":"contracts/child/EIP1559Burn.sol","abi":[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"burner","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"NativeTokenBurnt","type":"event"},{"inputs":[],"name":"burnDestination","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC20Predicate","outputs":[{"internalType":"contract IChildERC20Predicate","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC20Predicate","name":"newChildERC20Predicate","type":"address"},{"internalType":"address","name":"newBurnDestination","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}],"bytecode":"0x608060405234801561001057600080fd5b50610425806100206000396000f3fe6080604052600436106100435760003560e01c80630fca96871461004f5780633ccfd60b1461008b578063485cc955146100a2578063d57184e4146100c257600080fd5b3661004a57005b600080fd5b34801561005b57600080fd5b5060015461006f906001600160a01b031681565b6040516001600160a01b03909116815260200160405180910390f35b34801561009757600080fd5b506100a06100e8565b005b3480156100ae57600080fd5b506100a06100bd3660046103b6565b6101fc565b3480156100ce57600080fd5b5060005461006f906201000090046001600160a01b031681565b6000546201000090046001600160a01b031661014b5760405162461bcd60e51b815260206004820152601a60248201527f454950313535394275726e3a20554e494e495449414c495a454400000000000060448201526064015b60405180910390fd5b6000546001546040516361d9ad3f60e11b815261101060048201526001600160a01b0391821660248201524760448201819052926201000090049091169063c3b35a7e90606401600060405180830381600087803b1580156101ac57600080fd5b505af11580156101c0573d6000803e3d6000fd5b50506040518381523392507feb347a9a474ae97b7b32a903d84decf8fc80dc9cd6129085f5097de5cd3b3256915060200160405180910390a250565b600054610100900460ff161580801561021c5750600054600160ff909116105b806102365750303b158015610236575060005460ff166001145b6102995760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610142565b6000805460ff1916600117905580156102bc576000805461ff0019166101001790555b6001600160a01b0383166103125760405162461bcd60e51b815260206004820152601f60248201527f454950313535394275726e3a204241445f494e495449414c495a4154494f4e006044820152606401610142565b6000805462010000600160b01b031916620100006001600160a01b038681169190910291909117909155600180546001600160a01b0319169184169190911790558015610399576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050565b6001600160a01b03811681146103b357600080fd5b50565b600080604083850312156103c957600080fd5b82356103d48161039e565b915060208301356103e48161039e565b80915050925092905056fea26469706673582212204ef36b0d6b6d4a5e32117ffe6009ea0f1d44da93380a511f1e364bb3e312af6b64736f6c63430008130033","deployedBytecode":"0x6080604052600436106100435760003560e01c80630fca96871461004f5780633ccfd60b1461008b578063485cc955146100a2578063d57184e4146100c257600080fd5b3661004a57005b600080fd5b34801561005b57600080fd5b5060015461006f906001600160a01b031681565b6040516001600160a01b03909116815260200160405180910390f35b34801561009757600080fd5b506100a06100e8565b005b3480156100ae57600080fd5b506100a06100bd3660046103b6565b6101fc565b3480156100ce57600080fd5b5060005461006f906201000090046001600160a01b031681565b6000546201000090046001600160a01b031661014b5760405162461bcd60e51b815260206004820152601a60248201527f454950313535394275726e3a20554e494e495449414c495a454400000000000060448201526064015b60405180910390fd5b6000546001546040516361d9ad3f60e11b815261101060048201526001600160a01b0391821660248201524760448201819052926201000090049091169063c3b35a7e90606401600060405180830381600087803b1580156101ac57600080fd5b505af11580156101c0573d6000803e3d6000fd5b50506040518381523392507feb347a9a474ae97b7b32a903d84decf8fc80dc9cd6129085f5097de5cd3b3256915060200160405180910390a250565b600054610100900460ff161580801561021c5750600054600160ff909116105b806102365750303b158015610236575060005460ff166001145b6102995760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610142565b6000805460ff1916600117905580156102bc576000805461ff0019166101001790555b6001600160a01b0383166103125760405162461bcd60e51b815260206004820152601f60248201527f454950313535394275726e3a204241445f494e495449414c495a4154494f4e006044820152606401610142565b6000805462010000600160b01b031916620100006001600160a01b038681169190910291909117909155600180546001600160a01b0319169184169190911790558015610399576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050565b6001600160a01b03811681146103b357600080fd5b50565b600080604083850312156103c957600080fd5b82356103d48161039e565b915060208301356103e48161039e565b80915050925092905056fea26469706673582212204ef36b0d6b6d4a5e32117ffe6009ea0f1d44da93380a511f1e364bb3e312af6b64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var RootERC1155PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"RootERC1155Predicate","sourceName":"contracts/bridge/RootERC1155Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"depositor","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"depositor","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"ERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"ERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"TokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"depositBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"depositTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newChildERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC1155MetadataURI","name":"rootToken","type":"address"}],"name":"mapToken","outputs":[{"internalType":"address","name":"childToken","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155BatchReceived","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611bd2806100206000396000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c8063bc197c81116100ad578063f23a6e6111610071578063f23a6e61146102fe578063f43cda8b1461031d578063f4a120f714610330578063f645125514610343578063f8c8765e1461036a57600080fd5b8063bc197c8114610238578063c5ac2b1c14610270578063cb10f94c14610297578063d41f1771146102b0578063d7c9e3ec146102d757600080fd5b80637efab4f5116100f45780637efab4f5146101a157806395c7041c146101ca578063a78e111c146101dd578063b1768065146101f0578063b68ad1e41461022557600080fd5b806301ffc9a7146101265780630efe6a8b1461014e5780634c4c45de14610163578063654715e614610176575b600080fd5b610139610134366004611173565b61037d565b60405190151581526020015b60405180910390f35b61016161015c3660046111bc565b6103b4565b005b61016161017136600461123c565b6103c5565b600254610189906001600160a01b031681565b6040516001600160a01b039091168152602001610145565b6101896101af3660046112e8565b6004602052600090815260409020546001600160a01b031681565b600154610189906001600160a01b031681565b6101616101eb366004611305565b610448565b6102177f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610145565b600354610189906001600160a01b031681565b610257610246366004611497565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610145565b6102177faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610189906201000090046001600160a01b031681565b6102177f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102177f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61025761030c366004611544565b63f23a6e6160e01b95945050505050565b61016161032b3660046115ac565b61045a565b61018961033e3660046112e8565b610629565b6102177f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b610161610378366004611634565b610945565b60006001600160e01b03198216630271189760e51b14806103ae57506301ffc9a760e01b6001600160e01b03198316145b92915050565b6103c083338484610b54565b505050565b84831480156103d357508481145b6104305760405162461bcd60e51b8152602060048201526024808201527f526f6f74455243313135355072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b60648201526084015b60405180910390fd5b61043f87878787878787610cec565b50505050505050565b61045484848484610b54565b50505050565b6001546001600160a01b031633146104c35760405162461bcd60e51b815260206004820152602660248201527f526f6f74455243313135355072656469636174653a204f4e4c595f455849545f6044820152652422a62822a960d11b6064820152608401610427565b6002546001600160a01b038481169116146105335760405162461bcd60e51b815260206004820152602a60248201527f526f6f74455243313135355072656469636174653a204f4e4c595f4348494c446044820152695f50524544494341544560b01b6064820152608401610427565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e982869610562602060008486611690565b61056b916116ba565b0361058a576105856105808260208186611690565b610ecc565b610454565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26105b9602060008486611690565b6105c2916116ba565b036105d1576105858282610fcb565b60405162461bcd60e51b815260206004820152602760248201527f526f6f74455243313135355072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b6064820152608401610427565b60006001600160a01b03821661068d5760405162461bcd60e51b815260206004820152602360248201527f526f6f74455243313135355072656469636174653a20494e56414c49445f544f60448201526225a2a760e91b6064820152608401610427565b6001600160a01b0382811660009081526004602052604090205416156107015760405162461bcd60e51b8152602060048201526024808201527f526f6f74455243313135355072656469636174653a20414c52454144595f4d416044820152631414115160e21b6064820152608401610427565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b03928316926107ab921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03848116600081815260046020818152604080842080546001600160a01b031916968816969096179095558451908101855282815293516303a24d0760e21b8152908101919091529294509091630e89341c90602401600060405180830381865afa92505050801561084657506040513d6000823e601f3d908101601f1916820160405261084391908101906116fc565b60015b1561084e5790505b600060029054906101000a90046001600160a01b03166001600160a01b03166316f19831837f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad87856040516020016108a89392919061179e565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108d49291906117c8565b600060405180830381600087803b1580156108ee57600080fd5b505af1158015610902573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a35050919050565b600054610100900460ff16158080156109655750600054600160ff909116105b8061097f5750303b15801561097f575060005460ff166001145b6109e25760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610427565b6000805460ff191660011790558015610a05576000805461ff0019166101001790555b6001600160a01b03851615801590610a2557506001600160a01b03841615155b8015610a3957506001600160a01b03831615155b8015610a4d57506001600160a01b03821615155b610aaa5760405162461bcd60e51b815260206004820152602860248201527f526f6f74455243313135355072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b6064820152608401610427565b6000805462010000600160b01b031916620100006001600160a01b038881169190910291909117909155600180546001600160a01b031990811687841617909155600280548216868416179055600380549091169184169190911790558015610b4d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6000610b5f8561112c565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610b949033903090889088906004016117f4565b600060405180830381600087803b158015610bae57600080fd5b505af1158015610bc2573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935262010000909404841695506316f198319450610c5f939092169160e4016117c8565b600060405180830381600087803b158015610c7957600080fd5b505af1158015610c8d573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fbcbdf0c69f975f2a4085544938b054f02e77e87cbd055146d388c0be7120e04f9060600160405180910390a45050505050565b6000610cf78861112c565b905060005b84811015610da357886001600160a01b031663f242432a3330898986818110610d2757610d2761182c565b90506020020135888887818110610d4057610d4061182c565b905060200201356040518563ffffffff1660e01b8152600401610d6694939291906117f4565b600060405180830381600087803b158015610d8057600080fd5b505af1158015610d94573d6000803e3d6000fd5b50505050806001019050610cfc565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610e05907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e906020016118bd565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610e319291906117c8565b600060405180830381600087803b158015610e4b57600080fd5b505af1158015610e5f573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167f7e8ab6f25cb177d65db49b7a2197bb2a7df5757434857d411e2523b332a913e68a8a8a8a8a8a604051610eba96959493929190611928565b60405180910390a45050505050505050565b600080808080610ede86880188611971565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610f1357610f136119cc565b604051637921219560e11b81526001600160a01b0387169063f242432a90610f459030908890889088906004016117f4565b600060405180830381600087803b158015610f5f57600080fd5b505af1158015610f73573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907fc42752949ca07109e6f25adcde4a9407be23e084b1d32ca2bce8aa55bf3dd62590606001610eba565b600080808080610fdd868801886119e2565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080611014576110146119cc565b60005b83518110156110da57866001600160a01b031663f242432a308784815181106110425761104261182c565b602002602001015187858151811061105c5761105c61182c565b60200260200101518786815181106110765761107661182c565b60200260200101516040518563ffffffff1660e01b815260040161109d94939291906117f4565b600060405180830381600087803b1580156110b757600080fd5b505af11580156110cb573d6000803e3d6000fd5b50505050806001019050611017565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167fce612e98b81c726375e7c2395409e74ee0a29b22f7641ea5a8ce8508616448c0878787604051610eba93929190611b27565b6001600160a01b0380821660009081526004602052604090205416806111585761115582610629565b90505b6001600160a01b03811661116e5761116e6119cc565b919050565b60006020828403121561118557600080fd5b81356001600160e01b03198116811461119d57600080fd5b9392505050565b6001600160a01b03811681146111b957600080fd5b50565b6000806000606084860312156111d157600080fd5b83356111dc816111a4565b95602085013595506040909401359392505050565b60008083601f84011261120357600080fd5b5081356001600160401b0381111561121a57600080fd5b6020830191508360208260051b850101111561123557600080fd5b9250929050565b60008060008060008060006080888a03121561125757600080fd5b8735611262816111a4565b965060208801356001600160401b038082111561127e57600080fd5b61128a8b838c016111f1565b909850965060408a01359150808211156112a357600080fd5b6112af8b838c016111f1565b909650945060608a01359150808211156112c857600080fd5b506112d58a828b016111f1565b989b979a50959850939692959293505050565b6000602082840312156112fa57600080fd5b813561119d816111a4565b6000806000806080858703121561131b57600080fd5b8435611326816111a4565b93506020850135611336816111a4565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156113895761138961134b565b604052919050565b60006001600160401b038211156113aa576113aa61134b565b5060051b60200190565b600082601f8301126113c557600080fd5b813560206113da6113d583611391565b611361565b82815260059290921b840181019181810190868411156113f957600080fd5b8286015b8481101561141457803583529183019183016113fd565b509695505050505050565b60006001600160401b038211156114385761143861134b565b50601f01601f191660200190565b600082601f83011261145757600080fd5b81356114656113d58261141f565b81815284602083860101111561147a57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156114af57600080fd5b85356114ba816111a4565b945060208601356114ca816111a4565b935060408601356001600160401b03808211156114e657600080fd5b6114f289838a016113b4565b9450606088013591508082111561150857600080fd5b61151489838a016113b4565b9350608088013591508082111561152a57600080fd5b5061153788828901611446565b9150509295509295909350565b600080600080600060a0868803121561155c57600080fd5b8535611567816111a4565b94506020860135611577816111a4565b9350604086013592506060860135915060808601356001600160401b038111156115a057600080fd5b61153788828901611446565b600080600080606085870312156115c257600080fd5b8435935060208501356115d4816111a4565b925060408501356001600160401b03808211156115f057600080fd5b818701915087601f83011261160457600080fd5b81358181111561161357600080fd5b88602082850101111561162557600080fd5b95989497505060200194505050565b6000806000806080858703121561164a57600080fd5b8435611655816111a4565b93506020850135611665816111a4565b92506040850135611675816111a4565b91506060850135611685816111a4565b939692955090935050565b600080858511156116a057600080fd5b838611156116ad57600080fd5b5050820193919092039150565b803560208310156103ae57600019602084900360031b1b1692915050565b60005b838110156116f35781810151838201526020016116db565b50506000910152565b60006020828403121561170e57600080fd5b81516001600160401b0381111561172457600080fd5b8201601f8101841361173557600080fd5b80516117436113d58261141f565b81815285602083850101111561175857600080fd5b6117698260208301602086016116d8565b95945050505050565b6000815180845261178a8160208601602086016116d8565b601f01601f19169290920160200192915050565b8381526001600160a01b038316602082015260606040820181905260009061176990830184611772565b6001600160a01b03831681526040602082018190526000906117ec90830184611772565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b85811015611880578135611865816111a4565b6001600160a01b031687529582019590820190600101611852565b509495945050505050565b81835260006001600160fb1b038311156118a457600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c0606082018190526000906118f0908301888a611842565b828103608084015261190381878961188b565b905082810360a084015261191881858761188b565b9c9b505050505050505050505050565b60608152600061193c60608301888a611842565b828103602084015261194f81878961188b565b9050828103604084015261196481858761188b565b9998505050505050505050565b600080600080600060a0868803121561198957600080fd5b8535611994816111a4565b945060208601356119a4816111a4565b935060408601356119b4816111a4565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c087890312156119fb57600080fd5b86359550602080880135611a0e816111a4565b95506040880135611a1e816111a4565b945060608801356001600160401b0380821115611a3a57600080fd5b818a0191508a601f830112611a4e57600080fd5b8135611a5c6113d582611391565b81815260059190911b8301840190848101908d831115611a7b57600080fd5b938501935b82851015611aa2578435611a93816111a4565b82529385019390850190611a80565b9750505060808a0135925080831115611aba57600080fd5b611ac68b848c016113b4565b945060a08a0135925080831115611adc57600080fd5b5050611aea89828a016113b4565b9150509295509295509295565b600081518084526020808501945080840160005b8381101561188057815187529582019590820190600101611b0b565b606080825284519082018190526000906020906080840190828801845b82811015611b695781516001600160a01b031684529284019290840190600101611b44565b50505083810382850152611b7d8187611af7565b9150508281036040840152611b928185611af7565b969550505050505056fea2646970667358221220a129fa8b67110494523e0cc69d6b9705fd33df554433f902bbdc037049fa3b7b64736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101215760003560e01c8063bc197c81116100ad578063f23a6e6111610071578063f23a6e61146102fe578063f43cda8b1461031d578063f4a120f714610330578063f645125514610343578063f8c8765e1461036a57600080fd5b8063bc197c8114610238578063c5ac2b1c14610270578063cb10f94c14610297578063d41f1771146102b0578063d7c9e3ec146102d757600080fd5b80637efab4f5116100f45780637efab4f5146101a157806395c7041c146101ca578063a78e111c146101dd578063b1768065146101f0578063b68ad1e41461022557600080fd5b806301ffc9a7146101265780630efe6a8b1461014e5780634c4c45de14610163578063654715e614610176575b600080fd5b610139610134366004611173565b61037d565b60405190151581526020015b60405180910390f35b61016161015c3660046111bc565b6103b4565b005b61016161017136600461123c565b6103c5565b600254610189906001600160a01b031681565b6040516001600160a01b039091168152602001610145565b6101896101af3660046112e8565b6004602052600090815260409020546001600160a01b031681565b600154610189906001600160a01b031681565b6101616101eb366004611305565b610448565b6102177f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610145565b600354610189906001600160a01b031681565b610257610246366004611497565b63bc197c8160e01b95945050505050565b6040516001600160e01b03199091168152602001610145565b6102177faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b600054610189906201000090046001600160a01b031681565b6102177f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6102177f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b61025761030c366004611544565b63f23a6e6160e01b95945050505050565b61016161032b3660046115ac565b61045a565b61018961033e3660046112e8565b610629565b6102177f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b610161610378366004611634565b610945565b60006001600160e01b03198216630271189760e51b14806103ae57506301ffc9a760e01b6001600160e01b03198316145b92915050565b6103c083338484610b54565b505050565b84831480156103d357508481145b6104305760405162461bcd60e51b8152602060048201526024808201527f526f6f74455243313135355072656469636174653a20494e56414c49445f4c4560448201526309c8ea8960e31b60648201526084015b60405180910390fd5b61043f87878787878787610cec565b50505050505050565b61045484848484610b54565b50505050565b6001546001600160a01b031633146104c35760405162461bcd60e51b815260206004820152602660248201527f526f6f74455243313135355072656469636174653a204f4e4c595f455849545f6044820152652422a62822a960d11b6064820152608401610427565b6002546001600160a01b038481169116146105335760405162461bcd60e51b815260206004820152602a60248201527f526f6f74455243313135355072656469636174653a204f4e4c595f4348494c446044820152695f50524544494341544560b01b6064820152608401610427565b7f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e982869610562602060008486611690565b61056b916116ba565b0361058a576105856105808260208186611690565b610ecc565b610454565b7f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed26105b9602060008486611690565b6105c2916116ba565b036105d1576105858282610fcb565b60405162461bcd60e51b815260206004820152602760248201527f526f6f74455243313135355072656469636174653a20494e56414c49445f5349604482015266474e415455524560c81b6064820152608401610427565b60006001600160a01b03821661068d5760405162461bcd60e51b815260206004820152602360248201527f526f6f74455243313135355072656469636174653a20494e56414c49445f544f60448201526225a2a760e91b6064820152608401610427565b6001600160a01b0382811660009081526004602052604090205416156107015760405162461bcd60e51b8152602060048201526024808201527f526f6f74455243313135355072656469636174653a20414c52454144595f4d416044820152631414115160e21b6064820152608401610427565b6002546003546040516bffffffffffffffffffffffff19606086901b1660208201526001600160a01b03928316926107ab921690603401604051602081830303815290604052805190602001208360405160388101919091526f5af43d82803e903d91602b57fd5bf3ff60248201526014810192909252733d602d80600a3d3981f3363d3d373d3d3d363d73825260588201526037600c8201206078820152605560439091012090565b6001600160a01b03848116600081815260046020818152604080842080546001600160a01b031916968816969096179095558451908101855282815293516303a24d0760e21b8152908101919091529294509091630e89341c90602401600060405180830381865afa92505050801561084657506040513d6000823e601f3d908101601f1916820160405261084391908101906116fc565b60015b1561084e5790505b600060029054906101000a90046001600160a01b03166001600160a01b03166316f19831837f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad87856040516020016108a89392919061179e565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016108d49291906117c8565b600060405180830381600087803b1580156108ee57600080fd5b505af1158015610902573d6000803e3d6000fd5b50506040516001600160a01b038087169350871691507f85920d35e6c72f6b2affffa04298b0cecfeba86e4a9f407df661f1cb8ab5e61790600090a35050919050565b600054610100900460ff16158080156109655750600054600160ff909116105b8061097f5750303b15801561097f575060005460ff166001145b6109e25760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610427565b6000805460ff191660011790558015610a05576000805461ff0019166101001790555b6001600160a01b03851615801590610a2557506001600160a01b03841615155b8015610a3957506001600160a01b03831615155b8015610a4d57506001600160a01b03821615155b610aaa5760405162461bcd60e51b815260206004820152602860248201527f526f6f74455243313135355072656469636174653a204241445f494e495449416044820152672624ad20aa24a7a760c11b6064820152608401610427565b6000805462010000600160b01b031916620100006001600160a01b038881169190910291909117909155600180546001600160a01b031990811687841617909155600280548216868416179055600380549091169184169190911790558015610b4d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b6000610b5f8561112c565b604051637921219560e11b81529091506001600160a01b0386169063f242432a90610b949033903090889088906004016117f4565b600060405180830381600087803b158015610bae57600080fd5b505af1158015610bc2573d6000803e3d6000fd5b5050600054600254604080517f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82160208201526001600160a01b038b8116828401523360608301528a8116608083015260a082018a905260c08083018a90528351808403909101815260e08301938490526316f1983160e01b90935262010000909404841695506316f198319450610c5f939092169160e4016117c8565b600060405180830381600087803b158015610c7957600080fd5b505af1158015610c8d573d6000803e3d6000fd5b505060408051338152602081018790529081018590526001600160a01b03808816935084811692508816907fbcbdf0c69f975f2a4085544938b054f02e77e87cbd055146d388c0be7120e04f9060600160405180910390a45050505050565b6000610cf78861112c565b905060005b84811015610da357886001600160a01b031663f242432a3330898986818110610d2757610d2761182c565b90506020020135888887818110610d4057610d4061182c565b905060200201356040518563ffffffff1660e01b8152600401610d6694939291906117f4565b600060405180830381600087803b158015610d8057600080fd5b505af1158015610d94573d6000803e3d6000fd5b50505050806001019050610cfc565b506000546002546040516001600160a01b03620100009093048316926316f19831921690610e05907faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d18908d9033908e908e908e908e908e908e906020016118bd565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401610e319291906117c8565b600060405180830381600087803b158015610e4b57600080fd5b505af1158015610e5f573d6000803e3d6000fd5b50505050336001600160a01b0316816001600160a01b0316896001600160a01b03167f7e8ab6f25cb177d65db49b7a2197bb2a7df5757434857d411e2523b332a913e68a8a8a8a8a8a604051610eba96959493929190611928565b60405180910390a45050505050505050565b600080808080610ede86880188611971565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610f1357610f136119cc565b604051637921219560e11b81526001600160a01b0387169063f242432a90610f459030908890889088906004016117f4565b600060405180830381600087803b158015610f5f57600080fd5b505af1158015610f73573d6000803e3d6000fd5b5050604080516001600160a01b0389811682526020820188905291810186905281881693508482169250908916907fc42752949ca07109e6f25adcde4a9407be23e084b1d32ca2bce8aa55bf3dd62590606001610eba565b600080808080610fdd868801886119e2565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080611014576110146119cc565b60005b83518110156110da57866001600160a01b031663f242432a308784815181106110425761104261182c565b602002602001015187858151811061105c5761105c61182c565b60200260200101518786815181106110765761107661182c565b60200260200101516040518563ffffffff1660e01b815260040161109d94939291906117f4565b600060405180830381600087803b1580156110b757600080fd5b505af11580156110cb573d6000803e3d6000fd5b50505050806001019050611017565b50846001600160a01b0316816001600160a01b0316876001600160a01b03167fce612e98b81c726375e7c2395409e74ee0a29b22f7641ea5a8ce8508616448c0878787604051610eba93929190611b27565b6001600160a01b0380821660009081526004602052604090205416806111585761115582610629565b90505b6001600160a01b03811661116e5761116e6119cc565b919050565b60006020828403121561118557600080fd5b81356001600160e01b03198116811461119d57600080fd5b9392505050565b6001600160a01b03811681146111b957600080fd5b50565b6000806000606084860312156111d157600080fd5b83356111dc816111a4565b95602085013595506040909401359392505050565b60008083601f84011261120357600080fd5b5081356001600160401b0381111561121a57600080fd5b6020830191508360208260051b850101111561123557600080fd5b9250929050565b60008060008060008060006080888a03121561125757600080fd5b8735611262816111a4565b965060208801356001600160401b038082111561127e57600080fd5b61128a8b838c016111f1565b909850965060408a01359150808211156112a357600080fd5b6112af8b838c016111f1565b909650945060608a01359150808211156112c857600080fd5b506112d58a828b016111f1565b989b979a50959850939692959293505050565b6000602082840312156112fa57600080fd5b813561119d816111a4565b6000806000806080858703121561131b57600080fd5b8435611326816111a4565b93506020850135611336816111a4565b93969395505050506040820135916060013590565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156113895761138961134b565b604052919050565b60006001600160401b038211156113aa576113aa61134b565b5060051b60200190565b600082601f8301126113c557600080fd5b813560206113da6113d583611391565b611361565b82815260059290921b840181019181810190868411156113f957600080fd5b8286015b8481101561141457803583529183019183016113fd565b509695505050505050565b60006001600160401b038211156114385761143861134b565b50601f01601f191660200190565b600082601f83011261145757600080fd5b81356114656113d58261141f565b81815284602083860101111561147a57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156114af57600080fd5b85356114ba816111a4565b945060208601356114ca816111a4565b935060408601356001600160401b03808211156114e657600080fd5b6114f289838a016113b4565b9450606088013591508082111561150857600080fd5b61151489838a016113b4565b9350608088013591508082111561152a57600080fd5b5061153788828901611446565b9150509295509295909350565b600080600080600060a0868803121561155c57600080fd5b8535611567816111a4565b94506020860135611577816111a4565b9350604086013592506060860135915060808601356001600160401b038111156115a057600080fd5b61153788828901611446565b600080600080606085870312156115c257600080fd5b8435935060208501356115d4816111a4565b925060408501356001600160401b03808211156115f057600080fd5b818701915087601f83011261160457600080fd5b81358181111561161357600080fd5b88602082850101111561162557600080fd5b95989497505060200194505050565b6000806000806080858703121561164a57600080fd5b8435611655816111a4565b93506020850135611665816111a4565b92506040850135611675816111a4565b91506060850135611685816111a4565b939692955090935050565b600080858511156116a057600080fd5b838611156116ad57600080fd5b5050820193919092039150565b803560208310156103ae57600019602084900360031b1b1692915050565b60005b838110156116f35781810151838201526020016116db565b50506000910152565b60006020828403121561170e57600080fd5b81516001600160401b0381111561172457600080fd5b8201601f8101841361173557600080fd5b80516117436113d58261141f565b81815285602083850101111561175857600080fd5b6117698260208301602086016116d8565b95945050505050565b6000815180845261178a8160208601602086016116d8565b601f01601f19169290920160200192915050565b8381526001600160a01b038316602082015260606040820181905260009061176990830184611772565b6001600160a01b03831681526040602082018190526000906117ec90830184611772565b949350505050565b6001600160a01b0394851681529290931660208301526040820152606081019190915260a06080820181905260009082015260c00190565b634e487b7160e01b600052603260045260246000fd5b8183526000602080850194508260005b85811015611880578135611865816111a4565b6001600160a01b031687529582019590820190600101611852565b509495945050505050565b81835260006001600160fb1b038311156118a457600080fd5b8260051b80836020870137939093016020019392505050565b8981526001600160a01b0389811660208301528816604082015260c0606082018190526000906118f0908301888a611842565b828103608084015261190381878961188b565b905082810360a084015261191881858761188b565b9c9b505050505050505050505050565b60608152600061193c60608301888a611842565b828103602084015261194f81878961188b565b9050828103604084015261196481858761188b565b9998505050505050505050565b600080600080600060a0868803121561198957600080fd5b8535611994816111a4565b945060208601356119a4816111a4565b935060408601356119b4816111a4565b94979396509394606081013594506080013592915050565b634e487b7160e01b600052600160045260246000fd5b60008060008060008060c087890312156119fb57600080fd5b86359550602080880135611a0e816111a4565b95506040880135611a1e816111a4565b945060608801356001600160401b0380821115611a3a57600080fd5b818a0191508a601f830112611a4e57600080fd5b8135611a5c6113d582611391565b81815260059190911b8301840190848101908d831115611a7b57600080fd5b938501935b82851015611aa2578435611a93816111a4565b82529385019390850190611a80565b9750505060808a0135925080831115611aba57600080fd5b611ac68b848c016113b4565b945060a08a0135925080831115611adc57600080fd5b5050611aea89828a016113b4565b9150509295509295509295565b600081518084526020808501945080840160005b8381101561188057815187529582019590820190600101611b0b565b606080825284519082018190526000906020906080840190828801845b82811015611b695781516001600160a01b031684529284019290840190600101611b44565b50505083810382850152611b7d8187611af7565b9150508281036040840152611b928185611af7565b969550505050505056fea2646970667358221220a129fa8b67110494523e0cc69d6b9705fd33df554433f902bbdc037049fa3b7b64736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var ChildMintableERC1155PredicateArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"ChildMintableERC1155Predicate","sourceName":"contracts/bridge/ChildMintableERC1155Predicate.sol","abi":[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MintableERC1155Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"MintableERC1155DepositBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MintableERC1155Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"MintableERC1155WithdrawBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"rootToken","type":"address"},{"indexed":true,"internalType":"address","name":"childToken","type":"address"}],"name":"MintableTokenMapped","type":"event"},{"inputs":[],"name":"DEPOSIT_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEPOSIT_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAP_TOKEN_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_BATCH_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WITHDRAW_SIG","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"childTokenTemplate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"exitHelper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStateSender","type":"address"},{"internalType":"address","name":"newExitHelper","type":"address"},{"internalType":"address","name":"newRootERC1155Predicate","type":"address"},{"internalType":"address","name":"newChildTokenTemplate","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onL2StateReceive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rootERC1155Predicate","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"rootTokenToChildToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stateSender","outputs":[{"internalType":"contract IStateSender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"withdrawBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IChildERC1155","name":"childToken","type":"address"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdrawTo","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50611f7c806100206000396000f3fe608060405234801561001057600080fd5b50600436106100d55760003560e01c8063b8cd3ec011610087578063b8cd3ec0146101b6578063c5ac2b1c146101c9578063cb10f94c146101f0578063d41f177114610209578063d7c9e3ec14610230578063f43cda8b14610257578063f64512551461026a578063f8c8765e1461029157600080fd5b8063051eb2e2146100da5780637efab4f51461010a57806386937eb41461013357806395c7041c14610148578063b17680651461015b578063b5c5f67214610190578063b68ad1e4146101a3575b600080fd5b6002546100ed906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100ed610118366004611564565b6004602052600090815260409020546001600160a01b031681565b6101466101413660046115d3565b6102a4565b005b6001546100ed906001600160a01b031681565b6101827f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610101565b61014661019e36600461167f565b6102bc565b6003546100ed906001600160a01b031681565b6101466101c43660046116b4565b6102cd565b6101827faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6000546100ed906201000090046001600160a01b031681565b6101827f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101827f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6101466102653660046116fa565b6102df565b6101827f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61014661029f366004611782565b610514565b6102b38787878787878761062d565b50505050505050565b6102c8833384846109ba565b505050565b6102d9848484846109ba565b50505050565b6001546001600160a01b031633146103565760405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204f60448201526e27262cafa2ac24aa2fa422a62822a960891b60648201526084015b60405180910390fd5b6002546001600160a01b038481169116146103ce5760405162461bcd60e51b815260206004820152603260248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204f6044820152714e4c595f524f4f545f50524544494341544560701b606482015260840161034d565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216103fd6020600084866117de565b61040691611808565b036104255761042061041b82602081866117de565b610cd5565b6102d9565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d186104546020600084866117de565b61045d91611808565b0361046c576104208282610f40565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61049b6020600084866117de565b6104a491611808565b036104b35761042082826111ad565b60405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204960448201526f4e56414c49445f5349474e415455524560801b606482015260840161034d565b600054610100900460ff16158080156105345750600054600160ff909116105b8061054e5750303b15801561054e575060005460ff166001145b6105b15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161034d565b6000805460ff1916600117905580156105d4576000805461ff0019166101001790555b6105e085858585611317565b8015610626576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b8661063781611420565b6106535760405162461bcd60e51b815260040161034d90611826565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610693573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b79190611871565b6001600160a01b038181166000908152600460205260409020549192508a81169116146106f65760405162461bcd60e51b815260040161034d9061188e565b6001600160a01b03811661070c5761070c6118db565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610754573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107789190611871565b6001600160a01b03161461078e5761078e6118db565b868514801561079c57508483145b6107fe5760405162461bcd60e51b815260206004820152602d60248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204960448201526c09cac82989288be988a9c8ea89609b1b606482015260840161034d565b604051631ac8311560e21b81526001600160a01b038a1690636b20c454906108329033908a908a908a908a90600401611923565b6020604051808303816000875af1158015610851573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108759190611967565b6108915760405162461bcd60e51b815260040161034d90611989565b6000546002546040516001600160a01b03620100009093048316926316f198319216906108f2907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001611a1c565b6040516020818303038152906040526040518363ffffffff1660e01b815260040161091e929190611acd565b600060405180830381600087803b15801561093857600080fd5b505af115801561094c573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167fdd47868997765508c515e1f8ca079846dafbdfd8f98f6e76bca0891810b9f9d18b8b8b8b8b8b6040516109a796959493929190611af9565b60405180910390a4505050505050505050565b836109c481611420565b6109e05760405162461bcd60e51b815260040161034d90611826565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a20573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a449190611871565b6001600160a01b03818116600090815260046020526040902054919250878116911614610a835760405162461bcd60e51b815260040161034d9061188e565b6001600160a01b038116610a9957610a996118db565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ae1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b059190611871565b6001600160a01b031614610b1b57610b1b6118db565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca90610b4b90339088908890600401611b42565b6020604051808303816000875af1158015610b6a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8e9190611967565b610baa5760405162461bcd60e51b815260040161034d90611989565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352620100009094048416936316f1983193610c429391169160e401611acd565b600060405180830381600087803b158015610c5c57600080fd5b505af1158015610c70573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167fda58d73e08ba3c7767de904e68d208be8291494a9faaf70a6d4f736d24ec1f0f338888604051610cc593929190611b42565b60405180910390a4505050505050565b600080808080610ce786880188611b63565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610d2c5760405162461bcd60e51b815260040161034d9061188e565b610d3581611420565b610d4157610d416118db565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610da59190611871565b9050866001600160a01b0316816001600160a01b031614610dc857610dc86118db565b6001600160a01b038116610dde57610dde6118db565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e26573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e4a9190611871565b6001600160a01b031614610e6057610e606118db565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f690610e9090889088908890600401611b42565b6020604051808303816000875af1158015610eaf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ed39190611967565b610eef5760405162461bcd60e51b815260040161034d90611bbe565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f76a4cd47013e7e58abe817eedbb692d1614d71080b527412ebfb3f91a085a6de8988886040516109a793929190611b42565b600080808080610f5286880188611cdc565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080610f995760405162461bcd60e51b815260040161034d9061188e565b610fa281611420565b610fae57610fae6118db565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fee573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110129190611871565b9050866001600160a01b0316816001600160a01b031614611035576110356118db565b6001600160a01b03811661104b5761104b6118db565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611093573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110b79190611871565b6001600160a01b0316146110cd576110cd6118db565b604051635712868360e01b81526001600160a01b038316906357128683906110fd90889088908890600401611e21565b6020604051808303816000875af115801561111c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111409190611967565b61115c5760405162461bcd60e51b815260040161034d90611bbe565b856001600160a01b0316826001600160a01b0316886001600160a01b03167fc244cac13e0edc863dc5a2c3bd2b935f605b2ed225fb052eaef869bc24b76fde8888886040516109a793929190611e21565b6000806111bc83850185611e96565b9093509150506001600160a01b0382166111d8576111d86118db565b6001600160a01b038281166000908152600460205260409020541615611200576112006118db565b6003546040516bffffffffffffffffffffffff19606085901b166020820152600091611250916001600160a01b0390911690603401604051602081830303815290604052805190602001206114b5565b6001600160a01b0384811660009081526004602081905260409182902080546001600160a01b031916938516938417905590516379ccf11760e11b8152929350909163f399e22e916112a6918791879101611acd565b600060405180830381600087803b1580156112c057600080fd5b505af11580156112d4573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a35050505050565b6001600160a01b0384161580159061133757506001600160a01b03831615155b801561134b57506001600160a01b03821615155b801561135f57506001600160a01b03811615155b6113c55760405162461bcd60e51b815260206004820152603160248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204260448201527020a22fa4a724aa24a0a624ad20aa24a7a760791b606482015260840161034d565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000816001600160a01b03163b60000361143c57506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa9250505080156114a3575060408051601f3d908101601f191682019092526114a091810190611967565b60015b6114af57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166114af5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b604482015260640161034d565b6001600160a01b038116811461156157600080fd5b50565b60006020828403121561157657600080fd5b81356115818161154c565b9392505050565b60008083601f84011261159a57600080fd5b5081356001600160401b038111156115b157600080fd5b6020830191508360208260051b85010111156115cc57600080fd5b9250929050565b60008060008060008060006080888a0312156115ee57600080fd5b87356115f98161154c565b965060208801356001600160401b038082111561161557600080fd5b6116218b838c01611588565b909850965060408a013591508082111561163a57600080fd5b6116468b838c01611588565b909650945060608a013591508082111561165f57600080fd5b5061166c8a828b01611588565b989b979a50959850939692959293505050565b60008060006060848603121561169457600080fd5b833561169f8161154c565b95602085013595506040909401359392505050565b600080600080608085870312156116ca57600080fd5b84356116d58161154c565b935060208501356116e58161154c565b93969395505050506040820135916060013590565b6000806000806060858703121561171057600080fd5b8435935060208501356117228161154c565b925060408501356001600160401b038082111561173e57600080fd5b818701915087601f83011261175257600080fd5b81358181111561176157600080fd5b88602082850101111561177357600080fd5b95989497505060200194505050565b6000806000806080858703121561179857600080fd5b84356117a38161154c565b935060208501356117b38161154c565b925060408501356117c38161154c565b915060608501356117d38161154c565b939692955090935050565b600080858511156117ee57600080fd5b838611156117fb57600080fd5b5050820193919092039150565b803560208310156114af57600019602084900360031b1b1692915050565b6020808252602b908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204e60408201526a13d517d0d3d395149050d560aa1b606082015260800190565b60006020828403121561188357600080fd5b81516115818161154c565b6020808252602d908201527f4368696c644d696e7461626c65455243313135355072656469636174653a205560408201526c2726a0a82822a22faa27a5a2a760991b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561190a57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038616815260606020820181905260009061194890830186886118f1565b828103604084015261195b8185876118f1565b98975050505050505050565b60006020828403121561197957600080fd5b8151801515811461158157600080fd5b6020808252602a908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204260408201526915549397d1905253115160b21b606082015260800190565b8183526000602080850194508260005b85811015611a115781356119f68161154c565b6001600160a01b0316875295820195908201906001016119e3565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090611a4f908301888a6119d3565b8281036080840152611a628187896118f1565b905082810360a0840152611a778185876118f1565b9c9b505050505050505050505050565b6000815180845260005b81811015611aad57602081850181015186830182015201611a91565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611af190830184611a87565b949350505050565b606081526000611b0d60608301888a6119d3565b8281036020840152611b208187896118f1565b90508281036040840152611b358185876118f1565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a08688031215611b7b57600080fd5b8535611b868161154c565b94506020860135611b968161154c565b93506040860135611ba68161154c565b94979396509394606081013594506080013592915050565b6020808252602a908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204d60408201526912539517d1905253115160b21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611c4657611c46611c08565b604052919050565b60006001600160401b03821115611c6757611c67611c08565b5060051b60200190565b600082601f830112611c8257600080fd5b81356020611c97611c9283611c4e565b611c1e565b82815260059290921b84018101918181019086841115611cb657600080fd5b8286015b84811015611cd15780358352918301918301611cba565b509695505050505050565b60008060008060008060c08789031215611cf557600080fd5b86359550602080880135611d088161154c565b95506040880135611d188161154c565b945060608801356001600160401b0380821115611d3457600080fd5b818a0191508a601f830112611d4857600080fd5b8135611d56611c9282611c4e565b81815260059190911b8301840190848101908d831115611d7557600080fd5b938501935b82851015611d9c578435611d8d8161154c565b82529385019390850190611d7a565b9750505060808a0135925080831115611db457600080fd5b611dc08b848c01611c71565b945060a08a0135925080831115611dd657600080fd5b5050611de489828a01611c71565b9150509295509295509295565b600081518084526020808501945080840160005b83811015611a1157815187529582019590820190600101611e05565b606080825284519082018190526000906020906080840190828801845b82811015611e635781516001600160a01b031684529284019290840190600101611e3e565b50505083810382850152611e778187611df1565b9150508281036040840152611e8c8185611df1565b9695505050505050565b600080600060608486031215611eab57600080fd5b83359250602080850135611ebe8161154c565b925060408501356001600160401b0380821115611eda57600080fd5b818701915087601f830112611eee57600080fd5b813581811115611f0057611f00611c08565b611f12601f8201601f19168501611c1e565b91508082528884828501011115611f2857600080fd5b8084840185840137600084828401015250809350505050925092509256fea264697066735822122026b932a566e002e8c27e3e0f463c0498a2cad19becb4b82dde2b9525a3ca034464736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106100d55760003560e01c8063b8cd3ec011610087578063b8cd3ec0146101b6578063c5ac2b1c146101c9578063cb10f94c146101f0578063d41f177114610209578063d7c9e3ec14610230578063f43cda8b14610257578063f64512551461026a578063f8c8765e1461029157600080fd5b8063051eb2e2146100da5780637efab4f51461010a57806386937eb41461013357806395c7041c14610148578063b17680651461015b578063b5c5f67214610190578063b68ad1e4146101a3575b600080fd5b6002546100ed906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100ed610118366004611564565b6004602052600090815260409020546001600160a01b031681565b6101466101413660046115d3565b6102a4565b005b6001546100ed906001600160a01b031681565b6101827f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286981565b604051908152602001610101565b61014661019e36600461167f565b6102bc565b6003546100ed906001600160a01b031681565b6101466101c43660046116b4565b6102cd565b6101827faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d1881565b6000546100ed906201000090046001600160a01b031681565b6101827f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f82181565b6101827f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed281565b6101466102653660046116fa565b6102df565b6101827f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad81565b61014661029f366004611782565b610514565b6102b38787878787878761062d565b50505050505050565b6102c8833384846109ba565b505050565b6102d9848484846109ba565b50505050565b6001546001600160a01b031633146103565760405162461bcd60e51b815260206004820152602f60248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204f60448201526e27262cafa2ac24aa2fa422a62822a960891b60648201526084015b60405180910390fd5b6002546001600160a01b038481169116146103ce5760405162461bcd60e51b815260206004820152603260248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204f6044820152714e4c595f524f4f545f50524544494341544560701b606482015260840161034d565b7f87a7811f4bfedea3d341ad165680ae306b01aaeacc205d227629cf157dd9f8216103fd6020600084866117de565b61040691611808565b036104255761042061041b82602081866117de565b610cd5565b6102d9565b7faf50c8eab81226bc79eee3a10e3fe25db1a2be7241130e392b0675df839b6d186104546020600084866117de565b61045d91611808565b0361046c576104208282610f40565b7f2cef46a936bdc5b7e6e8c71aa04560c41cf7d88bb26901a7e7f4936ff02accad61049b6020600084866117de565b6104a491611808565b036104b35761042082826111ad565b60405162461bcd60e51b815260206004820152603060248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204960448201526f4e56414c49445f5349474e415455524560801b606482015260840161034d565b600054610100900460ff16158080156105345750600054600160ff909116105b8061054e5750303b15801561054e575060005460ff166001145b6105b15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161034d565b6000805460ff1916600117905580156105d4576000805461ff0019166101001790555b6105e085858585611317565b8015610626576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b8661063781611420565b6106535760405162461bcd60e51b815260040161034d90611826565b6000886001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610693573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b79190611871565b6001600160a01b038181166000908152600460205260409020549192508a81169116146106f65760405162461bcd60e51b815260040161034d9061188e565b6001600160a01b03811661070c5761070c6118db565b306001600160a01b0316896001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610754573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107789190611871565b6001600160a01b03161461078e5761078e6118db565b868514801561079c57508483145b6107fe5760405162461bcd60e51b815260206004820152602d60248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204960448201526c09cac82989288be988a9c8ea89609b1b606482015260840161034d565b604051631ac8311560e21b81526001600160a01b038a1690636b20c454906108329033908a908a908a908a90600401611923565b6020604051808303816000875af1158015610851573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108759190611967565b6108915760405162461bcd60e51b815260040161034d90611989565b6000546002546040516001600160a01b03620100009093048316926316f198319216906108f2907f5fb452c5a8f2b7c7ef2984e2f1063c7ee9b80b110cdc98ccb98f6654e10b5ed290869033908f908f908f908f908f908f90602001611a1c565b6040516020818303038152906040526040518363ffffffff1660e01b815260040161091e929190611acd565b600060405180830381600087803b15801561093857600080fd5b505af115801561094c573d6000803e3d6000fd5b50505050336001600160a01b0316896001600160a01b0316826001600160a01b03167fdd47868997765508c515e1f8ca079846dafbdfd8f98f6e76bca0891810b9f9d18b8b8b8b8b8b6040516109a796959493929190611af9565b60405180910390a4505050505050505050565b836109c481611420565b6109e05760405162461bcd60e51b815260040161034d90611826565b6000856001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610a20573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a449190611871565b6001600160a01b03818116600090815260046020526040902054919250878116911614610a835760405162461bcd60e51b815260040161034d9061188e565b6001600160a01b038116610a9957610a996118db565b306001600160a01b0316866001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610ae1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b059190611871565b6001600160a01b031614610b1b57610b1b6118db565b604051637a94c56560e11b81526001600160a01b0387169063f5298aca90610b4b90339088908890600401611b42565b6020604051808303816000875af1158015610b6a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b8e9190611967565b610baa5760405162461bcd60e51b815260040161034d90611989565b600054600254604080517f7a8dc26796a1e50e6e190b70259f58f6a4edd5b22280ceecc82b687b8e98286960208201526001600160a01b0385811682840152336060830152898116608083015260a0820189905260c08083018990528351808403909101815260e08301938490526316f1983160e01b909352620100009094048416936316f1983193610c429391169160e401611acd565b600060405180830381600087803b158015610c5c57600080fd5b505af1158015610c70573d6000803e3d6000fd5b50505050846001600160a01b0316866001600160a01b0316826001600160a01b03167fda58d73e08ba3c7767de904e68d208be8291494a9faaf70a6d4f736d24ec1f0f338888604051610cc593929190611b42565b60405180910390a4505050505050565b600080808080610ce786880188611b63565b6001600160a01b03808616600090815260046020526040902054959a50939850919650945092501680610d2c5760405162461bcd60e51b815260040161034d9061188e565b610d3581611420565b610d4157610d416118db565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610da59190611871565b9050866001600160a01b0316816001600160a01b031614610dc857610dc86118db565b6001600160a01b038116610dde57610dde6118db565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e26573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e4a9190611871565b6001600160a01b031614610e6057610e606118db565b604051630ab714fb60e11b81526001600160a01b0383169063156e29f690610e9090889088908890600401611b42565b6020604051808303816000875af1158015610eaf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ed39190611967565b610eef5760405162461bcd60e51b815260040161034d90611bbe565b846001600160a01b0316826001600160a01b0316886001600160a01b03167f76a4cd47013e7e58abe817eedbb692d1614d71080b527412ebfb3f91a085a6de8988886040516109a793929190611b42565b600080808080610f5286880188611cdc565b6001600160a01b03808616600090815260046020526040902054959b509399509197509550935016905080610f995760405162461bcd60e51b815260040161034d9061188e565b610fa281611420565b610fae57610fae6118db565b6000816001600160a01b0316631f2d00656040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fee573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110129190611871565b9050866001600160a01b0316816001600160a01b031614611035576110356118db565b6001600160a01b03811661104b5761104b6118db565b306001600160a01b0316826001600160a01b031663e61987056040518163ffffffff1660e01b8152600401602060405180830381865afa158015611093573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110b79190611871565b6001600160a01b0316146110cd576110cd6118db565b604051635712868360e01b81526001600160a01b038316906357128683906110fd90889088908890600401611e21565b6020604051808303816000875af115801561111c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111409190611967565b61115c5760405162461bcd60e51b815260040161034d90611bbe565b856001600160a01b0316826001600160a01b0316886001600160a01b03167fc244cac13e0edc863dc5a2c3bd2b935f605b2ed225fb052eaef869bc24b76fde8888886040516109a793929190611e21565b6000806111bc83850185611e96565b9093509150506001600160a01b0382166111d8576111d86118db565b6001600160a01b038281166000908152600460205260409020541615611200576112006118db565b6003546040516bffffffffffffffffffffffff19606085901b166020820152600091611250916001600160a01b0390911690603401604051602081830303815290604052805190602001206114b5565b6001600160a01b0384811660009081526004602081905260409182902080546001600160a01b031916938516938417905590516379ccf11760e11b8152929350909163f399e22e916112a6918791879101611acd565b600060405180830381600087803b1580156112c057600080fd5b505af11580156112d4573d6000803e3d6000fd5b50506040516001600160a01b038085169350861691507f0a1eaf9aa124c3f84c9dd77f7016af0f16f67639abb913af1697387db01f5ca590600090a35050505050565b6001600160a01b0384161580159061133757506001600160a01b03831615155b801561134b57506001600160a01b03821615155b801561135f57506001600160a01b03811615155b6113c55760405162461bcd60e51b815260206004820152603160248201527f4368696c644d696e7461626c65455243313135355072656469636174653a204260448201527020a22fa4a724aa24a0a624ad20aa24a7a760791b606482015260840161034d565b600080546001600160a01b03958616620100000262010000600160b01b0319909116179055600180549385166001600160a01b0319948516179055600280549285169284169290921790915560038054919093169116179055565b6000816001600160a01b03163b60000361143c57506000919050565b6040516301ffc9a760e01b8152636cdb3d1360e11b60048201526001600160a01b038316906301ffc9a790602401602060405180830381865afa9250505080156114a3575060408051601f3d908101601f191682019092526114a091810190611967565b60015b6114af57506000919050565b92915050565b6000763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c176000526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760096000f590506001600160a01b0381166114af5760405162461bcd60e51b8152602060048201526017602482015276115490cc4c4d8dce8818dc99585d194c8819985a5b1959604a1b604482015260640161034d565b6001600160a01b038116811461156157600080fd5b50565b60006020828403121561157657600080fd5b81356115818161154c565b9392505050565b60008083601f84011261159a57600080fd5b5081356001600160401b038111156115b157600080fd5b6020830191508360208260051b85010111156115cc57600080fd5b9250929050565b60008060008060008060006080888a0312156115ee57600080fd5b87356115f98161154c565b965060208801356001600160401b038082111561161557600080fd5b6116218b838c01611588565b909850965060408a013591508082111561163a57600080fd5b6116468b838c01611588565b909650945060608a013591508082111561165f57600080fd5b5061166c8a828b01611588565b989b979a50959850939692959293505050565b60008060006060848603121561169457600080fd5b833561169f8161154c565b95602085013595506040909401359392505050565b600080600080608085870312156116ca57600080fd5b84356116d58161154c565b935060208501356116e58161154c565b93969395505050506040820135916060013590565b6000806000806060858703121561171057600080fd5b8435935060208501356117228161154c565b925060408501356001600160401b038082111561173e57600080fd5b818701915087601f83011261175257600080fd5b81358181111561176157600080fd5b88602082850101111561177357600080fd5b95989497505060200194505050565b6000806000806080858703121561179857600080fd5b84356117a38161154c565b935060208501356117b38161154c565b925060408501356117c38161154c565b915060608501356117d38161154c565b939692955090935050565b600080858511156117ee57600080fd5b838611156117fb57600080fd5b5050820193919092039150565b803560208310156114af57600019602084900360031b1b1692915050565b6020808252602b908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204e60408201526a13d517d0d3d395149050d560aa1b606082015260800190565b60006020828403121561188357600080fd5b81516115818161154c565b6020808252602d908201527f4368696c644d696e7461626c65455243313135355072656469636174653a205560408201526c2726a0a82822a22faa27a5a2a760991b606082015260800190565b634e487b7160e01b600052600160045260246000fd5b81835260006001600160fb1b0383111561190a57600080fd5b8260051b80836020870137939093016020019392505050565b6001600160a01b038616815260606020820181905260009061194890830186886118f1565b828103604084015261195b8185876118f1565b98975050505050505050565b60006020828403121561197957600080fd5b8151801515811461158157600080fd5b6020808252602a908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204260408201526915549397d1905253115160b21b606082015260800190565b8183526000602080850194508260005b85811015611a115781356119f68161154c565b6001600160a01b0316875295820195908201906001016119e3565b509495945050505050565b8981526001600160a01b0389811660208301528816604082015260c060608201819052600090611a4f908301888a6119d3565b8281036080840152611a628187896118f1565b905082810360a0840152611a778185876118f1565b9c9b505050505050505050505050565b6000815180845260005b81811015611aad57602081850181015186830182015201611a91565b506000602082860101526020601f19601f83011685010191505092915050565b6001600160a01b0383168152604060208201819052600090611af190830184611a87565b949350505050565b606081526000611b0d60608301888a6119d3565b8281036020840152611b208187896118f1565b90508281036040840152611b358185876118f1565b9998505050505050505050565b6001600160a01b039390931683526020830191909152604082015260600190565b600080600080600060a08688031215611b7b57600080fd5b8535611b868161154c565b94506020860135611b968161154c565b93506040860135611ba68161154c565b94979396509394606081013594506080013592915050565b6020808252602a908201527f4368696c644d696e7461626c65455243313135355072656469636174653a204d60408201526912539517d1905253115160b21b606082015260800190565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715611c4657611c46611c08565b604052919050565b60006001600160401b03821115611c6757611c67611c08565b5060051b60200190565b600082601f830112611c8257600080fd5b81356020611c97611c9283611c4e565b611c1e565b82815260059290921b84018101918181019086841115611cb657600080fd5b8286015b84811015611cd15780358352918301918301611cba565b509695505050505050565b60008060008060008060c08789031215611cf557600080fd5b86359550602080880135611d088161154c565b95506040880135611d188161154c565b945060608801356001600160401b0380821115611d3457600080fd5b818a0191508a601f830112611d4857600080fd5b8135611d56611c9282611c4e565b81815260059190911b8301840190848101908d831115611d7557600080fd5b938501935b82851015611d9c578435611d8d8161154c565b82529385019390850190611d7a565b9750505060808a0135925080831115611db457600080fd5b611dc08b848c01611c71565b945060a08a0135925080831115611dd657600080fd5b5050611de489828a01611c71565b9150509295509295509295565b600081518084526020808501945080840160005b83811015611a1157815187529582019590820190600101611e05565b606080825284519082018190526000906020906080840190828801845b82811015611e635781516001600160a01b031684529284019290840190600101611e3e565b50505083810382850152611e778187611df1565b9150508281036040840152611e8c8185611df1565b9695505050505050565b600080600060608486031215611eab57600080fd5b83359250602080850135611ebe8161154c565b925060408501356001600160401b0380821115611eda57600080fd5b818701915087601f830112611eee57600080fd5b813581811115611f0057611f00611c08565b611f12601f8201601f19168501611c1e565b91508082528884828501011115611f2857600080fd5b8084840185840137600084828401015250809350505050925092509256fea264697066735822122026b932a566e002e8c27e3e0f463c0498a2cad19becb4b82dde2b9525a3ca034464736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var StakeManagerArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"StakeManager","sourceName":"contracts/blade/staking/StakeManager.sol","abi":[{"inputs":[{"internalType":"address","name":"validator","type":"address"}],"name":"InvalidSignature","type":"error"},{"inputs":[{"internalType":"string","name":"message","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"}],"name":"AddedToWhitelist","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"}],"name":"RemovedFromWhitelist","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"}],"name":"Snapshot","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"StakeAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"StakeRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"StakeWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"}],"name":"ValidatorDeactivated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"validator","type":"address"},{"indexed":false,"internalType":"uint256[4]","name":"blsKey","type":"uint256[4]"}],"name":"ValidatorRegistered","type":"event"},{"inputs":[],"name":"WITHDRAWAL_WAIT_PERIOD","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"epochNumber","type":"uint256"}],"name":"balanceOfAt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"domain","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"validator_","type":"address"}],"name":"getValidator","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256[4]","name":"blsKey","type":"uint256[4]"},{"internalType":"bool","name":"isWhitelisted","type":"bool"},{"internalType":"bool","name":"isActive","type":"bool"}],"internalType":"struct Validator","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newStakingToken","type":"address"},{"internalType":"address","name":"newBls","type":"address"},{"internalType":"address","name":"epochManager","type":"address"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"string","name":"newDomain","type":"string"},{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"stake","type":"uint256"},{"internalType":"uint256[4]","name":"blsKey","type":"uint256[4]"}],"internalType":"struct GenesisValidator[]","name":"genesisValidators","type":"tuple[]"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"pendingWithdrawals","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[2]","name":"signature","type":"uint256[2]"},{"internalType":"uint256[4]","name":"pubkey","type":"uint256[4]"}],"name":"register","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"stake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"validator","type":"address"}],"name":"stakeOf","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalStake","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"epochNumber","type":"uint256"}],"name":"totalSupplyAt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"unstake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"validators","outputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bool","name":"isWhitelisted","type":"bool"},{"internalType":"bool","name":"isActive","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"validators_","type":"address[]"}],"name":"whitelistValidators","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"withdrawable","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b50612cbf806100206000396000f3fe608060405234801561001057600080fd5b50600436106101b05760003560e01c80637b60f539116100ef578063c2fb26a611610092578063c2fb26a61461037d578063ce513b6f14610386578063dd62ed3e14610399578063e30c3978146103ac578063ea0fee4f146103bd578063f2fde38b146103c5578063f3f43703146103d8578063fa52c7d8146103eb57600080fd5b80637b60f539146102e95780638b0e9f3f146102fc5780638da5cb5b1461030457806395d89b4114610329578063981b24d014610331578063a457c2d714610344578063a694fc3a14610357578063a9059cbb1461036a57600080fd5b8063395093511161015757806339509351146102725780633ccfd60b14610285578063426233601461028d5780634ee2cd7e146102a0578063542c85f2146102b357806370a08231146102c6578063715018a6146102d957806379ba5097146102e157600080fd5b806306fdde03146101b5578063095ea7b3146101d357806318160ddd146101f65780631904bb2e146102085780631f6590b81461022857806323b872dd1461023d5780632e17de7814610250578063313ce56714610263575b600080fd5b6101bd610452565b6040516101ca9190612401565b60405180910390f35b6101e66101e136600461242b565b6104e4565b60405190151581526020016101ca565b6099545b6040519081526020016101ca565b61021b610216366004612455565b6104fe565b6040516101ca9190612470565b61023b6102363660046124cd565b610591565b005b6101e661024b36600461250f565b610676565b61023b61025e36600461254b565b61069a565b604051601281526020016101ca565b6101e661028036600461242b565b6106e1565b61023b610703565b6101fa61029b366004612455565b6107e8565b6101fa6102ae36600461242b565b6107f3565b61023b6102c1366004612564565b610806565b6101fa6102d4366004612455565b610861565b61023b61087c565b61023b610890565b61023b6102f7366004612763565b61090a565b6101fa610bc8565b6033546001600160a01b03165b6040516001600160a01b0390911681526020016101ca565b6101bd610bd8565b6101fa61033f36600461254b565b610be7565b6101e661035236600461242b565b610bf2565b61023b61036536600461254b565b610c6d565b6101e661037836600461242b565b610cb0565b6101fa60fe5481565b6101fa610394366004612455565b610cbe565b6101fa6103a736600461285a565b610d66565b6065546001600160a01b0316610311565b6101fa600181565b61023b6103d3366004612455565b610d91565b6101fa6103e6366004612455565b610e02565b61042b6103f9366004612455565b60ff60208190526000918252604090912080546005909101546001600160a01b03909116918181169161010090041683565b604080516001600160a01b03909416845291151560208401521515908201526060016101ca565b6060609a80546104619061288d565b80601f016020809104026020016040519081016040528092919081815260200182805461048d9061288d565b80156104da5780601f106104af576101008083540402835291602001916104da565b820191906000526020600020905b8154815290600101906020018083116104bd57829003601f168201915b5050505050905090565b6000336104f2818585610e9d565b60019150505b92915050565b6105066122bd565b6001600160a01b03828116600090815260ff60209081526040918290208251608080820185528254909516815283519485019384905293909291840191600184019060049082845b81548152602001906001019080831161054e5750505091835250506005919091015460ff8082161515602084015261010090910416151560409091015292915050565b33600090815260ff6020819052604090912060058101549091166105e95760405163973d02cb60e01b815260206004820152600960248201526815d2125511531254d560ba1b60448201526064015b60405180910390fd5b6105f4338484610fc1565b60058101805461ff001916610100179055610614600182018360046122f4565b5080546001600160a01b031916339081178255610630906110b9565b336001600160a01b03167f110ae3ae039a4632f836a35dc9b1282df88780883fb28779f22c2f7ccde8dd0a8360405161066991906128c7565b60405180910390a2505050565b600033610684858285611105565b61068f858585611179565b506001949350505050565b33600081815260ff60208190526040909120600501546101009004166106d35760405163973d02cb60e01b81526004016105e0906128d6565b6106dd338361131d565b5050565b6000336104f28185856106f48383610d66565b6106fe919061290f565b610e9d565b3360009081526101006020908152604080832060fd54825163eacdc5ff60e01b81529251919493849361078f936001600160a01b039093169263eacdc5ff926004808401939192918290030181865afa158015610764573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107889190612922565b849061137d565b808555604051828152919350915033907f8108595eb6bad3acefa9da467d90cc2217686d5c5ac85460f8b7849c840645fc9060200160405180910390a260fc546107e3906001600160a01b031633846113ef565b505050565b60006104f882611452565b60006107ff838361145d565b9392505050565b61080e6114a6565b8060005b8181101561085b5761084984848381811061082f5761082f61293b565b90506020020160208101906108449190612455565b611500565b8061085381612951565b915050610812565b50505050565b6001600160a01b031660009081526097602052604090205490565b6108846114a6565b61088e600061154f565b565b60655433906001600160a01b031681146108fe5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016105e0565b6109078161154f565b50565b600054610100900460ff161580801561092a5750600054600160ff909116105b806109445750303b158015610944575060005460ff166001145b6109a75760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016105e0565b6000805460ff1916600117905580156109ca576000805461ff0019166101001790555b610a156040518060400160405280600c81526020016b29ba30b5b2a6b0b730b3b2b960a11b815250604051806040016040528060058152602001645354414b4560d81b815250611568565b60fc80546001600160a01b03808a166001600160a01b03199283161790925560fb805489841690831617905560fd805492881692909116919091179055604051610a6390849060200161296a565b60408051601f19818403018152919052805160209091012060fe5560005b8251811015610b6f576000838281518110610a9e57610a9e61293b565b6020908102919091018101516040805160808101825282516001600160a01b0390811682528284015182860190815260018385018190526060840181905285518316600090815260ff90975293909520825181546001600160a01b031916921691909117815593519294509291610b19918301906004612332565b5060408201516005909101805460609093015115156101000261ff00199215159290921661ffff199093169290921717905580516020820151610b5c9190611599565b5080610b6781612951565b915050610a81565b50610b798461154f565b8015610bbf576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b6000610bd360995490565b905090565b6060609b80546104619061288d565b60006104f882611602565b60003381610c008286610d66565b905083811015610c605760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016105e0565b61068f8286868403610e9d565b33600081815260ff6020819052604090912060050154610100900416610ca65760405163973d02cb60e01b81526004016105e0906128d6565b6106dd3383611599565b6000336104f2818585611179565b60008060fd60009054906101000a90046001600160a01b03166001600160a01b031663eacdc5ff6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d14573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d389190612922565b6001600160a01b038416600090815261010060205260409020909150610d5e908261137d565b509392505050565b6001600160a01b03918216600090815260986020908152604080832093909416825291909152205490565b610d996114a6565b606580546001600160a01b0383166001600160a01b03199091168117909155610dca6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006104f860fd60009054906101000a90046001600160a01b03166001600160a01b031663eacdc5ff6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e5a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e7e9190612922565b6001600160a01b0384166000908152610100602052604090209061162d565b6001600160a01b038316610eff5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b60648201526084016105e0565b6001600160a01b038216610f605760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b60648201526084016105e0565b6001600160a01b0383811660008181526098602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b8135158015610fd257506020820135155b15610ffb57604051633615713d60e21b81526001600160a01b03841660048201526024016105e0565b60fb5460009081906001600160a01b031663ebbdac91858561101c896116cb565b6040518463ffffffff1660e01b815260040161103a93929190612986565b6040805180830381865afa158015611056573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061107a91906129da565b91509150801580611089575081155b156110b257604051633615713d60e21b81526001600160a01b03861660048201526024016105e0565b5050505050565b6001600160a01b038116600081815260ff6020526040808220600501805460ff19169055517fcdd2e9b91a56913d370075169cefa1602ba36be5301664f752192bb1709df7579190a250565b60006111118484610d66565b9050600019811461085b578181101561116c5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016105e0565b61085b8484848403610e9d565b6001600160a01b0383166111dd5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016105e0565b6001600160a01b03821661123f5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016105e0565b61124a838383611787565b6001600160a01b038316600090815260976020526040902054818110156112c25760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b60648201526084016105e0565b6001600160a01b038085166000818152609760205260408082208686039055928616808252908390208054860190559151600080516020612c6a833981519152906113109086815260200190565b60405180910390a361085b565b61132733826117f0565b816001600160a01b03167fa018dcbc822f59fb0d0c3e7a86c8e4259b9676cdea9e5fc26279b9c4c5d86eef8260405161136291815260200190565b60405180910390a2611374338261191e565b6106dd826119c5565b81546000905b83600101548110156113e8576000818152600285016020908152604091829020825180840190935280548352600101549082018190528410156113c657506113e8565b80516113d2908461290f565b92505080806113e090612951565b915050611383565b9250929050565b6040516001600160a01b0383166024820152604481018290526107e390849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152611a22565b60006104f882610861565b6001600160a01b038216600090815260c96020526040812081908190611484908590611af7565b915091508161149b5761149685610861565b61149d565b805b95945050505050565b6033546001600160a01b0316331461088e5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016105e0565b6001600160a01b038116600081815260ff6020526040808220600501805460ff19166001179055517fa850ae9193f515cbae8d35e8925bd2be26627fc91bce650b8652ed254e9cab039190a250565b606580546001600160a01b031916905561090781611bea565b600054610100900460ff1661158f5760405162461bcd60e51b81526004016105e090612a04565b6106dd8282611c3c565b6115a38282611c7c565b60fc546115bb906001600160a01b0316833084611d37565b816001600160a01b03167f7c717985ac273e663b7f3050f5b15a4388ff6ed952338954f650e2093e13937f826040516115f691815260200190565b60405180910390a25050565b60008060006116128460ca611af7565b915091508161162357609954611625565b805b949350505050565b60018201546000908082036116465760009150506104f8565b6000611653600183612a4f565b90505b845481106116c357600081815260028601602090815260409182902082518084019093528054835260010154908201819052851061169457506116c3565b80516116a0908561290f565b9350816000036116b057506116c3565b50806116bb81612a62565b915050611656565b505092915050565b6116d3612360565b60fb5460fe546040516bffffffffffffffffffffffff19606086811b8216602084015230901b1660348201524660488201526001600160a01b039092169163a850a90991906068016040516020818303038152906040526040518363ffffffff1660e01b8152600401611747929190612a79565b6040805180830381865afa158015611763573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104f89190612a92565b6001600160a01b03831615806117a457506001600160a01b038216155b6117e55760405162461bcd60e51b81526020600482015260126024820152712a2920a729a322a92fa327a92124a22222a760711b60448201526064016105e0565b6107e3838383611d6f565b6001600160a01b0382166118505760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016105e0565b61185c82600083611787565b6001600160a01b038216600090815260976020526040902054818110156118d05760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b60648201526084016105e0565b6001600160a01b0383166000818152609760209081526040808320868603905560998054879003905551858152919291600080516020612c6a833981519152910160405180910390a3505050565b6106dd81600160fd60009054906101000a90046001600160a01b03166001600160a01b031663eacdc5ff6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611977573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061199b9190612922565b6119a5919061290f565b6001600160a01b0385166000908152610100602052604090209190611db7565b6119ce81611452565b600003610907576001600160a01b038116600081815260ff6020526040808220600501805461ff0019169055517f23d934bfe7f1275bc6fd70432159c9cc1c0075d069f89da6a40f43bfe7a94ed39190a250565b6000611a77826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316611f2e9092919063ffffffff16565b9050805160001480611a98575080806020019051810190611a989190612b11565b6107e35760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016105e0565b60008060008411611b435760405162461bcd60e51b815260206004820152601660248201527504552433230536e617073686f743a20696420697320360541b60448201526064016105e0565b611b4b611f3d565b841115611b9a5760405162461bcd60e51b815260206004820152601d60248201527f4552433230536e617073686f743a206e6f6e6578697374656e7420696400000060448201526064016105e0565b6000611ba68486611fab565b84549091508103611bbe5760008092509250506113e8565b6001846001018281548110611bd557611bd561293b565b906000526020600020015492509250506113e8565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff16611c635760405162461bcd60e51b81526004016105e090612a04565b609a611c6f8382612b72565b50609b6107e38282612b72565b6001600160a01b038216611cd25760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016105e0565b611cde60008383611787565b8060996000828254611cf0919061290f565b90915550506001600160a01b038216600081815260976020908152604080832080548601905551848152600080516020612c6a833981519152910160405180910390a35050565b6040516001600160a01b038085166024830152831660448201526064810182905261085b9085906323b872dd60e01b9060840161141b565b6001600160a01b038316611d8e57611d8682612058565b6107e3612082565b6001600160a01b038216611da557611d8683612058565b611dae83612058565b6107e382612058565b81600003611e125760405162461bcd60e51b815260206004820152602260248201527f5769746864726177616c51756575654c69623a20494e56414c49445f414d4f55604482015261139560f21b60648201526084016105e0565b82546001840154818103611e69576040805180820182528581526020808201868152600085815260028a019092529281209151825591516001918201558601805491611e5d83612951565b91905055505050505050565b60006002860181611e7b600185612a4f565b815260200190815260200160002060010154905080841015611e9f57611e9f612c31565b83811015611eee576040805180820182528681526020808201878152600086815260028b019092529281209151825591516001918201558701805491611ee483612951565b9190505550611f26565b84600287016000611f00600186612a4f565b81526020019081526020016000206000016000828254611f20919061290f565b90915550505b505050505050565b60606116258484600085612090565b60fd546040805163eacdc5ff60e01b815290516000926001600160a01b03169163eacdc5ff9160048083019260209291908290030181865afa158015611f87573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bd39190612922565b81546000908103611fbe575060006104f8565b82546000905b8082101561200b576000611fd8838361216b565b60008781526020902090915085908201541115611ff757809150612005565b61200281600161290f565b92505b50611fc4565b60008211801561203757508361203486612026600186612a4f565b600091825260209091200190565b54145b1561205057612047600183612a4f565b925050506104f8565b5090506104f8565b6001600160a01b038116600090815260c9602052604090206109079061207d83610861565b612186565b61088e60ca61207d60995490565b6060824710156120f15760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016105e0565b600080866001600160a01b0316858760405161210d919061296a565b60006040518083038185875af1925050503d806000811461214a576040519150601f19603f3d011682016040523d82523d6000602084013e61214f565b606091505b5091509150612160878383876121d0565b979650505050505050565b600061217a6002848418612c47565b6107ff9084841661290f565b6000612190611f3d565b90508061219c84612249565b10156107e3578254600180820185556000858152602080822090930193909355938401805494850181558252902090910155565b6060831561223f578251600003612238576001600160a01b0385163b6122385760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016105e0565b5081611625565b6116258383612293565b8054600090810361225c57506000919050565b8154829061226c90600190612a4f565b8154811061227c5761227c61293b565b90600052602060002001549050919050565b919050565b8151156122a35781518083602001fd5b8060405162461bcd60e51b81526004016105e09190612401565b604051806080016040528060006001600160a01b031681526020016122e061237e565b815260006020820181905260409091015290565b8260048101928215612322579160200282015b82811115612322578235825591602001919060010190612307565b5061232e92915061239c565b5090565b8260048101928215612322579160200282015b82811115612322578251825591602001919060010190612345565b60405180604001604052806002906020820280368337509192915050565b60405180608001604052806004906020820280368337509192915050565b5b8082111561232e576000815560010161239d565b60005b838110156123cc5781810151838201526020016123b4565b50506000910152565b600081518084526123ed8160208601602086016123b1565b601f01601f19169290920160200192915050565b6020815260006107ff60208301846123d5565b80356001600160a01b038116811461228e57600080fd5b6000806040838503121561243e57600080fd5b61244783612414565b946020939093013593505050565b60006020828403121561246757600080fd5b6107ff82612414565b81516001600160a01b0316815260208083015160e08301919081840160005b60048110156124ac5782518252918301919083019060010161248f565b505050506040830151151560a0830152606090920151151560c09091015290565b60008060c083850312156124e057600080fd5b60408301848111156124f157600080fd5b8392508460c08501111561250457600080fd5b809150509250929050565b60008060006060848603121561252457600080fd5b61252d84612414565b925061253b60208501612414565b9150604084013590509250925092565b60006020828403121561255d57600080fd5b5035919050565b6000806020838503121561257757600080fd5b82356001600160401b038082111561258e57600080fd5b818501915085601f8301126125a257600080fd5b8135818111156125b157600080fd5b8660208260051b85010111156125c657600080fd5b60209290920196919550909350505050565b634e487b7160e01b600052604160045260246000fd5b604051606081016001600160401b0381118282101715612610576126106125d8565b60405290565b604051608081016001600160401b0381118282101715612610576126106125d8565b604051601f8201601f191681016001600160401b0381118282101715612660576126606125d8565b604052919050565b600082601f83011261267957600080fd5b813560206001600160401b03821115612694576126946125d8565b6126a2818360051b01612638565b82815260c092830285018201928282019190878511156126c157600080fd5b8387015b858110156127565781818a0312156126dd5760008081fd5b6126e56125ee565b6126ee82612414565b8152858201358682015260408a605f84011261270a5760008081fd5b612712612616565b808585018d8111156127245760008081fd5b8386015b8181101561273f5780358452928a01928a01612728565b5050918301919091525084529284019281016126c5565b5090979650505050505050565b60008060008060008060c0878903121561277c57600080fd5b61278587612414565b95506020612794818901612414565b95506127a260408901612414565b94506127b060608901612414565b935060808801356001600160401b03808211156127cc57600080fd5b818a0191508a601f8301126127e057600080fd5b8135818111156127f2576127f26125d8565b612804601f8201601f19168501612638565b8181528c8583860101111561281857600080fd5b818585018683013760009181019094015291935060a0890135918083111561283f57600080fd5b505061284d89828a01612668565b9150509295509295509295565b6000806040838503121561286d57600080fd5b61287683612414565b915061288460208401612414565b90509250929050565b600181811c908216806128a157607f821691505b6020821081036128c157634e487b7160e01b600052602260045260246000fd5b50919050565b60808181019083833792915050565b6020808252600990820152682b20a624a220aa27a960b91b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b808201808211156104f8576104f86128f9565b60006020828403121561293457600080fd5b5051919050565b634e487b7160e01b600052603260045260246000fd5b600060018201612963576129636128f9565b5060010190565b6000825161297c8184602087016123b1565b9190910192915050565b61010081016040858337608084604084013760c082018360005b60028110156129bf5781518352602092830192909101906001016129a0565b505050949350505050565b8051801515811461228e57600080fd5b600080604083850312156129ed57600080fd5b6129f6836129ca565b9150612884602084016129ca565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b818103818111156104f8576104f86128f9565b600081612a7157612a716128f9565b506000190190565b82815260406020820152600061162560408301846123d5565b600060408284031215612aa457600080fd5b82601f830112612ab357600080fd5b604051604081018181106001600160401b0382111715612ad557612ad56125d8565b8060405250806040840185811115612aec57600080fd5b845b81811015612b06578051835260209283019201612aee565b509195945050505050565b600060208284031215612b2357600080fd5b6107ff826129ca565b601f8211156107e357600081815260208120601f850160051c81016020861015612b535750805b601f850160051c820191505b81811015611f2657828155600101612b5f565b81516001600160401b03811115612b8b57612b8b6125d8565b612b9f81612b99845461288d565b84612b2c565b602080601f831160018114612bd45760008415612bbc5750858301515b600019600386901b1c1916600185901b178555611f26565b600085815260208120601f198616915b82811015612c0357888601518255948401946001909101908401612be4565b5085821015612c215787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b634e487b7160e01b600052600160045260246000fd5b600082612c6457634e487b7160e01b600052601260045260246000fd5b50049056feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa264697066735822122036f49d156164c122ed5eba55f5178d52fc1b8a3ceb06f21542e8592f30b3bfa964736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101b05760003560e01c80637b60f539116100ef578063c2fb26a611610092578063c2fb26a61461037d578063ce513b6f14610386578063dd62ed3e14610399578063e30c3978146103ac578063ea0fee4f146103bd578063f2fde38b146103c5578063f3f43703146103d8578063fa52c7d8146103eb57600080fd5b80637b60f539146102e95780638b0e9f3f146102fc5780638da5cb5b1461030457806395d89b4114610329578063981b24d014610331578063a457c2d714610344578063a694fc3a14610357578063a9059cbb1461036a57600080fd5b8063395093511161015757806339509351146102725780633ccfd60b14610285578063426233601461028d5780634ee2cd7e146102a0578063542c85f2146102b357806370a08231146102c6578063715018a6146102d957806379ba5097146102e157600080fd5b806306fdde03146101b5578063095ea7b3146101d357806318160ddd146101f65780631904bb2e146102085780631f6590b81461022857806323b872dd1461023d5780632e17de7814610250578063313ce56714610263575b600080fd5b6101bd610452565b6040516101ca9190612401565b60405180910390f35b6101e66101e136600461242b565b6104e4565b60405190151581526020016101ca565b6099545b6040519081526020016101ca565b61021b610216366004612455565b6104fe565b6040516101ca9190612470565b61023b6102363660046124cd565b610591565b005b6101e661024b36600461250f565b610676565b61023b61025e36600461254b565b61069a565b604051601281526020016101ca565b6101e661028036600461242b565b6106e1565b61023b610703565b6101fa61029b366004612455565b6107e8565b6101fa6102ae36600461242b565b6107f3565b61023b6102c1366004612564565b610806565b6101fa6102d4366004612455565b610861565b61023b61087c565b61023b610890565b61023b6102f7366004612763565b61090a565b6101fa610bc8565b6033546001600160a01b03165b6040516001600160a01b0390911681526020016101ca565b6101bd610bd8565b6101fa61033f36600461254b565b610be7565b6101e661035236600461242b565b610bf2565b61023b61036536600461254b565b610c6d565b6101e661037836600461242b565b610cb0565b6101fa60fe5481565b6101fa610394366004612455565b610cbe565b6101fa6103a736600461285a565b610d66565b6065546001600160a01b0316610311565b6101fa600181565b61023b6103d3366004612455565b610d91565b6101fa6103e6366004612455565b610e02565b61042b6103f9366004612455565b60ff60208190526000918252604090912080546005909101546001600160a01b03909116918181169161010090041683565b604080516001600160a01b03909416845291151560208401521515908201526060016101ca565b6060609a80546104619061288d565b80601f016020809104026020016040519081016040528092919081815260200182805461048d9061288d565b80156104da5780601f106104af576101008083540402835291602001916104da565b820191906000526020600020905b8154815290600101906020018083116104bd57829003601f168201915b5050505050905090565b6000336104f2818585610e9d565b60019150505b92915050565b6105066122bd565b6001600160a01b03828116600090815260ff60209081526040918290208251608080820185528254909516815283519485019384905293909291840191600184019060049082845b81548152602001906001019080831161054e5750505091835250506005919091015460ff8082161515602084015261010090910416151560409091015292915050565b33600090815260ff6020819052604090912060058101549091166105e95760405163973d02cb60e01b815260206004820152600960248201526815d2125511531254d560ba1b60448201526064015b60405180910390fd5b6105f4338484610fc1565b60058101805461ff001916610100179055610614600182018360046122f4565b5080546001600160a01b031916339081178255610630906110b9565b336001600160a01b03167f110ae3ae039a4632f836a35dc9b1282df88780883fb28779f22c2f7ccde8dd0a8360405161066991906128c7565b60405180910390a2505050565b600033610684858285611105565b61068f858585611179565b506001949350505050565b33600081815260ff60208190526040909120600501546101009004166106d35760405163973d02cb60e01b81526004016105e0906128d6565b6106dd338361131d565b5050565b6000336104f28185856106f48383610d66565b6106fe919061290f565b610e9d565b3360009081526101006020908152604080832060fd54825163eacdc5ff60e01b81529251919493849361078f936001600160a01b039093169263eacdc5ff926004808401939192918290030181865afa158015610764573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107889190612922565b849061137d565b808555604051828152919350915033907f8108595eb6bad3acefa9da467d90cc2217686d5c5ac85460f8b7849c840645fc9060200160405180910390a260fc546107e3906001600160a01b031633846113ef565b505050565b60006104f882611452565b60006107ff838361145d565b9392505050565b61080e6114a6565b8060005b8181101561085b5761084984848381811061082f5761082f61293b565b90506020020160208101906108449190612455565b611500565b8061085381612951565b915050610812565b50505050565b6001600160a01b031660009081526097602052604090205490565b6108846114a6565b61088e600061154f565b565b60655433906001600160a01b031681146108fe5760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016105e0565b6109078161154f565b50565b600054610100900460ff161580801561092a5750600054600160ff909116105b806109445750303b158015610944575060005460ff166001145b6109a75760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016105e0565b6000805460ff1916600117905580156109ca576000805461ff0019166101001790555b610a156040518060400160405280600c81526020016b29ba30b5b2a6b0b730b3b2b960a11b815250604051806040016040528060058152602001645354414b4560d81b815250611568565b60fc80546001600160a01b03808a166001600160a01b03199283161790925560fb805489841690831617905560fd805492881692909116919091179055604051610a6390849060200161296a565b60408051601f19818403018152919052805160209091012060fe5560005b8251811015610b6f576000838281518110610a9e57610a9e61293b565b6020908102919091018101516040805160808101825282516001600160a01b0390811682528284015182860190815260018385018190526060840181905285518316600090815260ff90975293909520825181546001600160a01b031916921691909117815593519294509291610b19918301906004612332565b5060408201516005909101805460609093015115156101000261ff00199215159290921661ffff199093169290921717905580516020820151610b5c9190611599565b5080610b6781612951565b915050610a81565b50610b798461154f565b8015610bbf576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b6000610bd360995490565b905090565b6060609b80546104619061288d565b60006104f882611602565b60003381610c008286610d66565b905083811015610c605760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016105e0565b61068f8286868403610e9d565b33600081815260ff6020819052604090912060050154610100900416610ca65760405163973d02cb60e01b81526004016105e0906128d6565b6106dd3383611599565b6000336104f2818585611179565b60008060fd60009054906101000a90046001600160a01b03166001600160a01b031663eacdc5ff6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610d14573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d389190612922565b6001600160a01b038416600090815261010060205260409020909150610d5e908261137d565b509392505050565b6001600160a01b03918216600090815260986020908152604080832093909416825291909152205490565b610d996114a6565b606580546001600160a01b0383166001600160a01b03199091168117909155610dca6033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b60006104f860fd60009054906101000a90046001600160a01b03166001600160a01b031663eacdc5ff6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e5a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e7e9190612922565b6001600160a01b0384166000908152610100602052604090209061162d565b6001600160a01b038316610eff5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b60648201526084016105e0565b6001600160a01b038216610f605760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b60648201526084016105e0565b6001600160a01b0383811660008181526098602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b8135158015610fd257506020820135155b15610ffb57604051633615713d60e21b81526001600160a01b03841660048201526024016105e0565b60fb5460009081906001600160a01b031663ebbdac91858561101c896116cb565b6040518463ffffffff1660e01b815260040161103a93929190612986565b6040805180830381865afa158015611056573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061107a91906129da565b91509150801580611089575081155b156110b257604051633615713d60e21b81526001600160a01b03861660048201526024016105e0565b5050505050565b6001600160a01b038116600081815260ff6020526040808220600501805460ff19169055517fcdd2e9b91a56913d370075169cefa1602ba36be5301664f752192bb1709df7579190a250565b60006111118484610d66565b9050600019811461085b578181101561116c5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016105e0565b61085b8484848403610e9d565b6001600160a01b0383166111dd5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016105e0565b6001600160a01b03821661123f5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016105e0565b61124a838383611787565b6001600160a01b038316600090815260976020526040902054818110156112c25760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b60648201526084016105e0565b6001600160a01b038085166000818152609760205260408082208686039055928616808252908390208054860190559151600080516020612c6a833981519152906113109086815260200190565b60405180910390a361085b565b61132733826117f0565b816001600160a01b03167fa018dcbc822f59fb0d0c3e7a86c8e4259b9676cdea9e5fc26279b9c4c5d86eef8260405161136291815260200190565b60405180910390a2611374338261191e565b6106dd826119c5565b81546000905b83600101548110156113e8576000818152600285016020908152604091829020825180840190935280548352600101549082018190528410156113c657506113e8565b80516113d2908461290f565b92505080806113e090612951565b915050611383565b9250929050565b6040516001600160a01b0383166024820152604481018290526107e390849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152611a22565b60006104f882610861565b6001600160a01b038216600090815260c96020526040812081908190611484908590611af7565b915091508161149b5761149685610861565b61149d565b805b95945050505050565b6033546001600160a01b0316331461088e5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016105e0565b6001600160a01b038116600081815260ff6020526040808220600501805460ff19166001179055517fa850ae9193f515cbae8d35e8925bd2be26627fc91bce650b8652ed254e9cab039190a250565b606580546001600160a01b031916905561090781611bea565b600054610100900460ff1661158f5760405162461bcd60e51b81526004016105e090612a04565b6106dd8282611c3c565b6115a38282611c7c565b60fc546115bb906001600160a01b0316833084611d37565b816001600160a01b03167f7c717985ac273e663b7f3050f5b15a4388ff6ed952338954f650e2093e13937f826040516115f691815260200190565b60405180910390a25050565b60008060006116128460ca611af7565b915091508161162357609954611625565b805b949350505050565b60018201546000908082036116465760009150506104f8565b6000611653600183612a4f565b90505b845481106116c357600081815260028601602090815260409182902082518084019093528054835260010154908201819052851061169457506116c3565b80516116a0908561290f565b9350816000036116b057506116c3565b50806116bb81612a62565b915050611656565b505092915050565b6116d3612360565b60fb5460fe546040516bffffffffffffffffffffffff19606086811b8216602084015230901b1660348201524660488201526001600160a01b039092169163a850a90991906068016040516020818303038152906040526040518363ffffffff1660e01b8152600401611747929190612a79565b6040805180830381865afa158015611763573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104f89190612a92565b6001600160a01b03831615806117a457506001600160a01b038216155b6117e55760405162461bcd60e51b81526020600482015260126024820152712a2920a729a322a92fa327a92124a22222a760711b60448201526064016105e0565b6107e3838383611d6f565b6001600160a01b0382166118505760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016105e0565b61185c82600083611787565b6001600160a01b038216600090815260976020526040902054818110156118d05760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b60648201526084016105e0565b6001600160a01b0383166000818152609760209081526040808320868603905560998054879003905551858152919291600080516020612c6a833981519152910160405180910390a3505050565b6106dd81600160fd60009054906101000a90046001600160a01b03166001600160a01b031663eacdc5ff6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611977573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061199b9190612922565b6119a5919061290f565b6001600160a01b0385166000908152610100602052604090209190611db7565b6119ce81611452565b600003610907576001600160a01b038116600081815260ff6020526040808220600501805461ff0019169055517f23d934bfe7f1275bc6fd70432159c9cc1c0075d069f89da6a40f43bfe7a94ed39190a250565b6000611a77826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316611f2e9092919063ffffffff16565b9050805160001480611a98575080806020019051810190611a989190612b11565b6107e35760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016105e0565b60008060008411611b435760405162461bcd60e51b815260206004820152601660248201527504552433230536e617073686f743a20696420697320360541b60448201526064016105e0565b611b4b611f3d565b841115611b9a5760405162461bcd60e51b815260206004820152601d60248201527f4552433230536e617073686f743a206e6f6e6578697374656e7420696400000060448201526064016105e0565b6000611ba68486611fab565b84549091508103611bbe5760008092509250506113e8565b6001846001018281548110611bd557611bd561293b565b906000526020600020015492509250506113e8565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff16611c635760405162461bcd60e51b81526004016105e090612a04565b609a611c6f8382612b72565b50609b6107e38282612b72565b6001600160a01b038216611cd25760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016105e0565b611cde60008383611787565b8060996000828254611cf0919061290f565b90915550506001600160a01b038216600081815260976020908152604080832080548601905551848152600080516020612c6a833981519152910160405180910390a35050565b6040516001600160a01b038085166024830152831660448201526064810182905261085b9085906323b872dd60e01b9060840161141b565b6001600160a01b038316611d8e57611d8682612058565b6107e3612082565b6001600160a01b038216611da557611d8683612058565b611dae83612058565b6107e382612058565b81600003611e125760405162461bcd60e51b815260206004820152602260248201527f5769746864726177616c51756575654c69623a20494e56414c49445f414d4f55604482015261139560f21b60648201526084016105e0565b82546001840154818103611e69576040805180820182528581526020808201868152600085815260028a019092529281209151825591516001918201558601805491611e5d83612951565b91905055505050505050565b60006002860181611e7b600185612a4f565b815260200190815260200160002060010154905080841015611e9f57611e9f612c31565b83811015611eee576040805180820182528681526020808201878152600086815260028b019092529281209151825591516001918201558701805491611ee483612951565b9190505550611f26565b84600287016000611f00600186612a4f565b81526020019081526020016000206000016000828254611f20919061290f565b90915550505b505050505050565b60606116258484600085612090565b60fd546040805163eacdc5ff60e01b815290516000926001600160a01b03169163eacdc5ff9160048083019260209291908290030181865afa158015611f87573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bd39190612922565b81546000908103611fbe575060006104f8565b82546000905b8082101561200b576000611fd8838361216b565b60008781526020902090915085908201541115611ff757809150612005565b61200281600161290f565b92505b50611fc4565b60008211801561203757508361203486612026600186612a4f565b600091825260209091200190565b54145b1561205057612047600183612a4f565b925050506104f8565b5090506104f8565b6001600160a01b038116600090815260c9602052604090206109079061207d83610861565b612186565b61088e60ca61207d60995490565b6060824710156120f15760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016105e0565b600080866001600160a01b0316858760405161210d919061296a565b60006040518083038185875af1925050503d806000811461214a576040519150601f19603f3d011682016040523d82523d6000602084013e61214f565b606091505b5091509150612160878383876121d0565b979650505050505050565b600061217a6002848418612c47565b6107ff9084841661290f565b6000612190611f3d565b90508061219c84612249565b10156107e3578254600180820185556000858152602080822090930193909355938401805494850181558252902090910155565b6060831561223f578251600003612238576001600160a01b0385163b6122385760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016105e0565b5081611625565b6116258383612293565b8054600090810361225c57506000919050565b8154829061226c90600190612a4f565b8154811061227c5761227c61293b565b90600052602060002001549050919050565b919050565b8151156122a35781518083602001fd5b8060405162461bcd60e51b81526004016105e09190612401565b604051806080016040528060006001600160a01b031681526020016122e061237e565b815260006020820181905260409091015290565b8260048101928215612322579160200282015b82811115612322578235825591602001919060010190612307565b5061232e92915061239c565b5090565b8260048101928215612322579160200282015b82811115612322578251825591602001919060010190612345565b60405180604001604052806002906020820280368337509192915050565b60405180608001604052806004906020820280368337509192915050565b5b8082111561232e576000815560010161239d565b60005b838110156123cc5781810151838201526020016123b4565b50506000910152565b600081518084526123ed8160208601602086016123b1565b601f01601f19169290920160200192915050565b6020815260006107ff60208301846123d5565b80356001600160a01b038116811461228e57600080fd5b6000806040838503121561243e57600080fd5b61244783612414565b946020939093013593505050565b60006020828403121561246757600080fd5b6107ff82612414565b81516001600160a01b0316815260208083015160e08301919081840160005b60048110156124ac5782518252918301919083019060010161248f565b505050506040830151151560a0830152606090920151151560c09091015290565b60008060c083850312156124e057600080fd5b60408301848111156124f157600080fd5b8392508460c08501111561250457600080fd5b809150509250929050565b60008060006060848603121561252457600080fd5b61252d84612414565b925061253b60208501612414565b9150604084013590509250925092565b60006020828403121561255d57600080fd5b5035919050565b6000806020838503121561257757600080fd5b82356001600160401b038082111561258e57600080fd5b818501915085601f8301126125a257600080fd5b8135818111156125b157600080fd5b8660208260051b85010111156125c657600080fd5b60209290920196919550909350505050565b634e487b7160e01b600052604160045260246000fd5b604051606081016001600160401b0381118282101715612610576126106125d8565b60405290565b604051608081016001600160401b0381118282101715612610576126106125d8565b604051601f8201601f191681016001600160401b0381118282101715612660576126606125d8565b604052919050565b600082601f83011261267957600080fd5b813560206001600160401b03821115612694576126946125d8565b6126a2818360051b01612638565b82815260c092830285018201928282019190878511156126c157600080fd5b8387015b858110156127565781818a0312156126dd5760008081fd5b6126e56125ee565b6126ee82612414565b8152858201358682015260408a605f84011261270a5760008081fd5b612712612616565b808585018d8111156127245760008081fd5b8386015b8181101561273f5780358452928a01928a01612728565b5050918301919091525084529284019281016126c5565b5090979650505050505050565b60008060008060008060c0878903121561277c57600080fd5b61278587612414565b95506020612794818901612414565b95506127a260408901612414565b94506127b060608901612414565b935060808801356001600160401b03808211156127cc57600080fd5b818a0191508a601f8301126127e057600080fd5b8135818111156127f2576127f26125d8565b612804601f8201601f19168501612638565b8181528c8583860101111561281857600080fd5b818585018683013760009181019094015291935060a0890135918083111561283f57600080fd5b505061284d89828a01612668565b9150509295509295509295565b6000806040838503121561286d57600080fd5b61287683612414565b915061288460208401612414565b90509250929050565b600181811c908216806128a157607f821691505b6020821081036128c157634e487b7160e01b600052602260045260246000fd5b50919050565b60808181019083833792915050565b6020808252600990820152682b20a624a220aa27a960b91b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b808201808211156104f8576104f86128f9565b60006020828403121561293457600080fd5b5051919050565b634e487b7160e01b600052603260045260246000fd5b600060018201612963576129636128f9565b5060010190565b6000825161297c8184602087016123b1565b9190910192915050565b61010081016040858337608084604084013760c082018360005b60028110156129bf5781518352602092830192909101906001016129a0565b505050949350505050565b8051801515811461228e57600080fd5b600080604083850312156129ed57600080fd5b6129f6836129ca565b9150612884602084016129ca565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b818103818111156104f8576104f86128f9565b600081612a7157612a716128f9565b506000190190565b82815260406020820152600061162560408301846123d5565b600060408284031215612aa457600080fd5b82601f830112612ab357600080fd5b604051604081018181106001600160401b0382111715612ad557612ad56125d8565b8060405250806040840185811115612aec57600080fd5b845b81811015612b06578051835260209283019201612aee565b509195945050505050565b600060208284031215612b2357600080fd5b6107ff826129ca565b601f8211156107e357600081815260208120601f850160051c81016020861015612b535750805b601f850160051c820191505b81811015611f2657828155600101612b5f565b81516001600160401b03811115612b8b57612b8b6125d8565b612b9f81612b99845461288d565b84612b2c565b602080601f831160018114612bd45760008415612bbc5750858301515b600019600386901b1c1916600185901b178555611f26565b600085815260208120601f198616915b82811015612c0357888601518255948401946001909101908401612be4565b5085821015612c215787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b634e487b7160e01b600052600160045260246000fd5b600082612c6457634e487b7160e01b600052601260045260246000fd5b50049056feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa264697066735822122036f49d156164c122ed5eba55f5178d52fc1b8a3ceb06f21542e8592f30b3bfa964736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` +var EpochManagerArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"EpochManager","sourceName":"contracts/blade/validator/EpochManager.sol","abi":[{"inputs":[{"internalType":"string","name":"only","type":"string"}],"name":"Unauthorized","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"startBlock","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"endBlock","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"epochRoot","type":"bytes32"}],"name":"NewEpoch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"epochId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"totalReward","type":"uint256"}],"name":"RewardDistributed","type":"event"},{"inputs":[],"name":"ALLOWLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCKLIST_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN_CONTRACT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TRANSFER_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"READ_ADDRESSLIST_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYSTEM","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_PKCHECK_PRECOMPILE_GAS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseReward","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"components":[{"internalType":"uint256","name":"startBlock","type":"uint256"},{"internalType":"uint256","name":"endBlock","type":"uint256"},{"internalType":"bytes32","name":"epochRoot","type":"bytes32"}],"internalType":"struct Epoch","name":"epoch","type":"tuple"}],"name":"commitEpoch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"currentEpochId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"epochId","type":"uint256"},{"components":[{"internalType":"address","name":"validator","type":"address"},{"internalType":"uint256","name":"signedBlocks","type":"uint256"}],"internalType":"struct Uptime[]","name":"uptime","type":"tuple[]"}],"name":"distributeRewardFor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"epochSize","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"epochs","outputs":[{"internalType":"uint256","name":"startBlock","type":"uint256"},{"internalType":"uint256","name":"endBlock","type":"uint256"},{"internalType":"bytes32","name":"epochRoot","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newStakeManager","type":"address"},{"internalType":"address","name":"newRewardToken","type":"address"},{"internalType":"address","name":"newRewardWallet","type":"address"},{"internalType":"uint256","name":"newBaseReward","type":"uint256"},{"internalType":"uint256","name":"newEpochSize","type":"uint256"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"paidRewardPerEpoch","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"pendingRewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardToken","outputs":[{"internalType":"contract IERC20Upgradeable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardWallet","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stakeManager","outputs":[{"internalType":"contract ERC20SnapshotUpgradeable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdrawReward","outputs":[],"stateMutability":"nonpayable","type":"function"}],"bytecode":"0x608060405234801561001057600080fd5b506112af806100206000396000f3fe608060405234801561001057600080fd5b50600436106101425760003560e01c806376ad03bc116100b8578063c6b61e4c1161007c578063c6b61e4c14610270578063c885bc58146102ba578063e0563ab1146102c2578063eacdc5ff146102cb578063f7c618c1146102d4578063fb75b2c7146102e757600080fd5b806376ad03bc1461022e5780638a9cd82d14610237578063947287cf1461024a57806397e5230d14610253578063a6b63eb81461025d57600080fd5b80633b878c221161010a5780633b878c22146101de57806351351d53146101e757806355b01e4d146101f5578063572d356e146102035780635ea5df791461020c5780637542ff951461021557600080fd5b806307358b991461014757806307b3e2521461017a5780630f50287c146101a0578063284017f5146101b557806331d7a262146101be575b600080fd5b610167610155366004610f20565b60396020526000908152604090205481565b6040519081526020015b60405180910390f35b6101886004600360981b0181565b6040516001600160a01b039091168152602001610171565b6101b36101ae366004610f39565b6102fa565b005b61018861202081565b6101676101cc366004610f8d565b603a6020526000908152604090205481565b61018861101081565b6101886002600160a01b0381565b6101886004600160991b0181565b61016760365481565b61016761138881565b603254610188906201000090046001600160a01b031681565b61016760355481565b6101b3610245366004610fa8565b610545565b61016761520881565b610167620249f081565b6101b361026b366004611027565b6108a5565b61029f61027e366004610f20565b60386020526000908152604090208054600182015460029092015490919083565b60408051938452602084019290925290820152606001610171565b6101b3610b7c565b61018861203081565b61016760375481565b603354610188906001600160a01b031681565b603454610188906001600160a01b031681565b336002600160a01b031461032a5760405163973d02cb60e01b81526004016103219061107c565b60405180910390fd5b603780546000918261033b836110b6565b9190505590508083146103865760405162461bcd60e51b815260206004820152601360248201527215539156141150d5115117d15413d0d217d251606a1b6044820152606401610321565b81356020830135116103d05760405162461bcd60e51b81526020600482015260136024820152721393d7d09313d0d2d4d7d0d3d3535255151151606a1b6044820152606401610321565b6036546103e2833560208501356110cf565b6103ed9060016110e8565b6103f79190611111565b156104525760405162461bcd60e51b815260206004820152602560248201527f45504f43485f4d5553545f42455f444956495349424c455f42595f45504f43486044820152645f53495a4560d81b6064820152608401610321565b8135603860006104636001856110cf565b815260200190815260200160002060010154600161048191906110e8565b146104c45760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f53544152545f424c4f434b60681b6044820152606401610321565b600081815260386020526040902082906104f582828135815560208201356001820155604082013560028201555050565b90505081602001358260000135847f0ce8712c4dee4bd5a691f0bc1c39594671591e77395f8ebf6a3fb5f63fbea66a856040013560405161053891815260200190565b60405180910390a4505050565b336002600160a01b031461056c5760405163973d02cb60e01b81526004016103219061107c565b600083815260396020526040902054156105c85760405162461bcd60e51b815260206004820152601a60248201527f5245574152445f414c52454144595f44495354524942555445440000000000006044820152606401610321565b60006105d384610bac565b90508060000361061b5760405162461bcd60e51b8152602060048201526013602482015272115413d0d217d393d517d0d3d3535255151151606a1b6044820152606401610321565b60006036548260355461062e9190611125565b610638919061113c565b603254604051630981b24d60e41b815260048101889052919250600091620100009091046001600160a01b03169063981b24d090602401602060405180830381865afa15801561068c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b09190611150565b9050836000805b828110156108465760008888838181106106d3576106d3611169565b9050604002018036038101906106e9919061117f565b9050868160200151111561073f5760405162461bcd60e51b815260206004820152601b60248201527f5349474e45445f424c4f434b535f455843454544535f544f54414c00000000006044820152606401610321565b603254815160405163277166bf60e11b81526001600160a01b039182166004820152602481018d905260009262010000900490911690634ee2cd7e90604401602060405180830381865afa15801561079b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107bf9190611150565b905060006107cd8988611125565b60208401516107dc848b611125565b6107e69190611125565b6107f0919061113c565b83516001600160a01b03166000908152603a602052604081208054929350839290919061081e9084906110e8565b9091555061082e905081866110e8565b9450505050808061083e906110b6565b9150506106b7565b50600088815260396020526040902081905561086181610bf7565b877feaf3d57629d9b1ce95715ccd98d6f5bf48023be1d5a06e09f64ab7f6d8be01d58260405161089391815260200190565b60405180910390a25050505050505050565b603254610100900460ff16158080156108c55750603254600160ff909116105b806108df5750303b1580156108df575060325460ff166001145b6109425760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610321565b6032805460ff191660011790558015610965576032805461ff0019166101001790555b6001600160a01b0386166109c75760405162461bcd60e51b815260206004820152602360248201527f45706f63684d616e616765723a20494e56414c49445f5354414b455f4d414e4160448201526223a2a960e91b6064820152608401610321565b6001600160a01b038516610a285760405162461bcd60e51b815260206004820152602260248201527f45706f63684d616e616765723a20494e56414c49445f5245574152445f544f4b60448201526122a760f11b6064820152608401610321565b6001600160a01b038416610a7e5760405162461bcd60e51b815260206004820152601a60248201527f45706f63684d616e616765723a205a45524f5f414444524553530000000000006044820152606401610321565b60008211610ace5760405162461bcd60e51b815260206004820181905260248201527f45706f63684d616e616765723a20494e56414c49445f45504f43485f53495a456044820152606401610321565b603280546001600160a01b03808916620100000262010000600160b01b031990921691909117909155603380548783166001600160a01b03199182161790915560348054928716929091169190911790556035839055603682905560016037558015610b74576032805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b336000818152603a6020526040812080549190556033549091610ba9916001600160a01b03169083610c15565b50565b6000818152603860205260408120600101548015610bed57600083815260386020526040902054610bdd90826110cf565b610be89060016110e8565b610bf0565b60005b9392505050565b603454603354610ba9916001600160a01b0391821691163084610c7d565b6040516001600160a01b038316602482015260448101829052610c7890849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610cbb565b505050565b6040516001600160a01b0380851660248301528316604482015260648101829052610cb59085906323b872dd60e01b90608401610c41565b50505050565b6000610d10826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610d909092919063ffffffff16565b9050805160001480610d31575080806020019051810190610d3191906111e4565b610c785760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610321565b6060610d9f8484600085610da7565b949350505050565b606082471015610e085760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610321565b600080866001600160a01b03168587604051610e24919061122a565b60006040518083038185875af1925050503d8060008114610e61576040519150601f19603f3d011682016040523d82523d6000602084013e610e66565b606091505b5091509150610e7787838387610e82565b979650505050505050565b60608315610ef1578251600003610eea576001600160a01b0385163b610eea5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610321565b5081610d9f565b610d9f8383815115610f065781518083602001fd5b8060405162461bcd60e51b81526004016103219190611246565b600060208284031215610f3257600080fd5b5035919050565b6000808284036080811215610f4d57600080fd5b833592506060601f1982011215610f6357600080fd5b506020830190509250929050565b80356001600160a01b0381168114610f8857600080fd5b919050565b600060208284031215610f9f57600080fd5b610bf082610f71565b600080600060408486031215610fbd57600080fd5b83359250602084013567ffffffffffffffff80821115610fdc57600080fd5b818601915086601f830112610ff057600080fd5b813581811115610fff57600080fd5b8760208260061b850101111561101457600080fd5b6020830194508093505050509250925092565b600080600080600060a0868803121561103f57600080fd5b61104886610f71565b945061105660208701610f71565b935061106460408701610f71565b94979396509394606081013594506080013592915050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b6000600182016110c8576110c86110a0565b5060010190565b818103818111156110e2576110e26110a0565b92915050565b808201808211156110e2576110e26110a0565b634e487b7160e01b600052601260045260246000fd5b600082611120576111206110fb565b500690565b80820281158282048414176110e2576110e26110a0565b60008261114b5761114b6110fb565b500490565b60006020828403121561116257600080fd5b5051919050565b634e487b7160e01b600052603260045260246000fd5b60006040828403121561119157600080fd5b6040516040810181811067ffffffffffffffff821117156111c257634e487b7160e01b600052604160045260246000fd5b6040526111ce83610f71565b8152602083013560208201528091505092915050565b6000602082840312156111f657600080fd5b81518015158114610bf057600080fd5b60005b83811015611221578181015183820152602001611209565b50506000910152565b6000825161123c818460208701611206565b9190910192915050565b6020815260008251806020840152611265816040850160208701611206565b601f01601f1916919091016040019291505056fea264697066735822122025299ac478733bb0b0bf2ed3e64e335b5f38efaa3eba0d9dbc1c83fce65116d364736f6c63430008130033","deployedBytecode":"0x608060405234801561001057600080fd5b50600436106101425760003560e01c806376ad03bc116100b8578063c6b61e4c1161007c578063c6b61e4c14610270578063c885bc58146102ba578063e0563ab1146102c2578063eacdc5ff146102cb578063f7c618c1146102d4578063fb75b2c7146102e757600080fd5b806376ad03bc1461022e5780638a9cd82d14610237578063947287cf1461024a57806397e5230d14610253578063a6b63eb81461025d57600080fd5b80633b878c221161010a5780633b878c22146101de57806351351d53146101e757806355b01e4d146101f5578063572d356e146102035780635ea5df791461020c5780637542ff951461021557600080fd5b806307358b991461014757806307b3e2521461017a5780630f50287c146101a0578063284017f5146101b557806331d7a262146101be575b600080fd5b610167610155366004610f20565b60396020526000908152604090205481565b6040519081526020015b60405180910390f35b6101886004600360981b0181565b6040516001600160a01b039091168152602001610171565b6101b36101ae366004610f39565b6102fa565b005b61018861202081565b6101676101cc366004610f8d565b603a6020526000908152604090205481565b61018861101081565b6101886002600160a01b0381565b6101886004600160991b0181565b61016760365481565b61016761138881565b603254610188906201000090046001600160a01b031681565b61016760355481565b6101b3610245366004610fa8565b610545565b61016761520881565b610167620249f081565b6101b361026b366004611027565b6108a5565b61029f61027e366004610f20565b60386020526000908152604090208054600182015460029092015490919083565b60408051938452602084019290925290820152606001610171565b6101b3610b7c565b61018861203081565b61016760375481565b603354610188906001600160a01b031681565b603454610188906001600160a01b031681565b336002600160a01b031461032a5760405163973d02cb60e01b81526004016103219061107c565b60405180910390fd5b603780546000918261033b836110b6565b9190505590508083146103865760405162461bcd60e51b815260206004820152601360248201527215539156141150d5115117d15413d0d217d251606a1b6044820152606401610321565b81356020830135116103d05760405162461bcd60e51b81526020600482015260136024820152721393d7d09313d0d2d4d7d0d3d3535255151151606a1b6044820152606401610321565b6036546103e2833560208501356110cf565b6103ed9060016110e8565b6103f79190611111565b156104525760405162461bcd60e51b815260206004820152602560248201527f45504f43485f4d5553545f42455f444956495349424c455f42595f45504f43486044820152645f53495a4560d81b6064820152608401610321565b8135603860006104636001856110cf565b815260200190815260200160002060010154600161048191906110e8565b146104c45760405162461bcd60e51b8152602060048201526013602482015272494e56414c49445f53544152545f424c4f434b60681b6044820152606401610321565b600081815260386020526040902082906104f582828135815560208201356001820155604082013560028201555050565b90505081602001358260000135847f0ce8712c4dee4bd5a691f0bc1c39594671591e77395f8ebf6a3fb5f63fbea66a856040013560405161053891815260200190565b60405180910390a4505050565b336002600160a01b031461056c5760405163973d02cb60e01b81526004016103219061107c565b600083815260396020526040902054156105c85760405162461bcd60e51b815260206004820152601a60248201527f5245574152445f414c52454144595f44495354524942555445440000000000006044820152606401610321565b60006105d384610bac565b90508060000361061b5760405162461bcd60e51b8152602060048201526013602482015272115413d0d217d393d517d0d3d3535255151151606a1b6044820152606401610321565b60006036548260355461062e9190611125565b610638919061113c565b603254604051630981b24d60e41b815260048101889052919250600091620100009091046001600160a01b03169063981b24d090602401602060405180830381865afa15801561068c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b09190611150565b9050836000805b828110156108465760008888838181106106d3576106d3611169565b9050604002018036038101906106e9919061117f565b9050868160200151111561073f5760405162461bcd60e51b815260206004820152601b60248201527f5349474e45445f424c4f434b535f455843454544535f544f54414c00000000006044820152606401610321565b603254815160405163277166bf60e11b81526001600160a01b039182166004820152602481018d905260009262010000900490911690634ee2cd7e90604401602060405180830381865afa15801561079b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107bf9190611150565b905060006107cd8988611125565b60208401516107dc848b611125565b6107e69190611125565b6107f0919061113c565b83516001600160a01b03166000908152603a602052604081208054929350839290919061081e9084906110e8565b9091555061082e905081866110e8565b9450505050808061083e906110b6565b9150506106b7565b50600088815260396020526040902081905561086181610bf7565b877feaf3d57629d9b1ce95715ccd98d6f5bf48023be1d5a06e09f64ab7f6d8be01d58260405161089391815260200190565b60405180910390a25050505050505050565b603254610100900460ff16158080156108c55750603254600160ff909116105b806108df5750303b1580156108df575060325460ff166001145b6109425760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610321565b6032805460ff191660011790558015610965576032805461ff0019166101001790555b6001600160a01b0386166109c75760405162461bcd60e51b815260206004820152602360248201527f45706f63684d616e616765723a20494e56414c49445f5354414b455f4d414e4160448201526223a2a960e91b6064820152608401610321565b6001600160a01b038516610a285760405162461bcd60e51b815260206004820152602260248201527f45706f63684d616e616765723a20494e56414c49445f5245574152445f544f4b60448201526122a760f11b6064820152608401610321565b6001600160a01b038416610a7e5760405162461bcd60e51b815260206004820152601a60248201527f45706f63684d616e616765723a205a45524f5f414444524553530000000000006044820152606401610321565b60008211610ace5760405162461bcd60e51b815260206004820181905260248201527f45706f63684d616e616765723a20494e56414c49445f45504f43485f53495a456044820152606401610321565b603280546001600160a01b03808916620100000262010000600160b01b031990921691909117909155603380548783166001600160a01b03199182161790915560348054928716929091169190911790556035839055603682905560016037558015610b74576032805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050505050565b336000818152603a6020526040812080549190556033549091610ba9916001600160a01b03169083610c15565b50565b6000818152603860205260408120600101548015610bed57600083815260386020526040902054610bdd90826110cf565b610be89060016110e8565b610bf0565b60005b9392505050565b603454603354610ba9916001600160a01b0391821691163084610c7d565b6040516001600160a01b038316602482015260448101829052610c7890849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610cbb565b505050565b6040516001600160a01b0380851660248301528316604482015260648101829052610cb59085906323b872dd60e01b90608401610c41565b50505050565b6000610d10826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610d909092919063ffffffff16565b9050805160001480610d31575080806020019051810190610d3191906111e4565b610c785760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610321565b6060610d9f8484600085610da7565b949350505050565b606082471015610e085760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610321565b600080866001600160a01b03168587604051610e24919061122a565b60006040518083038185875af1925050503d8060008114610e61576040519150601f19603f3d011682016040523d82523d6000602084013e610e66565b606091505b5091509150610e7787838387610e82565b979650505050505050565b60608315610ef1578251600003610eea576001600160a01b0385163b610eea5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610321565b5081610d9f565b610d9f8383815115610f065781518083602001fd5b8060405162461bcd60e51b81526004016103219190611246565b600060208284031215610f3257600080fd5b5035919050565b6000808284036080811215610f4d57600080fd5b833592506060601f1982011215610f6357600080fd5b506020830190509250929050565b80356001600160a01b0381168114610f8857600080fd5b919050565b600060208284031215610f9f57600080fd5b610bf082610f71565b600080600060408486031215610fbd57600080fd5b83359250602084013567ffffffffffffffff80821115610fdc57600080fd5b818601915086601f830112610ff057600080fd5b813581811115610fff57600080fd5b8760208260061b850101111561101457600080fd5b6020830194508093505050509250925092565b600080600080600060a0868803121561103f57600080fd5b61104886610f71565b945061105660208701610f71565b935061106460408701610f71565b94979396509394606081013594506080013592915050565b6020808252600a908201526914d654d5115350d0531360b21b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b6000600182016110c8576110c86110a0565b5060010190565b818103818111156110e2576110e26110a0565b92915050565b808201808211156110e2576110e26110a0565b634e487b7160e01b600052601260045260246000fd5b600082611120576111206110fb565b500690565b80820281158282048414176110e2576110e26110a0565b60008261114b5761114b6110fb565b500490565b60006020828403121561116257600080fd5b5051919050565b634e487b7160e01b600052603260045260246000fd5b60006040828403121561119157600080fd5b6040516040810181811067ffffffffffffffff821117156111c257634e487b7160e01b600052604160045260246000fd5b6040526111ce83610f71565b8152602083013560208201528091505092915050565b6000602082840312156111f657600080fd5b81518015158114610bf057600080fd5b60005b83811015611221578181015183820152602001611209565b50506000910152565b6000825161123c818460208701611206565b9190910192915050565b6020815260008251806020840152611265816040850160208701611206565b601f01601f1916919091016040019291505056fea264697066735822122025299ac478733bb0b0bf2ed3e64e335b5f38efaa3eba0d9dbc1c83fce65116d364736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` var GenesisProxyArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"GenesisProxy","sourceName":"contracts/lib/GenesisProxy.sol","abi":[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"beacon","type":"address"}],"name":"BeaconUpgraded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Upgraded","type":"event"},{"stateMutability":"payable","type":"fallback"},{"inputs":[{"internalType":"address","name":"initiator","type":"address"}],"name":"protectSetUpProxy","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"logic","type":"address"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"setUpProxy","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}],"bytecode":"0x60806040523480156200001157600080fd5b506000806040518060200160405280600081525082816200003b828260006200004e60201b60201c565b506200004990508262000080565b600080fd5b6200005983620000f2565b600082511180620000675750805b156200007b5762000079838362000134565b505b505050565b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f620000c260008051602062000446833981519152546001600160a01b031690565b604080516001600160a01b03928316815291841660208301520160405180910390a1620000ef8162000163565b50565b620000fd8162000201565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b60606200015c8383604051806060016040528060278152602001620004666027913962000298565b9392505050565b6001600160a01b038116620001ce5760405162461bcd60e51b815260206004820152602660248201527f455243313936373a206e65772061646d696e20697320746865207a65726f206160448201526564647265737360d01b60648201526084015b60405180910390fd5b80600080516020620004468339815191525b80546001600160a01b0319166001600160a01b039290921691909117905550565b6001600160a01b0381163b620002705760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b6064820152608401620001c5565b807f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc620001e0565b6060600080856001600160a01b031685604051620002b79190620003f2565b600060405180830381855af49150503d8060008114620002f4576040519150601f19603f3d011682016040523d82523d6000602084013e620002f9565b606091505b5090925090506200030d8683838762000317565b9695505050505050565b606083156200038b57825160000362000383576001600160a01b0385163b620003835760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401620001c5565b508162000397565b6200039783836200039f565b949350505050565b815115620003b05781518083602001fd5b8060405162461bcd60e51b8152600401620001c5919062000410565b60005b83811015620003e9578181015183820152602001620003cf565b50506000910152565b6000825162000406818460208701620003cc565b9190910192915050565b602081526000825180602084015262000431816040850160208701620003cc565b601f01601f1916919091016040019291505056feb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564","deployedBytecode":"0x60806040526004361061002d5760003560e01c806317cf3e3414610044578063da2655db146100645761003c565b3661003c5761003a610084565b005b61003a610084565b34801561005057600080fd5b5061003a61005f3660046108d2565b6101d6565b34801561007057600080fd5b5061003a61007f366004610934565b6102a5565b61008c610300565b6001600160a01b031633036101cc5760606001600160e01b0319600035166364d3180d60e11b81016100c7576100c0610333565b91506101c4565b63587086bd60e11b6001600160e01b03198216016100e7576100c061038a565b63070d7c6960e41b6001600160e01b0319821601610107576100c06103d0565b621eb96f60e61b6001600160e01b0319821601610126576100c0610401565b63a39f25e560e01b6001600160e01b0319821601610146576100c0610441565b60405162461bcd60e51b815260206004820152604260248201527f5472616e73706172656e745570677261646561626c6550726f78793a2061646d60448201527f696e2063616e6e6f742066616c6c6261636b20746f2070726f78792074617267606482015261195d60f21b608482015260a4015b60405180910390fd5b815160208301f35b6101d4610455565b565b600080516020610a3f833981519152546000196001600160a01b038216016102315760405162461bcd60e51b815260206004820152600e60248201526d0416c7265616479207365742d75760941b60448201526064016101bb565b336001600160a01b038216146102785760405162461bcd60e51b815260206004820152600c60248201526b155b985d5d1a1bdc9a5e995960a21b60448201526064016101bb565b61028183610465565b61028d848360006104bc565b6001600080516020610a3f8339815191525550505050565b600080516020610a3f83398151915280549082905580156102fc5760405162461bcd60e51b8152602060048201526011602482015270105b1c9958591e481c1c9bdd1958dd1959607a1b60448201526064016101bb565b5050565b60007fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b546001600160a01b0316919050565b606061033d6104e8565b600061034c3660048184610951565b8101906103599190610934565b9050610376816040518060200160405280600081525060006104bc565b505060408051602081019091526000815290565b606060008061039c3660048184610951565b8101906103a9919061097b565b915091506103b9828260016104bc565b604051806020016040528060008152509250505090565b60606103da6104e8565b60006103e93660048184610951565b8101906103f69190610934565b905061037681610465565b606061040b6104e8565b6000610415610300565b604080516001600160a01b03831660208201529192500160405160208183030381529060405291505090565b606061044b6104e8565b60006104156104f3565b6101d46104606104f3565b610502565b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f61048e610300565b604080516001600160a01b03928316815291841660208301520160405180910390a16104b981610526565b50565b6104c5836105cf565b6000825111806104d25750805b156104e3576104e1838361060f565b505b505050565b34156101d457600080fd5b60006104fd61063b565b905090565b3660008037600080366000845af43d6000803e808015610521573d6000f35b3d6000fd5b6001600160a01b03811661058b5760405162461bcd60e51b815260206004820152602660248201527f455243313936373a206e65772061646d696e20697320746865207a65726f206160448201526564647265737360d01b60648201526084016101bb565b807fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b80546001600160a01b0319166001600160a01b039290921691909117905550565b6105d881610663565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b60606106348383604051806060016040528060278152602001610a5f602791396106f7565b9392505050565b60007f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc610324565b6001600160a01b0381163b6106d05760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b60648201526084016101bb565b807f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc6105ae565b6060600080856001600160a01b03168560405161071491906109ef565b600060405180830381855af49150503d806000811461074f576040519150601f19603f3d011682016040523d82523d6000602084013e610754565b606091505b50915091506107658683838761076f565b9695505050505050565b606083156107de5782516000036107d7576001600160a01b0385163b6107d75760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016101bb565b50816107e8565b6107e883836107f0565b949350505050565b8151156108005781518083602001fd5b8060405162461bcd60e51b81526004016101bb9190610a0b565b6001600160a01b03811681146104b957600080fd5b634e487b7160e01b600052604160045260246000fd5b600082601f83011261085657600080fd5b813567ffffffffffffffff808211156108715761087161082f565b604051601f8301601f19908116603f011681019082821181831017156108995761089961082f565b816040528381528660208588010111156108b257600080fd5b836020870160208301376000602085830101528094505050505092915050565b6000806000606084860312156108e757600080fd5b83356108f28161081a565b925060208401356109028161081a565b9150604084013567ffffffffffffffff81111561091e57600080fd5b61092a86828701610845565b9150509250925092565b60006020828403121561094657600080fd5b81356106348161081a565b6000808585111561096157600080fd5b8386111561096e57600080fd5b5050820193919092039150565b6000806040838503121561098e57600080fd5b82356109998161081a565b9150602083013567ffffffffffffffff8111156109b557600080fd5b6109c185828601610845565b9150509250929050565b60005b838110156109e65781810151838201526020016109ce565b50506000910152565b60008251610a018184602087016109cb565b9190910192915050565b6020815260008251806020840152610a2a8160408501602087016109cb565b601f01601f1916919091016040019291505056fe16561015e0650c143c10fb1907c52a56b654e2f0922ca3245bde5beff81a333d416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a2646970667358221220abb148ad739bda14bfde881802dab93d2ab651041781eed877949635c7179ba364736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` var TransparentUpgradeableProxyArtifact string = `{"_format":"hh-sol-artifact-1","contractName":"TransparentUpgradeableProxy","sourceName":"@openzeppelin/contracts/proxy/transparent/TransparentUpgradeableProxy.sol","abi":[{"inputs":[{"internalType":"address","name":"_logic","type":"address"},{"internalType":"address","name":"admin_","type":"address"},{"internalType":"bytes","name":"_data","type":"bytes"}],"stateMutability":"payable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"beacon","type":"address"}],"name":"BeaconUpgraded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Upgraded","type":"event"},{"stateMutability":"payable","type":"fallback"},{"stateMutability":"payable","type":"receive"}],"bytecode":"0x608060405260405162000e3a38038062000e3a833981016040819052620000269162000424565b828162000036828260006200004d565b50620000449050826200007f565b50505062000557565b6200005883620000f1565b600082511180620000665750805b156200007a5762000078838362000133565b505b505050565b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f620000c160008051602062000df3833981519152546001600160a01b031690565b604080516001600160a01b03928316815291841660208301520160405180910390a1620000ee8162000162565b50565b620000fc8162000200565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b60606200015b838360405180606001604052806027815260200162000e136027913962000297565b9392505050565b6001600160a01b038116620001cd5760405162461bcd60e51b815260206004820152602660248201527f455243313936373a206e65772061646d696e20697320746865207a65726f206160448201526564647265737360d01b60648201526084015b60405180910390fd5b8060008051602062000df38339815191525b80546001600160a01b0319166001600160a01b039290921691909117905550565b6001600160a01b0381163b6200026f5760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b6064820152608401620001c4565b807f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc620001df565b6060600080856001600160a01b031685604051620002b6919062000504565b600060405180830381855af49150503d8060008114620002f3576040519150601f19603f3d011682016040523d82523d6000602084013e620002f8565b606091505b5090925090506200030c8683838762000316565b9695505050505050565b606083156200038a57825160000362000382576001600160a01b0385163b620003825760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401620001c4565b508162000396565b6200039683836200039e565b949350505050565b815115620003af5781518083602001fd5b8060405162461bcd60e51b8152600401620001c4919062000522565b80516001600160a01b0381168114620003e357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b60005b838110156200041b57818101518382015260200162000401565b50506000910152565b6000806000606084860312156200043a57600080fd5b6200044584620003cb565b92506200045560208501620003cb565b60408501519092506001600160401b03808211156200047357600080fd5b818601915086601f8301126200048857600080fd5b8151818111156200049d576200049d620003e8565b604051601f8201601f19908116603f01168101908382118183101715620004c857620004c8620003e8565b81604052828152896020848701011115620004e257600080fd5b620004f5836020830160208801620003fe565b80955050505050509250925092565b6000825162000518818460208701620003fe565b9190910192915050565b602081526000825180602084015262000543816040850160208701620003fe565b601f01601f19169190910160400192915050565b61088c80620005676000396000f3fe60806040523661001357610011610017565b005b6100115b61001f610169565b6001600160a01b0316330361015f5760606001600160e01b0319600035166364d3180d60e11b810161005a5761005361019c565b9150610157565b63587086bd60e11b6001600160e01b031982160161007a576100536101f3565b63070d7c6960e41b6001600160e01b031982160161009a57610053610239565b621eb96f60e61b6001600160e01b03198216016100b95761005361026a565b63a39f25e560e01b6001600160e01b03198216016100d9576100536102aa565b60405162461bcd60e51b815260206004820152604260248201527f5472616e73706172656e745570677261646561626c6550726f78793a2061646d60448201527f696e2063616e6e6f742066616c6c6261636b20746f2070726f78792074617267606482015261195d60f21b608482015260a4015b60405180910390fd5b815160208301f35b6101676102be565b565b60007fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b546001600160a01b0316919050565b60606101a66102ce565b60006101b53660048184610683565b8101906101c291906106c9565b90506101df816040518060200160405280600081525060006102d9565b505060408051602081019091526000815290565b60606000806102053660048184610683565b81019061021291906106fa565b91509150610222828260016102d9565b604051806020016040528060008152509250505090565b60606102436102ce565b60006102523660048184610683565b81019061025f91906106c9565b90506101df81610305565b60606102746102ce565b600061027e610169565b604080516001600160a01b03831660208201529192500160405160208183030381529060405291505090565b60606102b46102ce565b600061027e61035c565b6101676102c961035c565b61036b565b341561016757600080fd5b6102e28361038f565b6000825111806102ef5750805b15610300576102fe83836103cf565b505b505050565b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f61032e610169565b604080516001600160a01b03928316815291841660208301520160405180910390a1610359816103fb565b50565b60006103666104a4565b905090565b3660008037600080366000845af43d6000803e80801561038a573d6000f35b3d6000fd5b610398816104cc565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b60606103f4838360405180606001604052806027815260200161083060279139610560565b9392505050565b6001600160a01b0381166104605760405162461bcd60e51b815260206004820152602660248201527f455243313936373a206e65772061646d696e20697320746865207a65726f206160448201526564647265737360d01b606482015260840161014e565b807fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b80546001600160a01b0319166001600160a01b039290921691909117905550565b60007f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc61018d565b6001600160a01b0381163b6105395760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b606482015260840161014e565b807f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc610483565b6060600080856001600160a01b03168560405161057d91906107e0565b600060405180830381855af49150503d80600081146105b8576040519150601f19603f3d011682016040523d82523d6000602084013e6105bd565b606091505b50915091506105ce868383876105d8565b9695505050505050565b60608315610647578251600003610640576001600160a01b0385163b6106405760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161014e565b5081610651565b6106518383610659565b949350505050565b8151156106695781518083602001fd5b8060405162461bcd60e51b815260040161014e91906107fc565b6000808585111561069357600080fd5b838611156106a057600080fd5b5050820193919092039150565b80356001600160a01b03811681146106c457600080fd5b919050565b6000602082840312156106db57600080fd5b6103f4826106ad565b634e487b7160e01b600052604160045260246000fd5b6000806040838503121561070d57600080fd5b610716836106ad565b9150602083013567ffffffffffffffff8082111561073357600080fd5b818501915085601f83011261074757600080fd5b813581811115610759576107596106e4565b604051601f8201601f19908116603f01168101908382118183101715610781576107816106e4565b8160405282815288602084870101111561079a57600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b60005b838110156107d75781810151838201526020016107bf565b50506000910152565b600082516107f28184602087016107bc565b9190910192915050565b602081526000825180602084015261081b8160408501602087016107bc565b601f01601f1916919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a2646970667358221220e47bdad79754770e5755a6f8224b03af73f674035cf42b93fa6fc0731c0dbb6864736f6c63430008130033b53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564","deployedBytecode":"0x60806040523661001357610011610017565b005b6100115b61001f610169565b6001600160a01b0316330361015f5760606001600160e01b0319600035166364d3180d60e11b810161005a5761005361019c565b9150610157565b63587086bd60e11b6001600160e01b031982160161007a576100536101f3565b63070d7c6960e41b6001600160e01b031982160161009a57610053610239565b621eb96f60e61b6001600160e01b03198216016100b95761005361026a565b63a39f25e560e01b6001600160e01b03198216016100d9576100536102aa565b60405162461bcd60e51b815260206004820152604260248201527f5472616e73706172656e745570677261646561626c6550726f78793a2061646d60448201527f696e2063616e6e6f742066616c6c6261636b20746f2070726f78792074617267606482015261195d60f21b608482015260a4015b60405180910390fd5b815160208301f35b6101676102be565b565b60007fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b546001600160a01b0316919050565b60606101a66102ce565b60006101b53660048184610683565b8101906101c291906106c9565b90506101df816040518060200160405280600081525060006102d9565b505060408051602081019091526000815290565b60606000806102053660048184610683565b81019061021291906106fa565b91509150610222828260016102d9565b604051806020016040528060008152509250505090565b60606102436102ce565b60006102523660048184610683565b81019061025f91906106c9565b90506101df81610305565b60606102746102ce565b600061027e610169565b604080516001600160a01b03831660208201529192500160405160208183030381529060405291505090565b60606102b46102ce565b600061027e61035c565b6101676102c961035c565b61036b565b341561016757600080fd5b6102e28361038f565b6000825111806102ef5750805b15610300576102fe83836103cf565b505b505050565b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f61032e610169565b604080516001600160a01b03928316815291841660208301520160405180910390a1610359816103fb565b50565b60006103666104a4565b905090565b3660008037600080366000845af43d6000803e80801561038a573d6000f35b3d6000fd5b610398816104cc565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b60606103f4838360405180606001604052806027815260200161083060279139610560565b9392505050565b6001600160a01b0381166104605760405162461bcd60e51b815260206004820152602660248201527f455243313936373a206e65772061646d696e20697320746865207a65726f206160448201526564647265737360d01b606482015260840161014e565b807fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b80546001600160a01b0319166001600160a01b039290921691909117905550565b60007f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc61018d565b6001600160a01b0381163b6105395760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b606482015260840161014e565b807f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc610483565b6060600080856001600160a01b03168560405161057d91906107e0565b600060405180830381855af49150503d80600081146105b8576040519150601f19603f3d011682016040523d82523d6000602084013e6105bd565b606091505b50915091506105ce868383876105d8565b9695505050505050565b60608315610647578251600003610640576001600160a01b0385163b6106405760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161014e565b5081610651565b6106518383610659565b949350505050565b8151156106695781518083602001fd5b8060405162461bcd60e51b815260040161014e91906107fc565b6000808585111561069357600080fd5b838611156106a057600080fd5b5050820193919092039150565b80356001600160a01b03811681146106c457600080fd5b919050565b6000602082840312156106db57600080fd5b6103f4826106ad565b634e487b7160e01b600052604160045260246000fd5b6000806040838503121561070d57600080fd5b610716836106ad565b9150602083013567ffffffffffffffff8082111561073357600080fd5b818501915085601f83011261074757600080fd5b813581811115610759576107596106e4565b604051601f8201601f19908116603f01168101908382118183101715610781576107816106e4565b8160405282815288602084870101111561079a57600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b60005b838110156107d75781810151838201526020016107bf565b50506000910152565b600082516107f28184602087016107bc565b9190910192915050565b602081526000825180602084015261081b8160408501602087016107bc565b601f01601f1916919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a2646970667358221220e47bdad79754770e5755a6f8224b03af73f674035cf42b93fa6fc0731c0dbb6864736f6c63430008130033","linkReferences":{},"deployedLinkReferences":{}}` diff --git a/consensus/polybft/contractsapi/helper.go b/consensus/polybft/contractsapi/helper.go index d71b585972..42f4b93ab5 100644 --- a/consensus/polybft/contractsapi/helper.go +++ b/consensus/polybft/contractsapi/helper.go @@ -1,7 +1,6 @@ package contractsapi import ( - "github.com/0xPolygon/polygon-edge/types" "github.com/umbracle/ethgo" "github.com/umbracle/ethgo/abi" ) @@ -39,17 +38,6 @@ func (sse *StateSyncedEvent) EncodeAbi() ([]byte, error) { } var ( - _ StateTransactionInput = &CommitEpochValidatorSetFn{} - _ StateTransactionInput = &DistributeRewardForRewardPoolFn{} + _ StateTransactionInput = &CommitEpochEpochManagerFn{} + _ StateTransactionInput = &DistributeRewardForEpochManagerFn{} ) - -// IsStake indicates if transfer event (from ERC20 implementation) mints tokens to a non zero address -func (t *TransferEvent) IsStake() bool { - return t.To != types.ZeroAddress && t.From == types.ZeroAddress -} - -// IsUnstake indicates if transfer event (from ERC20 implementation) burns tokens from a non zero address -// meaning, it transfers them to zero address -func (t *TransferEvent) IsUnstake() bool { - return t.To == types.ZeroAddress && t.From != types.ZeroAddress -} diff --git a/consensus/polybft/contractsapi/init.go b/consensus/polybft/contractsapi/init.go index c857474f8f..7bcc86f6d7 100644 --- a/consensus/polybft/contractsapi/init.go +++ b/consensus/polybft/contractsapi/init.go @@ -13,7 +13,7 @@ const ( ) var ( - // core-contracts smart contracts + // Blade smart contracts CheckpointManager *artifact.Artifact ExitHelper *artifact.Artifact StateSender *artifact.Artifact @@ -29,7 +29,6 @@ var ( Merkle *artifact.Artifact ChildValidatorSet *artifact.Artifact NativeERC20 *artifact.Artifact - NativeERC20Mintable *artifact.Artifact StateReceiver *artifact.Artifact ChildERC20 *artifact.Artifact ChildERC20Predicate *artifact.Artifact @@ -49,11 +48,9 @@ var ( L2StateSender *artifact.Artifact CustomSupernetManager *artifact.Artifact StakeManager *artifact.Artifact - RewardPool *artifact.Artifact - ValidatorSet *artifact.Artifact + EpochManager *artifact.Artifact RootERC721 *artifact.Artifact RootERC1155 *artifact.Artifact - EIP1559Burn *artifact.Artifact GenesisProxy *artifact.Artifact TransparentUpgradeableProxy *artifact.Artifact @@ -224,11 +221,6 @@ func init() { log.Fatal(err) } - NativeERC20Mintable, err = artifact.DecodeArtifact([]byte(NativeERC20MintableArtifact)) - if err != nil { - log.Fatal(err) - } - RootERC20, err = artifact.DecodeArtifact([]byte(MockERC20Artifact)) if err != nil { log.Fatal(err) @@ -259,27 +251,12 @@ func init() { log.Fatal(err) } - CustomSupernetManager, err = artifact.DecodeArtifact([]byte(CustomSupernetManagerArtifact)) - if err != nil { - log.Fatal(err) - } - StakeManager, err = artifact.DecodeArtifact([]byte(StakeManagerArtifact)) if err != nil { log.Fatal(err) } - RewardPool, err = artifact.DecodeArtifact([]byte(RewardPoolArtifact)) - if err != nil { - log.Fatal(err) - } - - ValidatorSet, err = artifact.DecodeArtifact([]byte(ValidatorSetArtifact)) - if err != nil { - log.Fatal(err) - } - - EIP1559Burn, err = artifact.DecodeArtifact([]byte(EIP1559BurnArtifact)) + EpochManager, err = artifact.DecodeArtifact([]byte(EpochManagerArtifact)) if err != nil { log.Fatal(err) } diff --git a/consensus/polybft/fsm.go b/consensus/polybft/fsm.go index 59360cc997..7253fc98b1 100644 --- a/consensus/polybft/fsm.go +++ b/consensus/polybft/fsm.go @@ -77,12 +77,12 @@ type fsm struct { // commitEpochInput holds info about a single epoch // It is populated only for epoch-ending blocks. - commitEpochInput *contractsapi.CommitEpochValidatorSetFn + commitEpochInput *contractsapi.CommitEpochEpochManagerFn // distributeRewardsInput holds info about validators work in a single epoch // mainly, how many blocks they signed during given epoch // It is populated only for epoch-ending blocks. - distributeRewardsInput *contractsapi.DistributeRewardForRewardPoolFn + distributeRewardsInput *contractsapi.DistributeRewardForEpochManagerFn // isEndOfEpoch indicates if epoch reached its end isEndOfEpoch bool @@ -257,7 +257,7 @@ func (f *fsm) createCommitEpochTx() (*types.Transaction, error) { return nil, err } - return createStateTransactionWithData(f.Height(), contracts.ValidatorSetContract, input), nil + return createStateTransactionWithData(f.Height(), contracts.EpochManagerContract, input), nil } // createDistributeRewardsTx create a StateTransaction, which invokes RewardPool smart contract @@ -268,7 +268,7 @@ func (f *fsm) createDistributeRewardsTx() (*types.Transaction, error) { return nil, err } - return createStateTransactionWithData(f.Height(), contracts.RewardPoolContract, input), nil + return createStateTransactionWithData(f.Height(), contracts.EpochManagerContract, input), nil } // ValidateCommit is used to validate that a given commit is valid @@ -448,7 +448,7 @@ func (f *fsm) VerifyStateTransactions(transactions []*types.Transaction) error { if err = verifyBridgeCommitmentTx(f.Height(), tx.Hash, stateTxData, f.validators); err != nil { return err } - case *contractsapi.CommitEpochValidatorSetFn: + case *contractsapi.CommitEpochEpochManagerFn: if commitEpochTxExists { // if we already validated commit epoch tx, // that means someone added more than one commit epoch tx to block, @@ -461,7 +461,7 @@ func (f *fsm) VerifyStateTransactions(transactions []*types.Transaction) error { if err := f.verifyCommitEpochTx(tx); err != nil { return fmt.Errorf("error while verifying commit epoch transaction. error: %w", err) } - case *contractsapi.DistributeRewardForRewardPoolFn: + case *contractsapi.DistributeRewardForEpochManagerFn: if distributeRewardsTxExists { // if we already validated distribute rewards tx, // that means someone added more than one distribute rewards tx to block, diff --git a/consensus/polybft/fsm_test.go b/consensus/polybft/fsm_test.go index 105e366e9c..b6974fe327 100644 --- a/consensus/polybft/fsm_test.go +++ b/consensus/polybft/fsm_test.go @@ -100,7 +100,7 @@ func TestFSM_verifyCommitEpochTx(t *testing.T) { // submit tampered commit epoch transaction to the epoch ending block alteredCommitEpochTx := &types.Transaction{ - To: &contracts.ValidatorSetContract, + To: &contracts.EpochManagerContract, Input: []byte{}, Gas: 0, Type: types.StateTx, @@ -485,7 +485,7 @@ func TestFSM_VerifyStateTransactions_EndOfEpochWrongCommitEpochTx(t *testing.T) commitEpochInput, err := createTestCommitEpochInput(t, 1, 5).EncodeAbi() require.NoError(t, err) - commitEpochTx := createStateTransactionWithData(1, contracts.ValidatorSetContract, commitEpochInput) + commitEpochTx := createStateTransactionWithData(1, contracts.EpochManagerContract, commitEpochInput) assert.ErrorContains(t, fsm.VerifyStateTransactions([]*types.Transaction{commitEpochTx}), "invalid commit epoch transaction") } @@ -832,8 +832,8 @@ func TestFSM_Validate_EpochEndingBlock_MismatchInDeltas(t *testing.T) { stateBlock.Block.Header.ParentHash = parent.Hash stateBlock.Block.Header.Timestamp = uint64(time.Now().UTC().Unix()) stateBlock.Block.Transactions = []*types.Transaction{ - createStateTransactionWithData(1, contracts.ValidatorSetContract, commitEpochTxInput), - createStateTransactionWithData(1, contracts.RewardPoolContract, distributeRewardsTxInput), + createStateTransactionWithData(1, contracts.EpochManagerContract, commitEpochTxInput), + createStateTransactionWithData(1, contracts.EpochManagerContract, distributeRewardsTxInput), } proposal := stateBlock.Block.MarshalRLP() @@ -1308,11 +1308,11 @@ func TestFSM_DecodeCommitEpochStateTx(t *testing.T) { require.NoError(t, err) require.NotNil(t, input) - tx := createStateTransactionWithData(1, contracts.ValidatorSetContract, input) + tx := createStateTransactionWithData(1, contracts.EpochManagerContract, input) decodedInputData, err := decodeStateTransaction(tx.Input) require.NoError(t, err) - decodedCommitEpoch, ok := decodedInputData.(*contractsapi.CommitEpochValidatorSetFn) + decodedCommitEpoch, ok := decodedInputData.(*contractsapi.CommitEpochEpochManagerFn) require.True(t, ok) require.True(t, commitEpoch.ID.Cmp(decodedCommitEpoch.ID) == 0) require.NotNil(t, decodedCommitEpoch.Epoch) @@ -1426,7 +1426,7 @@ func TestFSM_VerifyStateTransaction_InvalidSignature(t *testing.T) { var txns []*types.Transaction - signature := createSignature(t, validators.GetPrivateIdentities("A", "B", "C", "D"), hash, signer.DomainStateReceiver) + signature := createSignature(t, validators.GetPrivateIdentities("A", "B", "C", "D", "E"), hash, signer.DomainStateReceiver) invalidValidator := validator.NewTestValidator(t, "G", 1) invalidSignature, err := invalidValidator.MustSign([]byte("malicious message"), signer.DomainStateReceiver).Marshal() require.NoError(t, err) @@ -1464,7 +1464,7 @@ func TestFSM_VerifyStateTransaction_TwoCommitmentMessages(t *testing.T) { var txns []*types.Transaction - signature := createSignature(t, validators.GetPrivateIdentities("A", "B", "C", "D"), hash, signer.DomainStateReceiver) + signature := createSignature(t, validators.GetPrivateIdentities("A", "B", "C", "D", "E"), hash, signer.DomainStateReceiver) commitmentMessageSigned.AggSignature = *signature inputData, err := commitmentMessageSigned.EncodeAbi() diff --git a/consensus/polybft/helpers_test.go b/consensus/polybft/helpers_test.go index a002e1efb6..a30f7c348d 100644 --- a/consensus/polybft/helpers_test.go +++ b/consensus/polybft/helpers_test.go @@ -59,7 +59,7 @@ func createSignature(t *testing.T, accounts []*wallet.Account, hash types.Hash, } func createTestCommitEpochInput(t *testing.T, epochID uint64, - epochSize uint64) *contractsapi.CommitEpochValidatorSetFn { + epochSize uint64) *contractsapi.CommitEpochEpochManagerFn { t.Helper() var startBlock uint64 = 0 @@ -67,7 +67,7 @@ func createTestCommitEpochInput(t *testing.T, epochID uint64, startBlock = (epochID - 1) * epochSize } - commitEpoch := &contractsapi.CommitEpochValidatorSetFn{ + commitEpoch := &contractsapi.CommitEpochEpochManagerFn{ ID: new(big.Int).SetUint64(epochID), Epoch: &contractsapi.Epoch{ StartBlock: new(big.Int).SetUint64(startBlock + 1), @@ -80,7 +80,7 @@ func createTestCommitEpochInput(t *testing.T, epochID uint64, } func createTestDistributeRewardsInput(t *testing.T, epochID uint64, - validatorSet validator.AccountSet, epochSize uint64) *contractsapi.DistributeRewardForRewardPoolFn { + validatorSet validator.AccountSet, epochSize uint64) *contractsapi.DistributeRewardForEpochManagerFn { t.Helper() if validatorSet == nil { @@ -96,7 +96,7 @@ func createTestDistributeRewardsInput(t *testing.T, epochID uint64, } } - return &contractsapi.DistributeRewardForRewardPoolFn{ + return &contractsapi.DistributeRewardForEpochManagerFn{ EpochID: new(big.Int).SetUint64(epochID), Uptime: uptime, } @@ -184,13 +184,10 @@ func createTestBridgeConfig() *BridgeConfig { ExitHelperAddr: types.StringToAddress("3"), RootERC20PredicateAddr: types.StringToAddress("4"), ChildMintableERC20PredicateAddr: types.StringToAddress("5"), - RootNativeERC20Addr: types.StringToAddress("6"), RootERC721PredicateAddr: types.StringToAddress("8"), ChildMintableERC721PredicateAddr: types.StringToAddress("9"), RootERC1155PredicateAddr: types.StringToAddress("11"), ChildMintableERC1155PredicateAddr: types.StringToAddress("12"), - CustomSupernetManagerAddr: types.StringToAddress("13"), - StakeManagerAddr: types.StringToAddress("14"), JSONRPCEndpoint: "http://localhost:8545", } } diff --git a/consensus/polybft/polybft.go b/consensus/polybft/polybft.go index 664b254695..0b127e2762 100644 --- a/consensus/polybft/polybft.go +++ b/consensus/polybft/polybft.go @@ -147,18 +147,8 @@ func GenesisPostHookFactory(config *chain.Chain, engineName string) func(txn *st initialTotalSupply.Add(initialTotalSupply, alloc.Balance) } - bridgeCfg := polyBFTConfig.Bridge - if bridgeCfg == nil { - return errMissingBridgeConfig - } - proxyAddrMapping := contracts.GetProxyImplementationMapping() - burnContractAddress, isBurnContractSet := getBurnContractAddress(config, polyBFTConfig) - if isBurnContractSet { - proxyAddrMapping[contracts.DefaultBurnContract] = burnContractAddress - } - if _, ok := config.Genesis.Alloc[contracts.RewardTokenContract]; ok { proxyAddrMapping[contracts.RewardTokenContract] = contracts.RewardTokenContractV1 } @@ -167,13 +157,13 @@ func GenesisPostHookFactory(config *chain.Chain, engineName string) func(txn *st return err } - // initialize ValidatorSet SC - if err = initValidatorSet(polyBFTConfig, transition); err != nil { + // initialize StakeManager SC + if err = initStakeManager(polyBFTConfig, transition); err != nil { return err } - // approve reward pool - if err = approveRewardPoolAsSpender(polyBFTConfig, transition); err != nil { + // approve EpochManager + if err = approveEpochManagerAsSpender(polyBFTConfig, transition); err != nil { return err } @@ -182,237 +172,199 @@ func GenesisPostHookFactory(config *chain.Chain, engineName string) func(txn *st return err } - // initialize RewardPool SC - if err = initRewardPool(polyBFTConfig, transition); err != nil { + // initialize EpochManager SC + if err = initEpochManager(polyBFTConfig, transition); err != nil { return err } - // check if there are Bridge Allow List Admins and Bridge Block List Admins - // and if there are, get the first address as the Admin - bridgeAllowListAdmin := types.ZeroAddress - if config.Params.BridgeAllowList != nil && len(config.Params.BridgeAllowList.AdminAddresses) > 0 { - bridgeAllowListAdmin = config.Params.BridgeAllowList.AdminAddresses[0] - } - - bridgeBlockListAdmin := types.ZeroAddress - if config.Params.BridgeBlockList != nil && len(config.Params.BridgeBlockList.AdminAddresses) > 0 { - bridgeBlockListAdmin = config.Params.BridgeBlockList.AdminAddresses[0] - } - - // initialize Predicate SCs - if bridgeAllowListAdmin != types.ZeroAddress || bridgeBlockListAdmin != types.ZeroAddress { - // The owner of the contract will be the allow list admin or the block list admin, if any of them is set. - owner := contracts.SystemCaller - useBridgeAllowList := bridgeAllowListAdmin != types.ZeroAddress - useBridgeBlockList := bridgeBlockListAdmin != types.ZeroAddress - - if bridgeAllowListAdmin != types.ZeroAddress { - owner = bridgeAllowListAdmin - } else if bridgeBlockListAdmin != types.ZeroAddress { - owner = bridgeBlockListAdmin - } - - // initialize ChildERC20PredicateAccessList SC - input, err := getInitERC20PredicateACLInput(polyBFTConfig.Bridge, owner, - useBridgeAllowList, useBridgeBlockList, false) - if err != nil { - return err - } - - if err = callContract(contracts.SystemCaller, contracts.ChildERC20PredicateContract, input, - "ChildERC20PredicateAccessList", transition); err != nil { - return err - } - - // initialize ChildERC721PredicateAccessList SC - input, err = getInitERC721PredicateACLInput(polyBFTConfig.Bridge, owner, - useBridgeAllowList, useBridgeBlockList, false) - if err != nil { - return err - } - - if err = callContract(contracts.SystemCaller, contracts.ChildERC721PredicateContract, input, - "ChildERC721PredicateAccessList", transition); err != nil { - return err - } - - // initialize ChildERC1155PredicateAccessList SC - input, err = getInitERC1155PredicateACLInput(polyBFTConfig.Bridge, owner, - useBridgeAllowList, useBridgeBlockList, false) - if err != nil { - return err - } - - if err = callContract(contracts.SystemCaller, contracts.ChildERC1155PredicateContract, input, - "ChildERC1155PredicateAccessList", transition); err != nil { - return err - } - - // initialize RootMintableERC20PredicateAccessList SC - input, err = getInitERC20PredicateACLInput(polyBFTConfig.Bridge, owner, - useBridgeAllowList, useBridgeBlockList, true) - if err != nil { - return err - } - - if err = callContract(contracts.SystemCaller, contracts.RootMintableERC20PredicateContract, input, - "RootMintableERC20PredicateAccessList", transition); err != nil { - return err - } + bridgeCfg := polyBFTConfig.Bridge + if bridgeCfg != nil { + // check if there are Bridge Allow List Admins and Bridge Block List Admins + // and if there are, get the first address as the Admin + bridgeAllowListAdmin := types.ZeroAddress + if config.Params.BridgeAllowList != nil && len(config.Params.BridgeAllowList.AdminAddresses) > 0 { + bridgeAllowListAdmin = config.Params.BridgeAllowList.AdminAddresses[0] + } + + bridgeBlockListAdmin := types.ZeroAddress + if config.Params.BridgeBlockList != nil && len(config.Params.BridgeBlockList.AdminAddresses) > 0 { + bridgeBlockListAdmin = config.Params.BridgeBlockList.AdminAddresses[0] + } + + // initialize Predicate SCs + if bridgeAllowListAdmin != types.ZeroAddress || bridgeBlockListAdmin != types.ZeroAddress { + // The owner of the contract will be the allow list admin or the block list admin, if any of them is set. + owner := contracts.SystemCaller + useBridgeAllowList := bridgeAllowListAdmin != types.ZeroAddress + useBridgeBlockList := bridgeBlockListAdmin != types.ZeroAddress + + if bridgeAllowListAdmin != types.ZeroAddress { + owner = bridgeAllowListAdmin + } else if bridgeBlockListAdmin != types.ZeroAddress { + owner = bridgeBlockListAdmin + } - // initialize RootMintableERC721PredicateAccessList SC - input, err = getInitERC721PredicateACLInput(polyBFTConfig.Bridge, owner, - useBridgeAllowList, useBridgeBlockList, true) - if err != nil { - return err - } + // initialize ChildERC20PredicateAccessList SC + input, err := getInitERC20PredicateACLInput(polyBFTConfig.Bridge, owner, + useBridgeAllowList, useBridgeBlockList, false) + if err != nil { + return err + } - if err = callContract(contracts.SystemCaller, contracts.RootMintableERC721PredicateContract, input, - "RootMintableERC721PredicateAccessList", transition); err != nil { - return err - } + if err = callContract(contracts.SystemCaller, contracts.ChildERC20PredicateContract, input, + "ChildERC20PredicateAccessList", transition); err != nil { + return err + } - // initialize RootMintableERC1155PredicateAccessList SC - input, err = getInitERC1155PredicateACLInput(polyBFTConfig.Bridge, owner, - useBridgeAllowList, useBridgeBlockList, true) - if err != nil { - return err - } + // initialize ChildERC721PredicateAccessList SC + input, err = getInitERC721PredicateACLInput(polyBFTConfig.Bridge, owner, + useBridgeAllowList, useBridgeBlockList, false) + if err != nil { + return err + } - if err = callContract(contracts.SystemCaller, contracts.RootMintableERC1155PredicateContract, input, - "RootMintableERC1155PredicateAccessList", transition); err != nil { - return err - } - } else { - // initialize ChildERC20Predicate SC - input, err := getInitERC20PredicateInput(bridgeCfg, false) - if err != nil { - return err - } + if err = callContract(contracts.SystemCaller, contracts.ChildERC721PredicateContract, input, + "ChildERC721PredicateAccessList", transition); err != nil { + return err + } - if err = callContract(contracts.SystemCaller, contracts.ChildERC20PredicateContract, input, - "ChildERC20Predicate", transition); err != nil { - return err - } + // initialize ChildERC1155PredicateAccessList SC + input, err = getInitERC1155PredicateACLInput(polyBFTConfig.Bridge, owner, + useBridgeAllowList, useBridgeBlockList, false) + if err != nil { + return err + } - // initialize ChildERC721Predicate SC - input, err = getInitERC721PredicateInput(bridgeCfg, false) - if err != nil { - return err - } + if err = callContract(contracts.SystemCaller, contracts.ChildERC1155PredicateContract, input, + "ChildERC1155PredicateAccessList", transition); err != nil { + return err + } - if err = callContract(contracts.SystemCaller, contracts.ChildERC721PredicateContract, input, - "ChildERC721Predicate", transition); err != nil { - return err - } + // initialize RootMintableERC20PredicateAccessList SC + input, err = getInitERC20PredicateACLInput(polyBFTConfig.Bridge, owner, + useBridgeAllowList, useBridgeBlockList, true) + if err != nil { + return err + } - // initialize ChildERC1155Predicate SC - input, err = getInitERC1155PredicateInput(bridgeCfg, false) - if err != nil { - return err - } + if err = callContract(contracts.SystemCaller, contracts.RootMintableERC20PredicateContract, input, + "RootMintableERC20PredicateAccessList", transition); err != nil { + return err + } - if err = callContract(contracts.SystemCaller, contracts.ChildERC1155PredicateContract, input, - "ChildERC1155Predicate", transition); err != nil { - return err - } + // initialize RootMintableERC721PredicateAccessList SC + input, err = getInitERC721PredicateACLInput(polyBFTConfig.Bridge, owner, + useBridgeAllowList, useBridgeBlockList, true) + if err != nil { + return err + } - // initialize RootMintableERC20Predicate SC - input, err = getInitERC20PredicateInput(bridgeCfg, true) - if err != nil { - return err - } + if err = callContract(contracts.SystemCaller, contracts.RootMintableERC721PredicateContract, input, + "RootMintableERC721PredicateAccessList", transition); err != nil { + return err + } - if err = callContract(contracts.SystemCaller, contracts.RootMintableERC20PredicateContract, input, - "RootMintableERC20Predicate", transition); err != nil { - return err - } + // initialize RootMintableERC1155PredicateAccessList SC + input, err = getInitERC1155PredicateACLInput(polyBFTConfig.Bridge, owner, + useBridgeAllowList, useBridgeBlockList, true) + if err != nil { + return err + } - // initialize RootMintableERC721Predicate SC - input, err = getInitERC721PredicateInput(bridgeCfg, true) - if err != nil { - return err - } + if err = callContract(contracts.SystemCaller, contracts.RootMintableERC1155PredicateContract, input, + "RootMintableERC1155PredicateAccessList", transition); err != nil { + return err + } + } else { + // initialize ChildERC20Predicate SC + input, err := getInitERC20PredicateInput(bridgeCfg, false) + if err != nil { + return err + } - if err = callContract(contracts.SystemCaller, contracts.RootMintableERC721PredicateContract, input, - "RootMintableERC721Predicate", transition); err != nil { - return err - } + if err = callContract(contracts.SystemCaller, contracts.ChildERC20PredicateContract, input, + "ChildERC20Predicate", transition); err != nil { + return err + } - // initialize RootMintableERC1155Predicate SC - input, err = getInitERC1155PredicateInput(bridgeCfg, true) - if err != nil { - return err - } + // initialize ChildERC721Predicate SC + input, err = getInitERC721PredicateInput(bridgeCfg, false) + if err != nil { + return err + } - if err = callContract(contracts.SystemCaller, contracts.RootMintableERC1155PredicateContract, input, - "RootMintableERC1155Predicate", transition); err != nil { - return err - } - } + if err = callContract(contracts.SystemCaller, contracts.ChildERC721PredicateContract, input, + "ChildERC721Predicate", transition); err != nil { + return err + } - if polyBFTConfig.NativeTokenConfig.IsMintable { - // initialize NativeERC20Mintable SC - params := &contractsapi.InitializeNativeERC20MintableFn{ - Predicate_: contracts.ChildERC20PredicateContract, - Owner_: polyBFTConfig.NativeTokenConfig.Owner, - RootToken_: types.ZeroAddress, // in case native mintable token is used, it is always root token - Name_: polyBFTConfig.NativeTokenConfig.Name, - Symbol_: polyBFTConfig.NativeTokenConfig.Symbol, - Decimals_: polyBFTConfig.NativeTokenConfig.Decimals, - TokenSupply_: initialTotalSupply, - } + // initialize ChildERC1155Predicate SC + input, err = getInitERC1155PredicateInput(bridgeCfg, false) + if err != nil { + return err + } - input, err := params.EncodeAbi() - if err != nil { - return err - } + if err = callContract(contracts.SystemCaller, contracts.ChildERC1155PredicateContract, input, + "ChildERC1155Predicate", transition); err != nil { + return err + } - if err = callContract(contracts.SystemCaller, - contracts.NativeERC20TokenContract, input, "NativeERC20Mintable", transition); err != nil { - return err - } - } else { - // initialize NativeERC20 SC - params := &contractsapi.InitializeNativeERC20Fn{ - Name_: polyBFTConfig.NativeTokenConfig.Name, - Symbol_: polyBFTConfig.NativeTokenConfig.Symbol, - Decimals_: polyBFTConfig.NativeTokenConfig.Decimals, - RootToken_: polyBFTConfig.Bridge.RootNativeERC20Addr, - Predicate_: contracts.ChildERC20PredicateContract, - TokenSupply_: initialTotalSupply, - } + // initialize RootMintableERC20Predicate SC + input, err = getInitERC20PredicateInput(bridgeCfg, true) + if err != nil { + return err + } - input, err := params.EncodeAbi() - if err != nil { - return err - } + if err = callContract(contracts.SystemCaller, contracts.RootMintableERC20PredicateContract, input, + "RootMintableERC20Predicate", transition); err != nil { + return err + } - if err = callContract(contracts.SystemCaller, - contracts.NativeERC20TokenContract, input, "NativeERC20", transition); err != nil { - return err - } + // initialize RootMintableERC721Predicate SC + input, err = getInitERC721PredicateInput(bridgeCfg, true) + if err != nil { + return err + } - // initialize EIP1559Burn SC - if isBurnContractSet { - burnParams := &contractsapi.InitializeEIP1559BurnFn{ - NewChildERC20Predicate: contracts.ChildERC20PredicateContract, - NewBurnDestination: config.Params.BurnContractDestinationAddress, + if err = callContract(contracts.SystemCaller, contracts.RootMintableERC721PredicateContract, input, + "RootMintableERC721Predicate", transition); err != nil { + return err } - input, err = burnParams.EncodeAbi() + // initialize RootMintableERC1155Predicate SC + input, err = getInitERC1155PredicateInput(bridgeCfg, true) if err != nil { return err } - if err = callContract(contracts.SystemCaller, - burnContractAddress, - input, "EIP1559Burn", transition); err != nil { + if err = callContract(contracts.SystemCaller, contracts.RootMintableERC1155PredicateContract, input, + "RootMintableERC1155Predicate", transition); err != nil { return err } } } + // initialize NativeERC20 SC + params := &contractsapi.InitializeNativeERC20Fn{ + Predicate_: contracts.ChildERC20PredicateContract, + Owner_: polyBFTConfig.BladeAdmin, + RootToken_: types.ZeroAddress, // in case native mintable token is used, it is always root token + Name_: polyBFTConfig.NativeTokenConfig.Name, + Symbol_: polyBFTConfig.NativeTokenConfig.Symbol, + Decimals_: polyBFTConfig.NativeTokenConfig.Decimals, + TokenSupply_: initialTotalSupply, + } + + input, err := params.EncodeAbi() + if err != nil { + return err + } + + if err = callContract(contracts.SystemCaller, + contracts.NativeERC20TokenContract, input, "NativeERC20", transition); err != nil { + return err + } + return nil } } @@ -534,8 +486,8 @@ func (p *Polybft) Start() error { // start state DB process go p.state.startStatsReleasing() - // polybft rootchain metrics - go p.publishRootchainMetrics(p.logger.Named("rootchain_metrics")) + /* // polybft rootchain metrics + go p.publishRootchainMetrics(p.logger.Named("rootchain_metrics")) */ return nil } @@ -543,16 +495,16 @@ func (p *Polybft) Start() error { // initRuntime creates consensus runtime func (p *Polybft) initRuntime() error { runtimeConfig := &runtimeConfig{ - PolyBFTConfig: p.consensusConfig, - Key: p.key, - DataDir: p.dataDir, - State: p.state, - blockchain: p.blockchain, - polybftBackend: p, - txPool: p.txPool, - bridgeTopic: p.bridgeTopic, - numBlockConfirmations: p.config.NumBlockConfirmations, - consensusConfig: p.config.Config, + PolyBFTConfig: p.consensusConfig, + Key: p.key, + DataDir: p.dataDir, + State: p.state, + blockchain: p.blockchain, + polybftBackend: p, + txPool: p.txPool, + bridgeTopic: p.bridgeTopic, + consensusConfig: p.config.Config, + eventTracker: p.config.EventTracker, } runtime, err := newConsensusRuntime(p.logger, runtimeConfig) @@ -832,17 +784,3 @@ func initProxies(transition *state.Transition, admin types.Address, return nil } - -func getBurnContractAddress(config *chain.Chain, polyBFTConfig PolyBFTConfig) (types.Address, bool) { - if config.Params.BurnContract != nil && - len(config.Params.BurnContract) == 1 && - !polyBFTConfig.NativeTokenConfig.IsMintable { - for _, address := range config.Params.BurnContract { - if _, ok := config.Genesis.Alloc[address]; ok { - return address, true - } - } - } - - return types.ZeroAddress, false -} diff --git a/consensus/polybft/polybft_config.go b/consensus/polybft/polybft_config.go index f85873e3ab..9a452389fc 100644 --- a/consensus/polybft/polybft_config.go +++ b/consensus/polybft/polybft_config.go @@ -16,7 +16,7 @@ import ( const ( ConsensusName = "polybft" - minNativeTokenParamsNumber = 4 + minNativeTokenParamsNumber = 3 defaultNativeTokenName = "Polygon" defaultNativeTokenSymbol = "MATIC" @@ -25,15 +25,13 @@ const ( var ( DefaultTokenConfig = &TokenConfig{ - Name: defaultNativeTokenName, - Symbol: defaultNativeTokenSymbol, - Decimals: defaultNativeTokenDecimals, - IsMintable: false, - Owner: types.ZeroAddress, + Name: defaultNativeTokenName, + Symbol: defaultNativeTokenSymbol, + Decimals: defaultNativeTokenDecimals, } errInvalidTokenParams = errors.New("native token params were not submitted in proper format " + - "()") + "()") ) // PolyBFTConfig is the configuration file for the Polybft consensus protocol. @@ -64,9 +62,6 @@ type PolyBFTConfig struct { InitialTrieRoot types.Hash `json:"initialTrieRoot"` - // SupernetID indicates ID of given supernet generated by stake manager contract - SupernetID int64 `json:"supernetID"` - // MinValidatorSetSize indicates the minimum size of validator set MinValidatorSetSize uint64 `json:"minValidatorSetSize"` @@ -81,11 +76,15 @@ type PolyBFTConfig struct { // BlockTrackerPollInterval specifies interval // at which block tracker polls for blocks on a rootchain - BlockTrackerPollInterval common.Duration `json:"blockTrackerPollInterval,omitempty"` + BlockTrackerPollInterval common.Duration `json:"blockTrackerPollInterval"` // ProxyContractsAdmin is the address that will have the privilege to change both the proxy // implementation address and the admin - ProxyContractsAdmin types.Address `json:"proxyContractsAdmin,omitempty"` + ProxyContractsAdmin types.Address `json:"proxyContractsAdmin"` + + // BladeAdmin is the address that will be the owner of the NativeERC20 mintable token, + // and StakeManager contract which manages validators + BladeAdmin types.Address `json:"bladeAdmin"` } // LoadPolyBFTConfig loads chain config from provided path and unmarshals PolyBFTConfig @@ -125,7 +124,6 @@ type BridgeConfig struct { ExitHelperAddr types.Address `json:"exitHelperAddress"` RootERC20PredicateAddr types.Address `json:"erc20PredicateAddress"` ChildMintableERC20PredicateAddr types.Address `json:"erc20ChildMintablePredicateAddress"` - RootNativeERC20Addr types.Address `json:"nativeERC20Address"` RootERC721PredicateAddr types.Address `json:"erc721PredicateAddress"` ChildMintableERC721PredicateAddr types.Address `json:"erc721ChildMintablePredicateAddress"` RootERC1155PredicateAddr types.Address `json:"erc1155PredicateAddress"` @@ -133,10 +131,7 @@ type BridgeConfig struct { ChildERC20Addr types.Address `json:"childERC20Address"` ChildERC721Addr types.Address `json:"childERC721Address"` ChildERC1155Addr types.Address `json:"childERC1155Address"` - CustomSupernetManagerAddr types.Address `json:"customSupernetManagerAddr"` - StakeManagerAddr types.Address `json:"stakeManagerAddr"` // only populated if stake-manager-deploy command is executed, and used for e2e tests - StakeTokenAddr types.Address `json:"stakeTokenAddr,omitempty"` BLSAddress types.Address `json:"blsAddr"` BN256G2Address types.Address `json:"bn256G2Addr"` @@ -159,7 +154,6 @@ type RootchainConfig struct { ExitHelperAddress types.Address RootERC20PredicateAddress types.Address ChildMintableERC20PredicateAddress types.Address - RootNativeERC20Address types.Address ChildERC20Address types.Address RootERC721PredicateAddress types.Address ChildMintableERC721PredicateAddress types.Address @@ -167,9 +161,6 @@ type RootchainConfig struct { RootERC1155PredicateAddress types.Address ChildMintableERC1155PredicateAddress types.Address ChildERC1155Address types.Address - CustomSupernetManagerAddress types.Address - StakeManagerAddress types.Address - StakeTokenAddress types.Address } // ToBridgeConfig creates BridgeConfig instance @@ -182,7 +173,6 @@ func (r *RootchainConfig) ToBridgeConfig() *BridgeConfig { ExitHelperAddr: r.ExitHelperAddress, RootERC20PredicateAddr: r.RootERC20PredicateAddress, ChildMintableERC20PredicateAddr: r.ChildMintableERC20PredicateAddress, - RootNativeERC20Addr: r.RootNativeERC20Address, RootERC721PredicateAddr: r.RootERC721PredicateAddress, ChildMintableERC721PredicateAddr: r.ChildMintableERC721PredicateAddress, RootERC1155PredicateAddr: r.RootERC1155PredicateAddress, @@ -190,8 +180,6 @@ func (r *RootchainConfig) ToBridgeConfig() *BridgeConfig { ChildERC20Addr: r.ChildERC20Address, ChildERC721Addr: r.ChildERC721Address, ChildERC1155Addr: r.ChildERC1155Address, - CustomSupernetManagerAddr: r.CustomSupernetManagerAddress, - StakeManagerAddr: r.StakeManagerAddress, BLSAddress: r.BLSAddress, BN256G2Address: r.BN256G2Address, } @@ -199,11 +187,9 @@ func (r *RootchainConfig) ToBridgeConfig() *BridgeConfig { // TokenConfig is the configuration of native token used by edge network type TokenConfig struct { - Name string `json:"name"` - Symbol string `json:"symbol"` - Decimals uint8 `json:"decimals"` - IsMintable bool `json:"isMintable"` - Owner types.Address `json:"owner"` + Name string `json:"name"` + Symbol string `json:"symbol"` + Decimals uint8 `json:"decimals"` } func ParseRawTokenConfig(rawConfig string) (*TokenConfig, error) { @@ -234,29 +220,10 @@ func ParseRawTokenConfig(rawConfig string) (*TokenConfig, error) { return nil, errInvalidTokenParams } - // is mintable native token used - isMintable, err := strconv.ParseBool(strings.TrimSpace(params[3])) - if err != nil { - return nil, errInvalidTokenParams - } - - // in case it is mintable native token, it is expected to have 5 parameters provided - if isMintable && len(params) != minNativeTokenParamsNumber+1 { - return nil, errInvalidTokenParams - } - - // owner address - owner := types.ZeroAddress - if isMintable { - owner = types.StringToAddress(strings.TrimSpace(params[4])) - } - return &TokenConfig{ - Name: name, - Symbol: symbol, - Decimals: uint8(decimals), - IsMintable: isMintable, - Owner: owner, + Name: name, + Symbol: symbol, + Decimals: uint8(decimals), }, nil } @@ -307,10 +274,3 @@ type rewardsConfigRaw struct { WalletAddress types.Address `json:"rewardWalletAddress"` WalletAmount *string `json:"rewardWalletAmount"` } - -// BurnContractInfo contains metadata for burn contract, which is part of EIP-1559 specification -type BurnContractInfo struct { - BlockNumber uint64 - Address types.Address - DestinationAddress types.Address -} diff --git a/consensus/polybft/polybft_test.go b/consensus/polybft/polybft_test.go index 781e0e84fa..d64b4dc72e 100644 --- a/consensus/polybft/polybft_test.go +++ b/consensus/polybft/polybft_test.go @@ -315,7 +315,7 @@ func Test_GenesisPostHookFactory(t *testing.T) { Bridge: bridgeCfg, EpochSize: epochSize, RewardConfig: &RewardsConfig{WalletAmount: ethgo.Ether(1000)}, - NativeTokenConfig: &TokenConfig{Name: "Test Mintable", Symbol: "TEST_MNT", Decimals: 18, IsMintable: true}, + NativeTokenConfig: &TokenConfig{Name: "Test Mintable", Symbol: "TEST_MNT", Decimals: 18}, MaxValidatorSetSize: maxValidators, }, bridgeAllowList: &chain.AddressListConfig{ @@ -323,11 +323,6 @@ func Test_GenesisPostHookFactory(t *testing.T) { EnabledAddresses: []types.Address{validators.Validators["1"].Address()}, }, }, - { - name: "missing bridge configuration", - config: &PolyBFTConfig{}, - expectedErr: errMissingBridgeConfig, - }, } for _, tc := range cases { diff --git a/consensus/polybft/sc_integration_test.go b/consensus/polybft/sc_integration_test.go index 24ed181235..9eb072878f 100644 --- a/consensus/polybft/sc_integration_test.go +++ b/consensus/polybft/sc_integration_test.go @@ -268,8 +268,8 @@ func TestIntegration_CommitEpoch(t *testing.T) { // init validator sets validatorSetSize := []int{5, 10, 50, 100} - intialBalance := uint64(5 * math.Pow(10, 18)) // 5 tokens - reward := uint64(math.Pow(10, 18)) // 1 token + initialBalance := uint64(5 * math.Pow(10, 18)) // 5 tokens + reward := uint64(math.Pow(10, 18)) // 1 token walletAddress := types.StringToAddress("1234889893") validatorSets := make([]*validator.TestValidators, len(validatorSetSize), len(validatorSetSize)) @@ -281,7 +281,7 @@ func TestIntegration_CommitEpoch(t *testing.T) { for j := 0; j < size; j++ { aliases[j] = "v" + strconv.Itoa(j) - vps[j] = intialBalance + vps[j] = initialBalance } validatorSets[i] = validator.NewTestValidatorsWithAliases(t, aliases, vps) @@ -295,17 +295,17 @@ func TestIntegration_CommitEpoch(t *testing.T) { initValidators := make([]*validator.GenesisValidator, accSet.Len()) // add contracts to genesis data alloc := map[types.Address]*chain.GenesisAccount{ - contracts.ValidatorSetContract: { - Code: contractsapi.ValidatorSet.DeployedBytecode, - }, - contracts.RewardPoolContract: { - Code: contractsapi.RewardPool.DeployedBytecode, + contracts.EpochManagerContract: { + Code: contractsapi.EpochManager.DeployedBytecode, }, contracts.NativeERC20TokenContract: { Code: contractsapi.NativeERC20.DeployedBytecode, }, + contracts.StakeManagerContract: { + Code: contractsapi.StakeManager.DeployedBytecode, + }, walletAddress: { - Balance: new(big.Int).SetUint64(intialBalance), + Balance: new(big.Int).SetUint64(initialBalance), }, } @@ -333,26 +333,20 @@ func TestIntegration_CommitEpoch(t *testing.T) { RewardConfig: &RewardsConfig{ TokenAddress: contracts.NativeERC20TokenContract, WalletAddress: walletAddress, - WalletAmount: new(big.Int).SetUint64(intialBalance), - }, - Bridge: &BridgeConfig{ - CustomSupernetManagerAddr: types.StringToAddress("0x12312451"), + WalletAmount: new(big.Int).SetUint64(initialBalance), }, } transition := newTestTransition(t, alloc) - // init ValidatorSet - err := initValidatorSet(polyBFTConfig, transition) - require.NoError(t, err) + // init StakeManager + require.NoError(t, initStakeManager(polyBFTConfig, transition)) - // init RewardPool - err = initRewardPool(polyBFTConfig, transition) - require.NoError(t, err) + // init EpochManager + require.NoError(t, initEpochManager(polyBFTConfig, transition)) - // approve reward pool as reward token spender - err = approveRewardPoolAsSpender(polyBFTConfig, transition) - require.NoError(t, err) + // approve EpochManager as reward token spender + require.NoError(t, approveEpochManagerAsSpender(polyBFTConfig, transition)) // create input for commit epoch commitEpoch := createTestCommitEpochInput(t, 1, polyBFTConfig.EpochSize) @@ -360,7 +354,7 @@ func TestIntegration_CommitEpoch(t *testing.T) { require.NoError(t, err) // call commit epoch - result := transition.Call2(contracts.SystemCaller, contracts.ValidatorSetContract, input, big.NewInt(0), 10000000000) + result := transition.Call2(contracts.SystemCaller, contracts.EpochManagerContract, input, big.NewInt(0), 10000000000) require.NoError(t, result.Err) t.Logf("Number of validators %d on commit epoch, Gas used %+v\n", accSet.Len(), result.GasUsed) @@ -370,7 +364,7 @@ func TestIntegration_CommitEpoch(t *testing.T) { require.NoError(t, err) // call reward distributor - result = transition.Call2(contracts.SystemCaller, contracts.RewardPoolContract, input, big.NewInt(0), 10000000000) + result = transition.Call2(contracts.SystemCaller, contracts.EpochManagerContract, input, big.NewInt(0), 10000000000) require.NoError(t, result.Err) t.Logf("Number of validators %d on reward distribution, Gas used %+v\n", accSet.Len(), result.GasUsed) @@ -379,7 +373,7 @@ func TestIntegration_CommitEpoch(t *testing.T) { require.NoError(t, err) // call commit epoch - result = transition.Call2(contracts.SystemCaller, contracts.ValidatorSetContract, input, big.NewInt(0), 10000000000) + result = transition.Call2(contracts.SystemCaller, contracts.EpochManagerContract, input, big.NewInt(0), 10000000000) require.NoError(t, result.Err) t.Logf("Number of validators %d on commit epoch, Gas used %+v\n", accSet.Len(), result.GasUsed) @@ -388,7 +382,7 @@ func TestIntegration_CommitEpoch(t *testing.T) { require.NoError(t, err) // call reward distributor - result = transition.Call2(contracts.SystemCaller, contracts.RewardPoolContract, input, big.NewInt(0), 10000000000) + result = transition.Call2(contracts.SystemCaller, contracts.EpochManagerContract, input, big.NewInt(0), 10000000000) require.NoError(t, result.Err) t.Logf("Number of validators %d on reward distribution, Gas used %+v\n", accSet.Len(), result.GasUsed) } diff --git a/consensus/polybft/signer/utils.go b/consensus/polybft/signer/utils.go index 5628167667..cd3eee4a75 100644 --- a/consensus/polybft/signer/utils.go +++ b/consensus/polybft/signer/utils.go @@ -36,13 +36,13 @@ var ( // MakeKOSKSignature creates KOSK signature which prevents rogue attack func MakeKOSKSignature(privateKey *bls.PrivateKey, address types.Address, - chainID int64, domain []byte, supernetManagerAddr types.Address) (*bls.Signature, error) { + chainID int64, domain []byte, stakeManagerAddr types.Address) (*bls.Signature, error) { spenderABI, err := addressABIType.Encode(address) if err != nil { return nil, err } - supernetManagerABI, err := addressABIType.Encode(supernetManagerAddr) + supernetManagerABI, err := addressABIType.Encode(stakeManagerAddr) if err != nil { return nil, err } diff --git a/consensus/polybft/stake_manager.go b/consensus/polybft/stake_manager.go index d91e80e71b..ba18013a6e 100644 --- a/consensus/polybft/stake_manager.go +++ b/consensus/polybft/stake_manager.go @@ -14,17 +14,19 @@ import ( "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/consensus/polybft/validator" "github.com/0xPolygon/polygon-edge/helper/hex" - "github.com/0xPolygon/polygon-edge/txrelayer" "github.com/0xPolygon/polygon-edge/types" "github.com/hashicorp/go-hclog" "github.com/umbracle/ethgo" "github.com/umbracle/ethgo/abi" + "github.com/umbracle/ethgo/contract" bolt "go.etcd.io/bbolt" ) var ( bigZero = big.NewInt(0) - validatorTypeABI = abi.MustNewType("tuple(uint256[4] blsKey, uint256 stake, bool isWhitelisted, bool isActive)") + validatorTypeABI = abi.MustNewType("tuple(uint256[4] blsKey," + + "uint256 stake, bool isWhitelisted, bool isActive)") + errUnknownStakeManagerEvent = errors.New("unknown event from stake manager contract") ) // StakeManager interface provides functions for handling stake change of validators @@ -42,6 +44,7 @@ var _ StakeManager = (*dummyStakeManager)(nil) type dummyStakeManager struct{} func (d *dummyStakeManager) PostBlock(req *PostBlockRequest) error { return nil } + func (d *dummyStakeManager) UpdateValidatorSet(epoch uint64, currentValidatorSet validator.AccountSet) (*validator.ValidatorSetDelta, error) { return &validator.ValidatorSetDelta{}, nil @@ -51,6 +54,7 @@ func (d *dummyStakeManager) UpdateValidatorSet(epoch uint64, func (d *dummyStakeManager) GetLogFilters() map[types.Address][]types.Hash { return make(map[types.Address][]types.Hash) } + func (d *dummyStakeManager) ProcessLog(header *types.Header, log *ethgo.Log, dbTx *bolt.Tx) error { return nil } @@ -60,37 +64,36 @@ var _ StakeManager = (*stakeManager)(nil) // stakeManager saves transfer events that happened in each block // and calculates updated validator set based on changed stake type stakeManager struct { - logger hclog.Logger - state *State - rootChainRelayer txrelayer.TxRelayer - key ethgo.Key - supernetManagerContract types.Address - validatorSetContract types.Address - maxValidatorSetSize int - polybftBackend polybftBackend + logger hclog.Logger + state *State + key ethgo.Key + stakeManagerContractAddr types.Address + validatorSetContract types.Address + maxValidatorSetSize int + polybftBackend polybftBackend + stakeManagerContract *contract.Contract + blockchain blockchainBackend } // newStakeManager returns a new instance of stake manager func newStakeManager( logger hclog.Logger, state *State, - rootchainRelayer txrelayer.TxRelayer, key ethgo.Key, - validatorSetAddr, supernetManagerAddr types.Address, + stakeManagerAddr types.Address, blockchain blockchainBackend, polybftBackend polybftBackend, maxValidatorSetSize int, dbTx *bolt.Tx, ) (*stakeManager, error) { sm := &stakeManager{ - logger: logger, - state: state, - rootChainRelayer: rootchainRelayer, - key: key, - supernetManagerContract: supernetManagerAddr, - validatorSetContract: validatorSetAddr, - maxValidatorSetSize: maxValidatorSetSize, - polybftBackend: polybftBackend, + logger: logger, + state: state, + key: key, + stakeManagerContractAddr: stakeManagerAddr, + maxValidatorSetSize: maxValidatorSetSize, + polybftBackend: polybftBackend, + blockchain: blockchain, } if err := sm.init(blockchain, dbTx); err != nil { @@ -151,27 +154,46 @@ func (s *stakeManager) init(blockchain blockchainBackend, dbTx *bolt.Tx) error { // we will use eventsGetter to update the fullValidatorSet if // for any reason, we don't have the correct state - eventsGetter := &eventsGetter[*contractsapi.TransferEvent]{ + eventsGetter := &eventsGetter[contractsapi.EventAbi]{ receiptsGetter: receiptsGetter{ blockchain: blockchain, }, isValidLogFn: func(l *types.Log) bool { - return l.Address == s.validatorSetContract + return l.Address == s.stakeManagerContractAddr }, - parseEventFn: func(h *types.Header, l *ethgo.Log) (*contractsapi.TransferEvent, bool, error) { - var transferEvent contractsapi.TransferEvent - doesMatch, err := transferEvent.ParseLog(l) + parseEventFn: func(h *types.Header, l *ethgo.Log) (contractsapi.EventAbi, bool, error) { + var ( + stakeAddedEvent contractsapi.StakeAddedEvent + stakeRemovedEvent contractsapi.StakeRemovedEvent + ) + + switch l.Topics[0] { + case stakeAddedEvent.Sig(): + doesMatch, err := stakeAddedEvent.ParseLog(l) + if err != nil { + return nil, false, err + } - return &transferEvent, doesMatch, err + return &stakeAddedEvent, doesMatch, err + case stakeRemovedEvent.Sig(): + doesMatch, err := stakeRemovedEvent.ParseLog(l) + if err != nil { + return nil, false, err + } + + return &stakeRemovedEvent, doesMatch, err + default: + return nil, false, nil + } }, } - transferEvents, err := eventsGetter.getEventsFromBlocksRange(validatorSet.BlockNumber+1, currentBlockNumber) + stakeEvents, err := eventsGetter.getEventsFromBlocksRange(validatorSet.BlockNumber+1, currentBlockNumber) if err != nil { return err } - if err := s.updateWithReceipts(&validatorSet, transferEvents, currentBlockNumber); err != nil { + if err := s.updateWithReceipts(&validatorSet, stakeEvents, currentBlockNumber); err != nil { return err } @@ -212,26 +234,25 @@ func (s *stakeManager) getOrInitValidatorSet(dbTx *bolt.Tx) (validatorSetState, func (s *stakeManager) updateWithReceipts( fullValidatorSet *validatorSetState, - transferEvents []*contractsapi.TransferEvent, + events []contractsapi.EventAbi, blockNumber uint64) error { - if len(transferEvents) == 0 { + if len(events) == 0 { return nil } - for _, event := range transferEvents { - if event.IsStake() { - s.logger.Debug("Stake transfer event", "to", event.To, "value", event.Value) + for _, event := range events { + switch stakeEvent := event.(type) { + case *contractsapi.StakeAddedEvent: + s.logger.Debug("Stake added event", "to", stakeEvent.Validator, "amount", stakeEvent.Amount) - // then this amount was minted To validator address - fullValidatorSet.Validators.addStake(event.To, event.Value) - } else if event.IsUnstake() { - s.logger.Debug("Unstake transfer event", "from", event.From, "value", event.Value) + fullValidatorSet.Validators.addStake(stakeEvent.Validator, stakeEvent.Amount) + case *contractsapi.StakeRemovedEvent: + s.logger.Debug("Stake removed event", "from", stakeEvent.Validator, "value", stakeEvent.Amount) - // then this amount was burned From validator address - fullValidatorSet.Validators.removeStake(event.From, event.Value) - } else { + fullValidatorSet.Validators.removeStake(stakeEvent.Validator, stakeEvent.Amount) + default: // this should not happen, but lets log it if it does - s.logger.Warn("Found a transfer event that represents neither stake nor unstake") + s.logger.Warn("Found a stake event that represents neither stake nor unstake") } } @@ -334,39 +355,27 @@ func (s *stakeManager) UpdateValidatorSet( // getBlsKey returns bls key for validator from the supernet contract func (s *stakeManager) getBlsKey(address types.Address) (*bls.PublicKey, error) { - getValidatorFn := &contractsapi.GetValidatorCustomSupernetManagerFn{ - Validator_: address, - } - - encoded, err := getValidatorFn.EncodeAbi() + provider, err := s.blockchain.GetStateProviderForBlock(s.blockchain.CurrentHeader()) if err != nil { return nil, err } - response, err := s.rootChainRelayer.Call( - s.key.Address(), - ethgo.Address(s.supernetManagerContract), - encoded) - if err != nil { - return nil, fmt.Errorf("failed to invoke validators function on the supernet manager: %w", err) - } + stakeManagerContractContract := contract.NewContract( + ethgo.Address(s.stakeManagerContractAddr), + contractsapi.StakeManager.Abi, contract.WithProvider(provider), + ) - byteResponse, err := hex.DecodeHex(response) - if err != nil { - return nil, fmt.Errorf("unable to decode hex response, %w", err) - } - - decoded, err := validatorTypeABI.Decode(byteResponse) + rawResult, err := stakeManagerContractContract.Call("getValidator", ethgo.Latest, address) if err != nil { return nil, err } - output, ok := decoded.(map[string]interface{}) + validatorData, ok := rawResult["0"].(map[string]interface{}) if !ok { - return nil, fmt.Errorf("could not convert decoded outputs to map") + return nil, fmt.Errorf("could not collect validator's data (%s) from StakeManager", address) } - blsKey, ok := output["blsKey"].([4]*big.Int) + blsKey, ok := validatorData["blsKey"].([4]*big.Int) if !ok { return nil, fmt.Errorf("failed to decode blskey") } @@ -386,25 +395,48 @@ func (s *stakeManager) getBlsKey(address types.Address) (*bls.PublicKey, error) // and the value is a slice of signatures of events we want to get. // This function is the implementation of EventSubscriber interface func (s *stakeManager) GetLogFilters() map[types.Address][]types.Hash { - var transferEvent contractsapi.TransferEvent - return map[types.Address][]types.Hash{ - s.validatorSetContract: {types.Hash(transferEvent.Sig())}, + s.stakeManagerContractAddr: { + types.Hash(new(contractsapi.StakeAddedEvent).Sig()), + types.Hash(new(contractsapi.StakeRemovedEvent).Sig()), + }, } } // ProcessLog is the implementation of EventSubscriber interface, // used to handle a log defined in GetLogFilters, provided by event provider func (s *stakeManager) ProcessLog(header *types.Header, log *ethgo.Log, dbTx *bolt.Tx) error { - var transferEvent contractsapi.TransferEvent + var ( + stakeAddedEvent contractsapi.StakeAddedEvent + stakeRemovedEvent contractsapi.StakeRemovedEvent + stakeEvents = make([]contractsapi.EventAbi, 1) + ) + + switch log.Topics[0] { + case stakeAddedEvent.Sig(): + doesMatch, err := stakeAddedEvent.ParseLog(log) + if err != nil { + return err + } - doesMatch, err := transferEvent.ParseLog(log) - if err != nil { - return err - } + if !doesMatch { + return nil + } - if !doesMatch { - return nil + stakeEvents[0] = &stakeAddedEvent + case stakeRemovedEvent.Sig(): + doesMatch, err := stakeRemovedEvent.ParseLog(log) + if err != nil { + return err + } + + if !doesMatch { + return nil + } + + stakeEvents[0] = &stakeRemovedEvent + default: + return errUnknownStakeManagerEvent } fullValidatorSet, err := s.getOrInitValidatorSet(dbTx) @@ -412,8 +444,7 @@ func (s *stakeManager) ProcessLog(header *types.Header, log *ethgo.Log, dbTx *bo return err } - if err := s.updateWithReceipts(&fullValidatorSet, - []*contractsapi.TransferEvent{&transferEvent}, header.Number); err != nil { + if err := s.updateWithReceipts(&fullValidatorSet, stakeEvents, header.Number); err != nil { return err } diff --git a/consensus/polybft/stake_manager_fuzz_test.go b/consensus/polybft/stake_manager_fuzz_test.go index e7286c9354..a7c3fdfd49 100644 --- a/consensus/polybft/stake_manager_fuzz_test.go +++ b/consensus/polybft/stake_manager_fuzz_test.go @@ -111,9 +111,7 @@ func FuzzTestStakeManagerPostBlock(f *testing.F) { stakeManager, err := newStakeManager( hclog.NewNullLogger(), state, - nil, wallet.NewEcdsaSigner(validators.GetValidator("A").Key()), - validatorSetAddr, types.StringToAddress("0x0002"), bcMock, nil, @@ -123,11 +121,10 @@ func FuzzTestStakeManagerPostBlock(f *testing.F) { require.NoError(t, err) header := &types.Header{Number: data.BlockID} - require.NoError(t, stakeManager.ProcessLog(header, convertLog(createTestLogForTransferEvent( + require.NoError(t, stakeManager.ProcessLog(header, convertLog(createTestLogForStakeAddedEvent( t, validatorSetAddr, validators.GetValidator(initialSetAliases[data.ValidatorID]).Address(), - types.ZeroAddress, data.StakeValue, )), nil)) @@ -157,9 +154,8 @@ func FuzzTestStakeManagerUpdateValidatorSet(f *testing.F) { stakeManager, err := newStakeManager( hclog.NewNullLogger(), state, - nil, wallet.NewEcdsaSigner(validators.GetValidator("A").Key()), - types.StringToAddress("0x0001"), types.StringToAddress("0x0002"), + types.StringToAddress("0x0001"), bcMock, nil, 10, diff --git a/consensus/polybft/stake_manager_test.go b/consensus/polybft/stake_manager_test.go index 534cd88ca0..9ab3c07dd4 100644 --- a/consensus/polybft/stake_manager_test.go +++ b/consensus/polybft/stake_manager_test.go @@ -29,7 +29,7 @@ func TestStakeManager_PostBlock(t *testing.T) { newStake = uint64(100) firstValidator = uint64(0) secondValidator = uint64(1) - validatorSetAddr = types.StringToAddress("0x0001") + stakeManagerAddr = types.StringToAddress("0x0001") ) t.Run("PostBlock - unstake to zero", func(t *testing.T) { @@ -39,6 +39,7 @@ func TestStakeManager_PostBlock(t *testing.T) { bcMock := new(blockchainMock) bcMock.On("CurrentHeader").Return(&types.Header{Number: block - 1}, true).Once() + bcMock.On("GetStateProviderForBlock", mock.Anything).Return(nil).Times(len(allAliases)) validators := validator.NewTestValidatorsWithAliases(t, allAliases) @@ -51,9 +52,8 @@ func TestStakeManager_PostBlock(t *testing.T) { stakeManager, err := newStakeManager( hclog.NewNullLogger(), state, - nil, wallet.NewEcdsaSigner(validators.GetValidator("A").Key()), - validatorSetAddr, types.StringToAddress("0x0002"), + stakeManagerAddr, bcMock, nil, 5, @@ -63,11 +63,10 @@ func TestStakeManager_PostBlock(t *testing.T) { header := &types.Header{Number: block} - require.NoError(t, stakeManager.ProcessLog(header, convertLog(createTestLogForTransferEvent( + require.NoError(t, stakeManager.ProcessLog(header, convertLog(createTestLogForStakeRemovedEvent( t, - validatorSetAddr, + stakeManagerAddr, validators.GetValidator(initialSetAliases[firstValidator]).Address(), - types.ZeroAddress, 1, // initial validator stake was 1 )), nil)) @@ -110,9 +109,8 @@ func TestStakeManager_PostBlock(t *testing.T) { stakeManager, err := newStakeManager( hclog.NewNullLogger(), state, - nil, wallet.NewEcdsaSigner(validators.GetValidator("A").Key()), - types.StringToAddress("0x0001"), types.StringToAddress("0x0002"), + types.StringToAddress("0x0001"), bcMock, nil, 5, @@ -121,10 +119,9 @@ func TestStakeManager_PostBlock(t *testing.T) { require.NoError(t, err) header := &types.Header{Number: block} - require.NoError(t, stakeManager.ProcessLog(header, convertLog(createTestLogForTransferEvent( + require.NoError(t, stakeManager.ProcessLog(header, convertLog(createTestLogForStakeAddedEvent( t, - validatorSetAddr, - types.ZeroAddress, + stakeManagerAddr, validators.GetValidator(initialSetAliases[secondValidator]).Address(), 250, )), nil)) @@ -166,7 +163,8 @@ func TestStakeManager_PostBlock(t *testing.T) { Return(nil, error(nil)) bcMock := new(blockchainMock) - bcMock.On("CurrentHeader").Return(&types.Header{Number: block - 1}, true).Once() + bcMock.On("CurrentHeader").Return(&types.Header{Number: block - 1}, true) + bcMock.On("GetStateProviderForBlock", mock.Anything).Return(nil).Times(len(allAliases)) // insert initial full validator set require.NoError(t, state.StakeStore.insertFullValidatorSet(validatorSetState{ @@ -177,9 +175,8 @@ func TestStakeManager_PostBlock(t *testing.T) { stakeManager, err := newStakeManager( hclog.NewNullLogger(), state, - txRelayerMock, wallet.NewEcdsaSigner(validators.GetValidator("A").Key()), - types.StringToAddress("0x0001"), types.StringToAddress("0x0002"), + types.StringToAddress("0x0001"), bcMock, nil, 5, @@ -190,10 +187,9 @@ func TestStakeManager_PostBlock(t *testing.T) { header := &types.Header{Number: block} for i := 0; i < len(allAliases); i++ { - require.NoError(t, stakeManager.ProcessLog(header, convertLog(createTestLogForTransferEvent( + require.NoError(t, stakeManager.ProcessLog(header, convertLog(createTestLogForStakeAddedEvent( t, - validatorSetAddr, - types.ZeroAddress, + stakeManagerAddr, validators.GetValidator(allAliases[i]).Address(), newStake, )), nil)) @@ -237,9 +233,8 @@ func TestStakeManager_UpdateValidatorSet(t *testing.T) { stakeManager, err := newStakeManager( hclog.NewNullLogger(), state, - nil, wallet.NewEcdsaSigner(validators.GetValidator("A").Key()), - types.StringToAddress("0x0001"), types.StringToAddress("0x0002"), + types.StringToAddress("0x0001"), bcMock, nil, 10, @@ -411,7 +406,7 @@ func TestStakeManager_UpdateOnInit(t *testing.T) { var ( allAliases = []string{"A", "B", "C", "D", "E", "F"} - validatorSetAddr = types.StringToAddress("0xf001") + stakeManagerAddr = types.StringToAddress("0xf001") epochID = uint64(120) ) @@ -446,10 +441,9 @@ func TestStakeManager_UpdateOnInit(t *testing.T) { { Status: &success, Logs: []*types.Log{ - createTestLogForTransferEvent( + createTestLogForStakeAddedEvent( t, - validatorSetAddr, - types.ZeroAddress, + stakeManagerAddr, addresses[len(addresses)-2], 4, ), @@ -460,10 +454,9 @@ func TestStakeManager_UpdateOnInit(t *testing.T) { { Status: &success, Logs: []*types.Log{ - createTestLogForTransferEvent( + createTestLogForStakeAddedEvent( t, - validatorSetAddr, - types.ZeroAddress, + stakeManagerAddr, addresses[len(addresses)-1], 6, ), @@ -475,9 +468,8 @@ func TestStakeManager_UpdateOnInit(t *testing.T) { _, err := newStakeManager( hclog.NewNullLogger(), state, - nil, wallet.NewEcdsaSigner(validators.GetValidator("A").Key()), - validatorSetAddr, types.StringToAddress("0x0002"), + stakeManagerAddr, bcMock, polyBackendMock, 5, @@ -506,15 +498,14 @@ func TestStakeManager_UpdateOnInit(t *testing.T) { } } -func createTestLogForTransferEvent(t *testing.T, validatorSet, from, to types.Address, stake uint64) *types.Log { +func createTestLogForStakeAddedEvent(t *testing.T, validatorSet, to types.Address, stake uint64) *types.Log { t.Helper() - var transferEvent contractsapi.TransferEvent + var stakeAddedEvent contractsapi.StakeAddedEvent - topics := make([]types.Hash, 3) - topics[0] = types.Hash(transferEvent.Sig()) - topics[1] = types.BytesToHash(from.Bytes()) - topics[2] = types.BytesToHash(to.Bytes()) + topics := make([]types.Hash, 2) + topics[0] = types.Hash(stakeAddedEvent.Sig()) + topics[1] = types.BytesToHash(to.Bytes()) encodedData, err := abi.MustNewType("uint256").Encode(new(big.Int).SetUint64(stake)) require.NoError(t, err) @@ -525,6 +516,24 @@ func createTestLogForTransferEvent(t *testing.T, validatorSet, from, to types.Ad } } +func createTestLogForStakeRemovedEvent(t *testing.T, validatorSet, to types.Address, unstake uint64) *types.Log { + t.Helper() + + var stakeRemovedEvent contractsapi.StakeRemovedEvent + + topics := make([]types.Hash, 2) + topics[0] = types.Hash(stakeRemovedEvent.Sig()) + topics[1] = types.BytesToHash(to.Bytes()) + encodedData, err := abi.MustNewType("uint256").Encode(new(big.Int).SetUint64(unstake)) + require.NoError(t, err) + + return &types.Log{ + Address: validatorSet, + Topics: topics, + Data: encodedData, + } +} + var _ txrelayer.TxRelayer = (*dummyStakeTxRelayer)(nil) type dummyStakeTxRelayer struct { diff --git a/consensus/polybft/state_event_getter_test.go b/consensus/polybft/state_event_getter_test.go index 5001f02e02..066f980909 100644 --- a/consensus/polybft/state_event_getter_test.go +++ b/consensus/polybft/state_event_getter_test.go @@ -14,7 +14,7 @@ import ( func TestEventDBInsertRetry_GetEvents(t *testing.T) { receipt := &types.Receipt{ Logs: []*types.Log{ - createTestLogForTransferEvent(t, contracts.ValidatorSetContract, types.ZeroAddress, types.ZeroAddress, 10), + createTestLogForStakeAddedEvent(t, contracts.EpochManagerContract, types.ZeroAddress, 10), }, } receipt.SetStatus(types.ReceiptSuccess) @@ -25,15 +25,15 @@ func TestEventDBInsertRetry_GetEvents(t *testing.T) { }, true) backend.On("GetReceiptsByHash", mock.Anything).Return([]*types.Receipt{receipt}, nil) - retryManager := &eventsGetter[*contractsapi.TransferEvent]{ + retryManager := &eventsGetter[*contractsapi.StakeAddedEvent]{ receiptsGetter: receiptsGetter{ blockchain: backend, }, isValidLogFn: func(l *types.Log) bool { - return l.Address == contracts.ValidatorSetContract + return l.Address == contracts.EpochManagerContract }, - parseEventFn: func(h *types.Header, l *ethgo.Log) (*contractsapi.TransferEvent, bool, error) { - var e contractsapi.TransferEvent + parseEventFn: func(h *types.Header, l *ethgo.Log) (*contractsapi.StakeAddedEvent, bool, error) { + var e contractsapi.StakeAddedEvent doesMatch, err := e.ParseLog(l) return &e, doesMatch, err diff --git a/consensus/polybft/state_sync_manager.go b/consensus/polybft/state_sync_manager.go index 89a2b20dd9..54fa79f157 100644 --- a/consensus/polybft/state_sync_manager.go +++ b/consensus/polybft/state_sync_manager.go @@ -1,7 +1,6 @@ package polybft import ( - "context" "encoding/hex" "encoding/json" "errors" @@ -17,6 +16,7 @@ import ( "google.golang.org/protobuf/proto" "github.com/0xPolygon/polygon-edge/bls" + "github.com/0xPolygon/polygon-edge/consensus" "github.com/0xPolygon/polygon-edge/consensus/polybft/bitmap" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" polybftProto "github.com/0xPolygon/polygon-edge/consensus/polybft/proto" @@ -24,8 +24,9 @@ import ( "github.com/0xPolygon/polygon-edge/consensus/polybft/validator" "github.com/0xPolygon/polygon-edge/consensus/polybft/wallet" "github.com/0xPolygon/polygon-edge/contracts" - "github.com/0xPolygon/polygon-edge/tracker" "github.com/0xPolygon/polygon-edge/types" + "github.com/Ethernal-Tech/blockchain-event-tracker/store" + "github.com/Ethernal-Tech/blockchain-event-tracker/tracker" ) type Runtime interface { @@ -73,17 +74,23 @@ func (d *dummyStateSyncManager) ProcessLog(header *types.Header, return nil } +type eventTrackerConfig struct { + consensus.EventTracker + + jsonrpcAddr string + stateSenderAddr types.Address + stateSenderStartBlock uint64 + trackerPollInterval time.Duration +} + // stateSyncConfig holds the configuration data of state sync manager type stateSyncConfig struct { - stateSenderAddr types.Address - stateSenderStartBlock uint64 - jsonrpcAddr string - dataDir string - topic topic - key *wallet.Key - maxCommitmentSize uint64 - numBlockConfirmations uint64 - blockTrackerPollInterval time.Duration + dataDir string + topic topic + key *wallet.Key + maxCommitmentSize uint64 + + eventTrackerConfig *eventTrackerConfig } var _ StateSyncManager = (*stateSyncManager)(nil) @@ -144,24 +151,38 @@ func (s *stateSyncManager) Close() { // initTracker starts a new event tracker (to receive new state sync events) func (s *stateSyncManager) initTracker() error { - ctx, cancelFn := context.WithCancel(context.Background()) - - evtTracker := tracker.NewEventTracker( - path.Join(s.config.dataDir, "/deposit.db"), - s.config.jsonrpcAddr, - ethgo.Address(s.config.stateSenderAddr), - s, - s.config.numBlockConfirmations, - s.config.stateSenderStartBlock, - s.logger, - s.config.blockTrackerPollInterval) + var stateSyncEvent contractsapi.StateSyncedEvent + + store, err := store.NewBoltDBEventTrackerStore(path.Join(s.config.dataDir, "/deposit.db")) + if err != nil { + return err + } + + eventTracker, err := tracker.NewEventTracker( + &tracker.EventTrackerConfig{ + EventSubscriber: s, + Logger: s.logger, + RPCEndpoint: s.config.eventTrackerConfig.jsonrpcAddr, + SyncBatchSize: s.config.eventTrackerConfig.EventTracker.SyncBatchSize, + NumBlockConfirmations: s.config.eventTrackerConfig.EventTracker.NumBlockConfirmations, + NumOfBlocksToReconcile: s.config.eventTrackerConfig.EventTracker.NumOfBlocksToReconcile, + PollInterval: s.config.eventTrackerConfig.trackerPollInterval, + LogFilter: map[ethgo.Address][]ethgo.Hash{ + ethgo.Address(s.config.eventTrackerConfig.stateSenderAddr): {stateSyncEvent.Sig()}, + }, + }, + store, s.config.eventTrackerConfig.stateSenderStartBlock, + ) + + if err != nil { + return err + } go func() { <-s.closeCh - cancelFn() }() - return evtTracker.Start(ctx) + return eventTracker.Start() } // initTransport subscribes to bridge topics (getting votes for commitments) diff --git a/consensus/polybft/state_sync_manager_test.go b/consensus/polybft/state_sync_manager_test.go index 67a8a0fa43..f4ba7b4e72 100644 --- a/consensus/polybft/state_sync_manager_test.go +++ b/consensus/polybft/state_sync_manager_test.go @@ -5,14 +5,12 @@ import ( "math/rand" "os" "testing" - "time" "github.com/hashicorp/go-hclog" "github.com/libp2p/go-libp2p/core/peer" "github.com/stretchr/testify/require" "github.com/umbracle/ethgo" "github.com/umbracle/ethgo/abi" - "github.com/umbracle/ethgo/testutil" "google.golang.org/protobuf/proto" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" @@ -37,8 +35,10 @@ func newTestStateSyncManager(t *testing.T, key *validator.TestValidator, runtime s := newStateSyncManager(hclog.NewNullLogger(), state, &stateSyncConfig{ - stateSenderAddr: types.Address{}, - jsonrpcAddr: "", + eventTrackerConfig: &eventTrackerConfig{ + stateSenderAddr: types.Address{}, + jsonrpcAddr: "", + }, dataDir: tmpDir, topic: topic, key: key.Key(), @@ -476,49 +476,6 @@ func TestStateSyncerManager_AddLog_BuildCommitments(t *testing.T) { }) } -func TestStateSyncerManager_EventTracker_Sync(t *testing.T) { - t.Parallel() - - vals := validator.NewTestValidators(t, 5) - s := newTestStateSyncManager(t, vals.GetValidator("0"), &mockRuntime{isActiveValidator: true}) - - server := testutil.DeployTestServer(t, nil) - - // Deploy contract - contractReceipt, err := server.SendTxn(ðgo.Transaction{ - Input: contractsapi.StateSender.Bytecode, - }) - require.NoError(t, err) - - // Create contract function call payload - encodedSyncStateData, err := (&contractsapi.SyncStateStateSenderFn{ - Receiver: types.BytesToAddress(server.Account(0).Bytes()), - Data: []byte{}, - }).EncodeAbi() - require.NoError(t, err) - - // prefill with 10 events - for i := 0; i < 10; i++ { - receipt, err := server.SendTxn(ðgo.Transaction{ - To: &contractReceipt.ContractAddress, - Input: encodedSyncStateData, - }) - require.NoError(t, err) - require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) - } - - s.config.stateSenderAddr = types.Address(contractReceipt.ContractAddress) - s.config.jsonrpcAddr = server.HTTPAddr() - - require.NoError(t, s.initTracker()) - - time.Sleep(2 * time.Second) - - events, err := s.state.StateSyncStore.getStateSyncEventsForCommitment(1, 10, nil) - require.NoError(t, err) - require.Len(t, events, 10) -} - func TestStateSyncManager_Close(t *testing.T) { t.Parallel() diff --git a/consensus/polybft/state_sync_relayer.go b/consensus/polybft/state_sync_relayer.go index 8c38a5ed94..158dbed878 100644 --- a/consensus/polybft/state_sync_relayer.go +++ b/consensus/polybft/state_sync_relayer.go @@ -28,7 +28,7 @@ const ( var ( errFailedToExecuteStateSync = errors.New("failed to execute state sync") - errUnknownStateSyncRelayerEvent = errors.New("unknown event") + errUnknownStateSyncRelayerEvent = errors.New("unknown event from state receiver contract") commitmentEventSignature = new(contractsapi.NewCommitmentEvent).Sig() stateSyncResultEventSignature = new(contractsapi.StateSyncResultEvent).Sig() diff --git a/consensus/polybft/state_transaction.go b/consensus/polybft/state_transaction.go index 0d98d3faf4..cb84469256 100644 --- a/consensus/polybft/state_transaction.go +++ b/consensus/polybft/state_transaction.go @@ -17,21 +17,21 @@ func decodeStateTransaction(txData []byte) (contractsapi.StateTransactionInput, sig := txData[:abiMethodIDLength] var ( - commitFn contractsapi.CommitStateReceiverFn - commitEpochFn contractsapi.CommitEpochValidatorSetFn - distributeRewardsFn contractsapi.DistributeRewardForRewardPoolFn + commitBridgeTxFn contractsapi.CommitStateReceiverFn + commitEpochFn contractsapi.CommitEpochEpochManagerFn + distributeRewardsFn contractsapi.DistributeRewardForEpochManagerFn obj contractsapi.StateTransactionInput ) - if bytes.Equal(sig, commitFn.Sig()) { + if bytes.Equal(sig, commitBridgeTxFn.Sig()) { // bridge commitment obj = &CommitmentMessageSigned{} } else if bytes.Equal(sig, commitEpochFn.Sig()) { // commit epoch - obj = &contractsapi.CommitEpochValidatorSetFn{} + obj = &contractsapi.CommitEpochEpochManagerFn{} } else if bytes.Equal(sig, distributeRewardsFn.Sig()) { // distribute rewards - obj = &contractsapi.DistributeRewardForRewardPoolFn{} + obj = &contractsapi.DistributeRewardForEpochManagerFn{} } else { return nil, fmt.Errorf("unknown state transaction") } diff --git a/consensus/polybft/state_transaction_test.go b/consensus/polybft/state_transaction_test.go index 78129342e9..7865083a7a 100644 --- a/consensus/polybft/state_transaction_test.go +++ b/consensus/polybft/state_transaction_test.go @@ -21,7 +21,7 @@ func TestStateTransaction_Signature(t *testing.T) { sig string }{ { - contractsapi.ValidatorSet.Abi.GetMethod("commitEpoch"), + contractsapi.EpochManager.Abi.GetMethod("commitEpoch"), "0f50287c", }, } @@ -35,7 +35,7 @@ func TestStateTransaction_Encoding(t *testing.T) { t.Parallel() cases := []contractsapi.StateTransactionInput{ - &contractsapi.CommitEpochValidatorSetFn{ + &contractsapi.CommitEpochEpochManagerFn{ ID: big.NewInt(1), Epoch: &contractsapi.Epoch{ StartBlock: big.NewInt(1), diff --git a/consensus/polybft/system_state.go b/consensus/polybft/system_state.go index e0f8ea07b9..86bfd684e9 100644 --- a/consensus/polybft/system_state.go +++ b/consensus/polybft/system_state.go @@ -41,7 +41,7 @@ func NewSystemState(valSetAddr types.Address, stateRcvAddr types.Address, provid s := &SystemStateImpl{} s.validatorContract = contract.NewContract( ethgo.Address(valSetAddr), - contractsapi.ValidatorSet.Abi, contract.WithProvider(provider), + contractsapi.EpochManager.Abi, contract.WithProvider(provider), ) s.sidechainBridgeContract = contract.NewContract( ethgo.Address(stateRcvAddr), diff --git a/consensus/polybft/system_state_test.go b/consensus/polybft/system_state_test.go index 04dc1cd615..ea001fe48b 100644 --- a/consensus/polybft/system_state_test.go +++ b/consensus/polybft/system_state_test.go @@ -52,7 +52,7 @@ func TestSystemState_GetNextCommittedIndex(t *testing.T) { transition: transition, } - systemState := NewSystemState(contracts.ValidatorSetContract, result.Address, provider) + systemState := NewSystemState(contracts.EpochManagerContract, result.Address, provider) expectedNextCommittedIndex := uint64(45) input, err := sideChainBridgeABI.Encode([1]interface{}{expectedNextCommittedIndex}) diff --git a/consensus/polybft/validator/validator_set.go b/consensus/polybft/validator/validator_set.go index 47f6e8c393..7e935f8523 100644 --- a/consensus/polybft/validator/validator_set.go +++ b/consensus/polybft/validator/validator_set.go @@ -3,9 +3,6 @@ package validator import ( "math/big" - "github.com/0xPolygon/polygon-edge/chain" - "github.com/0xPolygon/polygon-edge/forkmanager" - "github.com/0xPolygon/polygon-edge/helper/common" "github.com/0xPolygon/polygon-edge/types" "github.com/hashicorp/go-hclog" ) @@ -112,10 +109,5 @@ func getQuorumSize(blockNumber uint64, totalVotingPower *big.Int) *big.Int { quorum := new(big.Int) quorum.Mul(totalVotingPower, big.NewInt(2)) - if forkmanager.GetInstance().IsForkEnabled(chain.QuorumCalcAlignment, blockNumber) { - // this will floor the 2 * totalVotingPower / 3 and add one to it - return quorum.Div(quorum, big.NewInt(3)).Add(quorum, big.NewInt(1)) - } - - return common.BigIntDivCeil(quorum, big.NewInt(3)) + return quorum.Div(quorum, big.NewInt(3)).Add(quorum, big.NewInt(1)) } diff --git a/consensus/polybft/validator/validator_set_test.go b/consensus/polybft/validator/validator_set_test.go index 537a77dce6..82d18bff82 100644 --- a/consensus/polybft/validator/validator_set_test.go +++ b/consensus/polybft/validator/validator_set_test.go @@ -40,7 +40,7 @@ func TestValidatorSet_getQuorumSize(t *testing.T) { expectedQuorumSize int64 }{ {10, 7}, - {12, 8}, + {12, 9}, {13, 9}, {50, 34}, {100, 67}, diff --git a/contracts/system_addresses.go b/contracts/system_addresses.go index fe523f0843..a308c33190 100644 --- a/contracts/system_addresses.go +++ b/contracts/system_addresses.go @@ -3,10 +3,10 @@ package contracts import "github.com/0xPolygon/polygon-edge/types" var ( - // ValidatorSetContract is an address of validator set proxy contract deployed to child chain - ValidatorSetContract = types.StringToAddress("0x101") - // ValidatorSetContractV1 is an address of validator set implementation contract deployed to child chain - ValidatorSetContractV1 = types.StringToAddress("0x1011") + // EpochManagerContract is an address of validator set proxy contract deployed to child chain + EpochManagerContract = types.StringToAddress("0x101") + // EpochManagerContractV1 is an address of validator set implementation contract deployed to child chain + EpochManagerContractV1 = types.StringToAddress("0x1011") // BLSContract is an address of BLS proxy contract on the child chain BLSContract = types.StringToAddress("0x102") // BLSContractV1 is an address of BLS contract on the child chain @@ -19,10 +19,6 @@ var ( RewardTokenContract = types.StringToAddress("0x104") // RewardTokenContractV1 is an address of reward token on child chain RewardTokenContractV1 = types.StringToAddress("0x1041") - // RewardPoolContract is an address of RewardPoolContract proxy contract on the child chain - RewardPoolContract = types.StringToAddress("0x105") - // RewardPoolContractV1 is an address of RewardPoolContract contract on the child chain - RewardPoolContractV1 = types.StringToAddress("0x1051") // DefaultBurnContract is an address of eip1559 default proxy contract DefaultBurnContract = types.StringToAddress("0x106") // StateReceiverContract is an address of bridge proxy contract on the child chain @@ -39,6 +35,10 @@ var ( L2StateSenderContract = types.StringToAddress("0x1002") // L2StateSenderContractV1 is an address of bridge contract to the rootchain L2StateSenderContractV1 = types.StringToAddress("0x10021") + // StakeManagerContract is an address of stake manager proxy contract on child chain + StakeManagerContract = types.StringToAddress("0x10022") + // StakeManagerContract is an address of stake manager contract on child chain + StakeManagerContractV1 = types.StringToAddress("0x100221") // ChildERC20Contract is an address of bridgable ERC20 token contract on the child chain ChildERC20Contract = types.StringToAddress("0x1003") @@ -92,6 +92,8 @@ var ( AllowListBridgeAddr = types.StringToAddress("0x0200000000000000000000000000000000000004") // BlockListBridgeAddr is the address of the bridge block list BlockListBridgeAddr = types.StringToAddress("0x0300000000000000000000000000000000000004") + + ERC20Contract = types.StringToAddress("0x2040") ) // GetProxyImplementationMapping retrieves the addresses of proxy contracts that should be deployed unconditionally @@ -101,8 +103,8 @@ func GetProxyImplementationMapping() map[types.Address]types.Address { BLSContract: BLSContractV1, MerkleContract: MerkleContractV1, L2StateSenderContract: L2StateSenderContractV1, - ValidatorSetContract: ValidatorSetContractV1, - RewardPoolContract: RewardPoolContractV1, + EpochManagerContract: EpochManagerContractV1, + StakeManagerContract: StakeManagerContractV1, NativeERC20TokenContract: NativeERC20TokenContractV1, ChildERC20PredicateContract: ChildERC20PredicateContractV1, ChildERC721PredicateContract: ChildERC721PredicateContractV1, diff --git a/core-contracts b/core-contracts deleted file mode 160000 index 813c1b811d..0000000000 --- a/core-contracts +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 813c1b811d3cd5e7d52fa85bc7d4ce9f77d8227a diff --git a/docker/local/Dockerfile b/docker/local/Dockerfile index 0ee5db16e7..05b3b5b91b 100644 --- a/docker/local/Dockerfile +++ b/docker/local/Dockerfile @@ -2,7 +2,7 @@ FROM golang:1.20-alpine AS builder RUN apk add make git -WORKDIR /polygon-edge +WORKDIR /blade ADD go.mod go.sum ./ RUN go mod download @@ -15,12 +15,12 @@ FROM alpine:latest AS runner RUN apk --no-cache add ca-certificates jq -WORKDIR /polygon-edge +WORKDIR /blade -COPY --from=builder /polygon-edge/polygon-edge ./ -COPY ./docker/local/polygon-edge.sh ./ +COPY --from=builder /blade/blade ./ +COPY ./docker/local/blade.sh ./ # Expose json-rpc, libp2p and grpc ports EXPOSE 8545 9632 1478 5001 -ENTRYPOINT ["./polygon-edge.sh"] +ENTRYPOINT ["./blade.sh"] diff --git a/docker/local/blade.sh b/docker/local/blade.sh new file mode 100755 index 0000000000..386604e781 --- /dev/null +++ b/docker/local/blade.sh @@ -0,0 +1,91 @@ +#!/bin/sh + +set -e + +BLADE_BIN=./blade +CHAIN_CUSTOM_OPTIONS=$(tr "\n" " " << EOL +--block-gas-limit 10000000 +--epoch-size 10 +--chain-id 51001 +--name Blade +--premine 0x0000000000000000000000000000000000000000 +--premine 0x228466F2C715CbEC05dEAbfAc040ce3619d7CF0B:0xD3C21BCECCEDA1000000 +--premine 0xca48694ebcB2548dF5030372BE4dAad694ef174e:0xD3C21BCECCEDA1000000 +EOL +) + +# createGenesisConfig creates genesis configuration +createGenesisConfig() { + local consensus_type="$1" + local secrets="$2" + shift 2 + echo "Generating $consensus_type Genesis file..." + + "$BLADE_BIN" genesis $CHAIN_CUSTOM_OPTIONS \ + --dir /data/genesis.json \ + --validators-path /data \ + --validators-prefix data- \ + --consensus $consensus_type \ + --bootnode "/dns4/node-1/tcp/1478/p2p/$(echo "$secrets" | jq -r '.[0] | .node_id')" \ + --bootnode "/dns4/node-2/tcp/1478/p2p/$(echo "$secrets" | jq -r '.[1] | .node_id')" \ + --bootnode "/dns4/node-3/tcp/1478/p2p/$(echo "$secrets" | jq -r '.[2] | .node_id')" \ + --bootnode "/dns4/node-4/tcp/1478/p2p/$(echo "$secrets" | jq -r '.[3] | .node_id')" \ + "$@" +} + +case "$1" in + "init") + case "$2" in + "polybft") + echo "Generating PolyBFT secrets..." + secrets=$("$BLADE_BIN" secrets init --insecure --num 4 --data-dir /data/data- --json) + echo "Secrets have been successfully generated" + + rm -f /data/genesis.json + + proxyContractsAdmin=0x5aaeb6053f3e94c9b9a09f33669435e7ef1beaed + + createGenesisConfig "$2" "$secrets" \ + --reward-wallet 0xDEADBEEF:1000000 \ + --native-token-config "Polygon:MATIC:18" \ + --blade-admin $(echo "$secrets" | jq -r '.[0] | .address') \ + --proxy-contracts-admin ${proxyContractsAdmin} + + "$BLADE_BIN" bridge deploy \ + --json-rpc http://rootchain:8545 \ + --genesis /data/genesis.json \ + --proxy-contracts-admin ${proxyContractsAdmin} \ + --test + + addresses="$(echo "$secrets" | jq -r '.[0] | .address'),$(echo "$secrets" | jq -r '.[1] | .address'),$(echo "$secrets" | jq -r '.[2] | .address'),$(echo "$secrets" | jq -r '.[3] | .address')" + + "$BLADE_BIN" bridge fund \ + --json-rpc http://rootchain:8545 \ + --addresses ${addresses} \ + --amounts 1000000000000000000000000,1000000000000000000000000,1000000000000000000000000,1000000000000000000000000 + + ;; + esac + ;; + "start-node-1") + relayer_flag="" + # Start relayer only when run in polybft + if [ "$2" == "polybft" ]; then + echo "Starting relayer..." + relayer_flag="--relayer" + fi + + "$BLADE_BIN" server \ + --data-dir /data/data-1 \ + --chain /data/genesis.json \ + --grpc-address 0.0.0.0:9632 \ + --libp2p 0.0.0.0:1478 \ + --jsonrpc 0.0.0.0:8545 \ + --prometheus 0.0.0.0:5001 \ + $relayer_flag + ;; + *) + echo "Executing blade..." + exec "$BLADE_BIN" "$@" + ;; +esac diff --git a/docker/local/docker-compose.yml b/docker/local/docker-compose.yml index ac8ee69cb7..be2dea236c 100644 --- a/docker/local/docker-compose.yml +++ b/docker/local/docker-compose.yml @@ -4,7 +4,7 @@ services: ## RUN ROOTCHAIN rootchain: image: ghcr.io/0xpolygon/go-ethereum-console:latest - container_name: polygon-edge-rootchain + container_name: blade-rootchain command: [ "--dev", "--dev.period", "2", @@ -22,15 +22,15 @@ services: volumes: - eth1data:/eth1data networks: - - polygon-edge-docker + - blade-docker-network ## INITIALIZE GENESIS AND SECRETS, ETC. init: build: context: ../../ dockerfile: docker/local/Dockerfile - image: local/polygon-edge - container_name: polygon-edge-bootstrapper + image: local/blade + container_name: blade-bootstrapper command: [ "init", "${EDGE_CONSENSUS:-polybft}" ] depends_on: rootchain: @@ -38,12 +38,12 @@ services: volumes: - data:/data networks: - - polygon-edge-docker + - blade-docker-network ## RUN NODES node-1: - image: local/polygon-edge - container_name: polygon-edge-validator-1 + image: local/blade + container_name: blade-validator-1 command: [ "start-node-1", "${EDGE_CONSENSUS:-polybft}" ] depends_on: init: @@ -57,12 +57,12 @@ services: volumes: - data:/data networks: - - polygon-edge-docker + - blade-docker-network restart: on-failure node-2: - image: local/polygon-edge - container_name: polygon-edge-validator-2 + image: local/blade + container_name: blade-validator-2 command: [ "server", "--data-dir", @@ -86,12 +86,12 @@ services: volumes: - data:/data networks: - - polygon-edge-docker + - blade-docker-network restart: on-failure node-3: - image: local/polygon-edge - container_name: polygon-edge-validator-3 + image: local/blade + container_name: blade-validator-3 command: [ "server", "--data-dir", "/data/data-3", @@ -114,12 +114,12 @@ services: volumes: - data:/data networks: - - polygon-edge-docker + - blade-docker-network restart: on-failure node-4: - image: local/polygon-edge - container_name: polygon-edge-validator-4 + image: local/blade + container_name: blade-validator-4 command: [ "server", "--data-dir", "/data/data-4", @@ -142,13 +142,13 @@ services: volumes: - data:/data networks: - - polygon-edge-docker + - blade-docker-network restart: on-failure networks: - polygon-edge-docker: + blade-docker-network: driver: bridge - name: polygon-edge-docker + name: blade-docker-network volumes: data: diff --git a/docker/local/polygon-edge.sh b/docker/local/polygon-edge.sh deleted file mode 100755 index 6085642d5f..0000000000 --- a/docker/local/polygon-edge.sh +++ /dev/null @@ -1,140 +0,0 @@ -#!/bin/sh - -set -e - -POLYGON_EDGE_BIN=./polygon-edge -CHAIN_CUSTOM_OPTIONS=$(tr "\n" " " << EOL ---block-gas-limit 10000000 ---epoch-size 10 ---chain-id 51001 ---name polygon-edge-docker ---premine 0x0000000000000000000000000000000000000000 ---premine 0x228466F2C715CbEC05dEAbfAc040ce3619d7CF0B:0xD3C21BCECCEDA1000000 ---premine 0xca48694ebcB2548dF5030372BE4dAad694ef174e:0xD3C21BCECCEDA1000000 ---burn-contract 0:0x0000000000000000000000000000000000000000 -EOL -) - -# createGenesisConfig creates genesis configuration -createGenesisConfig() { - local consensus_type="$1" - local secrets="$2" - shift 2 - echo "Generating $consensus_type Genesis file..." - - "$POLYGON_EDGE_BIN" genesis $CHAIN_CUSTOM_OPTIONS \ - --dir /data/genesis.json \ - --validators-path /data \ - --validators-prefix data- \ - --consensus $consensus_type \ - --bootnode "/dns4/node-1/tcp/1478/p2p/$(echo "$secrets" | jq -r '.[0] | .node_id')" \ - --bootnode "/dns4/node-2/tcp/1478/p2p/$(echo "$secrets" | jq -r '.[1] | .node_id')" \ - --bootnode "/dns4/node-3/tcp/1478/p2p/$(echo "$secrets" | jq -r '.[2] | .node_id')" \ - --bootnode "/dns4/node-4/tcp/1478/p2p/$(echo "$secrets" | jq -r '.[3] | .node_id')" \ - "$@" -} - -case "$1" in - "init") - case "$2" in - "polybft") - echo "Generating PolyBFT secrets..." - secrets=$("$POLYGON_EDGE_BIN" secrets init --insecure --num 4 --data-dir /data/data- --json) - echo "Secrets have been successfully generated" - - rm -f /data/genesis.json - - proxyContractsAdmin=0x5aaeb6053f3e94c9b9a09f33669435e7ef1beaed - - createGenesisConfig "$2" "$secrets" \ - --reward-wallet 0xDEADBEEF:1000000 \ - --native-token-config "Polygon:MATIC:18:true:$(echo "$secrets" | jq -r '.[0] | .address')" \ - --proxy-contracts-admin ${proxyContractsAdmin} - - echo "Deploying stake manager..." - "$POLYGON_EDGE_BIN" polybft stake-manager-deploy \ - --jsonrpc http://rootchain:8545 \ - --genesis /data/genesis.json \ - --proxy-contracts-admin ${proxyContractsAdmin} \ - --test - - stakeManagerAddr=$(cat /data/genesis.json | jq -r '.params.engine.polybft.bridge.stakeManagerAddr') - stakeToken=$(cat /data/genesis.json | jq -r '.params.engine.polybft.bridge.stakeTokenAddr') - - "$POLYGON_EDGE_BIN" rootchain deploy \ - --stake-manager ${stakeManagerAddr} \ - --stake-token ${stakeToken} \ - --json-rpc http://rootchain:8545 \ - --genesis /data/genesis.json \ - --proxy-contracts-admin ${proxyContractsAdmin} \ - --test - - customSupernetManagerAddr=$(cat /data/genesis.json | jq -r '.params.engine.polybft.bridge.customSupernetManagerAddr') - supernetID=$(cat /data/genesis.json | jq -r '.params.engine.polybft.supernetID') - addresses="$(echo "$secrets" | jq -r '.[0] | .address'),$(echo "$secrets" | jq -r '.[1] | .address'),$(echo "$secrets" | jq -r '.[2] | .address'),$(echo "$secrets" | jq -r '.[3] | .address')" - - "$POLYGON_EDGE_BIN" rootchain fund \ - --json-rpc http://rootchain:8545 \ - --stake-token ${stakeToken} \ - --mint \ - --addresses ${addresses} \ - --amounts 1000000000000000000000000,1000000000000000000000000,1000000000000000000000000,1000000000000000000000000 - - "$POLYGON_EDGE_BIN" polybft whitelist-validators \ - --addresses ${addresses} \ - --supernet-manager ${customSupernetManagerAddr} \ - --private-key aa75e9a7d427efc732f8e4f1a5b7646adcc61fd5bae40f80d13c8419c9f43d6d \ - --jsonrpc http://rootchain:8545 - - counter=1 - while [ $counter -le 4 ]; do - echo "Registering validator: ${counter}" - - "$POLYGON_EDGE_BIN" polybft register-validator \ - --supernet-manager ${customSupernetManagerAddr} \ - --data-dir /data/data-${counter} \ - --jsonrpc http://rootchain:8545 - - "$POLYGON_EDGE_BIN" polybft stake \ - --data-dir /data/data-${counter} \ - --amount 1000000000000000000000000 \ - --supernet-id ${supernetID} \ - --stake-manager ${stakeManagerAddr} \ - --stake-token ${stakeToken} \ - --jsonrpc http://rootchain:8545 - - counter=$((counter + 1)) - done - - "$POLYGON_EDGE_BIN" polybft supernet \ - --private-key aa75e9a7d427efc732f8e4f1a5b7646adcc61fd5bae40f80d13c8419c9f43d6d \ - --supernet-manager ${customSupernetManagerAddr} \ - --finalize-genesis-set \ - --enable-staking \ - --genesis /data/genesis.json \ - --jsonrpc http://rootchain:8545 - ;; - esac - ;; - "start-node-1") - relayer_flag="" - # Start relayer only when run in polybft - if [ "$2" == "polybft" ]; then - echo "Starting relayer..." - relayer_flag="--relayer" - fi - - "$POLYGON_EDGE_BIN" server \ - --data-dir /data/data-1 \ - --chain /data/genesis.json \ - --grpc-address 0.0.0.0:9632 \ - --libp2p 0.0.0.0:1478 \ - --jsonrpc 0.0.0.0:8545 \ - --prometheus 0.0.0.0:5001 \ - $relayer_flag - ;; - *) - echo "Executing polygon-edge..." - exec "$POLYGON_EDGE_BIN" "$@" - ;; -esac diff --git a/e2e-polybft/e2e/acls_test.go b/e2e-polybft/e2e/acls_test.go index 5e841e1fb8..4d3b9d0490 100644 --- a/e2e-polybft/e2e/acls_test.go +++ b/e2e-polybft/e2e/acls_test.go @@ -1,7 +1,6 @@ package e2e import ( - "fmt" "math/big" "testing" @@ -44,7 +43,6 @@ func TestE2E_AllowList_ContractDeployment(t *testing.T) { otherAddr := types.Address{0x1} cluster := framework.NewTestCluster(t, 5, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, adminAddr)), framework.WithPremine(adminAddr, targetAddr), framework.WithContractDeployerAllowListAdmin(adminAddr), framework.WithContractDeployerAllowListEnabled(otherAddr), @@ -143,7 +141,6 @@ func TestE2E_BlockList_ContractDeployment(t *testing.T) { otherAddr := types.Address{0x1} cluster := framework.NewTestCluster(t, 5, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, adminAddr)), framework.WithPremine(adminAddr, targetAddr), framework.WithContractDeployerBlockListAdmin(adminAddr), framework.WithContractDeployerBlockListEnabled(otherAddr), @@ -227,7 +224,6 @@ func TestE2E_AllowList_Transactions(t *testing.T) { otherAddr := types.Address(other.Address()) cluster := framework.NewTestCluster(t, 5, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, adminAddr)), framework.WithPremine(adminAddr, targetAddr, otherAddr), framework.WithTransactionsAllowListAdmin(adminAddr), framework.WithTransactionsAllowListEnabled(otherAddr), @@ -321,7 +317,6 @@ func TestE2E_BlockList_Transactions(t *testing.T) { otherAddr := types.Address(other.Address()) cluster := framework.NewTestCluster(t, 5, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, adminAddr)), framework.WithPremine(adminAddr, targetAddr, otherAddr), framework.WithTransactionsBlockListAdmin(adminAddr), framework.WithTransactionsBlockListEnabled(otherAddr), @@ -392,8 +387,8 @@ func TestE2E_AddressLists_Bridge(t *testing.T) { otherAddr := types.Address(other.Address()) cluster := framework.NewTestCluster(t, 5, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, adminAddr)), framework.WithPremine(adminAddr, targetAddr, otherAddr), + framework.WithBridge(), framework.WithBridgeAllowListAdmin(adminAddr), framework.WithBridgeAllowListEnabled(otherAddr), framework.WithBridgeBlockListAdmin(adminAddr), diff --git a/e2e-polybft/e2e/bridge_test.go b/e2e-polybft/e2e/bridge_test.go index 98d1d720d9..de17722e45 100644 --- a/e2e-polybft/e2e/bridge_test.go +++ b/e2e-polybft/e2e/bridge_test.go @@ -13,11 +13,9 @@ import ( "github.com/umbracle/ethgo" "github.com/umbracle/ethgo/wallet" - "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/bridge/common" - "github.com/0xPolygon/polygon-edge/command/genesis" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" - "github.com/0xPolygon/polygon-edge/command/sidechain" + bridgeHelper "github.com/0xPolygon/polygon-edge/command/bridge/helper" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/contracts" @@ -32,16 +30,20 @@ const ( chainConfigFileName = "genesis.json" ) -func TestE2E_Bridge_Transfers(t *testing.T) { +func TestE2E_Bridge_RootchainTokensTransfers(t *testing.T) { const ( transfersCount = 5 - amount = 100 numBlockConfirmations = 2 // make epoch size long enough, so that all exit events are processed within the same epoch epochSize = 30 sprintSize = uint64(5) numberOfAttempts = 7 - stateSyncedLogsCount = 1 + stateSyncedLogsCount = 2 // map token and deposit + ) + + var ( + bridgeAmount = ethgo.Ether(2) + stateSyncedResult contractsapi.StateSyncResultEvent ) receiversAddrs := make([]types.Address, transfersCount) @@ -59,7 +61,7 @@ func TestE2E_Bridge_Transfers(t *testing.T) { receiverKeys[i] = hex.EncodeToString(rawKey) receiversAddrs[i] = types.Address(key.Address()) receivers[i] = types.Address(key.Address()).String() - amounts[i] = fmt.Sprintf("%d", amount) + amounts[i] = fmt.Sprintf("%d", bridgeAmount) t.Logf("Receiver#%d=%s\n", i+1, receivers[i]) } @@ -67,7 +69,15 @@ func TestE2E_Bridge_Transfers(t *testing.T) { cluster := framework.NewTestCluster(t, 5, framework.WithTestRewardToken(), framework.WithNumBlockConfirmations(numBlockConfirmations), - framework.WithEpochSize(epochSize)) + framework.WithEpochSize(epochSize), + framework.WithBridge(), + framework.WithSecretsCallback(func(addrs []types.Address, tcc *framework.TestClusterConfig) { + for i := 0; i < len(addrs); i++ { + tcc.StakeAmounts = append(tcc.StakeAmounts, ethgo.Ether(10)) + // premine receivers, so that they are able to do withdrawals + } + tcc.Premine = append(tcc.Premine, receivers...) + })) defer cluster.Stop() cluster.WaitForReady(t) @@ -76,107 +86,91 @@ func TestE2E_Bridge_Transfers(t *testing.T) { require.NoError(t, err) validatorSrv := cluster.Servers[0] - senderAccount, err := sidechain.GetAccountFromDir(validatorSrv.DataDir()) - require.NoError(t, err) childEthEndpoint := validatorSrv.JSONRPC().Eth() - // bridge some tokens for first validator to child chain - tokensToDeposit := ethgo.Ether(10) - - require.NoError(t, cluster.Bridge.Deposit( - common.ERC20, - polybftCfg.Bridge.RootNativeERC20Addr, - polybftCfg.Bridge.RootERC20PredicateAddr, - rootHelper.TestAccountPrivKey, - senderAccount.Address().String(), - tokensToDeposit.String(), - "", - cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, - false), - ) + rootchainTxRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) + require.NoError(t, err) - // wait for a couple of sprints - finalBlockNum := 5 * sprintSize - require.NoError(t, cluster.WaitForBlock(finalBlockNum, 2*time.Minute)) + txRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithClient(validatorSrv.JSONRPC())) + require.NoError(t, err) - // the transaction is processed and there should be a success event - var stateSyncedResult contractsapi.StateSyncResultEvent + deployerKey, err := bridgeHelper.DecodePrivateKey("") + require.NoError(t, err) - logs, err := getFilteredLogs(stateSyncedResult.Sig(), 0, finalBlockNum, childEthEndpoint) + receipt, err := rootchainTxRelayer.SendTransaction( + ðgo.Transaction{ + To: nil, + Input: contractsapi.RootERC20.Bytecode, + }, + deployerKey) require.NoError(t, err) + require.NotNil(t, receipt) + require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) - // assert that all deposits are executed successfully - checkStateSyncResultLogs(t, logs, stateSyncedLogsCount) + rootERC20Token := types.Address(receipt.ContractAddress) + t.Log("Rootchain token address:", rootERC20Token) - // check validator balance got increased by deposited amount - balance, err := childEthEndpoint.GetBalance(ethgo.Address(senderAccount.Address()), ethgo.Latest) - require.NoError(t, err) - // because we premined validators - expectedBalance := new(big.Int).Add(tokensToDeposit, command.DefaultPremineBalance) - require.Equal(t, expectedBalance, balance) + // wait for a couple of sprints + finalBlockNum := 1 * sprintSize + require.NoError(t, cluster.WaitForBlock(finalBlockNum, 2*time.Minute)) - t.Run("bridge ERC 20 tokens", func(t *testing.T) { + t.Run("bridge ERC20 tokens", func(t *testing.T) { // DEPOSIT ERC20 TOKENS // send a few transactions to the bridge - require.NoError(t, cluster.Bridge.Deposit( - common.ERC20, - polybftCfg.Bridge.RootNativeERC20Addr, - polybftCfg.Bridge.RootERC20PredicateAddr, - rootHelper.TestAccountPrivKey, - strings.Join(receivers[:], ","), - strings.Join(amounts[:], ","), - "", - cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, - false, - )) + require.NoError(t, + cluster.Bridge.Deposit( + common.ERC20, + rootERC20Token, + polybftCfg.Bridge.RootERC20PredicateAddr, + bridgeHelper.TestAccountPrivKey, + strings.Join(receivers[:], ","), + strings.Join(amounts[:], ","), + "", + cluster.Bridge.JSONRPCAddr(), + bridgeHelper.TestAccountPrivKey, + false, + )) finalBlockNum := 10 * sprintSize // wait for a couple of sprints require.NoError(t, cluster.WaitForBlock(finalBlockNum, 2*time.Minute)) - // the transactions are processed and there should be a success events + // the bridge transactions are processed and there should be a success state sync events logs, err := getFilteredLogs(stateSyncedResult.Sig(), 0, finalBlockNum, childEthEndpoint) require.NoError(t, err) // assert that all deposits are executed successfully - checkStateSyncResultLogs(t, logs, transfersCount+1) // because of the first deposit for the first validator + // because of the token mapping with the first deposit + checkStateSyncResultLogs(t, logs, transfersCount+1) + + // get child token address + childERC20Token := getChildToken(t, contractsapi.RootERC20Predicate.Abi, + polybftCfg.Bridge.RootERC20PredicateAddr, rootERC20Token, rootchainTxRelayer) // check receivers balances got increased by deposited amount for _, receiver := range receivers { - balance, err := childEthEndpoint.GetBalance(ethgo.Address(types.StringToAddress(receiver)), ethgo.Latest) - require.NoError(t, err) - require.Equal(t, big.NewInt(amount), balance) + balance := erc20BalanceOf(t, types.StringToAddress(receiver), childERC20Token, txRelayer) + require.Equal(t, bridgeAmount, balance) } t.Log("Deposits were successfully processed") // WITHDRAW ERC20 TOKENS - rootchainTxRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) - require.NoError(t, err) - - senderAccount, err := sidechain.GetAccountFromDir(validatorSrv.DataDir()) - require.NoError(t, err) - - t.Logf("Withdraw sender: %s\n", senderAccount.Ecdsa.Address()) - - rawKey, err := senderAccount.Ecdsa.MarshallPrivateKey() - require.NoError(t, err) - // send withdraw transaction - err = cluster.Bridge.Withdraw( - common.ERC20, - hex.EncodeToString(rawKey), - strings.Join(receivers[:], ","), - strings.Join(amounts[:], ","), - "", - validatorSrv.JSONRPCAddr(), - contracts.ChildERC20PredicateContract, - contracts.NativeERC20TokenContract, - false) - require.NoError(t, err) + for i, senderKey := range receiverKeys { + err = cluster.Bridge.Withdraw( + common.ERC20, + senderKey, + receivers[i], + amounts[i], + "", + validatorSrv.JSONRPCAddr(), + contracts.ChildERC20PredicateContract, + childERC20Token, + false) + require.NoError(t, err) + } currentBlock, err := childEthEndpoint.GetBlockByNumber(ethgo.Latest, false) require.NoError(t, err) @@ -232,9 +226,8 @@ func TestE2E_Bridge_Transfers(t *testing.T) { // assert that receiver's balances on RootERC20 smart contract are expected for _, receiver := range receivers { - balance := erc20BalanceOf(t, types.StringToAddress(receiver), - polybftCfg.Bridge.RootNativeERC20Addr, rootchainTxRelayer) - require.Equal(t, big.NewInt(amount), balance) + balance := erc20BalanceOf(t, types.StringToAddress(receiver), rootERC20Token, rootchainTxRelayer) + require.Equal(t, bridgeAmount, balance) } }) @@ -268,14 +261,14 @@ func TestE2E_Bridge_Transfers(t *testing.T) { // send two transactions to the bridge so that we have a minimal commitment require.NoError(t, cluster.Bridge.Deposit( common.ERC20, - polybftCfg.Bridge.RootNativeERC20Addr, + rootERC20Token, polybftCfg.Bridge.RootERC20PredicateAddr, - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, strings.Join(receivers[:depositsSubset], ","), strings.Join(amounts[:depositsSubset], ","), "", cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, false), ) @@ -295,14 +288,14 @@ func TestE2E_Bridge_Transfers(t *testing.T) { // send some more transactions to the bridge to build another commitment in epoch require.NoError(t, cluster.Bridge.Deposit( common.ERC20, - polybftCfg.Bridge.RootNativeERC20Addr, + rootERC20Token, polybftCfg.Bridge.RootERC20PredicateAddr, - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, strings.Join(receivers[depositsSubset:], ","), strings.Join(amounts[depositsSubset:], ","), "", cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, false), ) @@ -327,136 +320,6 @@ func TestE2E_Bridge_Transfers(t *testing.T) { // assert that all state syncs are executed successfully checkStateSyncResultLogs(t, logs, transfersCount) }) - - t.Run("non native ERC20 deposit and withdraw", func(t *testing.T) { - rootchainTxRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) - require.NoError(t, err) - - childchainTxRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithClient(validatorSrv.JSONRPC())) - require.NoError(t, err) - - // Deploy ERC20 contract to the rootchain - rootchainDeployer, err := rootHelper.DecodePrivateKey("") - require.NoError(t, err) - - txn := ðgo.Transaction{To: nil, Input: contractsapi.RootERC20.Bytecode} - receipt, err := rootchainTxRelayer.SendTransaction(txn, rootchainDeployer) - require.NoError(t, err) - require.NotNil(t, receipt) - require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) - - rootTokenAddr := receipt.ContractAddress - - t.Log("Rootchain token address:", rootTokenAddr) - - // wait for next sprint block as the starting point, - // in order to be able to make assertions against blocks offsetted by sprints - initialBlockNum, err := childEthEndpoint.BlockNumber() - require.NoError(t, err) - - initialBlockNum = initialBlockNum + sprintSize - (initialBlockNum % sprintSize) - require.NoError(t, cluster.WaitForBlock(initialBlockNum, 1*time.Minute)) - - t.Log("Initial block number:", initialBlockNum) - - // send a few transactions to the bridge - require.NoError(t, cluster.Bridge.Deposit( - common.ERC20, - types.Address(rootTokenAddr), - polybftCfg.Bridge.RootERC20PredicateAddr, - rootHelper.TestAccountPrivKey, - strings.Join(receivers[:], ","), - strings.Join(amounts[:], ","), - "", - cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, - false, - )) - - // wait for a few more sprints - finalBlockNumber := initialBlockNum + 10*sprintSize - require.NoError(t, cluster.WaitForBlock(finalBlockNumber, 2*time.Minute)) - - t.Log("Final block number:", finalBlockNumber) - - // the transactions are processed and there should be a success events - logs, err := getFilteredLogs(stateSyncedResult.Sig(), initialBlockNum, finalBlockNumber, childEthEndpoint) - require.NoError(t, err) - - // assert that all deposits are executed successfully - // map token action is executed along with the first deposit transaction - checkStateSyncResultLogs(t, logs, transfersCount+1) - - // retrieve child token address - childTokenAddr := getChildToken( - t, - contractsapi.ChildERC20Predicate.Abi, - contracts.ChildERC20PredicateContract, - types.Address(rootTokenAddr), - childchainTxRelayer, - ) - - t.Log("Childchain token address:", childTokenAddr) - - // check receivers balances got increased by deposited amount - for _, receiver := range receiversAddrs { - balance := erc20BalanceOf(t, receiver, childTokenAddr, childchainTxRelayer) - require.Equal(t, big.NewInt(int64(amount)), balance) - } - - t.Log("Deposits were successfully processed") - - // get initial exit id - initialExitEventID := getLastExitEventID(t, childchainTxRelayer) - - // WITHDRAW ERC20 TOKENS - for i, receiverKey := range receiverKeys { - t.Logf("Withdraw to: %s\n", receivers[i]) - - require.NoError(t, cluster.Bridge.Withdraw( - common.ERC20, - receiverKey, - receivers[i], - amounts[i], - "", - validatorSrv.JSONRPCAddr(), - contracts.ChildERC20PredicateContract, - childTokenAddr, - false, - )) - } - - currentBlock, err := childEthEndpoint.GetBlockByNumber(ethgo.Latest, false) - require.NoError(t, err) - - currentExtra, err := polybft.GetIbftExtra(currentBlock.ExtraData) - require.NoError(t, err) - - t.Logf("Latest block number: %d, epoch number: %d\n", currentBlock.Number, currentExtra.Checkpoint.EpochNumber) - - require.NoError(t, waitForRootchainEpoch( - currentExtra.Checkpoint.EpochNumber+1, - 3*time.Minute, - rootchainTxRelayer, - polybftCfg.Bridge.CheckpointManagerAddr, - )) - - exitHelper := polybftCfg.Bridge.ExitHelperAddr - childJSONRPC := validatorSrv.JSONRPCAddr() - - initialExitEventID++ - for i := initialExitEventID; i < initialExitEventID+transfersCount; i++ { - // send exit transaction to exit helper - err = cluster.Bridge.SendExitTransaction(exitHelper, i, childJSONRPC) - require.NoError(t, err) - } - - // assert that receiver's balances on RootERC20 smart contract are expected - for _, receiver := range receivers { - balance := erc20BalanceOf(t, types.StringToAddress(receiver), types.Address(rootTokenAddr), rootchainTxRelayer) - require.Equal(t, big.NewInt(amount), balance) - } - }) } func TestE2E_Bridge_ERC721Transfer(t *testing.T) { @@ -467,9 +330,6 @@ func TestE2E_Bridge_ERC721Transfer(t *testing.T) { stateSyncedLogsCount = 2 ) - minter, err := wallet.GenerateKey() - require.NoError(t, err) - receiverKeys := make([]string, transfersCount) receivers := make([]string, transfersCount) receiversAddrs := make([]types.Address, transfersCount) @@ -492,9 +352,14 @@ func TestE2E_Bridge_ERC721Transfer(t *testing.T) { cluster := framework.NewTestCluster(t, 5, framework.WithEpochSize(epochSize), - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, minter.Address())), - framework.WithPremine(types.Address(minter.Address())), - framework.WithPremine(receiversAddrs...)) + framework.WithPremine(receiversAddrs...), + framework.WithBridge(), + framework.WithSecretsCallback(func(addrs []types.Address, tcc *framework.TestClusterConfig) { + for i := 0; i < len(addrs); i++ { + tcc.StakeAmounts = append(tcc.StakeAmounts, ethgo.Ether(10)) + } + }), + ) defer cluster.Stop() cluster.WaitForReady(t) @@ -505,12 +370,15 @@ func TestE2E_Bridge_ERC721Transfer(t *testing.T) { rootchainTxRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) require.NoError(t, err) - rootchainDeployer, err := rootHelper.DecodePrivateKey("") + rootchainDeployer, err := bridgeHelper.DecodePrivateKey("") require.NoError(t, err) // deploy root ERC 721 token - deployTxn := ðgo.Transaction{To: nil, Input: contractsapi.RootERC721.Bytecode} - receipt, err := rootchainTxRelayer.SendTransaction(deployTxn, rootchainDeployer) + receipt, err := rootchainTxRelayer.SendTransaction( + ðgo.Transaction{ + To: nil, + Input: contractsapi.RootERC721.Bytecode, + }, rootchainDeployer) require.NoError(t, err) rootERC721Addr := receipt.ContractAddress @@ -523,12 +391,12 @@ func TestE2E_Bridge_ERC721Transfer(t *testing.T) { common.ERC721, types.Address(rootERC721Addr), polybftCfg.Bridge.RootERC721PredicateAddr, - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, strings.Join(receivers[:], ","), "", strings.Join(tokenIDs[:], ","), cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, false), ) @@ -629,9 +497,6 @@ func TestE2E_Bridge_ERC1155Transfer(t *testing.T) { stateSyncedLogsCount = 2 ) - minter, err := wallet.GenerateKey() - require.NoError(t, err) - receiverKeys := make([]string, transfersCount) receivers := make([]string, transfersCount) receiversAddrs := make([]types.Address, transfersCount) @@ -657,9 +522,14 @@ func TestE2E_Bridge_ERC1155Transfer(t *testing.T) { cluster := framework.NewTestCluster(t, 5, framework.WithNumBlockConfirmations(0), framework.WithEpochSize(epochSize), - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, minter.Address())), - framework.WithPremine(types.Address(minter.Address())), - framework.WithPremine(receiversAddrs...)) + framework.WithPremine(receiversAddrs...), + framework.WithBridge(), + framework.WithSecretsCallback(func(addrs []types.Address, tcc *framework.TestClusterConfig) { + for i := 0; i < len(addrs); i++ { + tcc.StakeAmounts = append(tcc.StakeAmounts, ethgo.Ether(10)) + } + }), + ) defer cluster.Stop() cluster.WaitForReady(t) @@ -670,12 +540,15 @@ func TestE2E_Bridge_ERC1155Transfer(t *testing.T) { rootchainTxRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) require.NoError(t, err) - rootchainDeployer, err := rootHelper.DecodePrivateKey("") + rootchainDeployer, err := bridgeHelper.DecodePrivateKey("") require.NoError(t, err) // deploy root ERC 1155 token - deployTxn := ðgo.Transaction{To: nil, Input: contractsapi.RootERC1155.Bytecode} - receipt, err := rootchainTxRelayer.SendTransaction(deployTxn, rootchainDeployer) + receipt, err := rootchainTxRelayer.SendTransaction( + ðgo.Transaction{ + To: nil, + Input: contractsapi.RootERC1155.Bytecode, + }, rootchainDeployer) require.NoError(t, err) rootERC1155Addr := receipt.ContractAddress @@ -688,12 +561,12 @@ func TestE2E_Bridge_ERC1155Transfer(t *testing.T) { common.ERC1155, types.Address(rootERC1155Addr), polybftCfg.Bridge.RootERC1155PredicateAddr, - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, strings.Join(receivers[:], ","), strings.Join(amounts[:], ","), strings.Join(tokenIDs[:], ","), cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, false), ) @@ -756,7 +629,7 @@ func TestE2E_Bridge_ERC1155Transfer(t *testing.T) { t.Log("Deposits were successfully processed") // WITHDRAW ERC1155 TOKENS - senderAccount, err := sidechain.GetAccountFromDir(cluster.Servers[0].DataDir()) + senderAccount, err := validatorHelper.GetAccountFromDir(cluster.Servers[0].DataDir()) require.NoError(t, err) t.Logf("Withdraw sender: %s\n", senderAccount.Ecdsa.Address()) @@ -816,7 +689,7 @@ func TestE2E_Bridge_ERC1155Transfer(t *testing.T) { } } -func TestE2E_Bridge_ChildChainMintableTokensTransfer(t *testing.T) { +func TestE2E_Bridge_ChildchainTokensTransfer(t *testing.T) { const ( transfersCount = uint64(4) amount = 100 @@ -857,7 +730,7 @@ func TestE2E_Bridge_ChildChainMintableTokensTransfer(t *testing.T) { cluster := framework.NewTestCluster(t, 5, framework.WithNumBlockConfirmations(0), framework.WithEpochSize(epochSize), - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, adminAddr)), + framework.WithBridge(), framework.WithBridgeBlockListAdmin(adminAddr), framework.WithPremine(append(depositors, adminAddr)...)) //nolint:makezero defer cluster.Stop() @@ -869,7 +742,7 @@ func TestE2E_Bridge_ChildChainMintableTokensTransfer(t *testing.T) { childEthEndpoint := validatorSrv.JSONRPC().Eth() // fund accounts on rootchain - require.NoError(t, validatorSrv.RootchainFundFor(depositors, funds, polybftCfg.Bridge.StakeTokenAddr)) + require.NoError(t, validatorSrv.RootchainFundFor(depositors, funds)) cluster.WaitForReady(t) @@ -1155,7 +1028,10 @@ func TestE2E_Bridge_ChildChainMintableTokensTransfer(t *testing.T) { func TestE2E_CheckpointSubmission(t *testing.T) { // spin up a cluster with epoch size set to 5 blocks - cluster := framework.NewTestCluster(t, 5, framework.WithEpochSize(5), framework.WithTestRewardToken()) + cluster := framework.NewTestCluster(t, 5, + framework.WithEpochSize(5), + framework.WithTestRewardToken(), + framework.WithBridge()) defer cluster.Stop() // initialize tx relayer used to query CheckpointManager smart contract @@ -1203,135 +1079,14 @@ func TestE2E_CheckpointSubmission(t *testing.T) { require.NoError(t, err) } -func TestE2E_Bridge_ChangeVotingPower(t *testing.T) { - const ( - votingPowerChanges = 2 - epochSize = 5 - ) - - minter, err := wallet.GenerateKey() - require.NoError(t, err) - - cluster := framework.NewTestCluster(t, 5, - framework.WithEpochSize(epochSize), - framework.WithEpochReward(1000000), - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, minter.Address())), - framework.WithPremine(types.Address(minter.Address())), - ) - defer cluster.Stop() - - // load polybft config - polybftCfg, err := polybft.LoadPolyBFTConfig(path.Join(cluster.Config.TmpDir, chainConfigFileName)) - require.NoError(t, err) - - validatorSecretFiles, err := genesis.GetValidatorKeyFiles(cluster.Config.TmpDir, cluster.Config.ValidatorPrefix) - require.NoError(t, err) - - votingPowerChangeValidators := make([]ethgo.Address, votingPowerChanges) - - for i := 0; i < votingPowerChanges; i++ { - validator, err := sidechain.GetAccountFromDir(path.Join(cluster.Config.TmpDir, validatorSecretFiles[i])) - require.NoError(t, err) - - votingPowerChangeValidators[i] = validator.Ecdsa.Address() - } - - // child chain tx relayer - childRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Servers[0].JSONRPCAddr())) - require.NoError(t, err) - - // root chain tx relayer - rootRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) - require.NoError(t, err) - - // waiting two epochs, so that some rewards get accumulated - require.NoError(t, cluster.WaitForBlock(2*epochSize, 1*time.Minute)) - - queryValidators := func(handler func(idx int, validatorInfo *polybft.ValidatorInfo)) { - for i, validatorAddr := range votingPowerChangeValidators { - // query validator info - validatorInfo, err := sidechain.GetValidatorInfo( - validatorAddr, - polybftCfg.Bridge.CustomSupernetManagerAddr, - polybftCfg.Bridge.StakeManagerAddr, - polybftCfg.SupernetID, - rootRelayer, - childRelayer) - require.NoError(t, err) - - handler(i, validatorInfo) - } - } - - // validatorsMap holds only changed validators - validatorsMap := make(map[ethgo.Address]*polybft.ValidatorInfo, votingPowerChanges) - - queryValidators(func(idx int, validator *polybft.ValidatorInfo) { - t.Logf("[Validator#%d] Voting power (original)=%d, rewards=%d\n", - idx+1, validator.Stake, validator.WithdrawableRewards) - - validatorsMap[validator.Address] = validator - validatorSrv := cluster.Servers[idx] - - // fund validators (send accumulated rewards amount) - require.NoError(t, validatorSrv.RootchainFund(polybftCfg.Bridge.StakeTokenAddr, validator.WithdrawableRewards)) - - // stake previously funded amount - require.NoError(t, validatorSrv.Stake(polybftCfg, validator.WithdrawableRewards)) - }) - - queryValidators(func(idx int, validator *polybft.ValidatorInfo) { - t.Logf("[Validator#%d] Voting power (after stake)=%d\n", idx+1, validator.Stake) - - previousValidatorInfo := validatorsMap[validator.Address] - stakedAmount := new(big.Int).Add(previousValidatorInfo.WithdrawableRewards, previousValidatorInfo.Stake) - - // assert that total stake has increased by staked amount - require.Equal(t, stakedAmount, validator.Stake) - - validatorsMap[validator.Address] = validator - }) - - currentBlockNum, err := childRelayer.Client().Eth().BlockNumber() - require.NoError(t, err) - - // wait for next epoch-ending block as the starting point, - // in order to be able to easier track checkpoints submission - endOfEpochBlockNum := currentBlockNum + epochSize - (currentBlockNum % epochSize) - require.NoError(t, cluster.WaitForBlock(endOfEpochBlockNum, 1*time.Minute)) - - currentBlock, err := childRelayer.Client().Eth().GetBlockByNumber(ethgo.Latest, false) - require.NoError(t, err) - - currentExtra, err := polybft.GetIbftExtra(currentBlock.ExtraData) - require.NoError(t, err) - - targetEpoch := currentExtra.Checkpoint.EpochNumber + 2 - require.NoError(t, waitForRootchainEpoch(targetEpoch, 2*time.Minute, - rootRelayer, polybftCfg.Bridge.CheckpointManagerAddr)) - - // make sure that correct validator set is submitted to the checkpoint manager - checkpointValidators, err := getCheckpointManagerValidators(rootRelayer, ethgo.Address(polybftCfg.Bridge.CheckpointManagerAddr)) - require.NoError(t, err) - - for _, checkpointValidator := range checkpointValidators { - if validator, ok := validatorsMap[checkpointValidator.Address]; ok { - require.Equal(t, validator.Stake, checkpointValidator.Stake) - } else { - require.Equal(t, command.DefaultPremineBalance, checkpointValidator.Stake) - } - } -} - func TestE2E_Bridge_Transfers_AccessLists(t *testing.T) { var ( transfersCount = 5 depositAmount = ethgo.Ether(5) withdrawAmount = ethgo.Ether(1) // make epoch size long enough, so that all exit events are processed within the same epoch - epochSize = 30 - sprintSize = uint64(5) - stateSyncedLogsCount = 1 + epochSize = 30 + sprintSize = uint64(5) ) receivers := make([]string, transfersCount) @@ -1345,6 +1100,8 @@ func TestE2E_Bridge_Transfers_AccessLists(t *testing.T) { framework.WithNumBlockConfirmations(0), framework.WithEpochSize(epochSize), framework.WithTestRewardToken(), + framework.WithRootTrackerPollInterval(3*time.Second), + framework.WithBridge(), framework.WithBridgeAllowListAdmin(adminAddr), framework.WithBridgeBlockListAdmin(adminAddr), framework.WithSecretsCallback(func(a []types.Address, tcc *framework.TestClusterConfig) { @@ -1354,6 +1111,10 @@ func TestE2E_Bridge_Transfers_AccessLists(t *testing.T) { withdrawAmounts[i] = fmt.Sprintf("%d", withdrawAmount) t.Logf("Receiver#%d=%s\n", i+1, receivers[i]) + + // premine access list admin account + tcc.Premine = append(tcc.Premine, adminAddr.String()) + tcc.StakeAmounts = append(tcc.StakeAmounts, ethgo.Ether(10)) } }), ) @@ -1366,61 +1127,46 @@ func TestE2E_Bridge_Transfers_AccessLists(t *testing.T) { validatorSrv := cluster.Servers[0] childEthEndpoint := validatorSrv.JSONRPC().Eth() + relayer, err := txrelayer.NewTxRelayer(txrelayer.WithClient(validatorSrv.JSONRPC())) + require.NoError(t, err) - var stateSyncedResult contractsapi.StateSyncResultEvent + senderAccount, err := validatorHelper.GetAccountFromDir(validatorSrv.DataDir()) + require.NoError(t, err) // fund admin on rootchain - require.NoError(t, cluster.Servers[0].RootchainFundFor([]types.Address{adminAddr}, []*big.Int{ethgo.Ether(10)}, - polybftCfg.Bridge.StakeTokenAddr)) + require.NoError(t, validatorSrv.RootchainFundFor([]types.Address{adminAddr}, []*big.Int{ethgo.Ether(1)})) - adminBalanceOnChild := ethgo.Ether(5) - - // bridge some tokens for admin to child chain - require.NoError( - t, cluster.Bridge.Deposit( - common.ERC20, - polybftCfg.Bridge.RootNativeERC20Addr, - polybftCfg.Bridge.RootERC20PredicateAddr, - rootHelper.TestAccountPrivKey, - adminAddr.String(), - adminBalanceOnChild.String(), - "", - cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, - false), - ) - - // wait for a couple of sprints - finalBlockNum := 5 * sprintSize - require.NoError(t, cluster.WaitForBlock(finalBlockNum, 2*time.Minute)) - - // the transaction is processed and there should be a success events - logs, err := getFilteredLogs(stateSyncedResult.Sig(), 0, finalBlockNum, childEthEndpoint) + rootchainTxRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) require.NoError(t, err) - // assert that all deposits are executed successfully - checkStateSyncResultLogs(t, logs, stateSyncedLogsCount) + deployerKey, err := bridgeHelper.DecodePrivateKey("") + require.NoError(t, err) - // check admin balance got increased by deposited amount - balance, err := childEthEndpoint.GetBalance(ethgo.Address(adminAddr), ethgo.Latest) + // deploy root erc20 token + receipt, err := rootchainTxRelayer.SendTransaction( + ðgo.Transaction{ + To: nil, Input: contractsapi.RootERC20.Bytecode, + }, deployerKey) require.NoError(t, err) - require.Equal(t, adminBalanceOnChild, balance) + require.NotNil(t, receipt) + require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) + rootERC20Token := types.Address(receipt.ContractAddress) - t.Run("bridge native (ERC 20) tokens", func(t *testing.T) { + t.Run("bridge ERC 20 tokens", func(t *testing.T) { // DEPOSIT ERC20 TOKENS // send a few transactions to the bridge require.NoError( t, cluster.Bridge.Deposit( common.ERC20, - polybftCfg.Bridge.RootNativeERC20Addr, + rootERC20Token, polybftCfg.Bridge.RootERC20PredicateAddr, - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, strings.Join(receivers[:], ","), strings.Join(depositAmounts[:], ","), "", cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, + bridgeHelper.TestAccountPrivKey, false), ) @@ -1428,37 +1174,28 @@ func TestE2E_Bridge_Transfers_AccessLists(t *testing.T) { // wait for a couple of sprints require.NoError(t, cluster.WaitForBlock(finalBlockNum, 2*time.Minute)) + var stateSyncedResult contractsapi.StateSyncResultEvent + // the transactions are processed and there should be a success events logs, err := getFilteredLogs(stateSyncedResult.Sig(), 0, finalBlockNum, childEthEndpoint) require.NoError(t, err) - // because of the admin deposit on child chain at the beginning - totalTransfers := transfersCount + 1 - // assert that all deposits are executed successfully - checkStateSyncResultLogs(t, logs, totalTransfers) + // (token mapping and transferCount of deposits) + checkStateSyncResultLogs(t, logs, transfersCount+1) - // check receivers balances got increased by deposited amount - // because we premined validators - expectedBalance := new(big.Int).Add(command.DefaultPremineBalance, depositAmount) + // get child token address + childERC20Token := getChildToken(t, contractsapi.RootERC20Predicate.Abi, + polybftCfg.Bridge.RootERC20PredicateAddr, rootERC20Token, rootchainTxRelayer) for _, receiver := range receivers { - balance, err := childEthEndpoint.GetBalance(ethgo.Address(types.StringToAddress(receiver)), ethgo.Latest) - require.NoError(t, err) - require.Equal(t, expectedBalance, balance) + balance := erc20BalanceOf(t, types.StringToAddress(receiver), childERC20Token, relayer) + require.Equal(t, depositAmount, balance) } t.Log("Deposits were successfully processed") // WITHDRAW ERC20 TOKENS - rootchainTxRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) - require.NoError(t, err) - - senderAccount, err := sidechain.GetAccountFromDir(validatorSrv.DataDir()) - require.NoError(t, err) - - t.Logf("Withdraw sender: %s\n", senderAccount.Ecdsa.Address()) - rawKey, err := senderAccount.Ecdsa.MarshallPrivateKey() require.NoError(t, err) @@ -1472,7 +1209,7 @@ func TestE2E_Bridge_Transfers_AccessLists(t *testing.T) { "", validatorSrv.JSONRPCAddr(), contracts.ChildERC20PredicateContract, - contracts.NativeERC20TokenContract, + childERC20Token, false) require.Error(t, err) @@ -1488,7 +1225,7 @@ func TestE2E_Bridge_Transfers_AccessLists(t *testing.T) { "", validatorSrv.JSONRPCAddr(), contracts.ChildERC20PredicateContract, - contracts.NativeERC20TokenContract, + childERC20Token, false) require.NoError(t, err) @@ -1526,7 +1263,7 @@ func TestE2E_Bridge_Transfers_AccessLists(t *testing.T) { oldBalances := map[types.Address]*big.Int{} for _, receiver := range receivers { - balance := erc20BalanceOf(t, types.StringToAddress(receiver), polybftCfg.Bridge.RootNativeERC20Addr, rootchainTxRelayer) + balance := erc20BalanceOf(t, types.StringToAddress(receiver), rootERC20Token, rootchainTxRelayer) oldBalances[types.StringToAddress(receiver)] = balance } @@ -1538,303 +1275,9 @@ func TestE2E_Bridge_Transfers_AccessLists(t *testing.T) { // assert that receiver's balances on RootERC20 smart contract are expected for _, receiver := range receivers { - balance := erc20BalanceOf(t, types.StringToAddress(receiver), polybftCfg.Bridge.RootNativeERC20Addr, rootchainTxRelayer) + balance := erc20BalanceOf(t, types.StringToAddress(receiver), rootERC20Token, rootchainTxRelayer) require.Equal(t, oldBalances[types.StringToAddress(receiver)].Add( oldBalances[types.StringToAddress(receiver)], withdrawAmount), balance) } }) } - -func TestE2E_Bridge_Transfers_WithRootTrackerPollInterval(t *testing.T) { - var ( - numBlockConfirmations = uint64(2) - epochSize = 30 - sprintSize = uint64(5) - rootPollInterval = 5 * time.Second - numberOfAttempts = uint64(4) - stateSyncedLogsCount = 1 - ) - - cluster := framework.NewTestCluster(t, 5, - framework.WithEpochSize(epochSize), - framework.WithNumBlockConfirmations(numBlockConfirmations), - framework.WithRootTrackerPollInterval(rootPollInterval), - framework.WithTestRewardToken(), - ) - defer cluster.Stop() - - cluster.WaitForReady(t) - - polybftCfg, err := polybft.LoadPolyBFTConfig(path.Join(cluster.Config.TmpDir, chainConfigFileName)) - require.NoError(t, err) - - validatorSrv := cluster.Servers[0] - senderAccount, err := sidechain.GetAccountFromDir(validatorSrv.DataDir()) - require.NoError(t, err) - - childEthEndpoint := validatorSrv.JSONRPC().Eth() - - // bridge some tokens for first validator to child chain - tokensToDeposit := ethgo.Ether(10) - - require.NoError(t, cluster.Bridge.Deposit( - common.ERC20, - polybftCfg.Bridge.RootNativeERC20Addr, - polybftCfg.Bridge.RootERC20PredicateAddr, - rootHelper.TestAccountPrivKey, - senderAccount.Address().String(), - tokensToDeposit.String(), - "", - cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, - false), - ) - - // wait for a couple of sprints - finalBlockNum := 5 * sprintSize - - // the transaction is processed and there should be a success event - var stateSyncedResult contractsapi.StateSyncResultEvent - - for i := uint64(0); i < numberOfAttempts; i++ { - logs, err := getFilteredLogs(stateSyncedResult.Sig(), 0, finalBlockNum+i*sprintSize, childEthEndpoint) - require.NoError(t, err) - - if len(logs) == stateSyncedLogsCount || i == numberOfAttempts-1 { - // assert that all deposits are executed successfully - checkStateSyncResultLogs(t, logs, stateSyncedLogsCount) - - break - } - - require.NoError(t, cluster.WaitForBlock(finalBlockNum+(i+1)*sprintSize, 2*time.Minute)) - } - - // check validator balance got increased by deposited amount - balance, err := childEthEndpoint.GetBalance(ethgo.Address(senderAccount.Address()), ethgo.Latest) - require.NoError(t, err) - - // because we premined the validators - expectedBalance := new(big.Int).Add(command.DefaultPremineBalance, tokensToDeposit) - require.Equal(t, expectedBalance, balance) -} - -func TestE2E_Bridge_NonMintableERC20Token_WithPremine(t *testing.T) { - var ( - numBlockConfirmations = uint64(2) - epochSize = 10 - sprintSize = uint64(5) - numberOfAttempts = uint64(4) - stateSyncedLogsCount = 2 - exitEventsCount = uint64(2) - tokensToTransfer = ethgo.Gwei(10) - bigZero = big.NewInt(0) - ) - - nonValidatorKey, err := wallet.GenerateKey() - require.NoError(t, err) - - nonValidatorKeyRaw, err := nonValidatorKey.MarshallPrivateKey() - require.NoError(t, err) - - // start cluster with default, non-mintable native erc20 root token - // with london fork enabled - cluster := framework.NewTestCluster(t, 5, - framework.WithEpochSize(epochSize), - framework.WithNumBlockConfirmations(numBlockConfirmations), - // this enables London (EIP-1559) fork - framework.WithBurnContract(&polybft.BurnContractInfo{ - BlockNumber: 0, - Address: types.StringToAddress("0xBurnContractAddress")}), - framework.WithTestRewardToken(), - framework.WithSecretsCallback(func(_ []types.Address, tcc *framework.TestClusterConfig) { - nonValidatorKeyString := hex.EncodeToString(nonValidatorKeyRaw) - - // do premine to a non validator address - tcc.Premine = append(tcc.Premine, - fmt.Sprintf("%s:%s:%s", - nonValidatorKey.Address(), - command.DefaultPremineBalance.String(), - nonValidatorKeyString)) - }), - ) - - rootchainTxRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) - require.NoError(t, err) - - childEthEndpoint := cluster.Servers[0].JSONRPC().Eth() - - defer cluster.Stop() - - cluster.WaitForReady(t) - - polybftCfg, err := polybft.LoadPolyBFTConfig(path.Join(cluster.Config.TmpDir, chainConfigFileName)) - require.NoError(t, err) - - checkBalancesFn := func(address types.Address, rootExpected, childExpected *big.Int) { - t.Log("Checking balance of native ERC20 token on root and child", "Address", address, - "Root expected", rootExpected, "Child Expected", childExpected) - - balance := erc20BalanceOf(t, address, - polybftCfg.Bridge.RootNativeERC20Addr, rootchainTxRelayer) - t.Log("Balance of native ERC20 token on root", balance, "Address", address) - require.Equal(t, rootExpected, balance) - - balance, err = childEthEndpoint.GetBalance(ethgo.Address(address), ethgo.Latest) - require.NoError(t, err) - t.Log("Balance of native ERC20 token on child", balance, "Address", address) - require.True(t, balance.Cmp(childExpected) >= 0) // because of London fork - } - - t.Run("check the balances at the beginning", func(t *testing.T) { - // check the balances on root and child at the beginning to see if they are as expected - checkBalancesFn(types.Address(nonValidatorKey.Address()), bigZero, command.DefaultPremineBalance) - - for _, server := range cluster.Servers { - validatorAccount, err := sidechain.GetAccountFromDir(server.DataDir()) - require.NoError(t, err) - - checkBalancesFn(validatorAccount.Address(), bigZero, command.DefaultPremineBalance) - } - }) - - // this test case will check first if they can withdraw some of the premined amount of non-mintable token - t.Run("Do a withdraw for premined validator address and premined non-validator address", func(t *testing.T) { - validatorSrv := cluster.Servers[1] - validatorAcc, err := sidechain.GetAccountFromDir(validatorSrv.DataDir()) - require.NoError(t, err) - - validatorRawKey, err := validatorAcc.Ecdsa.MarshallPrivateKey() - require.NoError(t, err) - - err = cluster.Bridge.Withdraw( - common.ERC20, - hex.EncodeToString(validatorRawKey), - validatorAcc.Address().String(), - tokensToTransfer.String(), - "", - validatorSrv.JSONRPCAddr(), - contracts.ChildERC20PredicateContract, - contracts.NativeERC20TokenContract, - false) - require.NoError(t, err) - - validatorBalanceAfterWithdraw, err := childEthEndpoint.GetBalance( - ethgo.Address(validatorAcc.Address()), ethgo.Latest) - require.NoError(t, err) - - err = cluster.Bridge.Withdraw( - common.ERC20, - hex.EncodeToString(nonValidatorKeyRaw), - nonValidatorKey.Address().String(), - tokensToTransfer.String(), - "", - validatorSrv.JSONRPCAddr(), - contracts.ChildERC20PredicateContract, - contracts.NativeERC20TokenContract, - false) - require.NoError(t, err) - - nonValidatorBalanceAfterWithdraw, err := childEthEndpoint.GetBalance( - nonValidatorKey.Address(), ethgo.Latest) - require.NoError(t, err) - - currentBlock, err := childEthEndpoint.GetBlockByNumber(ethgo.Latest, false) - require.NoError(t, err) - - currentExtra, err := polybft.GetIbftExtra(currentBlock.ExtraData) - require.NoError(t, err) - - t.Logf("Latest block number: %d, epoch number: %d\n", currentBlock.Number, currentExtra.Checkpoint.EpochNumber) - - currentEpoch := currentExtra.Checkpoint.EpochNumber - - exitHelper := polybftCfg.Bridge.ExitHelperAddr - childJSONRPC := validatorSrv.JSONRPCAddr() - - successfulExitTransactions := make([]bool, exitEventsCount) - - for i := uint64(0); i < numberOfAttempts; i++ { - t.Log("Number of attempts: ", i+1) - - require.NoError(t, waitForRootchainEpoch(currentEpoch+i, 3*time.Minute, - rootchainTxRelayer, polybftCfg.Bridge.CheckpointManagerAddr)) - - for exitEventID := uint64(1); exitEventID <= exitEventsCount; exitEventID++ { - if successfulExitTransactions[exitEventID-1] { - continue - } - - // send exit transaction to exit helper - if err = cluster.Bridge.SendExitTransaction(exitHelper, exitEventID, childJSONRPC); err == nil { - successfulExitTransactions[exitEventID-1] = true - - continue - } - - if i == numberOfAttempts-1 { - require.NoError(t, err) - } - } - - allExitsSuccessfull := true - for _, isSuccessfull := range successfulExitTransactions { - if !isSuccessfull { - allExitsSuccessfull = false - - break - } - } - - if allExitsSuccessfull { - break - } - } - - // assert that receiver's balances on RootERC20 smart contract are expected - checkBalancesFn(validatorAcc.Address(), tokensToTransfer, validatorBalanceAfterWithdraw) - checkBalancesFn(types.Address(nonValidatorKey.Address()), tokensToTransfer, nonValidatorBalanceAfterWithdraw) - }) - - t.Run("Do a deposit to some validator and non-validator address", func(t *testing.T) { - validatorSrv := cluster.Servers[4] - validatorAcc, err := sidechain.GetAccountFromDir(validatorSrv.DataDir()) - require.NoError(t, err) - - require.NoError(t, cluster.Bridge.Deposit( - common.ERC20, - polybftCfg.Bridge.RootNativeERC20Addr, - polybftCfg.Bridge.RootERC20PredicateAddr, - rootHelper.TestAccountPrivKey, - strings.Join([]string{validatorAcc.Address().String(), nonValidatorKey.Address().String()}, ","), - strings.Join([]string{tokensToTransfer.String(), tokensToTransfer.String()}, ","), - "", - cluster.Bridge.JSONRPCAddr(), - rootHelper.TestAccountPrivKey, - false), - ) - - currentBlock, err := childEthEndpoint.GetBlockByNumber(ethgo.Latest, false) - require.NoError(t, err) - - // wait for a couple of sprints - finalBlockNum := currentBlock.Number + 5*sprintSize - - // the transaction is processed and there should be a success event - var stateSyncedResult contractsapi.StateSyncResultEvent - - for i := uint64(0); i < numberOfAttempts; i++ { - logs, err := getFilteredLogs(stateSyncedResult.Sig(), 0, finalBlockNum+i*sprintSize, childEthEndpoint) - require.NoError(t, err) - - if len(logs) == stateSyncedLogsCount || i == numberOfAttempts-1 { - // assert that all deposits are executed successfully - checkStateSyncResultLogs(t, logs, stateSyncedLogsCount) - - break - } - - require.NoError(t, cluster.WaitForBlock(finalBlockNum+(i+1)*sprintSize, 2*time.Minute)) - } - }) -} diff --git a/e2e-polybft/e2e/burn_contract_test.go b/e2e-polybft/e2e/burn_contract_test.go deleted file mode 100644 index a95e101eaf..0000000000 --- a/e2e-polybft/e2e/burn_contract_test.go +++ /dev/null @@ -1,38 +0,0 @@ -package e2e - -import ( - "testing" - - "github.com/stretchr/testify/require" - "github.com/umbracle/ethgo" - "github.com/umbracle/ethgo/wallet" - - "github.com/0xPolygon/polygon-edge/consensus/polybft" - "github.com/0xPolygon/polygon-edge/e2e-polybft/framework" - "github.com/0xPolygon/polygon-edge/types" -) - -func TestE2E_BurnContract_Deployed(t *testing.T) { - contractKey, _ := wallet.GenerateKey() - destinationKey, _ := wallet.GenerateKey() - - contractAddr := types.Address(contractKey.Address()) - destinationAddr := types.Address(destinationKey.Address()) - - cluster := framework.NewTestCluster(t, 5, - framework.WithTestRewardToken(), - framework.WithBurnContract(&polybft.BurnContractInfo{ - Address: contractAddr, - DestinationAddress: destinationAddr, - }), - ) - defer cluster.Stop() - - cluster.WaitForReady(t) - client := cluster.Servers[0].JSONRPC().Eth() - - // Get the code for the default deployed burn contract - code, err := client.GetCode(ethgo.Address(contractAddr), ethgo.Latest) - require.NoError(t, err) - require.NotEqual(t, code, "0x") -} diff --git a/e2e-polybft/e2e/consensus_test.go b/e2e-polybft/e2e/consensus_test.go index c7e6d82bd1..754e26eb47 100644 --- a/e2e-polybft/e2e/consensus_test.go +++ b/e2e-polybft/e2e/consensus_test.go @@ -1,6 +1,7 @@ package e2e import ( + "bytes" "fmt" "math/big" "path" @@ -9,7 +10,6 @@ import ( "testing" "time" - "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/umbracle/ethgo" "github.com/umbracle/ethgo/abi" @@ -17,7 +17,7 @@ import ( "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/genesis" - "github.com/0xPolygon/polygon-edge/command/sidechain" + validatorHelper "github.com/0xPolygon/polygon-edge/command/validator/helper" "github.com/0xPolygon/polygon-edge/consensus/polybft" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/contracts" @@ -28,7 +28,7 @@ import ( var uint256ABIType = abi.MustNewType("tuple(uint256)") -func TestE2E_Consensus_Basic_WithNonValidators(t *testing.T) { +func TestE2E_Consensus_Basic(t *testing.T) { const ( epochSize = 4 validatorsNum = 5 @@ -37,7 +37,6 @@ func TestE2E_Consensus_Basic_WithNonValidators(t *testing.T) { cluster := framework.NewTestCluster(t, validatorsNum, framework.WithEpochSize(epochSize), framework.WithNonValidators(2), - framework.WithTestRewardToken(), ) defer cluster.Stop() @@ -47,8 +46,8 @@ func TestE2E_Consensus_Basic_WithNonValidators(t *testing.T) { relayer, err := txrelayer.NewTxRelayer(txrelayer.WithClient(cluster.Servers[0].JSONRPC())) require.NoError(t, err) - // because we are pre-mining native tokens to validators - initialTotalSupply := new(big.Int).Mul(big.NewInt(validatorsNum), command.DefaultPremineBalance) + initialTotalSupply := new(big.Int).Mul(big.NewInt(validatorsNum+1 /*because of reward token*/), + command.DefaultPremineBalance) // check if initial total supply of native ERC20 token is the same as expected totalSupply := queryNativeERC20Metadata(t, "totalSupply", uint256ABIType, relayer) @@ -107,7 +106,6 @@ func TestE2E_Consensus_BulkDrop(t *testing.T) { cluster := framework.NewTestCluster(t, clusterSize, framework.WithEpochSize(epochSize), framework.WithBlockTime(time.Second), - framework.WithTestRewardToken(), ) defer cluster.Stop() @@ -149,22 +147,18 @@ func TestE2E_Consensus_RegisterValidator(t *testing.T) { firstValidatorDataDir = fmt.Sprintf("test-chain-%d", validatorSetSize+1) // directory where the first validator secrets will be stored secondValidatorDataDir = fmt.Sprintf("test-chain-%d", validatorSetSize+2) // directory where the second validator secrets will be stored - initMinterBalance = ethgo.Ether(4e6) - premineBalance = ethgo.Ether(2e6) // 2M native tokens (so that we have enough balance to fund new validator) + premineBalance = ethgo.Ether(2e6) // 2M native tokens (so that we have enough balance to fund new validator) + stakeAmount = ethgo.Ether(500) ) - minter, err := wallet.GenerateKey() - require.NoError(t, err) - // start cluster with 'validatorSize' validators cluster := framework.NewTestCluster(t, validatorSetSize, framework.WithEpochSize(epochSize), framework.WithEpochReward(int(ethgo.Ether(1).Uint64())), - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, minter.Address())), framework.WithSecretsCallback(func(addresses []types.Address, config *framework.TestClusterConfig) { - config.Premine = append(config.Premine, fmt.Sprintf("%s:%s", minter.Address(), initMinterBalance)) for _, a := range addresses { config.Premine = append(config.Premine, fmt.Sprintf("%s:%s", a, premineBalance)) + config.StakeAmounts = append(config.StakeAmounts, stakeAmount) } }), ) @@ -174,10 +168,7 @@ func TestE2E_Consensus_RegisterValidator(t *testing.T) { // first validator is the owner of ChildValidator set smart contract owner := cluster.Servers[0] - childChainRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(owner.JSONRPCAddr())) - require.NoError(t, err) - - rootChainRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) + relayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(owner.JSONRPCAddr())) require.NoError(t, err) polybftConfig, err := polybft.LoadPolyBFTConfig(path.Join(cluster.Config.TmpDir, chainConfigFileName)) @@ -200,10 +191,6 @@ func TestE2E_Consensus_RegisterValidator(t *testing.T) { require.NoError(t, err) require.Equal(t, validatorSetSize+2, len(validatorSecrets)) - // collect owners validator secrets - firstValidatorSecrets := validatorSecrets[validatorSetSize] - secondValidatorSecrets := validatorSecrets[validatorSetSize+1] - genesisBlock, err := owner.JSONRPC().Eth().GetBlockByNumber(0, false) require.NoError(t, err) @@ -214,28 +201,22 @@ func TestE2E_Consensus_RegisterValidator(t *testing.T) { require.NoError(t, owner.WhitelistValidators([]string{ firstValidatorAddr.String(), secondValidatorAddr.String(), - }, polybftConfig.Bridge.CustomSupernetManagerAddr)) + })) - // set the initial balance of the new validators at the rootchain - initialBalance := ethgo.Ether(500) + // set the initial balance of the new validators + initialBalance := ethgo.Ether(1000) - // fund first new validator - err = cluster.Bridge.FundValidators(polybftConfig.Bridge.StakeTokenAddr, - []string{path.Join(cluster.Config.TmpDir, firstValidatorSecrets)}, []*big.Int{initialBalance}) - require.NoError(t, err) - - // fund second new validator - err = cluster.Bridge.FundValidators(polybftConfig.Bridge.StakeTokenAddr, - []string{path.Join(cluster.Config.TmpDir, secondValidatorSecrets)}, []*big.Int{initialBalance}) - require.NoError(t, err) + // mint tokens to new validators + require.NoError(t, owner.MintNativeERC20Token([]string{firstValidatorAddr.String(), secondValidatorAddr.String()}, + []*big.Int{initialBalance, initialBalance})) // first validator's balance to be received - firstBalance, err := rootChainRelayer.Client().Eth().GetBalance(firstValidatorAddr, ethgo.Latest) + firstBalance, err := relayer.Client().Eth().GetBalance(firstValidatorAddr, ethgo.Latest) require.NoError(t, err) t.Logf("First validator balance=%d\n", firstBalance) // second validator's balance to be received - secondBalance, err := rootChainRelayer.Client().Eth().GetBalance(secondValidatorAddr, ethgo.Latest) + secondBalance, err := relayer.Client().Eth().GetBalance(secondValidatorAddr, ethgo.Latest) require.NoError(t, err) t.Logf("Second validator balance=%d\n", secondBalance) @@ -246,73 +227,34 @@ func TestE2E_Consensus_RegisterValidator(t *testing.T) { cluster.InitTestServer(t, cluster.Config.ValidatorPrefix+strconv.Itoa(validatorSetSize+2), cluster.Bridge.JSONRPCAddr(), framework.Validator) + // wait for couple of epochs until new validators start + require.NoError(t, cluster.WaitForBlock(epochSize*3, time.Minute)) + // collect the first and the second validator from the cluster firstValidator := cluster.Servers[validatorSetSize] secondValidator := cluster.Servers[validatorSetSize+1] - initialStake := ethgo.Ether(499) - // register the first validator with stake - require.NoError(t, firstValidator.RegisterValidator(polybftConfig.Bridge.CustomSupernetManagerAddr)) + require.NoError(t, firstValidator.RegisterValidator()) // register the second validator without stake - require.NoError(t, secondValidator.RegisterValidator(polybftConfig.Bridge.CustomSupernetManagerAddr)) + require.NoError(t, secondValidator.RegisterValidator()) // stake manually for the first validator - require.NoError(t, firstValidator.Stake(polybftConfig, initialStake)) + require.NoError(t, firstValidator.Stake(polybftConfig, stakeAmount)) // stake manually for the second validator - require.NoError(t, secondValidator.Stake(polybftConfig, initialStake)) + require.NoError(t, secondValidator.Stake(polybftConfig, stakeAmount)) - firstValidatorInfo, err := sidechain.GetValidatorInfo(firstValidatorAddr, - polybftConfig.Bridge.CustomSupernetManagerAddr, polybftConfig.Bridge.StakeManagerAddr, - polybftConfig.SupernetID, rootChainRelayer, childChainRelayer) + firstValidatorInfo, err := validatorHelper.GetValidatorInfo(firstValidatorAddr, relayer) require.NoError(t, err) require.True(t, firstValidatorInfo.IsActive) - require.True(t, firstValidatorInfo.Stake.Cmp(initialStake) == 0) + require.True(t, firstValidatorInfo.Stake.Cmp(stakeAmount) == 0) - secondValidatorInfo, err := sidechain.GetValidatorInfo(secondValidatorAddr, - polybftConfig.Bridge.CustomSupernetManagerAddr, polybftConfig.Bridge.StakeManagerAddr, - polybftConfig.SupernetID, rootChainRelayer, childChainRelayer) + secondValidatorInfo, err := validatorHelper.GetValidatorInfo(secondValidatorAddr, relayer) require.NoError(t, err) require.True(t, secondValidatorInfo.IsActive) - require.True(t, secondValidatorInfo.Stake.Cmp(initialStake) == 0) - - // wait for the stake to be bridged - require.NoError(t, cluster.WaitForBlock(polybftConfig.EpochSize*4, time.Minute)) - - checkpointManagerAddr := ethgo.Address(polybftConfig.Bridge.CheckpointManagerAddr) - - // check if the validators are added to active validator set - rootchainValidators := []*polybft.ValidatorInfo{} - err = cluster.Bridge.WaitUntil(time.Second, time.Minute, func() (bool, error) { - rootchainValidators, err = getCheckpointManagerValidators(rootChainRelayer, checkpointManagerAddr) - if err != nil { - return true, err - } - - return len(rootchainValidators) == validatorSetSize+2, nil - }) - - require.NoError(t, err) - require.Equal(t, validatorSetSize+2, len(rootchainValidators)) - - var ( - isFirstValidatorFound bool - isSecondValidatorFound bool - ) - - for _, v := range rootchainValidators { - if v.Address == firstValidatorAddr { - isFirstValidatorFound = true - } else if v.Address == secondValidatorAddr { - isSecondValidatorFound = true - } - } - - // new validators should be in the active validator set - require.True(t, isFirstValidatorFound) - require.True(t, isSecondValidatorFound) + require.True(t, secondValidatorInfo.Stake.Cmp(stakeAmount) == 0) currentBlock, err := owner.JSONRPC().Eth().GetBlockByNumber(ethgo.Latest, false) require.NoError(t, err) @@ -322,39 +264,39 @@ func TestE2E_Consensus_RegisterValidator(t *testing.T) { bigZero := big.NewInt(0) - firstValidatorInfo, err = sidechain.GetValidatorInfo(firstValidatorAddr, - polybftConfig.Bridge.CustomSupernetManagerAddr, polybftConfig.Bridge.StakeManagerAddr, - polybftConfig.SupernetID, rootChainRelayer, childChainRelayer) + firstValidatorInfo, err = validatorHelper.GetValidatorInfo(firstValidatorAddr, relayer) require.NoError(t, err) require.True(t, firstValidatorInfo.IsActive) require.True(t, firstValidatorInfo.WithdrawableRewards.Cmp(bigZero) > 0) - secondValidatorInfo, err = sidechain.GetValidatorInfo(secondValidatorAddr, - polybftConfig.Bridge.CustomSupernetManagerAddr, polybftConfig.Bridge.StakeManagerAddr, - polybftConfig.SupernetID, rootChainRelayer, childChainRelayer) + secondValidatorInfo, err = validatorHelper.GetValidatorInfo(secondValidatorAddr, relayer) require.NoError(t, err) require.True(t, secondValidatorInfo.IsActive) require.True(t, secondValidatorInfo.WithdrawableRewards.Cmp(bigZero) > 0) + + // wait until one of the validators mine one block to check if they joined consensus + require.NoError(t, cluster.WaitUntil(3*time.Minute, 2*time.Second, func() bool { + latestBlock, err := cluster.Servers[0].JSONRPC().Eth().GetBlockByNumber(ethgo.Latest, false) + require.NoError(t, err) + + blockMiner := latestBlock.Miner.Bytes() + + return bytes.Equal(firstValidatorAddr.Bytes(), blockMiner) || + bytes.Equal(secondValidatorAddr.Bytes(), blockMiner) + })) } func TestE2E_Consensus_Validator_Unstake(t *testing.T) { var ( - premineAmount = ethgo.Ether(10) - minterBalance = ethgo.Ether(1e6) + stakeAmount = ethgo.Ether(100) ) - minter, err := wallet.GenerateKey() - require.NoError(t, err) - cluster := framework.NewTestCluster(t, 5, framework.WithEpochReward(int(ethgo.Ether(1).Uint64())), framework.WithEpochSize(5), - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, minter.Address())), framework.WithSecretsCallback(func(addresses []types.Address, config *framework.TestClusterConfig) { - config.Premine = append(config.Premine, fmt.Sprintf("%s:%d", minter.Address(), minterBalance)) - for _, a := range addresses { - config.Premine = append(config.Premine, fmt.Sprintf("%s:%d", a, premineAmount)) - config.StakeAmounts = append(config.StakeAmounts, new(big.Int).Set(premineAmount)) + for range addresses { + config.StakeAmounts = append(config.StakeAmounts, new(big.Int).Set(stakeAmount)) } }), ) @@ -364,13 +306,10 @@ func TestE2E_Consensus_Validator_Unstake(t *testing.T) { srv := cluster.Servers[0] - childChainRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(srv.JSONRPCAddr())) + relayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(srv.JSONRPCAddr())) require.NoError(t, err) - rootChainRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) - require.NoError(t, err) - - validatorAcc, err := sidechain.GetAccountFromDir(srv.DataDir()) + validatorAcc, err := validatorHelper.GetAccountFromDir(srv.DataDir()) require.NoError(t, err) cluster.WaitForReady(t) @@ -384,9 +323,7 @@ func TestE2E_Consensus_Validator_Unstake(t *testing.T) { // wait for some rewards to get accumulated require.NoError(t, cluster.WaitForBlock(polybftCfg.EpochSize*3, time.Minute)) - validatorInfo, err := sidechain.GetValidatorInfo(validatorAddr, - polybftCfg.Bridge.CustomSupernetManagerAddr, polybftCfg.Bridge.StakeManagerAddr, - polybftCfg.SupernetID, rootChainRelayer, childChainRelayer) + validatorInfo, err := validatorHelper.GetValidatorInfo(validatorAddr, relayer) require.NoError(t, err) require.True(t, validatorInfo.IsActive) @@ -400,41 +337,20 @@ func TestE2E_Consensus_Validator_Unstake(t *testing.T) { // unstake entire balance (which should remove validator from the validator set in next epoch) require.NoError(t, srv.Unstake(initialStake)) - // wait for one epoch to withdraw from child - require.NoError(t, cluster.WaitForBlock(polybftCfg.EpochSize*4, time.Minute)) - - // withdraw from child - require.NoError(t, srv.WithdrawChildChain()) - currentBlock, err := srv.JSONRPC().Eth().GetBlockByNumber(ethgo.Latest, false) require.NoError(t, err) - currentExtra, err := polybft.GetIbftExtra(currentBlock.ExtraData) - require.NoError(t, err) - - t.Logf("Latest block number: %d, epoch number: %d\n", currentBlock.Number, currentExtra.Checkpoint.EpochNumber) - - currentEpoch := currentExtra.Checkpoint.EpochNumber - - // wait for checkpoint to be submitted - require.NoError(t, waitForRootchainEpoch(currentEpoch, time.Minute, - rootChainRelayer, polybftCfg.Bridge.CheckpointManagerAddr)) - - exitEventID := uint64(1) - - // send exit transaction to exit helper - err = cluster.Bridge.SendExitTransaction(polybftCfg.Bridge.ExitHelperAddr, exitEventID, srv.JSONRPCAddr()) - require.NoError(t, err) + // wait for couple of epochs to withdraw stake + require.NoError(t, cluster.WaitForBlock(currentBlock.Number+(polybftCfg.EpochSize*2), time.Minute)) + require.NoError(t, srv.WitdhrawStake()) // check that validator is no longer active (out of validator set) - validatorInfo, err = sidechain.GetValidatorInfo(validatorAddr, - polybftCfg.Bridge.CustomSupernetManagerAddr, polybftCfg.Bridge.StakeManagerAddr, - polybftCfg.SupernetID, rootChainRelayer, childChainRelayer) + validatorInfo, err = validatorHelper.GetValidatorInfo(validatorAddr, relayer) require.NoError(t, err) require.False(t, validatorInfo.IsActive) require.True(t, validatorInfo.Stake.Cmp(big.NewInt(0)) == 0) - t.Logf("Stake (after unstake)=%d\n", validatorInfo.Stake) + t.Logf("Stake (after unstake and withdraw)=%d\n", validatorInfo.Stake) balanceBeforeRewardsWithdraw, err := srv.JSONRPC().Eth().GetBalance(validatorAcc.Ecdsa.Address(), ethgo.Latest) require.NoError(t, err) @@ -447,37 +363,12 @@ func TestE2E_Consensus_Validator_Unstake(t *testing.T) { require.NoError(t, err) t.Logf("Balance (after withdrawal of rewards)=%s\n", newValidatorBalance) require.True(t, newValidatorBalance.Cmp(balanceBeforeRewardsWithdraw) > 0) - - l1Relayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) - require.NoError(t, err) - - checkpointManagerAddr := ethgo.Address(polybftCfg.Bridge.CheckpointManagerAddr) - - // query rootchain validator set and make sure that validator which unstaked all the funds isn't present in validator set anymore - // (execute it multiple times if needed, because it is unknown in advance how much time it is going to take until checkpoint is submitted) - rootchainValidators := []*polybft.ValidatorInfo{} - err = cluster.Bridge.WaitUntil(time.Second, 10*time.Second, func() (bool, error) { - rootchainValidators, err = getCheckpointManagerValidators(l1Relayer, checkpointManagerAddr) - if err != nil { - return true, err - } - - return len(rootchainValidators) == 4, nil - }) - require.NoError(t, err) - require.Equal(t, 4, len(rootchainValidators)) - - for _, validator := range rootchainValidators { - if validator.Address == validatorAddr { - t.Fatalf("not expected to find validator %v in the current validator set", validator.Address) - } - } } func TestE2E_Consensus_MintableERC20NativeToken(t *testing.T) { const ( validatorCount = 5 - epochSize = 5 + epochSize = 10 tokenName = "Edge Coin" tokenSymbol = "EDGE" @@ -491,14 +382,19 @@ func TestE2E_Consensus_MintableERC20NativeToken(t *testing.T) { minter, err := wallet.GenerateKey() require.NoError(t, err) + receiver, err := wallet.GenerateKey() + require.NoError(t, err) + // because we are using native token as reward wallet, and it has default premine balance initialTotalSupply := new(big.Int).Set(command.DefaultPremineBalance) cluster := framework.NewTestCluster(t, validatorCount, framework.WithNativeTokenConfig( - fmt.Sprintf("%s:%s:%d:true:%s", tokenName, tokenSymbol, decimals, minter.Address())), + fmt.Sprintf("%s:%s:%d", tokenName, tokenSymbol, decimals)), + framework.WithBladeAdmin(minter.Address().String()), framework.WithEpochSize(epochSize), + framework.WithBaseFeeConfig(""), framework.WithSecretsCallback(func(addrs []types.Address, config *framework.TestClusterConfig) { config.Premine = append(config.Premine, fmt.Sprintf("%s:%d", minter.Address(), initMinterBalance)) initialTotalSupply.Add(initialTotalSupply, initMinterBalance) @@ -538,50 +434,47 @@ func TestE2E_Consensus_MintableERC20NativeToken(t *testing.T) { require.Equal(t, decimals, decimalsCount) // send mint transactions - mintFn, exists := contractsapi.NativeERC20Mintable.Abi.Methods["mint"] - require.True(t, exists) - - mintAmount := ethgo.Ether(10) + mintAmount := ethgo.Ether(1) nativeTokenAddr := ethgo.Address(contracts.NativeERC20TokenContract) // make sure minter account can mint tokens - for _, addr := range validatorsAddrs { - balance, err := targetJSONRPC.Eth().GetBalance(ethgo.Address(addr), ethgo.Latest) - require.NoError(t, err) - t.Logf("Pre-mint balance: %v=%d\n", addr, balance) - - mintInput, err := mintFn.Encode([]interface{}{addr, mintAmount}) - require.NoError(t, err) + receiverAddr := types.Address(receiver.Address()) + balanceBefore, err := targetJSONRPC.Eth().GetBalance(ethgo.Address(receiverAddr), ethgo.Latest) + require.NoError(t, err) + t.Logf("Pre-mint balance: %v=%d\n", receiverAddr, balanceBefore) - receipt, err := relayer.SendTransaction( - ðgo.Transaction{ - To: &nativeTokenAddr, - Input: mintInput, - Type: ethgo.TransactionDynamicFee, - }, minter) - require.NoError(t, err) - require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) + mintFn := &contractsapi.MintRootERC20Fn{ + To: receiverAddr, + Amount: mintAmount, + } - balance, err = targetJSONRPC.Eth().GetBalance(ethgo.Address(addr), ethgo.Latest) - require.NoError(t, err) + mintInput, err := mintFn.EncodeAbi() + require.NoError(t, err) - t.Logf("Post-mint balance: %v=%d\n", addr, balance) - require.Equal(t, new(big.Int).Add(initValidatorsBalance, mintAmount), balance) - } + receipt, err := relayer.SendTransaction( + ðgo.Transaction{ + To: &nativeTokenAddr, + Input: mintInput, + Type: ethgo.TransactionDynamicFee, + }, minter) + require.NoError(t, err) + require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) - // assert that minter balance remained the same - minterBalance, err := targetJSONRPC.Eth().GetBalance(minter.Address(), ethgo.Latest) + balanceAfter, err := targetJSONRPC.Eth().GetBalance(ethgo.Address(receiverAddr), ethgo.Latest) require.NoError(t, err) - require.Equal(t, initMinterBalance, minterBalance) + + t.Logf("Post-mint balance: %v=%d\n", receiverAddr, balanceAfter) + require.True(t, balanceAfter.Cmp(new(big.Int).Add(mintAmount, balanceBefore)) >= 0) // try sending mint transaction from non minter account and make sure it would fail - nonMinterAcc, err := sidechain.GetAccountFromDir(cluster.Servers[1].DataDir()) + nonMinterAcc, err := validatorHelper.GetAccountFromDir(cluster.Servers[1].DataDir()) require.NoError(t, err) - mintInput, err := mintFn.Encode([]interface{}{validatorsAddrs[0], ethgo.Ether(1)}) + mintFn = &contractsapi.MintRootERC20Fn{To: validatorsAddrs[0], Amount: mintAmount} + mintInput, err = mintFn.EncodeAbi() require.NoError(t, err) - receipt, err := relayer.SendTransaction( + receipt, err = relayer.SendTransaction( ðgo.Transaction{ To: &nativeTokenAddr, Input: mintInput, @@ -608,21 +501,13 @@ func TestE2E_Consensus_CustomRewardToken(t *testing.T) { // first validator is the owner of ChildValidator set smart contract owner := cluster.Servers[0] - childChainRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(owner.JSONRPCAddr())) - require.NoError(t, err) - - rootChainRelayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Bridge.JSONRPCAddr())) - require.NoError(t, err) - - polybftConfig, err := polybft.LoadPolyBFTConfig(path.Join(cluster.Config.TmpDir, chainConfigFileName)) + relayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(owner.JSONRPCAddr())) require.NoError(t, err) - validatorAcc, err := sidechain.GetAccountFromDir(owner.DataDir()) + validatorAcc, err := validatorHelper.GetAccountFromDir(owner.DataDir()) require.NoError(t, err) - validatorInfo, err := sidechain.GetValidatorInfo(validatorAcc.Ecdsa.Address(), - polybftConfig.Bridge.CustomSupernetManagerAddr, polybftConfig.Bridge.StakeManagerAddr, - polybftConfig.SupernetID, rootChainRelayer, childChainRelayer) + validatorInfo, err := validatorHelper.GetValidatorInfo(validatorAcc.Ecdsa.Address(), relayer) t.Logf("[Validator#%v] Witdhrawable rewards=%d\n", validatorInfo.Address, validatorInfo.WithdrawableRewards) require.NoError(t, err) @@ -633,22 +518,20 @@ func TestE2E_Consensus_CustomRewardToken(t *testing.T) { // and check if balance of sender, receiver, burn contract and miner is updates correctly // in accordance with EIP-1559 specifications func TestE2E_Consensus_EIP1559Check(t *testing.T) { - sender1, err := wallet.GenerateKey() - require.NoError(t, err) - - sender2, err := wallet.GenerateKey() - require.NoError(t, err) - - recipientKey, err := wallet.GenerateKey() + sender, err := wallet.GenerateKey() require.NoError(t, err) - recipient := recipientKey.Address() + recipient := ethgo.Address(types.StringToAddress("1234")) - // first account should have some matics premined + // sender must have premined some native tokens cluster := framework.NewTestCluster(t, 5, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, sender1.Address())), - framework.WithPremine(types.Address(sender1.Address()), types.Address(sender2.Address())), - framework.WithBurnContract(&polybft.BurnContractInfo{BlockNumber: 0, Address: types.ZeroAddress}), + framework.WithPremine(types.Address(sender.Address())), + framework.WithBaseFeeConfig(""), + framework.WithSecretsCallback(func(a []types.Address, config *framework.TestClusterConfig) { + for range a { + config.StakeAmounts = append(config.StakeAmounts, command.DefaultPremineBalance) + } + }), ) defer cluster.Stop() @@ -656,26 +539,25 @@ func TestE2E_Consensus_EIP1559Check(t *testing.T) { client := cluster.Servers[0].JSONRPC().Eth() - waitUntilBalancesChanged := func(acct ethgo.Address, bal *big.Int) error { - err := cluster.WaitUntil(30*time.Second, 2*time.Second, func() bool { + waitUntilBalancesChanged := func(acct ethgo.Address, initialBalance *big.Int) error { + err := cluster.WaitUntil(30*time.Second, 1*time.Second, func() bool { balance, err := client.GetBalance(recipient, ethgo.Latest) if err != nil { return true } - return balance.Cmp(bal) > 0 + return balance.Cmp(initialBalance) > 0 }) return err } - relayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Servers[0].JSONRPCAddr())) + relayer, err := txrelayer.NewTxRelayer(txrelayer.WithClient(cluster.Servers[0].JSONRPC())) require.NoError(t, err) - // create and send tx sendAmount := ethgo.Gwei(1) - txn := []*ethgo.Transaction{ + txns := []*ethgo.Transaction{ { Value: sendAmount, To: &recipient, @@ -698,37 +580,32 @@ func TestE2E_Consensus_EIP1559Check(t *testing.T) { var prevMiner ethgo.Address - for i := 0; i < 2; i++ { - curTxn := txn[i] - - senderInitialBalance, _ := client.GetBalance(sender1.Address(), ethgo.Latest) + for i, txn := range txns { + senderInitialBalance, _ := client.GetBalance(sender.Address(), ethgo.Latest) receiverInitialBalance, _ := client.GetBalance(recipient, ethgo.Latest) burnContractInitialBalance, _ := client.GetBalance(ethgo.Address(types.ZeroAddress), ethgo.Latest) - receipt, err := relayer.SendTransaction(curTxn, sender1) + receipt, err := relayer.SendTransaction(txn, sender) require.NoError(t, err) + require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) - // wait for balance to get changed + // wait for recipient's balance to increase err = waitUntilBalancesChanged(recipient, receiverInitialBalance) require.NoError(t, err) - // Retrieve the transaction receipt - txReceipt, err := client.GetTransactionByHash(receipt.TransactionHash) - require.NoError(t, err) - - block, _ := client.GetBlockByHash(txReceipt.BlockHash, true) + block, _ := client.GetBlockByHash(receipt.BlockHash, true) finalMinerFinalBalance, _ := client.GetBalance(block.Miner, ethgo.Latest) if i == 0 { prevMiner = block.Miner } - senderFinalBalance, _ := client.GetBalance(sender1.Address(), ethgo.Latest) + senderFinalBalance, _ := client.GetBalance(sender.Address(), ethgo.Latest) receiverFinalBalance, _ := client.GetBalance(recipient, ethgo.Latest) burnContractFinalBalance, _ := client.GetBalance(ethgo.Address(types.ZeroAddress), ethgo.Latest) - diffReciverBalance := new(big.Int).Sub(receiverFinalBalance, receiverInitialBalance) - assert.Equal(t, sendAmount, diffReciverBalance, "Receiver balance should be increased by send amount") + diffReceiverBalance := new(big.Int).Sub(receiverFinalBalance, receiverInitialBalance) + require.Equal(t, sendAmount, diffReceiverBalance, "Receiver balance should be increased by send amount") if i == 1 && prevMiner != block.Miner { initialMinerBalance = big.NewInt(0) @@ -738,12 +615,146 @@ func TestE2E_Consensus_EIP1559Check(t *testing.T) { diffSenderBalance := new(big.Int).Sub(senderInitialBalance, senderFinalBalance) diffMinerBalance := new(big.Int).Sub(finalMinerFinalBalance, initialMinerBalance) - diffSenderBalance.Sub(diffSenderBalance, diffReciverBalance) + diffSenderBalance.Sub(diffSenderBalance, diffReceiverBalance) diffSenderBalance.Sub(diffSenderBalance, diffBurnContractBalance) diffSenderBalance.Sub(diffSenderBalance, diffMinerBalance) - assert.Zero(t, diffSenderBalance.Int64(), "Sender balance should be decreased by send amount + gas") + require.Zero(t, diffSenderBalance.Int64(), "Sender balance should be decreased by send amount + gas") initialMinerBalance = finalMinerFinalBalance } } + +func TestE2E_Consensus_ChangeVotingPowerByStakingPendingRewards(t *testing.T) { + const ( + votingPowerChanges = 2 + epochSize = 10 + numOfEpochsToCheckChange = 2 + ) + + stakeAmount := ethgo.Ether(1) + + cluster := framework.NewTestCluster(t, 5, + framework.WithEpochSize(epochSize), + framework.WithEpochReward(1000000), + framework.WithSecretsCallback(func(addresses []types.Address, config *framework.TestClusterConfig) { + for range addresses { + config.StakeAmounts = append(config.StakeAmounts, stakeAmount) + } + }), + ) + defer cluster.Stop() + + // load polybft config + polybftCfg, err := polybft.LoadPolyBFTConfig(path.Join(cluster.Config.TmpDir, chainConfigFileName)) + require.NoError(t, err) + + validatorSecretFiles, err := genesis.GetValidatorKeyFiles(cluster.Config.TmpDir, cluster.Config.ValidatorPrefix) + require.NoError(t, err) + + votingPowerChangeValidators := make([]ethgo.Address, votingPowerChanges) + + for i := 0; i < votingPowerChanges; i++ { + validator, err := validatorHelper.GetAccountFromDir(path.Join(cluster.Config.TmpDir, validatorSecretFiles[i])) + require.NoError(t, err) + + votingPowerChangeValidators[i] = validator.Ecdsa.Address() + } + + // tx relayer + relayer, err := txrelayer.NewTxRelayer(txrelayer.WithIPAddress(cluster.Servers[0].JSONRPCAddr())) + require.NoError(t, err) + + epochEndingBlock := uint64(2 * epochSize) + + // waiting two epochs, so that some rewards get accumulated + require.NoError(t, cluster.WaitForBlock(epochEndingBlock, 1*time.Minute)) + + queryValidators := func(handler func(idx int, validatorInfo *polybft.ValidatorInfo)) { + for i, validatorAddr := range votingPowerChangeValidators { + // query validator info + validatorInfo, err := validatorHelper.GetValidatorInfo( + validatorAddr, + relayer) + require.NoError(t, err) + + handler(i, validatorInfo) + } + } + + bigZero := big.NewInt(0) + + // validatorsMap holds only changed validators + validatorsMap := make(map[ethgo.Address]*polybft.ValidatorInfo, votingPowerChanges) + + queryValidators(func(idx int, validator *polybft.ValidatorInfo) { + t.Logf("[Validator#%d] Voting power (original)=%d, rewards=%d\n", + idx+1, validator.Stake, validator.WithdrawableRewards) + + validatorsMap[validator.Address] = validator + validatorSrv := cluster.Servers[idx] + + // validator should have some withdrawable rewards by now + require.True(t, validator.WithdrawableRewards.Cmp(bigZero) > 0) + + // withdraw pending rewards + require.NoError(t, validatorSrv.WithdrawRewards()) + + // stake withdrawable rewards (since rewards are in native erc20 token in this test) + require.NoError(t, validatorSrv.Stake(polybftCfg, validator.WithdrawableRewards)) + }) + + queryValidators(func(idx int, validator *polybft.ValidatorInfo) { + t.Logf("[Validator#%d] Voting power (after stake)=%d\n", idx+1, validator.Stake) + + previousValidatorInfo := validatorsMap[validator.Address] + stakedAmount := new(big.Int).Add(previousValidatorInfo.WithdrawableRewards, previousValidatorInfo.Stake) + + // assert that total stake has increased by staked amount + require.Equal(t, stakedAmount, validator.Stake) + + validatorsMap[validator.Address] = validator + }) + + // start checking for delta from this epoch ending block + epochEndingBlock += epochSize + + didVotingPowerChangeInConsensus := false + + // we will check for couple of epoch ending blocks to see Voting Power change + for i := 0; i < numOfEpochsToCheckChange; i++ { + require.NoError(t, cluster.WaitForBlock(epochEndingBlock, time.Minute)) + + latestBlock, err := cluster.Servers[0].JSONRPC().Eth().GetBlockByNumber(ethgo.BlockNumber(epochEndingBlock), false) + require.NoError(t, err) + + epochEndingBlock += epochSize + + currentExtra, err := polybft.GetIbftExtra(latestBlock.ExtraData) + require.NoError(t, err) + + if currentExtra.Validators == nil || currentExtra.Validators.IsEmpty() { + continue + } + + for addr, validator := range validatorsMap { + a := types.Address(addr) + + if !currentExtra.Validators.Updated.ContainsAddress(a) { + continue + } + + if currentExtra.Validators.Updated.GetValidatorMetadata(a).VotingPower.Cmp(validator.Stake) != 0 { + continue + } + } + + didVotingPowerChangeInConsensus = true + + break + } + + if !didVotingPowerChangeInConsensus { + t.Errorf("voting power did not change in consensus for %d epochs", numOfEpochsToCheckChange) + } +} diff --git a/e2e-polybft/e2e/helpers_test.go b/e2e-polybft/e2e/helpers_test.go index 7a49362eba..f29a17eefb 100644 --- a/e2e-polybft/e2e/helpers_test.go +++ b/e2e-polybft/e2e/helpers_test.go @@ -296,7 +296,7 @@ func erc721OwnerOf(t *testing.T, tokenID *big.Int, tokenAddr types.Address, rela func queryNativeERC20Metadata(t *testing.T, funcName string, abiType *abi.Type, relayer txrelayer.TxRelayer) interface{} { t.Helper() - valueHex, err := ABICall(relayer, contractsapi.NativeERC20Mintable, + valueHex, err := ABICall(relayer, contractsapi.NativeERC20, ethgo.Address(contracts.NativeERC20TokenContract), ethgo.ZeroAddress, funcName) require.NoError(t, err) diff --git a/e2e-polybft/e2e/jsonrpc_test.go b/e2e-polybft/e2e/jsonrpc_test.go index a8382eff36..e6b5064c86 100644 --- a/e2e-polybft/e2e/jsonrpc_test.go +++ b/e2e-polybft/e2e/jsonrpc_test.go @@ -1,7 +1,6 @@ package e2e import ( - "fmt" "math/big" "testing" @@ -26,7 +25,6 @@ func TestE2E_JsonRPC(t *testing.T) { require.NoError(t, err) cluster := framework.NewTestCluster(t, 4, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, acct.Address())), framework.WithPremine(types.Address(acct.Address())), ) defer cluster.Stop() diff --git a/e2e-polybft/e2e/migration_test.go b/e2e-polybft/e2e/migration_test.go index f3a931e9d4..e7dc6fd5de 100644 --- a/e2e-polybft/e2e/migration_test.go +++ b/e2e-polybft/e2e/migration_test.go @@ -1,6 +1,7 @@ package e2e import ( + "context" "os" "path/filepath" "testing" @@ -31,9 +32,13 @@ func TestE2E_Migration(t *testing.T) { srvs := framework.NewTestServers(t, 1, func(config *framework.TestServerConfig) { config.SetConsensus(framework.ConsensusDev) config.Premine(types.Address(userAddr), initialBalance) + config.SetBaseFeeConfig("") }) + srv := srvs[0] + require.NoError(t, srv.WaitForReady(context.TODO())) + rpcClient := srv.JSONRPC() // Fetch the balances before sending @@ -59,13 +64,14 @@ func TestE2E_Migration(t *testing.T) { //send transaction to user2 sendAmount := ethgo.Gwei(10000) - receipt, err := relayer.SendTransaction(ðgo.Transaction{ - From: userAddr, - To: &userAddr2, - Gas: 1000000, - Value: sendAmount, - GasPrice: ethgo.Gwei(2).Uint64(), - }, userKey) + receipt, err := relayer.SendTransaction( + ðgo.Transaction{ + From: userAddr, + To: &userAddr2, + Gas: 1000000, + Value: sendAmount, + GasPrice: ethgo.Gwei(2).Uint64(), + }, userKey) require.NoError(t, err) require.NotNil(t, receipt) diff --git a/e2e-polybft/e2e/network_test.go b/e2e-polybft/e2e/network_test.go index 7129244d70..c04a1320c1 100644 --- a/e2e-polybft/e2e/network_test.go +++ b/e2e-polybft/e2e/network_test.go @@ -21,7 +21,6 @@ func TestE2E_NetworkDiscoveryProtocol(t *testing.T) { // create cluster cluster := framework.NewTestCluster(t, validatorCount, - framework.WithTestRewardToken(), framework.WithNonValidators(nonValidatorCount), framework.WithBootnodeCount(1)) defer cluster.Stop() diff --git a/e2e-polybft/e2e/txpool_test.go b/e2e-polybft/e2e/txpool_test.go index 257939b4ac..f0f0e2320a 100644 --- a/e2e-polybft/e2e/txpool_test.go +++ b/e2e-polybft/e2e/txpool_test.go @@ -1,7 +1,6 @@ package e2e import ( - "fmt" "math/big" "sync" "testing" @@ -13,7 +12,6 @@ import ( "github.com/umbracle/ethgo/jsonrpc" "github.com/umbracle/ethgo/wallet" - "github.com/0xPolygon/polygon-edge/consensus/polybft" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" "github.com/0xPolygon/polygon-edge/e2e-polybft/framework" "github.com/0xPolygon/polygon-edge/txrelayer" @@ -26,9 +24,9 @@ func TestE2E_TxPool_Transfer(t *testing.T) { require.NoError(t, err) cluster := framework.NewTestCluster(t, 5, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, sender.Address())), framework.WithPremine(types.Address(sender.Address())), - framework.WithBurnContract(&polybft.BurnContractInfo{BlockNumber: 0, Address: types.ZeroAddress})) + framework.WithBaseFeeConfig(""), + ) defer cluster.Stop() cluster.WaitForReady(t) @@ -102,9 +100,8 @@ func TestE2E_TxPool_Transfer_Linear(t *testing.T) { // first account should have some matics premined cluster := framework.NewTestCluster(t, 5, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, premine.Address())), framework.WithPremine(types.Address(premine.Address())), - framework.WithBurnContract(&polybft.BurnContractInfo{BlockNumber: 0, Address: types.ZeroAddress}), + framework.WithBaseFeeConfig(""), ) defer cluster.Stop() @@ -191,7 +188,6 @@ func TestE2E_TxPool_TransactionWithHeaderInstructions(t *testing.T) { require.NoError(t, err) cluster := framework.NewTestCluster(t, 4, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, sidechainKey.Address())), framework.WithPremine(types.Address(sidechainKey.Address())), ) defer cluster.Stop() @@ -237,9 +233,8 @@ func TestE2E_TxPool_BroadcastTransactions(t *testing.T) { // First account should have some matics premined cluster := framework.NewTestCluster(t, 5, - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, sender.Address())), framework.WithPremine(types.Address(sender.Address())), - framework.WithBurnContract(&polybft.BurnContractInfo{BlockNumber: 0, Address: types.ZeroAddress}), + framework.WithBaseFeeConfig(""), ) defer cluster.Stop() diff --git a/e2e-polybft/framework/test-bridge.go b/e2e-polybft/framework/test-bridge.go index 5d66c72bee..5a0cf42143 100644 --- a/e2e-polybft/framework/test-bridge.go +++ b/e2e-polybft/framework/test-bridge.go @@ -1,24 +1,19 @@ package framework import ( - "context" "errors" "fmt" "math/big" "path" "strconv" - "strings" "testing" "time" - "golang.org/x/sync/errgroup" - "github.com/0xPolygon/polygon-edge/command" bridgeCommon "github.com/0xPolygon/polygon-edge/command/bridge/common" + "github.com/0xPolygon/polygon-edge/command/bridge/server" "github.com/0xPolygon/polygon-edge/command/genesis" cmdHelper "github.com/0xPolygon/polygon-edge/command/helper" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" - "github.com/0xPolygon/polygon-edge/command/rootchain/server" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" "github.com/0xPolygon/polygon-edge/consensus/polybft" "github.com/0xPolygon/polygon-edge/consensus/polybft/wallet" @@ -50,7 +45,7 @@ func NewTestBridge(t *testing.T, clusterConfig *TestClusterConfig) (*TestBridge, func (t *TestBridge) Start() error { // Build arguments args := []string{ - "rootchain", + "bridge", "server", "--data-dir", t.clusterConfig.Dir("test-rootchain"), } @@ -307,16 +302,9 @@ func (t *TestBridge) cmdRun(args ...string) error { // deployRootchainContracts deploys and initializes rootchain contracts func (t *TestBridge) deployRootchainContracts(genesisPath string) error { - polybftConfig, err := polybft.LoadPolyBFTConfig(genesisPath) - if err != nil { - return err - } - args := []string{ - "rootchain", + "bridge", "deploy", - "--stake-manager", polybftConfig.Bridge.StakeManagerAddr.String(), - "--stake-token", polybftConfig.Bridge.StakeTokenAddr.String(), "--proxy-contracts-admin", t.clusterConfig.GetProxyContractsAdmin(), "--genesis", genesisPath, "--test", @@ -330,7 +318,7 @@ func (t *TestBridge) deployRootchainContracts(genesisPath string) error { } // fundAddressesOnRoot sends predefined amount of tokens to rootchain addresses -func (t *TestBridge) fundAddressesOnRoot(tokenConfig *polybft.TokenConfig, polybftConfig polybft.PolyBFTConfig) error { +func (t *TestBridge) fundAddressesOnRoot(polybftConfig polybft.PolyBFTConfig) error { validatorSecrets, err := genesis.GetValidatorKeyFiles(t.clusterConfig.TmpDir, t.clusterConfig.ValidatorPrefix) if err != nil { return fmt.Errorf("could not get validator secrets on initial rootchain funding of genesis validators: %w", err) @@ -345,23 +333,20 @@ func (t *TestBridge) fundAddressesOnRoot(tokenConfig *polybft.TokenConfig, polyb balances[i] = command.DefaultPremineBalance } - if err := t.FundValidators(polybftConfig.Bridge.StakeTokenAddr, + if err := t.FundValidators( secrets, balances); err != nil { return fmt.Errorf("failed to fund validators on the rootchain: %w", err) } // then fund all other addresses if token is non-mintable // so that they can do premine on SupernetMAnager - if tokenConfig.IsMintable || len(t.clusterConfig.Premine) == 0 { + if len(t.clusterConfig.Premine) == 0 { return nil } // non-validator addresses don't need to mint stake token, // they only need to be funded with root token - args := []string{ - "rootchain", - "fund", - } + args := []string{"bridge", "fund"} for _, premineRaw := range t.clusterConfig.Premine { premineInfo, err := cmdHelper.ParsePremineInfo(premineRaw) @@ -380,145 +365,13 @@ func (t *TestBridge) fundAddressesOnRoot(tokenConfig *polybft.TokenConfig, polyb return nil } -func (t *TestBridge) whitelistValidators(validatorAddresses []types.Address, - polybftConfig polybft.PolyBFTConfig) error { - addressesAsString := make([]string, len(validatorAddresses)) - for i := 0; i < len(validatorAddresses); i++ { - addressesAsString[i] = validatorAddresses[i].String() - } - - args := []string{ - "polybft", - "whitelist-validators", - "--addresses", strings.Join(addressesAsString, ","), - "--jsonrpc", t.JSONRPCAddr(), - "--supernet-manager", polybftConfig.Bridge.CustomSupernetManagerAddr.String(), - "--private-key", rootHelper.TestAccountPrivKey, - } - - if err := t.cmdRun(args...); err != nil { - return fmt.Errorf("failed to whitelist genesis validators on supernet manager: %w", err) - } - - return nil -} - -func (t *TestBridge) registerGenesisValidators(polybftConfig polybft.PolyBFTConfig) error { - validatorSecrets, err := genesis.GetValidatorKeyFiles(t.clusterConfig.TmpDir, t.clusterConfig.ValidatorPrefix) - if err != nil { - return fmt.Errorf("could not get validator secrets on whitelist of genesis validators: %w", err) - } - - g, ctx := errgroup.WithContext(context.Background()) - - for _, secret := range validatorSecrets { - secret := secret - - g.Go(func() error { - select { - case <-ctx.Done(): - return ctx.Err() - default: - args := []string{ - "polybft", - "register-validator", - "--jsonrpc", t.JSONRPCAddr(), - "--supernet-manager", polybftConfig.Bridge.CustomSupernetManagerAddr.String(), - "--" + polybftsecrets.AccountDirFlag, path.Join(t.clusterConfig.TmpDir, secret), - } - - if err := t.cmdRun(args...); err != nil { - return fmt.Errorf("failed to register genesis validator on supernet manager: %w", err) - } - - return nil - } - }) - } - - return g.Wait() -} - -func (t *TestBridge) initialStakingOfGenesisValidators(polybftConfig polybft.PolyBFTConfig) error { - validatorSecrets, err := genesis.GetValidatorKeyFiles(t.clusterConfig.TmpDir, t.clusterConfig.ValidatorPrefix) - if err != nil { - return fmt.Errorf("could not get validator secrets on initial staking of genesis validators: %w", err) - } - - g, ctx := errgroup.WithContext(context.Background()) - - for i, secret := range validatorSecrets { - secret := secret - i := i - - g.Go(func() error { - select { - case <-ctx.Done(): - return ctx.Err() - default: - args := []string{ - "polybft", - "stake", - "--jsonrpc", t.JSONRPCAddr(), - "--stake-manager", polybftConfig.Bridge.StakeManagerAddr.String(), - "--" + polybftsecrets.AccountDirFlag, path.Join(t.clusterConfig.TmpDir, secret), - "--amount", t.getStakeAmount(i).String(), - "--supernet-id", strconv.FormatInt(polybftConfig.SupernetID, 10), - "--stake-token", polybftConfig.Bridge.StakeTokenAddr.String(), - } - - if err := t.cmdRun(args...); err != nil { - return fmt.Errorf("failed to do initial staking for genesis validator on stake manager: %w", err) - } - - return nil - } - }) - } - - return g.Wait() -} - -func (t *TestBridge) getStakeAmount(validatorIndex int) *big.Int { - l := len(t.clusterConfig.StakeAmounts) - if l == 0 || l <= validatorIndex { - return command.DefaultStake - } - - return t.clusterConfig.StakeAmounts[validatorIndex] -} - -func (t *TestBridge) finalizeGenesis(genesisPath string, polybftConfig polybft.PolyBFTConfig) error { - args := []string{ - "polybft", - "supernet", - "--jsonrpc", t.JSONRPCAddr(), - "--private-key", rootHelper.TestAccountPrivKey, - "--genesis", genesisPath, - "--supernet-manager", polybftConfig.Bridge.CustomSupernetManagerAddr.String(), - "--finalize-genesis-set", - "--enable-staking", - } - - if err := t.cmdRun(args...); err != nil { - return fmt.Errorf("failed to finalize genesis validators on supernet manager: %w", err) - } - - return nil -} - // FundValidators sends tokens to a rootchain validators -func (t *TestBridge) FundValidators(tokenAddress types.Address, secretsPaths []string, amounts []*big.Int) error { +func (t *TestBridge) FundValidators(secretsPaths []string, amounts []*big.Int) error { if len(secretsPaths) != len(amounts) { return errors.New("expected the same length of secrets paths and amounts") } - args := []string{ - "rootchain", - "fund", - "--stake-token", tokenAddress.String(), - "--mint", - } + args := []string{"bridge", "fund"} for i := 0; i < len(secretsPaths); i++ { secretsManager, err := polybftsecrets.GetSecretsManager(secretsPaths[i], "", true) @@ -541,140 +394,3 @@ func (t *TestBridge) FundValidators(tokenAddress types.Address, secretsPaths []s return nil } - -func (t *TestBridge) deployStakeManager(genesisPath string) error { - args := []string{ - "polybft", - "stake-manager-deploy", - "--jsonrpc", t.JSONRPCAddr(), - "--genesis", genesisPath, - "--proxy-contracts-admin", t.clusterConfig.GetProxyContractsAdmin(), - "--test", - } - - if err := t.cmdRun(args...); err != nil { - return fmt.Errorf("failed to deploy stake manager contract: %w", err) - } - - return nil -} - -func (t *TestBridge) mintNativeRootToken(validatorAddresses []types.Address, tokenConfig *polybft.TokenConfig, - polybftConfig polybft.PolyBFTConfig) error { - if tokenConfig.IsMintable { - // if token is mintable, it is premined in genesis command, - // so we just return here - return nil - } - - // if token is non-mintable, then to do premine we first need to mint those tokens - // to validators and other provided addresses - args := []string{ - "bridge", - "mint-erc20", - "--jsonrpc", t.JSONRPCAddr(), - "--erc20-token", polybftConfig.Bridge.RootNativeERC20Addr.String(), - } - - // mint something for every validator - for _, addr := range validatorAddresses { - args = append(args, "--addresses", addr.String()) - args = append(args, "--amounts", command.DefaultPremineBalance.String()) - } - - // mint something to others as well - for _, premineRaw := range t.clusterConfig.Premine { - premineInfo, err := cmdHelper.ParsePremineInfo(premineRaw) - if err != nil { - return err - } - - args = append(args, "--addresses", premineInfo.Address.String()) - args = append(args, "--amounts", premineInfo.Amount.String()) - } - - return t.cmdRun(args...) -} - -func (t *TestBridge) premineNativeRootToken(tokenConfig *polybft.TokenConfig, - polybftConfig polybft.PolyBFTConfig) error { - if tokenConfig.IsMintable { - // if token is mintable, it is premined in genesis command, - // so we just return here - return nil - } - - validatorSecrets, err := genesis.GetValidatorKeyFiles(t.clusterConfig.TmpDir, t.clusterConfig.ValidatorPrefix) - if err != nil { - return fmt.Errorf("could not get validator secrets on premining native root"+ - " token for genesis validators: %w", err) - } - - premineCmdArgs := func(secret, key string, amount *big.Int) error { - args := []string{ - "rootchain", - "premine", - "--jsonrpc", t.JSONRPCAddr(), - "--supernet-manager", polybftConfig.Bridge.CustomSupernetManagerAddr.String(), - "--amount", amount.String(), - "--erc20-token", polybftConfig.Bridge.RootNativeERC20Addr.String(), - "--root-erc20-predicate", polybftConfig.Bridge.RootERC20PredicateAddr.String(), - } - - if secret != "" { - args = append(args, "--"+polybftsecrets.AccountDirFlag, path.Join(t.clusterConfig.TmpDir, secret)) - } else { - args = append(args, "--private-key", key) - } - - return t.cmdRun(args...) - } - - g, ctx := errgroup.WithContext(context.Background()) - - // premine validators - for _, secret := range validatorSecrets { - secret := secret - - g.Go(func() error { - select { - case <-ctx.Done(): - return ctx.Err() - default: - if err := premineCmdArgs(secret, "", command.DefaultPremineBalance); err != nil { - return fmt.Errorf("failed to do premine of native root token for genesis validator: %w", - err) - } - - return nil - } - }) - } - - // now premine for other addresses - for _, premineRaw := range t.clusterConfig.Premine { - premineRaw := premineRaw - - g.Go(func() error { - select { - case <-ctx.Done(): - return ctx.Err() - default: - premineInfo, err := cmdHelper.ParsePremineInfo(premineRaw) - if err != nil { - return fmt.Errorf("failed to do premine of native root token for non-validator"+ - " account: %w. premine raw: %s", err, premineRaw) - } - - if err := premineCmdArgs("", premineInfo.Key, premineInfo.Amount); err != nil { - return fmt.Errorf("failed to do premine of native root token for "+ - "non-validator account: %w. premine raw: %s", err, premineRaw) - } - - return nil - } - }) - } - - return g.Wait() -} diff --git a/e2e-polybft/framework/test-cluster.go b/e2e-polybft/framework/test-cluster.go index 794447508a..1f0cc4ce10 100644 --- a/e2e-polybft/framework/test-cluster.go +++ b/e2e-polybft/framework/test-cluster.go @@ -17,6 +17,7 @@ import ( "testing" "time" + "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/command/genesis" "github.com/0xPolygon/polygon-edge/consensus/polybft" "github.com/0xPolygon/polygon-edge/consensus/polybft/contractsapi" @@ -50,7 +51,7 @@ const ( nonValidatorPrefix = "test-non-validator-" // NativeTokenMintableTestCfg is the test native token config for Supernets originated native tokens - NativeTokenMintableTestCfg = "Mintable Edge Coin:MEC:18:true:%s" //nolint:gosec + NativeTokenMintableTestCfg = "Mintable Edge Coin:MEC:18" //nolint:gosec ) type NodeType int @@ -98,18 +99,20 @@ type TestClusterConfig struct { NonValidatorCount int WithLogs bool WithStdout bool + HasBridge bool LogsDir string TmpDir string BlockGasLimit uint64 BlockTime time.Duration - BurnContract *polybft.BurnContractInfo ValidatorPrefix string Binary string ValidatorSetSize uint64 EpochSize int EpochReward int NativeTokenConfigRaw string + BaseFeeConfig string SecretsCallback func([]types.Address, *TestClusterConfig) + BladeAdmin string ContractDeployerAllowListAdmin []types.Address ContractDeployerAllowListEnabled []types.Address @@ -248,6 +251,22 @@ func WithValidatorSnapshot(validatorsLen uint64) ClusterOption { } } +func WithBridge() ClusterOption { + return func(h *TestClusterConfig) { + h.HasBridge = true + } +} + +func WithBaseFeeConfig(config string) ClusterOption { + return func(h *TestClusterConfig) { + if config == "" { + h.BaseFeeConfig = command.DefaultGenesisBaseFeeConfig + } else { + h.BaseFeeConfig = config + } + } +} + func WithGenesisState(databasePath string, stateRoot types.Hash) ClusterOption { return func(h *TestClusterConfig) { h.InitialTrieDB = databasePath @@ -285,12 +304,6 @@ func WithBlockGasLimit(blockGasLimit uint64) ClusterOption { } } -func WithBurnContract(burnContract *polybft.BurnContractInfo) ClusterOption { - return func(h *TestClusterConfig) { - h.BurnContract = burnContract - } -} - func WithNumBlockConfirmations(numBlockConfirmations uint64) ClusterOption { return func(h *TestClusterConfig) { h.NumBlockConfirmations = numBlockConfirmations @@ -399,6 +412,12 @@ func WithProxyContractsAdmin(address string) ClusterOption { } } +func WithBladeAdmin(address string) ClusterOption { + return func(h *TestClusterConfig) { + h.BladeAdmin = address + } +} + func isTrueEnv(e string) bool { return strings.ToLower(os.Getenv(e)) == "true" } @@ -425,6 +444,7 @@ func NewTestCluster(t *testing.T, validatorsCount int, opts ...ClusterOption) *T EpochReward: 1, BlockGasLimit: 1e7, // 10M StakeAmounts: []*big.Int{}, + HasBridge: false, } if config.ValidatorPrefix == "" { @@ -495,6 +515,13 @@ func NewTestCluster(t *testing.T, validatorsCount int, opts ...ClusterOption) *T "--trieroot", cluster.Config.InitialStateRoot.String(), } + bladeAdmin := cluster.Config.BladeAdmin + if cluster.Config.BladeAdmin == "" { + bladeAdmin = addresses[0].String() + } + + args = append(args, "--blade-admin", bladeAdmin) + if cluster.Config.BlockTime != 0 { args = append(args, "--block-time", cluster.Config.BlockTime.String()) @@ -509,30 +536,26 @@ func NewTestCluster(t *testing.T, validatorsCount int, opts ...ClusterOption) *T args = append(args, "--reward-token-code", cluster.Config.TestRewardToken) } - // add optional genesis flags + if cluster.Config.BaseFeeConfig != "" { + args = append(args, "--base-fee-config", cluster.Config.BaseFeeConfig) + } + if cluster.Config.NativeTokenConfigRaw != "" { args = append(args, "--native-token-config", cluster.Config.NativeTokenConfigRaw) } - tokenConfig, err := polybft.ParseRawTokenConfig(cluster.Config.NativeTokenConfigRaw) - require.NoError(t, err) - - if len(cluster.Config.Premine) != 0 && tokenConfig.IsMintable { - // only add premine flags in genesis if token is mintable - for _, premine := range cluster.Config.Premine { - args = append(args, "--premine", premine) - } + for _, premine := range cluster.Config.Premine { + args = append(args, "--premine", premine) } - burnContract := cluster.Config.BurnContract - if burnContract != nil { - args = append(args, "--burn-contract", - fmt.Sprintf("%d:%s:%s", - burnContract.BlockNumber, burnContract.Address, burnContract.DestinationAddress)) + if len(cluster.Config.StakeAmounts) > 0 { + for i, addr := range addresses { + args = append(args, "--stake", fmt.Sprintf("%s:%s", addr.String(), cluster.getStakeAmount(i).String())) + } } validators, err := genesis.ReadValidatorsByPrefix( - cluster.Config.TmpDir, cluster.Config.ValidatorPrefix) + cluster.Config.TmpDir, cluster.Config.ValidatorPrefix, nil) require.NoError(t, err) if cluster.Config.BootnodeCount > 0 { @@ -586,24 +609,26 @@ func NewTestCluster(t *testing.T, validatorsCount int, opts ...ClusterOption) *T strings.Join(sliceAddressToSliceString(cluster.Config.TransactionsBlockListEnabled), ",")) } - if len(cluster.Config.BridgeAllowListAdmin) != 0 { - args = append(args, "--bridge-allow-list-admin", - strings.Join(sliceAddressToSliceString(cluster.Config.BridgeAllowListAdmin), ",")) - } + if cluster.Config.HasBridge { + if len(cluster.Config.BridgeAllowListAdmin) != 0 { + args = append(args, "--bridge-allow-list-admin", + strings.Join(sliceAddressToSliceString(cluster.Config.BridgeAllowListAdmin), ",")) + } - if len(cluster.Config.BridgeAllowListEnabled) != 0 { - args = append(args, "--bridge-allow-list-enabled", - strings.Join(sliceAddressToSliceString(cluster.Config.BridgeAllowListEnabled), ",")) - } + if len(cluster.Config.BridgeAllowListEnabled) != 0 { + args = append(args, "--bridge-allow-list-enabled", + strings.Join(sliceAddressToSliceString(cluster.Config.BridgeAllowListEnabled), ",")) + } - if len(cluster.Config.BridgeBlockListAdmin) != 0 { - args = append(args, "--bridge-block-list-admin", - strings.Join(sliceAddressToSliceString(cluster.Config.BridgeBlockListAdmin), ",")) - } + if len(cluster.Config.BridgeBlockListAdmin) != 0 { + args = append(args, "--bridge-block-list-admin", + strings.Join(sliceAddressToSliceString(cluster.Config.BridgeBlockListAdmin), ",")) + } - if len(cluster.Config.BridgeBlockListEnabled) != 0 { - args = append(args, "--bridge-block-list-enabled", - strings.Join(sliceAddressToSliceString(cluster.Config.BridgeBlockListEnabled), ",")) + if len(cluster.Config.BridgeBlockListEnabled) != 0 { + args = append(args, "--bridge-block-list-enabled", + strings.Join(sliceAddressToSliceString(cluster.Config.BridgeBlockListEnabled), ",")) + } } proxyAdminAddr := cluster.Config.ProxyContractsAdmin @@ -617,50 +642,22 @@ func NewTestCluster(t *testing.T, validatorsCount int, opts ...ClusterOption) *T require.NoError(t, err) } - // start bridge - cluster.Bridge, err = NewTestBridge(t, cluster.Config) - require.NoError(t, err) - - // deploy stake manager contract - err = cluster.Bridge.deployStakeManager(genesisPath) - require.NoError(t, err) - - // deploy rootchain contracts - err = cluster.Bridge.deployRootchainContracts(genesisPath) - require.NoError(t, err) - polybftConfig, err := polybft.LoadPolyBFTConfig(genesisPath) require.NoError(t, err) - tokenConfig, err := polybft.ParseRawTokenConfig(cluster.Config.NativeTokenConfigRaw) - require.NoError(t, err) - - // fund addresses on the rootchain - err = cluster.Bridge.fundAddressesOnRoot(tokenConfig, polybftConfig) - require.NoError(t, err) - - // whitelist genesis validators on the rootchain - err = cluster.Bridge.whitelistValidators(addresses, polybftConfig) - require.NoError(t, err) - - // register genesis validators on the rootchain - err = cluster.Bridge.registerGenesisValidators(polybftConfig) - require.NoError(t, err) - - // do initial staking for genesis validators on the rootchain - err = cluster.Bridge.initialStakingOfGenesisValidators(polybftConfig) - require.NoError(t, err) - - // add premine if token is non-mintable - err = cluster.Bridge.mintNativeRootToken(addresses, tokenConfig, polybftConfig) - require.NoError(t, err) + if cluster.Config.HasBridge { + // start bridge + cluster.Bridge, err = NewTestBridge(t, cluster.Config) + require.NoError(t, err) - err = cluster.Bridge.premineNativeRootToken(tokenConfig, polybftConfig) - require.NoError(t, err) + // fund addresses on the rootchain + err = cluster.Bridge.fundAddressesOnRoot(polybftConfig) + require.NoError(t, err) - // finalize genesis validators on the rootchain - err = cluster.Bridge.finalizeGenesis(genesisPath, polybftConfig) - require.NoError(t, err) + // deploy rootchain contracts + err = cluster.Bridge.deployRootchainContracts(genesisPath) + require.NoError(t, err) + } for i := 1; i <= int(cluster.Config.ValidatorSetSize); i++ { nodeType := Validator @@ -830,6 +827,15 @@ func (c *TestCluster) getOpenPort() int64 { return c.initialPort } +func (c *TestCluster) getStakeAmount(validatorIndex int) *big.Int { + l := len(c.Config.StakeAmounts) + if l == 0 || l <= validatorIndex || validatorIndex < 0 { + return command.DefaultStake + } + + return c.Config.StakeAmounts[validatorIndex] +} + // runCommand executes command with given arguments func runCommand(binary string, args []string, stdout io.Writer) error { var stdErr bytes.Buffer diff --git a/e2e-polybft/framework/test-server.go b/e2e-polybft/framework/test-server.go index cbb25a50c4..0cde4b92ff 100644 --- a/e2e-polybft/framework/test-server.go +++ b/e2e-polybft/framework/test-server.go @@ -11,11 +11,11 @@ import ( "testing" "time" - rootHelper "github.com/0xPolygon/polygon-edge/command/rootchain/helper" polybftsecrets "github.com/0xPolygon/polygon-edge/command/secrets/init" "github.com/0xPolygon/polygon-edge/consensus/polybft" "github.com/0xPolygon/polygon-edge/consensus/polybft/validator" "github.com/0xPolygon/polygon-edge/consensus/polybft/wallet" + "github.com/0xPolygon/polygon-edge/contracts" "github.com/0xPolygon/polygon-edge/server/proto" txpoolProto "github.com/0xPolygon/polygon-edge/txpool/proto" "github.com/0xPolygon/polygon-edge/types" @@ -196,22 +196,20 @@ func (t *TestServer) Stop() { } // RootchainFund funds given validator account on the rootchain -func (t *TestServer) RootchainFund(stakeToken types.Address, amount *big.Int) error { - return t.RootchainFundFor([]types.Address{t.address}, []*big.Int{amount}, stakeToken) +func (t *TestServer) RootchainFund(amount *big.Int) error { + return t.RootchainFundFor([]types.Address{t.address}, []*big.Int{amount}) } // RootchainFundFor funds given account on the rootchain -func (t *TestServer) RootchainFundFor(accounts []types.Address, amounts []*big.Int, stakeToken types.Address) error { +func (t *TestServer) RootchainFundFor(accounts []types.Address, amounts []*big.Int) error { if len(accounts) != len(amounts) { return errors.New("same size for accounts and amounts must be provided to the rootchain funding") } args := []string{ - "rootchain", + "bridge", "fund", "--json-rpc", t.BridgeJSONRPCAddr(), - "--stake-token", stakeToken.String(), - "--mint", } for i := 0; i < len(accounts); i++ { @@ -234,14 +232,11 @@ func (t *TestServer) RootchainFundFor(accounts []types.Address, amounts []*big.I // Stake stakes given amount to validator account encapsulated by given server instance func (t *TestServer) Stake(polybftConfig polybft.PolyBFTConfig, amount *big.Int) error { args := []string{ - "polybft", + "validator", "stake", - "--jsonrpc", t.BridgeJSONRPCAddr(), - "--stake-manager", polybftConfig.Bridge.StakeManagerAddr.String(), + "--jsonrpc", t.JSONRPCAddr(), "--" + polybftsecrets.AccountDirFlag, t.config.DataDir, "--amount", amount.String(), - "--supernet-id", strconv.FormatInt(polybftConfig.SupernetID, 10), - "--stake-token", polybftConfig.Bridge.StakeTokenAddr.String(), } return runCommand(t.clusterConfig.Binary, args, t.clusterConfig.GetStdout("stake")) @@ -250,7 +245,7 @@ func (t *TestServer) Stake(polybftConfig polybft.PolyBFTConfig, amount *big.Int) // Unstake unstakes given amount from validator account encapsulated by given server instance func (t *TestServer) Unstake(amount *big.Int) error { args := []string{ - "polybft", + "validator", "unstake", "--" + polybftsecrets.AccountDirFlag, t.config.DataDir, "--jsonrpc", t.JSONRPCAddr(), @@ -261,67 +256,69 @@ func (t *TestServer) Unstake(amount *big.Int) error { } // RegisterValidator is a wrapper function which registers new validator on a root chain -func (t *TestServer) RegisterValidator(supernetManagerAddr types.Address) error { +func (t *TestServer) RegisterValidator() error { args := []string{ - "polybft", + "validator", "register-validator", - "--jsonrpc", t.BridgeJSONRPCAddr(), - "--supernet-manager", supernetManagerAddr.String(), + "--jsonrpc", t.JSONRPCAddr(), "--" + polybftsecrets.AccountDirFlag, t.DataDir(), } - return runCommand(t.clusterConfig.Binary, args, t.clusterConfig.GetStdout("bridge")) + return runCommand(t.clusterConfig.Binary, args, t.clusterConfig.GetStdout("validator")) } // WhitelistValidators invokes whitelist-validators helper CLI command, // that whitelists validators on the root chain -func (t *TestServer) WhitelistValidators(addresses []string, supernetManager types.Address) error { +func (t *TestServer) WhitelistValidators(addresses []string) error { args := []string{ - "polybft", + "validator", "whitelist-validators", - "--private-key", rootHelper.TestAccountPrivKey, - "--jsonrpc", t.BridgeJSONRPCAddr(), - "--supernet-manager", supernetManager.String(), + "--" + polybftsecrets.AccountDirFlag, t.config.DataDir, + "--jsonrpc", t.JSONRPCAddr(), } for _, addr := range addresses { args = append(args, "--addresses", addr) } - return runCommand(t.clusterConfig.Binary, args, t.clusterConfig.GetStdout("bridge")) + return runCommand(t.clusterConfig.Binary, args, t.clusterConfig.GetStdout("validator")) } -// WithdrawChildChain withdraws available balance from child chain -func (t *TestServer) WithdrawChildChain() error { +// MintNativeERC20Token mints given amounts of native erc20 token on blade to given addresses +func (t *TestServer) MintNativeERC20Token(addresses []string, amounts []*big.Int) error { args := []string{ - "polybft", - "withdraw-child", + "mint-erc20", "--" + polybftsecrets.AccountDirFlag, t.config.DataDir, "--jsonrpc", t.JSONRPCAddr(), + "--erc20-token", contracts.NativeERC20TokenContract.String(), + } + + for _, addr := range addresses { + args = append(args, "--addresses", addr) + } + + for _, amount := range amounts { + args = append(args, "--amounts", amount.String()) } - return runCommand(t.clusterConfig.Binary, args, t.clusterConfig.GetStdout("withdraw-child")) + return runCommand(t.clusterConfig.Binary, args, t.clusterConfig.GetStdout("mint-erc20")) } -// WithdrawRootChain withdraws available balance from root chain -func (t *TestServer) WithdrawRootChain(recipient string, amount *big.Int, - stakeManager ethgo.Address, bridgeJSONRPC string) error { +// WitdhrawStake withdraws given amount of stake back to the validator address +func (t *TestServer) WitdhrawStake() error { args := []string{ - "polybft", - "withdraw-root", + "validator", + "withdraw", "--" + polybftsecrets.AccountDirFlag, t.config.DataDir, - "--to", recipient, - "--amount", amount.String(), - "--stake-manager", stakeManager.String(), - "--jsonrpc", bridgeJSONRPC, + "--jsonrpc", t.JSONRPCAddr(), } - return runCommand(t.clusterConfig.Binary, args, t.clusterConfig.GetStdout("withdraw-root")) + return runCommand(t.clusterConfig.Binary, args, t.clusterConfig.GetStdout("withdraw")) } // WithdrawRewards withdraws pending rewards for given validator on RewardPool contract func (t *TestServer) WithdrawRewards() error { args := []string{ - "polybft", + "validator", "withdraw-rewards", "--" + polybftsecrets.AccountDirFlag, t.config.DataDir, "--jsonrpc", t.JSONRPCAddr(), diff --git a/e2e-polybft/property/property_test.go b/e2e-polybft/property/property_test.go index 1feb7bd3dc..28c518c7e1 100644 --- a/e2e-polybft/property/property_test.go +++ b/e2e-polybft/property/property_test.go @@ -9,7 +9,6 @@ import ( "time" "github.com/stretchr/testify/require" - "github.com/umbracle/ethgo/wallet" "pgregory.net/rapid" "github.com/0xPolygon/polygon-edge/e2e-polybft/framework" @@ -22,9 +21,6 @@ func TestProperty_DifferentVotingPower(t *testing.T) { maxStake = 20 ) - minter, err := wallet.GenerateKey() - require.NoError(t, err) - rapid.Check(t, func(tt *rapid.T) { var ( numNodes = rapid.Uint64Range(5, 8).Draw(tt, "number of cluster nodes") @@ -44,7 +40,6 @@ func TestProperty_DifferentVotingPower(t *testing.T) { cluster := framework.NewPropertyTestCluster(t, int(numNodes), framework.WithEpochSize(epochSize), framework.WithBlockTime(blockTime), - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, minter.Address())), framework.WithSecretsCallback(func(adresses []types.Address, config *framework.TestClusterConfig) { for i := range adresses { config.StakeAmounts = append(config.StakeAmounts, stakes[i]) @@ -65,9 +60,6 @@ func TestProperty_DropValidators(t *testing.T) { blockTime = time.Second * 4 ) - minter, err := wallet.GenerateKey() - require.NoError(t, err) - rapid.Check(t, func(tt *rapid.T) { var ( numNodes = rapid.Uint64Range(5, 8).Draw(tt, "number of cluster nodes") @@ -77,7 +69,6 @@ func TestProperty_DropValidators(t *testing.T) { cluster := framework.NewPropertyTestCluster(t, int(numNodes), framework.WithEpochSize(epochSize), framework.WithBlockTime(blockTime), - framework.WithNativeTokenConfig(fmt.Sprintf(framework.NativeTokenMintableTestCfg, minter.Address())), framework.WithSecretsCallback(func(adresses []types.Address, config *framework.TestClusterConfig) { for range adresses { config.StakeAmounts = append(config.StakeAmounts, big.NewInt(20)) diff --git a/e2e/framework/config.go b/e2e/framework/config.go index cdc3275273..ebe8ed4f66 100644 --- a/e2e/framework/config.go +++ b/e2e/framework/config.go @@ -3,6 +3,7 @@ package framework import ( "math/big" + "github.com/0xPolygon/polygon-edge/command" "github.com/0xPolygon/polygon-edge/crypto" "github.com/0xPolygon/polygon-edge/types" ) @@ -40,13 +41,12 @@ type TestServerConfig struct { DevInterval int // Dev consensus update interval [s] BlockGasLimit uint64 // Block gas limit BlockGasTarget uint64 // Gas target for new blocks - BaseFee uint64 // Initial base fee + BaseFeeConfig string // Base fee configuration ShowsLog bool // Flag specifying if logs are shown Name string // Name of the server SaveLogs bool // Flag specifying if logs are saved LogsDir string // Directory where logs are saved Signer crypto.TxSigner // Signer used for transactions - } // DataDir returns path of data directory server uses @@ -122,3 +122,12 @@ func (t *TestServerConfig) SetLogsDir(dir string) { func (t *TestServerConfig) SetName(name string) { t.Name = name } + +// SetBaseFeeConfig sets base fee configuration +func (t *TestServerConfig) SetBaseFeeConfig(baseFeeConfig string) { + if baseFeeConfig == "" { + t.BaseFeeConfig = command.DefaultGenesisBaseFeeConfig + } else { + t.BaseFeeConfig = baseFeeConfig + } +} diff --git a/e2e/framework/testserver.go b/e2e/framework/testserver.go index 436d64e885..db7dfc6f5c 100644 --- a/e2e/framework/testserver.go +++ b/e2e/framework/testserver.go @@ -195,13 +195,7 @@ func (t *TestServer) GenerateGenesis() error { blockGasLimit := strconv.FormatUint(t.Config.BlockGasLimit, 10) args = append(args, "--block-gas-limit", blockGasLimit) - // add base fee - if t.Config.BaseFee != 0 { - args = append(args, "--base-fee-config", *common.EncodeUint64(t.Config.BaseFee)) - } - - // london hardfork is enabled by default so there must be a default burn contract - args = append(args, "--burn-contract", "0:0x0000000000000000000000000000000000000000") + args = append(args, "--base-fee-config", t.Config.BaseFeeConfig) cmd := exec.Command(resolveBinary(), args...) //nolint:gosec cmd.Dir = t.Config.RootDir diff --git a/go.mod b/go.mod index fa5ab2a666..5e21c10ead 100644 --- a/go.mod +++ b/go.mod @@ -47,6 +47,7 @@ require ( gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce gopkg.in/yaml.v3 v3.0.1 pgregory.net/rapid v1.1.0 + github.com/Ethernal-Tech/blockchain-event-tracker v0.0.0-20231202204931-b886edca635a ) require ( diff --git a/go.sum b/go.sum index 951d12e84d..c6b7ed52d2 100644 --- a/go.sum +++ b/go.sum @@ -38,6 +38,8 @@ github.com/DataDog/gostackparse v0.7.0 h1:i7dLkXHvYzHV308hnkvVGDL3BR4FWl7IsXNPz/ github.com/DataDog/gostackparse v0.7.0/go.mod h1:lTfqcJKqS9KnXQGnyQMCugq3u1FP6UZMfWR0aitKFMM= github.com/DataDog/sketches-go v1.4.2 h1:gppNudE9d19cQ98RYABOetxIhpTCl4m7CnbRZjvVA/o= github.com/DataDog/sketches-go v1.4.2/go.mod h1:xJIXldczJyyjnbDop7ZZcLxJdV3+7Kra7H1KMgpgkLk= +github.com/Ethernal-Tech/blockchain-event-tracker v0.0.0-20231202204931-b886edca635a h1:IujnjiVu6UcVYhUIAaCN1ZI122VZzTO80epIbF6pDbk= +github.com/Ethernal-Tech/blockchain-event-tracker v0.0.0-20231202204931-b886edca635a/go.mod h1:IgWSrKhiPnqV6M68wQt8MyWNeWwA+3sYZQP6Y6STR2M= github.com/Microsoft/go-winio v0.5.0/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= diff --git a/scripts/cluster b/scripts/cluster index 74c5c570b1..2979da2cfe 100755 --- a/scripts/cluster +++ b/scripts/cluster @@ -37,6 +37,7 @@ function showhelp() { echo " stop Stop the running environment" echo " destroy Destroy the running environment" echo " write-logs Writes STDOUT and STDERR output to log file. Not applicable when using --docker flag." + echo " with-bridge Run with native bridge enabled" echo "Flags:" echo " --docker Run using Docker (requires docker-compose)." echo " --help Display this help information" @@ -63,19 +64,19 @@ function createGenesis() { --premine 0x0000000000000000000000000000000000000000 \ --epoch-size 10 \ --reward-wallet 0xDEADBEEF:1000000 \ - --native-token-config "Polygon:MATIC:18:true:$address1" \ - --burn-contract 0:0x0000000000000000000000000000000000000000 \ + --native-token-config "Blade:BLADE:18" \ + --blade-admin $address1 \ --proxy-contracts-admin 0x5aaeb6053f3e94c9b9a09f33669435e7ef1beaed } -function initRootchain() { - echo "Initializing rootchain" +function initBridge() { + echo "Initializing bridge" - if [ "$1" == "write-logs" ]; then - echo "Writing rootchain server logs to the file..." - ./polygon-edge rootchain server 2>&1 | tee ./rootchain-server.log & + if [ "$1" == "write-logs" ] || [ "$2" == "write-logs" ]; then + echo "Writing bridge server logs to the file..." + ./polygon-edge bridge server 2>&1 | tee ./bridge-server.log & else - ./polygon-edge rootchain server >/dev/null & + ./polygon-edge bridge server >/dev/null & fi set +e @@ -89,61 +90,13 @@ function initRootchain() { proxyContractsAdmin=0x5aaeb6053f3e94c9b9a09f33669435e7ef1beaed - ./polygon-edge polybft stake-manager-deploy \ - --jsonrpc http://127.0.0.1:8545 \ - --proxy-contracts-admin ${proxyContractsAdmin} \ - --test - - stakeManagerAddr=$(cat genesis.json | jq -r '.params.engine.polybft.bridge.stakeManagerAddr') - stakeToken=$(cat genesis.json | jq -r '.params.engine.polybft.bridge.stakeTokenAddr') - - ./polygon-edge rootchain deploy \ - --stake-manager ${stakeManagerAddr} \ - --stake-token ${stakeToken} \ - --proxy-contracts-admin ${proxyContractsAdmin} \ - --test - - customSupernetManagerAddr=$(cat genesis.json | jq -r '.params.engine.polybft.bridge.customSupernetManagerAddr') - supernetID=$(cat genesis.json | jq -r '.params.engine.polybft.supernetID') - - ./polygon-edge rootchain fund \ - --stake-token ${stakeToken} \ - --mint \ + ./polygon-edge bridge fund \ --addresses ${address1},${address2},${address3},${address4} \ --amounts 1000000000000000000000000,1000000000000000000000000,1000000000000000000000000,1000000000000000000000000 - ./polygon-edge polybft whitelist-validators \ - --addresses ${address1},${address2},${address3},${address4} \ - --supernet-manager ${customSupernetManagerAddr} \ - --private-key aa75e9a7d427efc732f8e4f1a5b7646adcc61fd5bae40f80d13c8419c9f43d6d \ - --jsonrpc http://127.0.0.1:8545 - - counter=1 - while [ $counter -le 4 ]; do - echo "Registering validator: ${counter}" - - ./polygon-edge polybft register-validator \ - --supernet-manager ${customSupernetManagerAddr} \ - --data-dir test-chain-${counter} \ - --jsonrpc http://127.0.0.1:8545 - - ./polygon-edge polybft stake \ - --data-dir test-chain-${counter} \ - --amount 1000000000000000000000000 \ - --supernet-id ${supernetID} \ - --stake-manager ${stakeManagerAddr} \ - --stake-token ${stakeToken} \ - --jsonrpc http://127.0.0.1:8545 - - ((counter++)) - done - - ./polygon-edge polybft supernet \ - --private-key aa75e9a7d427efc732f8e4f1a5b7646adcc61fd5bae40f80d13c8419c9f43d6d \ - --supernet-manager ${customSupernetManagerAddr} \ - --finalize-genesis-set \ - --enable-staking \ - --jsonrpc http://127.0.0.1:8545 + ./polygon-edge bridge deploy \ + --proxy-contracts-admin ${proxyContractsAdmin} \ + --test } function startNodes() { @@ -247,7 +200,10 @@ case "$2" in initPolybftConsensus # Create genesis file and start the server from binary createGenesis - initRootchain $2 + if [ "$2" == "with-bridge" ] || [ "$3" == "with-bridge" ]; then + echo "Running bridge" + initBridge $2 $3 + fi startNodes $1 $2 exit 0 else diff --git a/server/config.go b/server/config.go index 63240f6ddf..b1ed771ed3 100644 --- a/server/config.go +++ b/server/config.go @@ -44,8 +44,9 @@ type Config struct { Relayer bool - NumBlockConfirmations uint64 - MetricsInterval time.Duration + MetricsInterval time.Duration + + EventTracker *EventTracker } // Telemetry holds the config details for metric services @@ -62,3 +63,9 @@ type JSONRPC struct { ConcurrentRequestsDebug uint64 WebSocketReadLimit uint64 } + +type EventTracker struct { + SyncBatchSize uint64 + NumBlockConfirmations uint64 + NumOfBlocksToReconcile uint64 +} diff --git a/server/server.go b/server/server.go index e88e3f27ca..30bb488cbc 100644 --- a/server/server.go +++ b/server/server.go @@ -563,18 +563,23 @@ func (s *Server) setupConsensus() error { consensus, err := engine( &consensus.Params{ - Context: context.Background(), - Config: config, - TxPool: s.txpool, - Network: s.network, - Blockchain: s.blockchain, - Executor: s.executor, - Grpc: s.grpcServer, - Logger: s.logger, - SecretsManager: s.secretsManager, - BlockTime: uint64(blockTime.Seconds()), - NumBlockConfirmations: s.config.NumBlockConfirmations, - MetricsInterval: s.config.MetricsInterval, + Context: context.Background(), + Config: config, + TxPool: s.txpool, + Network: s.network, + Blockchain: s.blockchain, + Executor: s.executor, + Grpc: s.grpcServer, + Logger: s.logger, + SecretsManager: s.secretsManager, + BlockTime: uint64(blockTime.Seconds()), + MetricsInterval: s.config.MetricsInterval, + // event tracker + EventTracker: &consensus.EventTracker{ + NumBlockConfirmations: s.config.EventTracker.NumBlockConfirmations, + SyncBatchSize: s.config.EventTracker.SyncBatchSize, + NumOfBlocksToReconcile: s.config.EventTracker.NumOfBlocksToReconcile, + }, }, ) @@ -1006,16 +1011,6 @@ func initForkManager(engineName string, config *chain.Chain) error { fm.RegisterFork(name, f.Params) } - // Register handlers and additional forks here - if err := types.RegisterTxHashFork(chain.TxHashWithType); err != nil { - return err - } - - // Register Handler for London fork fix - if err := state.RegisterLondonFixFork(chain.LondonFix); err != nil { - return err - } - if factory := forkManagerFactory[ConsensusType(engineName)]; factory != nil { if err := factory(config.Params.Forks); err != nil { return err diff --git a/sonar-project.properties b/sonar-project.properties index cecd90badb..f242a78b28 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -2,7 +2,7 @@ sonar.projectKey=0xPolygon_polygon-edge sonar.organization=0xpolygon sonar.sources=. -sonar.exclusions=**/vendor/**,**/*.py,**/core-contracts/**,**/tests/** +sonar.exclusions=**/vendor/**,**/*.py,**/blade-contracts/**,**/tests/** sonar.tests=. sonar.test.inclusions=**/*_test.go diff --git a/state/executor.go b/state/executor.go index 8e211e9aed..286e712917 100644 --- a/state/executor.go +++ b/state/executor.go @@ -450,7 +450,7 @@ func (t *Transition) ContextPtr() *runtime.TxContext { } func (t *Transition) subGasLimitPrice(msg *types.Transaction) error { - upfrontGasCost := GetLondonFixHandler(uint64(t.ctx.Number)).getUpfrontGasCost(msg, t.ctx.BaseFee) + upfrontGasCost := new(big.Int).Mul(new(big.Int).SetUint64(msg.Gas), msg.GetGasPrice(t.ctx.BaseFee.Uint64())) if err := t.state.SubBalance(msg.From, upfrontGasCost); err != nil { if errors.Is(err, runtime.ErrNotEnoughFunds) { @@ -476,7 +476,39 @@ func (t *Transition) nonceCheck(msg *types.Transaction) error { // checkDynamicFees checks correctness of the EIP-1559 feature-related fields. // Basically, makes sure gas tip cap and gas fee cap are good for dynamic and legacy transactions func (t *Transition) checkDynamicFees(msg *types.Transaction) error { - return GetLondonFixHandler(uint64(t.ctx.Number)).checkDynamicFees(msg, t) + if !t.config.London { + return nil + } + + if msg.Type == types.DynamicFeeTx { + if msg.GasFeeCap.BitLen() == 0 && msg.GasTipCap.BitLen() == 0 { + return nil + } + + if l := msg.GasFeeCap.BitLen(); l > 256 { + return fmt.Errorf("%w: address %v, GasFeeCap bit length: %d", ErrFeeCapVeryHigh, + msg.From.String(), l) + } + + if l := msg.GasTipCap.BitLen(); l > 256 { + return fmt.Errorf("%w: address %v, GasTipCap bit length: %d", ErrTipVeryHigh, + msg.From.String(), l) + } + + if msg.GasFeeCap.Cmp(msg.GasTipCap) < 0 { + return fmt.Errorf("%w: address %v, GasTipCap: %s, GasFeeCap: %s", ErrTipAboveFeeCap, + msg.From.String(), msg.GasTipCap, msg.GasFeeCap) + } + } + + // This will panic if baseFee is nil, but basefee presence is verified + // as part of header validation. + if gasFeeCap := msg.GetGasFeeCap(); gasFeeCap.Cmp(t.ctx.BaseFee) < 0 { + return fmt.Errorf("%w: address %v, GasFeeCap/GasPrice: %s, BaseFee: %s", ErrFeeCapTooLow, + msg.From.String(), gasFeeCap, t.ctx.BaseFee) + } + + return nil } // errors that can originate in the consensus rules checks of the apply method below @@ -602,9 +634,13 @@ func (t *Transition) apply(msg *types.Transaction) (*runtime.ExecutionResult, er // Define effective tip based on tx type. // We use EIP-1559 fields of the tx if the london hardfork is enabled. // Effective tip became to be either gas tip cap or (gas fee cap - current base fee) - effectiveTip := GetLondonFixHandler(uint64(t.ctx.Number)).getEffectiveTip( - msg, gasPrice, t.ctx.BaseFee, t.config.London, - ) + var effectiveTip *big.Int + + if t.config.London { + effectiveTip = msg.EffectiveGasTip(t.ctx.BaseFee) + } else { + effectiveTip = new(big.Int).Set(gasPrice) + } // Pay the coinbase fee as a miner reward using the calculated effective tip. coinbaseFee := new(big.Int).Mul(new(big.Int).SetUint64(result.GasUsed), effectiveTip) diff --git a/state/londonFix_fork.go b/state/londonFix_fork.go deleted file mode 100644 index ca8c6dd900..0000000000 --- a/state/londonFix_fork.go +++ /dev/null @@ -1,164 +0,0 @@ -package state - -import ( - "fmt" - "math/big" - - "github.com/0xPolygon/polygon-edge/forkmanager" - "github.com/0xPolygon/polygon-edge/helper/common" - "github.com/0xPolygon/polygon-edge/types" -) - -const LondonFixHandler forkmanager.HandlerDesc = "LondonFixHandler" - -type LondonFixFork interface { - checkDynamicFees(*types.Transaction, *Transition) error - getUpfrontGasCost(msg *types.Transaction, baseFee *big.Int) *big.Int - getEffectiveTip(msg *types.Transaction, gasPrice *big.Int, - baseFee *big.Int, isLondonForkEnabled bool) *big.Int -} - -type LondonFixForkV1 struct{} - -// checkDynamicFees checks correctness of the EIP-1559 feature-related fields. -// Basically, makes sure gas tip cap and gas fee cap are good for dynamic and legacy transactions -// and that GasFeeCap/GasPrice cap is not lower than base fee when London fork is active. -func (l *LondonFixForkV1) checkDynamicFees(msg *types.Transaction, t *Transition) error { - if msg.Type != types.DynamicFeeTx { - return nil - } - - if msg.GasFeeCap.BitLen() == 0 && msg.GasTipCap.BitLen() == 0 { - return nil - } - - if l := msg.GasFeeCap.BitLen(); l > 256 { - return fmt.Errorf("%w: address %v, GasFeeCap bit length: %d", ErrFeeCapVeryHigh, - msg.From.String(), l) - } - - if l := msg.GasTipCap.BitLen(); l > 256 { - return fmt.Errorf("%w: address %v, GasTipCap bit length: %d", ErrTipVeryHigh, - msg.From.String(), l) - } - - if msg.GasFeeCap.Cmp(msg.GasTipCap) < 0 { - return fmt.Errorf("%w: address %v, GasTipCap: %s, GasFeeCap: %s", ErrTipAboveFeeCap, - msg.From.String(), msg.GasTipCap, msg.GasFeeCap) - } - - // This will panic if baseFee is nil, but basefee presence is verified - // as part of header validation. - if msg.GasFeeCap.Cmp(t.ctx.BaseFee) < 0 { - return fmt.Errorf("%w: address %v, GasFeeCap: %s, BaseFee: %s", ErrFeeCapTooLow, - msg.From.String(), msg.GasFeeCap, t.ctx.BaseFee) - } - - return nil -} - -func (l *LondonFixForkV1) getUpfrontGasCost(msg *types.Transaction, baseFee *big.Int) *big.Int { - upfrontGasCost := new(big.Int).SetUint64(msg.Gas) - - factor := new(big.Int) - if msg.GasFeeCap != nil && msg.GasFeeCap.BitLen() > 0 { - // Apply EIP-1559 tx cost calculation factor - factor = factor.Set(msg.GasFeeCap) - } else { - // Apply legacy tx cost calculation factor - factor = factor.Set(msg.GasPrice) - } - - return upfrontGasCost.Mul(upfrontGasCost, factor) -} - -func (l *LondonFixForkV1) getEffectiveTip(msg *types.Transaction, gasPrice *big.Int, - baseFee *big.Int, isLondonForkEnabled bool) *big.Int { - if isLondonForkEnabled && msg.Type == types.DynamicFeeTx { - return common.BigMin( - new(big.Int).Sub(msg.GasFeeCap, baseFee), - new(big.Int).Set(msg.GasTipCap), - ) - } - - return new(big.Int).Set(gasPrice) -} - -type LondonFixForkV2 struct{} - -func (l *LondonFixForkV2) checkDynamicFees(msg *types.Transaction, t *Transition) error { - if !t.config.London { - return nil - } - - if msg.Type == types.DynamicFeeTx { - if msg.GasFeeCap.BitLen() == 0 && msg.GasTipCap.BitLen() == 0 { - return nil - } - - if l := msg.GasFeeCap.BitLen(); l > 256 { - return fmt.Errorf("%w: address %v, GasFeeCap bit length: %d", ErrFeeCapVeryHigh, - msg.From.String(), l) - } - - if l := msg.GasTipCap.BitLen(); l > 256 { - return fmt.Errorf("%w: address %v, GasTipCap bit length: %d", ErrTipVeryHigh, - msg.From.String(), l) - } - - if msg.GasFeeCap.Cmp(msg.GasTipCap) < 0 { - return fmt.Errorf("%w: address %v, GasTipCap: %s, GasFeeCap: %s", ErrTipAboveFeeCap, - msg.From.String(), msg.GasTipCap, msg.GasFeeCap) - } - } - - // This will panic if baseFee is nil, but basefee presence is verified - // as part of header validation. - if gasFeeCap := msg.GetGasFeeCap(); gasFeeCap.Cmp(t.ctx.BaseFee) < 0 { - return fmt.Errorf("%w: address %v, GasFeeCap/GasPrice: %s, BaseFee: %s", ErrFeeCapTooLow, - msg.From.String(), gasFeeCap, t.ctx.BaseFee) - } - - return nil -} - -func (l *LondonFixForkV2) getUpfrontGasCost(msg *types.Transaction, baseFee *big.Int) *big.Int { - return new(big.Int).Mul(new(big.Int).SetUint64(msg.Gas), msg.GetGasPrice(baseFee.Uint64())) -} - -func (l *LondonFixForkV2) getEffectiveTip(msg *types.Transaction, gasPrice *big.Int, - baseFee *big.Int, isLondonForkEnabled bool) *big.Int { - if isLondonForkEnabled { - return msg.EffectiveGasTip(baseFee) - } - - return new(big.Int).Set(gasPrice) -} - -func RegisterLondonFixFork(londonFixFork string) error { - fh := forkmanager.GetInstance() - - if err := fh.RegisterHandler( - forkmanager.InitialFork, LondonFixHandler, &LondonFixForkV1{}); err != nil { - return err - } - - if fh.IsForkRegistered(londonFixFork) { - if err := fh.RegisterHandler( - londonFixFork, LondonFixHandler, &LondonFixForkV2{}); err != nil { - return err - } - } - - return nil -} - -func GetLondonFixHandler(blockNumber uint64) LondonFixFork { - if h := forkmanager.GetInstance().GetHandler(LondonFixHandler, blockNumber); h != nil { - //nolint:forcetypeassert - return h.(LondonFixFork) - } - - // for tests - return &LondonFixForkV2{} -} diff --git a/tracker/event_tracker.go b/tracker/event_tracker.go deleted file mode 100644 index 14e1d18553..0000000000 --- a/tracker/event_tracker.go +++ /dev/null @@ -1,155 +0,0 @@ -package tracker - -import ( - "context" - "time" - - "github.com/0xPolygon/polygon-edge/helper/common" - hcf "github.com/hashicorp/go-hclog" - "github.com/umbracle/ethgo" - "github.com/umbracle/ethgo/blocktracker" - "github.com/umbracle/ethgo/jsonrpc" - "github.com/umbracle/ethgo/tracker" -) - -const minBlockMaxBacklog = 96 - -type eventSubscription interface { - AddLog(log *ethgo.Log) error -} - -type EventTracker struct { - dbPath string - rpcEndpoint string - contractAddr ethgo.Address - startBlock uint64 - subscriber eventSubscription - logger hcf.Logger - numBlockConfirmations uint64 // minimal number of child blocks required for the parent block to be considered final - pollInterval time.Duration -} - -func NewEventTracker( - dbPath string, - rpcEndpoint string, - contractAddr ethgo.Address, - subscriber eventSubscription, - numBlockConfirmations uint64, - startBlock uint64, - logger hcf.Logger, - pollInterval time.Duration, -) *EventTracker { - return &EventTracker{ - dbPath: dbPath, - rpcEndpoint: rpcEndpoint, - contractAddr: contractAddr, - subscriber: subscriber, - numBlockConfirmations: numBlockConfirmations, - startBlock: startBlock, - logger: logger.Named("event_tracker"), - pollInterval: pollInterval, - } -} - -func (e *EventTracker) Start(ctx context.Context) error { - e.logger.Info("Start tracking events", - "contract", e.contractAddr, - "JSON RPC address", e.rpcEndpoint, - "num block confirmations", e.numBlockConfirmations, - "start block", e.startBlock, - "poll interval", e.pollInterval) - - provider, err := jsonrpc.NewClient(e.rpcEndpoint) - if err != nil { - return err - } - - store, err := NewEventTrackerStore(e.dbPath, e.numBlockConfirmations, e.subscriber, e.logger) - if err != nil { - return err - } - - blockMaxBacklog := e.numBlockConfirmations * 2 - if blockMaxBacklog < minBlockMaxBacklog { - blockMaxBacklog = minBlockMaxBacklog - } - - jsonBlockTracker := blocktracker.NewJSONBlockTracker(provider.Eth()) - jsonBlockTracker.PollInterval = e.pollInterval - blockTracker := blocktracker.NewBlockTracker( - provider.Eth(), - blocktracker.WithBlockMaxBacklog(blockMaxBacklog), - blocktracker.WithTracker(jsonBlockTracker), - ) - - go func() { - <-ctx.Done() - blockTracker.Close() - store.Close() - }() - - // Init and start block tracker concurrently, retrying indefinitely - go common.RetryForever(ctx, time.Second, func(context.Context) error { - // Init - start := time.Now().UTC() - if err := blockTracker.Init(); err != nil { - e.logger.Error("failed to init blocktracker", "error", err) - - return err - } - elapsed := time.Now().UTC().Sub(start) - - // Start - if err := blockTracker.Start(); err != nil { - if common.IsContextDone(err) { - return nil - } - - e.logger.Error("failed to start blocktracker", "error", err) - - return err - } - - e.logger.Info("Block tracker has been started", "max backlog", blockMaxBacklog, "init time", elapsed) - - return nil - }) - - tt, err := tracker.NewTracker(provider.Eth(), - tracker.WithBatchSize(10), - tracker.WithBlockTracker(blockTracker), - tracker.WithStore(store), - tracker.WithFilter(&tracker.FilterConfig{ - Async: true, - Address: []ethgo.Address{ - e.contractAddr, - }, - Start: e.startBlock, - }), - ) - if err != nil { - return err - } - // Sync concurrently, retrying indefinitely - go common.RetryForever(ctx, time.Second, func(ctx context.Context) error { - // Some errors from sync can cause this channel to be closed. - // We need to ensure that it is not closed before we retry, - // otherwise we will get a panic. - tt.ReadyCh = make(chan struct{}) - - // Run the sync - if err := tt.Sync(ctx); err != nil { - if common.IsContextDone(err) { - return nil - } - - e.logger.Error("failed to sync", "error", err) - - return err - } - - return nil - }) - - return nil -} diff --git a/tracker/event_tracker_store.go b/tracker/event_tracker_store.go deleted file mode 100644 index 12e4a3cfb0..0000000000 --- a/tracker/event_tracker_store.go +++ /dev/null @@ -1,348 +0,0 @@ -package tracker - -import ( - "bytes" - "encoding/hex" - "encoding/json" - "fmt" - "strings" - - "github.com/0xPolygon/polygon-edge/helper/common" - hcf "github.com/hashicorp/go-hclog" - "github.com/umbracle/ethgo" - "github.com/umbracle/ethgo/tracker/store" - bolt "go.etcd.io/bbolt" -) - -const dbLastBlockPrefix = "lastBlock_" - -var ( - _ store.Store = (*EventTrackerStore)(nil) - - dbLogs = []byte("logs") - dbConf = []byte("conf") - dbNextToProcess = []byte("nextToProcess") - nextToProcessKey = []byte("0") -) - -// EventTrackerStore is a tracker store implementation. -type EventTrackerStore struct { - conn *bolt.DB - numBlockConfirmations uint64 - subscriber eventSubscription - logger hcf.Logger -} - -// NewEventTrackerStore creates a new EventTrackerStore -func NewEventTrackerStore( - path string, - numBlockConfirmations uint64, - subscriber eventSubscription, - logger hcf.Logger) (*EventTrackerStore, error) { - db, err := bolt.Open(path, 0600, nil) - if err != nil { - return nil, err - } - - store := &EventTrackerStore{ - conn: db, - numBlockConfirmations: numBlockConfirmations, - subscriber: subscriber, - logger: logger, - } - - if err := store.setupDB(); err != nil { - store.Close() - - return nil, err - } - - return store, nil -} - -func (b *EventTrackerStore) setupDB() error { - return b.conn.Update(func(tx *bolt.Tx) error { - if _, err := tx.CreateBucketIfNotExists(dbConf); err != nil { - return err - } - - return nil - }) -} - -// Close implements the store interface -func (b *EventTrackerStore) Close() error { - return b.conn.Close() -} - -// Get implements the store interface -func (b *EventTrackerStore) Get(k string) (string, error) { - var result []byte - - if err := b.conn.View(func(tx *bolt.Tx) error { - bucket := tx.Bucket(dbConf) - result = bucket.Get([]byte(k)) - - return nil - }); err != nil { - return "", err - } - - return string(result), nil -} - -// ListPrefix implements the store interface -func (b *EventTrackerStore) ListPrefix(prefix string) ([]string, error) { - var result []string - - if err := b.conn.View(func(tx *bolt.Tx) error { - pfx := []byte(prefix) - c := tx.Bucket(dbConf).Cursor() - - for k, v := c.Seek(pfx); k != nil && bytes.HasPrefix(k, pfx); k, v = c.Next() { - result = append(result, string(v)) - } - - return nil - }); err != nil { - return nil, err - } - - return result, nil -} - -// Set implements the store interface -func (b *EventTrackerStore) Set(k, v string) error { - if err := b.conn.Update(func(tx *bolt.Tx) error { - bucket := tx.Bucket(dbConf) - - return bucket.Put([]byte(k), []byte(v)) - }); err != nil { - return err - } - - if strings.HasPrefix(k, dbLastBlockPrefix) { - if err := b.onNewBlock(k[len(dbLastBlockPrefix):], v); err != nil { - b.logger.Warn("new block error", "err", err) - - return err - } - } - - return nil -} - -func (b *EventTrackerStore) onNewBlock(filterHash, blockData string) error { - var block ethgo.Block - - bytes, err := hex.DecodeString(blockData) - if err != nil { - return err - } - - if err := block.UnmarshalJSON(bytes); err != nil { - return err - } - - if block.Number <= b.numBlockConfirmations { - return nil // there is nothing to process yet - } - - entry, err := b.getImplEntry(filterHash) - if err != nil { - return nil - } - - logs, lastProcessedKey, err := entry.getFinalizedLogs(block.Number - b.numBlockConfirmations) - if err != nil { - return err - } - - if len(logs) == 0 { - return nil // nothing to process - } - - // notify subscriber with logs - for _, log := range logs { - if err := b.subscriber.AddLog(log); err != nil { - return err - } - } - - // save next to process only if every AddLog finished successfully - nextToProcessIdx := common.EncodeBytesToUint64(lastProcessedKey) + 1 - if err := entry.saveNextToProcessIndx(nextToProcessIdx); err != nil { - return err - } - - b.logger.Debug("Event logs have been notified to a subscriber", "len", len(logs), "next", nextToProcessIdx) - - return nil -} - -// GetEntry implements the store interface -func (b *EventTrackerStore) GetEntry(hash string) (store.Entry, error) { - return b.getImplEntry(hash) -} - -func (b *EventTrackerStore) getImplEntry(hash string) (*Entry, error) { - logsBucketName := append(dbLogs, []byte(hash)...) - nextToProcessBucketName := append(dbNextToProcess, []byte(hash)...) - - if err := b.conn.Update(func(tx *bolt.Tx) error { - if _, err := tx.CreateBucketIfNotExists(logsBucketName); err != nil { - return err - } - - if _, err := tx.CreateBucketIfNotExists(nextToProcessBucketName); err != nil { - return err - } - - return nil - }); err != nil { - return nil, err - } - - return &Entry{ - conn: b.conn, - bucketLogs: logsBucketName, - bucketNextToProcess: nextToProcessBucketName, - }, nil -} - -// Entry is an store.Entry implementation -type Entry struct { - conn *bolt.DB - bucketLogs []byte - bucketNextToProcess []byte -} - -// LastIndex implements the store.Entry interface -func (e *Entry) LastIndex() (uint64, error) { - var result uint64 - - if err := e.conn.View(func(tx *bolt.Tx) error { - result = getLastIndex(tx.Bucket(e.bucketLogs)) - - return nil - }); err != nil { - return 0, err - } - - return result, nil -} - -// StoreLog implements the store.Entry interface -func (e *Entry) StoreLog(log *ethgo.Log) error { - return e.StoreLogs([]*ethgo.Log{log}) -} - -// StoreLogs implements the store.Entry interface -// logs are added in sequentional order -func (e *Entry) StoreLogs(logs []*ethgo.Log) error { - if len(logs) == 0 { // dont start tx if there is nothing to add - return nil - } - - return e.conn.Update(func(tx *bolt.Tx) error { - bucketLogs := tx.Bucket(e.bucketLogs) - logFirstIndx := getLastIndex(bucketLogs) - - for idx, log := range logs { - logIdx := logFirstIndx + uint64(idx) - - val, err := log.MarshalJSON() - if err != nil { - return err - } - - if err := bucketLogs.Put(common.EncodeUint64ToBytes(logIdx), val); err != nil { - return err - } - } - - return nil - }) -} - -// RemoveLogs implements the store.Entry interface -func (e *Entry) RemoveLogs(indx uint64) error { - return e.conn.Update(func(tx *bolt.Tx) error { - cursorLogs := tx.Bucket(e.bucketLogs).Cursor() - - // remove logs - for k, _ := cursorLogs.Seek(common.EncodeUint64ToBytes(indx)); k != nil; k, _ = cursorLogs.Next() { - if err := cursorLogs.Delete(); err != nil { - return err - } - } - - return nil - }) -} - -// GetLog implements the store.Entry interface -func (e *Entry) GetLog(idx uint64, log *ethgo.Log) error { - return e.conn.View(func(tx *bolt.Tx) error { - val := tx.Bucket(e.bucketLogs).Get(common.EncodeUint64ToBytes(idx)) - if val == nil { - return fmt.Errorf("log not found: %d", idx) - } - - return log.UnmarshalJSON(val) - }) -} - -func (e *Entry) getFinalizedLogs(untilBlockNumber uint64) ([]*ethgo.Log, []byte, error) { - var ( - logs []*ethgo.Log - lastProcessedKey []byte - key, value []byte - ) - - if err := e.conn.View(func(tx *bolt.Tx) error { - bucketLastProcessedBlock := tx.Bucket(e.bucketNextToProcess) - cursorLogs := tx.Bucket(e.bucketLogs).Cursor() - - // pick first unprocessed block - if _, val := bucketLastProcessedBlock.Cursor().First(); val != nil { - key, value = cursorLogs.Seek(val) - } else { - key, value = cursorLogs.First() - } - - for ; key != nil; key, value = cursorLogs.Next() { - log := ðgo.Log{} - if err := json.Unmarshal(value, log); err != nil { - return err - } - - if log.BlockNumber > untilBlockNumber { - break - } - - logs = append(logs, log) - lastProcessedKey = key - } - - return nil - }); err != nil { - return nil, nil, err - } - - return logs, lastProcessedKey, nil -} - -func (e *Entry) saveNextToProcessIndx(nextToProcessIdx uint64) error { - return e.conn.Update(func(tx *bolt.Tx) error { - return tx.Bucket(e.bucketNextToProcess).Put(nextToProcessKey, common.EncodeUint64ToBytes(nextToProcessIdx)) - }) -} - -func getLastIndex(bucket *bolt.Bucket) uint64 { - if last, _ := bucket.Cursor().Last(); last != nil { - return common.EncodeBytesToUint64(last) + 1 - } - - return 0 -} diff --git a/tracker/event_tracker_store_test.go b/tracker/event_tracker_store_test.go deleted file mode 100644 index fb97f21005..0000000000 --- a/tracker/event_tracker_store_test.go +++ /dev/null @@ -1,169 +0,0 @@ -package tracker - -import ( - "encoding/hex" - "os" - "path/filepath" - "testing" - - "github.com/0xPolygon/polygon-edge/helper/common" - "github.com/hashicorp/go-hclog" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - "github.com/umbracle/ethgo" - "github.com/umbracle/ethgo/tracker/store" -) - -func createSetupDB(subscriber eventSubscription, numBlockConfirmations uint64) store.SetupDB { - return func(t *testing.T) (store.Store, func()) { - t.Helper() - - dir, err := os.MkdirTemp("/tmp", "boltdb-test") - require.NoError(t, err) - - path := filepath.Join(dir, "test.db") - store, err := NewEventTrackerStore(path, numBlockConfirmations, subscriber, hclog.Default()) - require.NoError(t, err) - - closeFn := func() { - require.NoError(t, os.RemoveAll(dir)) - } - - return store, closeFn - } -} - -func TestBoltDBStore(t *testing.T) { - store.TestStore(t, createSetupDB(nil, 2)) -} - -func TestEntry_getFinalizedLogs(t *testing.T) { - const someFilterHash = "test" - - tstore, closeFn := createSetupDB(nil, 3)(t) - defer closeFn() - - entry, err := tstore.(*EventTrackerStore).getImplEntry(someFilterHash) - require.NoError(t, err) - - require.NoError(t, entry.StoreLogs([]*ethgo.Log{ - {BlockNumber: 1}, {BlockNumber: 5}, {BlockNumber: 8}, {BlockNumber: 11}, {BlockNumber: 12}, {BlockNumber: 15}, - })) - - logs, key, err := entry.getFinalizedLogs(10) - - assert.NoError(t, err) - assert.Len(t, logs, 3) - assert.Equal(t, common.EncodeUint64ToBytes(2), key) - - err = entry.saveNextToProcessIndx(1) // next time should start from the second one - require.NoError(t, err) - - logs, key, err = entry.getFinalizedLogs(14) - - assert.NoError(t, err) - assert.Len(t, logs, 4) - assert.Equal(t, common.EncodeUint64ToBytes(4), key) -} - -func TestEntry_saveNextToProcessIndx(t *testing.T) { - const someFilterHash = "test" - - tstore, closeFn := createSetupDB(nil, 2)(t) - defer closeFn() - - entry, err := tstore.(*EventTrackerStore).getImplEntry(someFilterHash) - require.NoError(t, err) - - require.NoError(t, entry.StoreLogs([]*ethgo.Log{ - {BlockNumber: 1}, {BlockNumber: 5}, {BlockNumber: 8}, {BlockNumber: 11}, {BlockNumber: 12}, {BlockNumber: 15}, - })) - - for i := 0; i < 10; i++ { - require.NoError(t, entry.saveNextToProcessIndx(uint64(i))) - } -} - -func TestEventTrackerStore_SetNotLastBlock(t *testing.T) { - subs := &mockEventSubscriber{} - - tstore, closeFn := createSetupDB(subs, 2)(t) - defer closeFn() - - assert.NoError(t, tstore.(*EventTrackerStore).Set("dummy", "dummy")) //nolint - assert.Len(t, subs.logs, 0) -} - -func TestEventTrackerStore_onNewBlockBad(t *testing.T) { - tstore, closeFn := createSetupDB(nil, 0)(t) - defer closeFn() - - assert.Error(t, tstore.(*EventTrackerStore).onNewBlock("dummy", "dummy")) //nolint - assert.Error(t, tstore.(*EventTrackerStore).onNewBlock("dummy", hex.EncodeToString([]byte{0, 1}))) //nolint -} - -func TestEventTrackerStore_OnNewBlockNothingToProcess(t *testing.T) { - subs := &mockEventSubscriber{} - - tstore, closeFn := createSetupDB(subs, 10)(t) - defer closeFn() - - block := ethgo.Block{Number: 8} - - bytes, err := block.MarshalJSON() - require.NoError(t, err) - - value := hex.EncodeToString(bytes) - - // block less than numBlockConfirmations - assert.NoError(t, tstore.(*EventTrackerStore).onNewBlock("dummy", value)) //nolint - assert.Len(t, subs.logs, 0) - - block = ethgo.Block{Number: 12} - - bytes, err = block.MarshalJSON() - require.NoError(t, err) - - value = hex.EncodeToString(bytes) - - // no logs - assert.NoError(t, tstore.(*EventTrackerStore).onNewBlock("dummy", value)) //nolint - assert.Len(t, subs.logs, 0) -} - -func TestEventTrackerStore_SetLastBlockSubscriberNotified(t *testing.T) { - const hash = "dummy_hash" - - subs := &mockEventSubscriber{} - - tstore, closeFn := createSetupDB(subs, 2)(t) - defer closeFn() - - entry, err := tstore.GetEntry(hash) - require.NoError(t, err) - - require.NoError(t, entry.StoreLogs([]*ethgo.Log{ - {BlockNumber: 1}, {BlockNumber: 2}, {BlockNumber: 3}, - })) - - // There are 3 logs in store (one for block 1, one for block 2, one for block 3) and numBlockConfirmations is 2 - // If block 2 arrives (`tstore.Set(dbLastBlockPrefix+hash, value)`) subscriber should be notified with 0 logs - // If block 3 arrives subscriber should be notified with 1 log - // If block 4 arrives subscriber should be notified with 2 logs - // If block 5 arrives subscriber should be notified with all 3 logs - for i := 0; i < 4; i++ { - block := ethgo.Block{Number: uint64(i + 2)} - - bytes, err := block.MarshalJSON() - require.NoError(t, err) - - value := hex.EncodeToString(bytes) - - assert.NoError(t, tstore.Set(dbLastBlockPrefix+hash, value)) - assert.Len(t, subs.logs, i) - - subs.logs = nil - - require.NoError(t, entry.(*Entry).saveNextToProcessIndx(0)) //nolint - } -} diff --git a/tracker/event_tracker_test.go b/tracker/event_tracker_test.go deleted file mode 100644 index 7717808c42..0000000000 --- a/tracker/event_tracker_test.go +++ /dev/null @@ -1,102 +0,0 @@ -package tracker - -import ( - "context" - "os" - "path" - "sync" - "testing" - "time" - - "github.com/0xPolygon/polygon-edge/types" - "github.com/hashicorp/go-hclog" - "github.com/stretchr/testify/require" - "github.com/umbracle/ethgo" - "github.com/umbracle/ethgo/testutil" -) - -type mockEventSubscriber struct { - lock sync.RWMutex - logs []*ethgo.Log -} - -func (m *mockEventSubscriber) AddLog(log *ethgo.Log) error { - m.lock.Lock() - defer m.lock.Unlock() - - if len(m.logs) == 0 { - m.logs = []*ethgo.Log{} - } - - m.logs = append(m.logs, log) - - return nil -} - -func (m *mockEventSubscriber) len() int { - m.lock.RLock() - defer m.lock.RUnlock() - - return len(m.logs) -} - -func TestEventTracker_TrackSyncEvents(t *testing.T) { - const ( - numBlockConfirmations = 6 - eventsPerStep = 8 - ) - - server := testutil.DeployTestServer(t, nil) - - tmpDir, err := os.MkdirTemp("/tmp", "test-event-tracker") - defer os.RemoveAll(tmpDir) - require.NoError(t, err) - - cc := &testutil.Contract{} - cc.AddCallback(func() string { - return ` - event StateSync(uint256 indexed id, address indexed target, bytes data); - - function emitEvent() public payable { - emit StateSync(1, msg.sender, bytes("")); - } - ` - }) - - _, addr, err := server.DeployContract(cc) - require.NoError(t, err) - - // prefill with eventsPerStep + numBlockConfirmations events - for i := 0; i < eventsPerStep+numBlockConfirmations; i++ { - receipt, err := server.TxnTo(addr, "emitEvent") - require.NoError(t, err) - require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) - } - - sub := &mockEventSubscriber{} - - tracker := &EventTracker{ - logger: hclog.NewNullLogger(), - subscriber: sub, - dbPath: path.Join(tmpDir, "test.db"), - rpcEndpoint: server.HTTPAddr(), - contractAddr: addr, - numBlockConfirmations: numBlockConfirmations, - pollInterval: time.Second, - } - - err = tracker.Start(context.Background()) - require.NoError(t, err) - - time.Sleep(2 * time.Second) - require.Equal(t, eventsPerStep, sub.len()) - // send eventsPerStep more events - for i := 0; i < eventsPerStep; i++ { - receipt, err := server.TxnTo(addr, "emitEvent") - require.NoError(t, err) - require.Equal(t, uint64(types.ReceiptSuccess), receipt.Status) - } - - time.Sleep(2 * time.Second) - require.Equal(t, eventsPerStep*2, sub.len()) -} diff --git a/txpool/txpool.go b/txpool/txpool.go index 60e6e15075..31915c1cdd 100644 --- a/txpool/txpool.go +++ b/txpool/txpool.go @@ -15,7 +15,6 @@ import ( "github.com/0xPolygon/polygon-edge/blockchain" "github.com/0xPolygon/polygon-edge/chain" - "github.com/0xPolygon/polygon-edge/forkmanager" "github.com/0xPolygon/polygon-edge/network" "github.com/0xPolygon/polygon-edge/state" "github.com/0xPolygon/polygon-edge/state/runtime" @@ -625,14 +624,6 @@ func (p *TxPool) validateTx(tx *types.Transaction) error { return fmt.Errorf("%w: type %d rejected, london hardfork is not enabled", ErrTxTypeNotSupported, tx.Type) } - // DynamicFeeTx should be rejected if TxHashWithType fork is registered but not enabled for current block - blockNumber, err := forkmanager.GetInstance().GetForkBlock(chain.TxHashWithType) - if err == nil && blockNumber > currentBlockNumber { - metrics.IncrCounter([]string{txPoolMetrics, "dynamic_tx_not_allowed"}, 1) - - return ErrDynamicTxNotAllowed - } - // Check EIP-1559-related fields and make sure they are correct if tx.GasFeeCap == nil || tx.GasTipCap == nil { metrics.IncrCounter([]string{txPoolMetrics, "underpriced_tx"}, 1) diff --git a/types/buildroot/buildroot.go b/types/buildroot/buildroot.go index ad99ffbfa1..4706f1973f 100644 --- a/types/buildroot/buildroot.go +++ b/types/buildroot/buildroot.go @@ -26,10 +26,8 @@ func CalculateReceiptsRoot(receipts []*types.Receipt) types.Hash { // CalculateTransactionsRoot calculates the root of a list of transactions func CalculateTransactionsRoot(transactions []*types.Transaction, blockNumber uint64) types.Hash { - handler := types.GetTransactionHashHandler(blockNumber) - return CalculateRoot(len(transactions), func(indx int) []byte { - return handler.SerializeForRootCalculation(transactions[indx], &arenaPool) + return transactions[indx].MarshalRLPTo(nil) }) } diff --git a/types/transaction.go b/types/transaction.go index 87dbea350a..fef49d0822 100644 --- a/types/transaction.go +++ b/types/transaction.go @@ -6,6 +6,7 @@ import ( "sync/atomic" "github.com/0xPolygon/polygon-edge/helper/common" + "github.com/0xPolygon/polygon-edge/helper/keccak" ) const ( @@ -84,7 +85,9 @@ func (t *Transaction) IsValueTransfer() bool { // ComputeHash computes the hash of the transaction func (t *Transaction) ComputeHash(blockNumber uint64) *Transaction { - GetTransactionHashHandler(blockNumber).ComputeHash(t) + hash := keccak.DefaultKeccakPool.Get() + hash.WriteFn(t.Hash[:0], t.MarshalRLPTo) + keccak.DefaultKeccakPool.Put(hash) return t } diff --git a/types/transaction_fork_hash.go b/types/transaction_fork_hash.go deleted file mode 100644 index 6c84461e5d..0000000000 --- a/types/transaction_fork_hash.go +++ /dev/null @@ -1,97 +0,0 @@ -package types - -import ( - "math/big" - - "github.com/0xPolygon/polygon-edge/forkmanager" - "github.com/0xPolygon/polygon-edge/helper/keccak" - "github.com/umbracle/fastrlp" -) - -const txHashHandler = "txHash" - -type TransactionHashFork interface { - SerializeForRootCalculation(*Transaction, *fastrlp.ArenaPool) []byte - ComputeHash(*Transaction) -} - -var ( - _ TransactionHashFork = (*TransactionHashForkV1)(nil) - _ TransactionHashFork = (*TransactionHashForkV2)(nil) -) - -type TransactionHashForkV1 struct { -} - -func (th *TransactionHashForkV1) SerializeForRootCalculation(t *Transaction, ap *fastrlp.ArenaPool) []byte { - ar := ap.Get() - chainID := t.ChainID - t.ChainID = big.NewInt(0) - - defer func() { - ap.Put(ar) - - t.ChainID = chainID - }() - - ar.Reset() - - return t.MarshalRLPWith(ar).MarshalTo(nil) -} - -func (th *TransactionHashForkV1) ComputeHash(t *Transaction) { - ar := marshalArenaPool.Get() - hash := keccak.DefaultKeccakPool.Get() - - chainID := t.ChainID - t.ChainID = big.NewInt(0) - - v := t.MarshalRLPWith(ar) - hash.WriteRlp(t.Hash[:0], v) - - t.ChainID = chainID - - marshalArenaPool.Put(ar) - keccak.DefaultKeccakPool.Put(hash) -} - -type TransactionHashForkV2 struct { -} - -func (th *TransactionHashForkV2) SerializeForRootCalculation(t *Transaction, _ *fastrlp.ArenaPool) []byte { - return t.MarshalRLPTo(nil) -} - -func (th *TransactionHashForkV2) ComputeHash(t *Transaction) { - hash := keccak.DefaultKeccakPool.Get() - hash.WriteFn(t.Hash[:0], t.MarshalRLPTo) - keccak.DefaultKeccakPool.Put(hash) -} - -func RegisterTxHashFork(txHashWithTypeFork string) error { - fh := forkmanager.GetInstance() - - if err := fh.RegisterHandler( - forkmanager.InitialFork, txHashHandler, &TransactionHashForkV1{}); err != nil { - return err - } - - if fh.IsForkRegistered(txHashWithTypeFork) { - if err := fh.RegisterHandler( - txHashWithTypeFork, txHashHandler, &TransactionHashForkV2{}); err != nil { - return err - } - } - - return nil -} - -func GetTransactionHashHandler(blockNumber uint64) TransactionHashFork { - if h := forkmanager.GetInstance().GetHandler(txHashHandler, blockNumber); h != nil { - //nolint:forcetypeassert - return h.(TransactionHashFork) - } - - // because of tests - return &TransactionHashForkV1{} -}