From 737bf91de3e670141de4d001d0ef9c876b3a7f08 Mon Sep 17 00:00:00 2001 From: "F. Eugene Aumson" Date: Fri, 6 Sep 2024 14:11:27 +0000 Subject: [PATCH] issue ERC20 staking rewards (native rewards TBD) --- .../ERC20TokenStakingManager.go | 2 +- .../NativeTokenStakingManager.go | 2 +- contracts/staking/ERC20TokenStakingManager.sol | 5 +++++ contracts/staking/NativeTokenStakingManager.sol | 5 +++++ contracts/staking/PoSValidatorManager.sol | 10 ++++++++++ .../staking/tests/ERC20TokenStakingManagerTests.t.sol | 3 ++- .../staking/tests/NativeTokenStakingManagerTests.t.sol | 3 ++- contracts/staking/tests/PoSValidatorManagerTests.t.sol | 1 + 8 files changed, 27 insertions(+), 4 deletions(-) diff --git a/abi-bindings/go/staking/ERC20TokenStakingManager/ERC20TokenStakingManager.go b/abi-bindings/go/staking/ERC20TokenStakingManager/ERC20TokenStakingManager.go index 84ab412f9..785d6b813 100644 --- a/abi-bindings/go/staking/ERC20TokenStakingManager/ERC20TokenStakingManager.go +++ b/abi-bindings/go/staking/ERC20TokenStakingManager/ERC20TokenStakingManager.go @@ -48,7 +48,7 @@ type ValidatorManagerSettings struct { // ERC20TokenStakingManagerMetaData contains all meta data concerning the ERC20TokenStakingManager contract. var ERC20TokenStakingManagerMetaData = &bind.MetaData{ ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"init\",\"type\":\"uint8\",\"internalType\":\"enumICMInitializable\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"WARP_MESSENGER\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIWarpMessenger\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"activeValidators\",\"inputs\":[{\"name\":\"nodeID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"completeDelegatorRegistration\",\"inputs\":[{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"completeEndDelegation\",\"inputs\":[{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"completeEndValidation\",\"inputs\":[{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"completeValidatorRegistration\",\"inputs\":[{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"getWeight\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"initialize\",\"inputs\":[{\"name\":\"settings\",\"type\":\"tuple\",\"internalType\":\"structPoSValidatorManagerSettings\",\"components\":[{\"name\":\"baseSettings\",\"type\":\"tuple\",\"internalType\":\"structValidatorManagerSettings\",\"components\":[{\"name\":\"pChainBlockchainID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"subnetID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"maximumHourlyChurn\",\"type\":\"uint8\",\"internalType\":\"uint8\"}]},{\"name\":\"minimumStakeAmount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"maximumStakeAmount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"minimumStakeDuration\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"rewardCalculator\",\"type\":\"address\",\"internalType\":\"contractIRewardCalculator\"}]},{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"contractIERC20Mintable\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initializeDelegatorRegistration\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"delegationAmount\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initializeEndDelegation\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"includeUptimeProof\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initializeEndValidation\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"includeUptimeProof\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initializeValidatorRegistration\",\"inputs\":[{\"name\":\"stakeAmount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"nodeID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"registrationExpiry\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"blsPublicKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"resendDelegatorRegistration\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"resendEndDelegation\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"resendEndValidatorMessage\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"resendRegisterValidatorMessage\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"valueToWeight\",\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"weightToValue\",\"inputs\":[{\"name\":\"weight\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"pure\"},{\"type\":\"event\",\"name\":\"DelegationEnded\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"nonce\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DelegatorAdded\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"delegatorAddress\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"nonce\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"validatorWeight\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"delegatorWeight\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"setWeightMessageID\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DelegatorRegistered\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"nonce\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"},{\"name\":\"startTime\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DelegatorRemovalInitialized\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"nonce\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"},{\"name\":\"validatorWeight\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"endTime\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"setWeightMessageID\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Initialized\",\"inputs\":[{\"name\":\"version\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidationPeriodCreated\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"nodeID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"registerValidationMessageID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"weight\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"registrationExpiry\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidationPeriodEnded\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"status\",\"type\":\"uint8\",\"indexed\":true,\"internalType\":\"enumValidatorStatus\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidationPeriodRegistered\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"weight\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"timestamp\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidatorRemovalInitialized\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"setWeightMessageID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"weight\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"endTime\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"AddressEmptyCode\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"AddressInsufficientBalance\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"FailedInnerCall\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidInitialization\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"NotInitializing\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"ReentrancyGuardReentrantCall\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"SafeERC20FailedOperation\",\"inputs\":[{\"name\":\"token\",\"type\":\"address\",\"internalType\":\"address\"}]}]", - Bin: "0x608060405234801561000f575f80fd5b5060405161486538038061486583398101604081905261002e91610107565b60018160018111156100425761004261012c565b0361004f5761004f610055565b50610140565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805468010000000000000000900460ff16156100a55760405163f92ee8a960e01b815260040160405180910390fd5b80546001600160401b03908116146101045780546001600160401b0319166001600160401b0390811782556040519081527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15b50565b5f60208284031215610117575f80fd5b815160028110610125575f80fd5b9392505050565b634e487b7160e01b5f52602160045260245ffd5b6147188061014d5f395ff3fe608060405234801561000f575f80fd5b5060043610610111575f3560e01c806366435abf1161009e57806398f3e2b41161006e57806398f3e2b4146102645780639e1bc4ef14610277578063a3a65e481461028a578063b771b3bc1461029d578063bee0a03f146102c3575f80fd5b806366435abf146102185780636d0e43fa1461022b57806376f786211461023e578063872fda6414610251575f80fd5b806327f39ca8116100e457806327f39ca8146101a15780632e2194d8146101b4578063467ef06f146101df5780635297fae6146101f25780636206585614610205575f80fd5b80630118acc4146101155780630322ed981461012a5780630cdd09851461013d578063162f1f611461018e575b5f80fd5b610128610123366004613d84565b6102d6565b005b610128610138366004613dbf565b610761565b61017b61014b366004613dbf565b5f9081527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb08602052604090205490565b6040519081526020015b60405180910390f35b61012861019c366004613dbf565b6108bd565b6101286101af366004613dea565b61092a565b6101c76101c2366004613dbf565b610a0e565b6040516001600160401b039091168152602001610185565b6101286101ed366004613e27565b610a24565b610128610200366004613e40565b610a4f565b61017b610213366004613e7e565b610c40565b6101c7610226366004613dbf565b610c59565b610128610239366004613dbf565b610c6d565b61012861024c366004613d84565b610cda565b61017b61025f366004613f29565b610cf5565b610128610272366004613e40565b610d1a565b61017b610285366004613fc5565b610eba565b610128610298366004613e27565b610ecd565b6102ab6005600160991b0181565b6040516001600160a01b039091168152602001610185565b6101286102d1366004613dbf565b61108a565b5f8381527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d0360205260408120600101545f8051602061466c833981519152918415610328576103258285611159565b90505b5f868152600384016020526040808220815161010081019092528054829060ff16600481111561035a5761035a613fe5565b600481111561036b5761036b613fe5565b8152815461010090046001600160a01b03166020820152600182015460408201526002808301546001600160401b038082166060850152600160401b820481166080850152600160801b8204811660a0850152600160c01b909104811660c084015260039093015490921660e090910152909150815160048111156103f2576103f2613fe5565b146104445760405162461bcd60e51b815260206004820152602a60248201525f8051602061468c8339815191526044820152696e6f742061637469766560b01b60648201526084015b60405180910390fd5b60208101516001600160a01b031633146104a95760405162461bcd60e51b815260206004820152603360248201525f8051602061468c8339815191526044820152723737ba1037bbb732b210313c9039b2b73232b960691b606482015260840161043b565b5f6104b3846113f5565b60038084526001600160401b0342811660a0860152821660e08501525f8a815290870160205260409020835181549293508492829060ff1916600183600481111561050057610500613fe5565b021790555060208201518154610100600160a81b0319166101006001600160a01b0390921691909102178155604082015160018201556060820151600282018054608085015160a086015160c08701516001600160401b039586166001600160801b031990941693909317600160401b92861692909202919091176001600160801b0316600160801b918516919091026001600160c01b031617600160c01b9184169190910217905560e0909201516003909101805467ffffffffffffffff1916919092161790555f6105d285611469565b905082606001516001600160401b03168160a001516001600160401b0316116106495760405162461bcd60e51b815260206004820152602360248201527f506f5356616c696461746f724d616e616765723a20496e76616c69642077656960448201526219da1d60ea1b606482015260840161043b565b5f83606001518260a0015161065e919061400d565b905061066a8682611548565b5f610676878584611590565b5f8c815260058a016020526040902090915061069282826140b7565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb906106bf908590600401614198565b6020604051808303815f875af11580156106db573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106ff91906141ca565b604080516001600160401b03868116825242602083015291810183905291925086169089908e907f5318ab4d7cdf77056db2db5b539a08fe7d1a63d6885ecee8236a0dbda2843b4e9060600160405180910390a4505050505050505050505050565b5f8181527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb066020526040812080545f805160206146ac8339815191529291906107a990614034565b90501180156107db575060035f83815260078301602052604090205460ff1660058111156107d9576107d9613fe5565b145b61083f5760405162461bcd60e51b815260206004820152602f60248201527f56616c696461746f724d616e616765723a2056616c696461746f72206e6f742060448201526e1c195b991a5b99c81c995b5bdd985b608a1b606482015260840161043b565b5f82815260068201602052604090819020905163ee5b48eb60e01b81526005600160991b019163ee5b48eb9161087891906004016141e1565b6020604051808303815f875af1158015610894573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108b891906141ca565b505050565b6108c6816117ad565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d05602052604090819020905163ee5b48eb60e01b81525f8051602061466c833981519152916005600160991b019163ee5b48eb91610878916004016141e1565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805460029190600160401b900460ff1680610973575080546001600160401b03808416911610155b156109915760405163f92ee8a960e01b815260040160405180910390fd5b805468ffffffffffffffffff19166001600160401b03831617600160401b1781556109bc848461187c565b805468ff0000000000000000191681556040516001600160401b03831681527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a150505050565b5f610a1e64e8d4a510008361427f565b92915050565b5f610a2e82611896565b9050610a4b8160a001516001600160401b03168260400151611c23565b5050565b5f8051602061466c8339815191525f610a6784611c59565b90505f80610a788360400151611e3a565b5091509150610a8685612075565b5f8581526004850160205260408120610a9e91613ccc565b5f610aa883611469565b9050816001600160401b031681608001516001600160401b03161015610ae05760405162461bcd60e51b815260040161043b90614292565b5f8681526003860160205260409020600201546001600160401b03808416600160c01b909204161115610b255760405162461bcd60e51b815260040161043b906142d4565b60015f87815260038701602052604090205460ff166004811115610b4b57610b4b613fe5565b14610bb45760405162461bcd60e51b815260206004820152603360248201527f506f5356616c696461746f724d616e616765723a2064656c65676174696f6e4960448201527211081b9bdd081c195b991a5b99c81859191959606a1b606482015260840161043b565b5f868152600386016020908152604091829020805460ff1916600290811782550180546001600160401b0342818116600160401b0267ffffffffffffffff60401b19909316929092179092559251928352841691859189917f245fc69b36e168426e0306fc8d8300661b9af297c7958820dbf804f9f63e7064910160405180910390a450505050505050565b5f610a1e6001600160401b03831664e8d4a5100061431d565b5f610c6382611469565b60a0015192915050565b610c7681612075565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d04602052604090819020905163ee5b48eb60e01b81525f8051602061466c833981519152916005600160991b019163ee5b48eb91610878916004016141e1565b8115610cec57610cea8382611159565b505b6108b88361214e565b5f80610d0086612506565b9050610d0e858286866125b3565b9150505b949350505050565b5f8051602061466c8339815191525f610d3284611c59565b90505f80610d438360400151611e3a565b5091509150610d51856117ad565b5f8581526005850160205260408120610d6991613ccc565b5f610d7383611469565b9050816001600160401b031681608001516001600160401b03161015610dab5760405162461bcd60e51b815260040161043b90614292565b5f8681526003808701602052604090912001546001600160401b0380841691161115610de95760405162461bcd60e51b815260040161043b906142d4565b60035f87815260038701602052604090205460ff166004811115610e0f57610e0f613fe5565b14610e635760405162461bcd60e51b815260206004820152603160248201525f8051602061468c8339815191526044820152701b9bdd081c195b991a5b99c81859191959607a1b606482015260840161043b565b5f868152600386016020526040808220805460ff19166004179055516001600160401b03841691859189917f52e9b1eaef84d46cda83ccb9d427267bc4d04f756b4a32c8302722b79e5c65ab91a450505050505050565b5f610ec6833384612a08565b9392505050565b5f805160206146ac8339815191525f610ee583611c59565b90505f80610ef68360400151612dc3565b9150915080610f585760405162461bcd60e51b815260206004820152602860248201527f56616c696461746f724d616e616765723a20526567697374726174696f6e206e6044820152671bdd081d985b1a5960c21b606482015260840161043b565b5f82815260058501602052604081208054610f7290614034565b9050118015610fa4575060015f83815260078601602052604090205460ff166005811115610fa257610fa2613fe5565b145b610fc05760405162461bcd60e51b815260040161043b90614334565b5f8281526005850160205260408120610fd891613ccc565b5f8281526007850160208181526040808420805460ff191660021781556003810180546001600160401b0342818116600160801b0267ffffffffffffffff60801b19909316929092178355600190930154875260088b0185528387208990559588905293835292548151600160401b90910490931683529082019290925283917ff8fd1c90fb9cfa2ca2358fdf5806b086ad43315d92b221c929efc7f105ce7568910160405180910390a25050505050565b5f8181527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb056020526040812080545f805160206146ac8339815191529291906110d290614034565b9050118015611104575060015f83815260078301602052604090205460ff16600581111561110257611102613fe5565b145b6111205760405162461bcd60e51b815260040161043b90614334565b5f82815260058201602052604090819020905163ee5b48eb60e01b81526005600160991b019163ee5b48eb9161087891906004016141e1565b6040516306f8253560e41b815263ffffffff821660048201525f90819081906005600160991b0190636f825350906024015f60405180830381865afa1580156111a4573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f191682016040526111cb9190810190614386565b915091508061122e5760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a20696e76616c69642077617260448201526870206d65737361676560b81b606482015260840161043b565b6005600160991b016001600160a01b0316634213cf786040518163ffffffff1660e01b8152600401602060405180830381865afa158015611271573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061129591906141ca565b8251146112f95760405162461bcd60e51b815260206004820152602c60248201527f506f5356616c696461746f724d616e616765723a20696e76616c696420736f7560448201526b1c98d94818da185a5b88125160a21b606482015260840161043b565b60208201516001600160a01b03161561136f5760405162461bcd60e51b815260206004820152603260248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964206f726960448201527167696e2073656e646572206164647265737360701b606482015260840161043b565b5f8061137e8460400151612f64565b915091508187146113eb5760405162461bcd60e51b815260206004820152603160248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964207570746044820152701a5b59481d985b1a59185d1a5bdb881251607a1b606482015260840161043b565b9695505050505050565b5f8181525f805160206146ec8339815191526020526040812060030180545f805160206146ac833981519152916001600160401b039091169081908461143a83614458565b91906101000a8154816001600160401b0302191690836001600160401b03160217905550508092505050919050565b611471613d03565b5f8281525f805160206146ec8339815191526020526040908190208151610100810190925280545f805160206146ac833981519152929190829060ff1660058111156114bf576114bf613fe5565b60058111156114d0576114d0613fe5565b81526001820154602082015260028201546001600160a01b03811660408301526001600160401b03600160a01b909104811660608301526003909201548083166080830152600160401b8104831660a0830152600160801b8104831660c0830152600160c01b900490911660e0909101529392505050565b5f9182525f805160206146ec833981519152602052604090912060030180546001600160401b03909216600160401b0267ffffffffffffffff60401b19909216919091179055565b60408051603680825260608281019093525f91906020820181803683370190505090505f5b6002811015611609576115c981600161447d565b6115d490600861431d565b5081515f908390839081106115eb576115eb614490565b60200101906001600160f81b03191690815f1a9053506001016115b5565b505f5b600481101561166c5761162081600361447d565b61162b90600861431d565b6001901c60f81b8261163e8360026144a4565b8151811061164e5761164e614490565b60200101906001600160f81b03191690815f1a90535060010161160c565b505f5b60208110156116ce5761168381601f61447d565b61168e90600861431d565b86901c60f81b826116a08360066144a4565b815181106116b0576116b0614490565b60200101906001600160f81b03191690815f1a90535060010161166f565b505f5b6008811015611739576116e581600761447d565b6116f090600861431d565b6001600160401b038616901c60f81b8261170b8360266144a4565b8151811061171b5761171b614490565b60200101906001600160f81b03191690815f1a9053506001016116d1565b505f5b60088110156117a45761175081600761447d565b61175b90600861431d565b6001600160401b038516901c60f81b8261177683602e6144a4565b8151811061178657611786614490565b60200101906001600160f81b03191690815f1a90535060010161173c565b50949350505050565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d056020526040812080545f8051602061466c8339815191529291906117f590614034565b9050118015611827575060035f83815260038301602052604090205460ff16600481111561182557611825613fe5565b145b610a4b5760405162461bcd60e51b815260206004820152603360248201525f8051602061468c83398151915260448201527272656d6f76616c206e6f742070656e64696e6760681b606482015260840161043b565b61188461313c565b61188d82613187565b610a4b816131cd565b61189e613d03565b5f805160206146ac8339815191525f6118b684611c59565b90505f806118c78360400151612dc3565b91509150801561192c5760405162461bcd60e51b815260206004820152602a60248201527f56616c696461746f724d616e616765723a20726567697374726174696f6e20736044820152691d1a5b1b081d985b1a5960b21b606482015260840161043b565b5f828152600785016020526040808220815161010081019092528054829060ff16600581111561195e5761195e613fe5565b600581111561196f5761196f613fe5565b81526001820154602082015260028201546001600160a01b03811660408301526001600160401b03600160a01b909104811660608301526003928301548082166080840152600160401b8104821660a0840152600160801b8104821660c0840152600160c01b90041660e0909101529091505f90825160058111156119f6576119f6613fe5565b1480611a145750600182516005811115611a1257611a12613fe5565b145b611a735760405162461bcd60e51b815260206004820152602a60248201527f56616c696461746f724d616e616765723a20696e76616c69642076616c696461604482015269746f722073746174757360b01b606482015260840161043b565b600382516005811115611a8857611a88613fe5565b03611aaf57505f8381526006860160205260408120600491611aaa9190613ccc565b611ab3565b5060055b6020808301515f90815260088801909152604081205581816005811115611adc57611adc613fe5565b90816005811115611aef57611aef613fe5565b9052505f84815260078701602052604090208251815484929190829060ff19166001836005811115611b2357611b23613fe5565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b0319909316959094169490941717929092161791909117905581516005811115611bee57611bee613fe5565b60405185907f1c08e59656f1a18dc2da76826cdc52805c43e897a17c50faefb8ab3c1526cc16905f90a3509695505050505050565b7f6e5bdfcce15e53c3406ea67bfce37dcd26f5152d5492824e43fd5e3c8ac5ab0054610a4b906001600160a01b03168284613281565b60408051606080820183525f8083526020830181905292820152905f805160206146ac8339815191526040516306f8253560e41b815263ffffffff851660048201529091505f9081906005600160991b0190636f825350906024015f60405180830381865afa158015611cce573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f19168201604052611cf59190810190614386565b9150915080611d5c5760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20496e76696e76616c6964616c696460448201526c2077617270206d65737361676560981b606482015260840161043b565b8254825114611dbf5760405162461bcd60e51b815260206004820152602960248201527f56616c696461746f724d616e616765723a20696e76616c696420736f757263656044820152680818da185a5b88125160ba1b606482015260840161043b565b60208201516001600160a01b031615611e325760405162461bcd60e51b815260206004820152602f60248201527f56616c696461746f724d616e616765723a20696e76616c6964206f726967696e60448201526e2073656e646572206164647265737360881b606482015260840161043b565b509392505050565b5f805f8351603614611e5e5760405162461bcd60e51b815260040161043b906144b7565b5f805b6002811015611ead57611e7581600161447d565b611e8090600861431d565b61ffff16868281518110611e9657611e96614490565b016020015160f81c901b9190911790600101611e61565b5061ffff811615611ed05760405162461bcd60e51b815260040161043b90614500565b5f805b6004811015611f2b57611ee781600361447d565b611ef290600861431d565b63ffffffff1687611f048360026144a4565b81518110611f1457611f14614490565b016020015160f81c901b9190911790600101611ed3565b5063ffffffff8116600314611f525760405162461bcd60e51b815260040161043b90614543565b5f805b6020811015611fa757611f6981601f61447d565b611f7490600861431d565b88611f808360066144a4565b81518110611f9057611f90614490565b016020015160f81c901b9190911790600101611f55565b505f805b600881101561200657611fbf81600761447d565b611fca90600861431d565b6001600160401b031689611fdf8360266144a4565b81518110611fef57611fef614490565b016020015160f81c901b9190911790600101611fab565b505f805b60088110156120655761201e81600761447d565b61202990600861431d565b6001600160401b03168a61203e83602e6144a4565b8151811061204e5761204e614490565b016020015160f81c901b919091179060010161200a565b5091989097509095509350505050565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d046020526040812080545f8051602061466c8339815191529291906120bd90614034565b90501180156120ef575060015f83815260038301602052604090205460ff1660048111156120ed576120ed613fe5565b145b610a4b5760405162461bcd60e51b815260206004820152603860248201525f8051602061468c83398151915260448201527f726567697374726174696f6e206e6f742070656e64696e670000000000000000606482015260840161043b565b5f8181525f805160206146ec83398151915260205260408082208151610100810190925280545f805160206146ac83398151915293929190829060ff16600581111561219c5761219c613fe5565b60058111156121ad576121ad613fe5565b8152600182015460208201526002808301546001600160a01b03811660408401526001600160401b03600160a01b909104811660608401526003909301548084166080840152600160401b8104841660a0840152600160801b8104841660c0840152600160c01b900490921660e0909101529091508151600581111561223557612235613fe5565b146122915760405162461bcd60e51b815260206004820152602660248201527f56616c696461746f724d616e616765723a2076616c696461746f72206e6f742060448201526561637469766560d01b606482015260840161043b565b60408101516001600160a01b0316336001600160a01b03161461230b5760405162461bcd60e51b815260206004820152602c60248201527f56616c696461746f724d616e616765723a2073656e646572206e6f742076616c60448201526b34b230ba37b91037bbb732b960a11b606482015260840161043b565b6123188160a001516132e0565b60038152426001600160401b031660e08201525f83815260078301602052604090208151815483929190829060ff1916600183600581111561235c5761235c613fe5565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b031990931695909416949094171792909216179190911790555f61242884612422816113f5565b5f611590565b5f858152600685016020526040902090915061244482826140b7565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb90612471908590600401614198565b6020604051808303815f875af115801561248d573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906124b191906141ca565b60a0840151604080516001600160401b039092168252426020830152919250829187917f13d58394cf269d48bcf927959a29a5ffee7c9924dafff8927ecdf3c48ffa7c67910160405180910390a35050505050565b5f5f8051602061466c8339815191528161251f84613481565b90505f61252b82610a0e565b83549091506001600160401b0382161080159061255557508260010154816001600160401b031611155b610d125760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964207374616044820152681ad948185b5bdd5b9d60ba1b606482015260840161043b565b5f6125bc6134b7565b5f805160206146ac833981519152426001600160401b0385161180156125f657506001600160401b0384166125f4426202a3006144a4565b115b6126585760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20696e76616c69642072656769737460448201526c726174696f6e2065787069727960981b606482015260840161043b565b856126af5760405162461bcd60e51b815260206004820152602160248201527f56616c696461746f724d616e616765723a20696e76616c6964206e6f646520496044820152601160fa1b606482015260840161043b565b5f8681526008820160205260409020541561271d5760405162461bcd60e51b815260206004820152602860248201527f56616c696461746f724d616e616765723a206e6f646520494420616c72656164604482015267792061637469766560c01b606482015260840161043b565b82516030146127845760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20696e76616c696420626c7350756260448201526c0d8d2c696caf240d8cadccee8d609b1b606482015260840161043b565b61278d856132e0565b5f806127d46040518060a00160405280856001015481526020018a8152602001896001600160401b03168152602001886001600160401b03168152602001878152506134ee565b5f828152600586016020526040902091935091506127f282826140b7565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb9061281f908590600401614198565b6020604051808303815f875af115801561283b573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061285f91906141ca565b604080516101008101825260018152602081018c90529192508101336001600160a01b031681526001600160401b038a1660208083018290525f604080850182905260608501939093526080840181905260a0909301839052868352600788019052902081518154829060ff191660018360058111156128e1576128e1613fe5565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b031990931695909416949094171792909216179190911790556129a2836113f5565b50604080516001600160401b03808b1682528916602082015282918b9186917f79b81620b81daf2c08cd5bb3dbb79e75d2d7a87f52171fde5aadc8c47823026e910160405180910390a4509092505050610d1260015f805160206146cc83398151915255565b5f612a116134b7565b5f612a1e6101c284613481565b90505f8051602061466c8339815191525f612a3887611469565b9050600281516005811115612a4f57612a4f613fe5565b14612aae5760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a2076616c696461746f72206e6044820152686f742061637469766560b81b606482015260840161043b565b5f838260a00151612abf919061458a565b9050612acb8882611548565b5f612ad5896113f5565b90505f898983604051602001612b1d9392919092835260609190911b6bffffffffffffffffffffffff1916602083015260c01b6001600160c01b0319166034820152603c0190565b604051602081830303815290604052805190602001209050612b3e866132e0565b5f612b4a8b8486611590565b5f8381526004880160205260409020909150612b6682826140b7565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb90612b93908590600401614198565b6020604051808303815f875af1158015612baf573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190612bd391906141ca565b60408051610100810190915290915080600181526020018c6001600160a01b031681526020018d8152602001896001600160401b031681526020015f6001600160401b031681526020015f6001600160401b03168152602001856001600160401b031681526020015f6001600160401b0316815250876003015f8581526020019081526020015f205f820151815f015f6101000a81548160ff02191690836004811115612c8257612c82613fe5565b02179055506020828101518254610100600160a81b0319166101006001600160a01b039283160217835560408085015160018501556060808601516002860180546080808a015160a08b015160c08c01516001600160401b039687166001600160801b031990951694909417600160401b92871692909202919091176001600160801b0316600160801b918616919091026001600160c01b031617600160c01b928516929092029190911790915560e0909701516003909601805467ffffffffffffffff19169682169690961790955581518a861681528b861694810194909452938d1690830152918101849052908d16918e9186917fb0024b263bc3a0b728a6edea50a69efa841189f8d32ee8af9d1c2b1a1a223426910160405180910390a450909650505050505050610ec660015f805160206146cc83398151915255565b5f808251602714612de65760405162461bcd60e51b815260040161043b906144b7565b5f805b6002811015612e3557612dfd81600161447d565b612e0890600861431d565b61ffff16858281518110612e1e57612e1e614490565b016020015160f81c901b9190911790600101612de9565b5061ffff811615612e585760405162461bcd60e51b815260040161043b90614500565b5f805b6004811015612eb357612e6f81600361447d565b612e7a90600861431d565b63ffffffff1686612e8c8360026144a4565b81518110612e9c57612e9c614490565b016020015160f81c901b9190911790600101612e5b565b5063ffffffff8116600214612eda5760405162461bcd60e51b815260040161043b90614543565b5f805b6020811015612f2f57612ef181601f61447d565b612efc90600861431d565b87612f088360066144a4565b81518110612f1857612f18614490565b016020015160f81c901b9190911790600101612edd565b505f86602681518110612f4457612f44614490565b016020015191976001600160f81b03199092161515965090945050505050565b5f808251602e14612f875760405162461bcd60e51b815260040161043b906144b7565b5f805b6002811015612fd657612f9e81600161447d565b612fa990600861431d565b61ffff16858281518110612fbf57612fbf614490565b016020015160f81c901b9190911790600101612f8a565b5061ffff811615612ff95760405162461bcd60e51b815260040161043b90614500565b5f805b60048110156130545761301081600361447d565b61301b90600861431d565b63ffffffff168661302d8360026144a4565b8151811061303d5761303d614490565b016020015160f81c901b9190911790600101612ffc565b5063ffffffff811660041461307b5760405162461bcd60e51b815260040161043b90614543565b5f805b60208110156130d05761309281601f61447d565b61309d90600861431d565b876130a98360066144a4565b815181106130b9576130b9614490565b016020015160f81c901b919091179060010161307e565b505f805b600881101561312f576130e881600761447d565b6130f390600861431d565b6001600160401b0316886131088360266144a4565b8151811061311857613118614490565b016020015160f81c901b91909117906001016130d4565b5090969095509350505050565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a0054600160401b900460ff1661318557604051631afcd79f60e31b815260040160405180910390fd5b565b61318f61313c565b613198816138a6565b6131ca606082013560808301356131b560c0850160a08601613e7e565b6131c560e0860160c087016145aa565b6138c7565b50565b6131d561313c565b7f6e5bdfcce15e53c3406ea67bfce37dcd26f5152d5492824e43fd5e3c8ac5ab006001600160a01b0382166132615760405162461bcd60e51b815260206004820152602c60248201527f4552433230546f6b656e5374616b696e674d616e616765723a207a65726f207460448201526b6f6b656e206164647265737360a01b606482015260840161043b565b80546001600160a01b0319166001600160a01b0392909216919091179055565b6040516001600160a01b038381166024830152604482018390526108b891859182169063a9059cbb906064015b604051602081830303815290604052915060e01b6020820180516001600160e01b038381831617835250505050613922565b7fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb02545f805160206146ac8339815191529060ff165f0361331e575050565b60408051606081018252600383015480825260048401546001600160401b038082166020850152600160401b9091041692820192909252904290610e1090613366908361447d565b10613382576001600160401b03841660408301528082526133a1565b8382604001818151613394919061458a565b6001600160401b03169052505b5f8260200151836040015160646133b891906145c5565b6133c291906145f0565b600285015490915060ff908116908216111561343d5760405162461bcd60e51b815260206004820152603460248201527f56616c696461746f724d616e616765723a206d6178696d756d20686f75726c796044820152730818da1d5c9b881c985d1948195e18d95959195960621b606482015260840161043b565b5050805160038301556020810151600490920180546040909201516001600160401b03908116600160401b026001600160801b031990931693169290921717905550565b5f610a1e827f6e5bdfcce15e53c3406ea67bfce37dcd26f5152d5492824e43fd5e3c8ac5ab00546001600160a01b031690613983565b5f805160206146cc8339815191528054600119016134e857604051633ee5aeb560e01b815260040160405180910390fd5b60029055565b5f60608260800151516030146135585760405162461bcd60e51b815260206004820152602960248201527f5374616b696e674d657373616765733a20696e76616c6964207369676e6174756044820152680e4ca40d8cadccee8d60bb1b606482015260840161043b565b60408051608680825260c082019092525f916020820181803683370190505090505f5b60028110156135cf5761358f81600161447d565b61359a90600861431d565b5081515f908390839081106135b1576135b1614490565b60200101906001600160f81b03191690815f1a90535060010161357b565b505f5b600481101561362d576135e681600361447d565b6135f190600861431d565b505f826135ff8360026144a4565b8151811061360f5761360f614490565b60200101906001600160f81b03191690815f1a9053506001016135d2565b505f5b602081101561368a578451816020811061364c5761364c614490565b1a60f81b8261365c8360066144a4565b8151811061366c5761366c614490565b60200101906001600160f81b03191690815f1a905350600101613630565b505f5b60208110156136ea57846020015181602081106136ac576136ac614490565b1a60f81b826136bc8360266144a4565b815181106136cc576136cc614490565b60200101906001600160f81b03191690815f1a90535060010161368d565b505f5b600881101561375e5761370181600761447d565b61370c90600861431d565b60ff1685604001516001600160401b0316901c60f81b8282604661373091906144a4565b8151811061374057613740614490565b60200101906001600160f81b03191690815f1a9053506001016136ed565b505f5b60308110156137c9578460800151818151811061378057613780614490565b01602001516001600160f81b0319168261379b83604e6144a4565b815181106137ab576137ab614490565b60200101906001600160f81b03191690815f1a905350600101613761565b505f5b600881101561383b576137e081600761447d565b6137eb90600861431d565b60608601516001600160401b0390811691161c60f81b8261380d83607e6144a4565b8151811061381d5761381d614490565b60200101906001600160f81b03191690815f1a9053506001016137cc565b5060028160405161384c9190614615565b602060405180830381855afa158015613867573d5f803e3d5ffd5b5050506040513d601f19601f8201168201806040525081019061388a91906141ca565b94909350915050565b60015f805160206146cc83398151915255565b6138ae61313c565b6138b6613ae5565b6138be613af5565b6131ca81613afd565b6138cf61313c565b5f5f8051602061466c833981519152948555506001840192909255600290920180546001600160a01b03909216600160401b026001600160e01b03199092166001600160401b0390931692909217179055565b5f6139366001600160a01b03841683613b69565b905080515f1415801561395a5750808060200190518101906139589190614630565b155b156108b857604051635274afe760e01b81526001600160a01b038416600482015260240161043b565b6040516370a0823160e01b81523060048201525f9081906001600160a01b038516906370a0823190602401602060405180830381865afa1580156139c9573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906139ed91906141ca565b9050613a046001600160a01b038516333086613b76565b6040516370a0823160e01b81523060048201525f906001600160a01b038616906370a0823190602401602060405180830381865afa158015613a48573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190613a6c91906141ca565b9050818111613ad25760405162461bcd60e51b815260206004820152602c60248201527f5361666545524332305472616e7366657246726f6d3a2062616c616e6365206e60448201526b1bdd081a5b98dc99585cd95960a21b606482015260840161043b565b613adc828261447d565b95945050505050565b613aed61313c565b613185613bb5565b61318561313c565b613b0561313c565b80355f805160206146ac83398151915290815560208201357fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb0155613b4f606083016040840161464b565b600291909101805460ff191660ff90921691909117905550565b6060610ec683835f613bbd565b6040516001600160a01b038481166024830152838116604483015260648201839052613baf9186918216906323b872dd906084016132ae565b50505050565b61389361313c565b606081471015613be25760405163cd78605960e01b815230600482015260240161043b565b5f80856001600160a01b03168486604051613bfd9190614615565b5f6040518083038185875af1925050503d805f8114613c37576040519150601f19603f3d011682016040523d82523d5f602084013e613c3c565b606091505b50915091506113eb868383606082613c5c57613c5782613ca3565b610ec6565b8151158015613c7357506001600160a01b0384163b155b15613c9c57604051639996b31560e01b81526001600160a01b038516600482015260240161043b565b5080610ec6565b805115613cb35780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b508054613cd890614034565b5f825580601f10613ce7575050565b601f0160209004905f5260205f20908101906131ca9190613d47565b604080516101008101909152805f81525f6020820181905260408201819052606082018190526080820181905260a0820181905260c0820181905260e09091015290565b5b80821115613d5b575f8155600101613d48565b5090565b80151581146131ca575f80fd5b803563ffffffff81168114613d7f575f80fd5b919050565b5f805f60608486031215613d96575f80fd5b833592506020840135613da881613d5f565b9150613db660408501613d6c565b90509250925092565b5f60208284031215613dcf575f80fd5b5035919050565b6001600160a01b03811681146131ca575f80fd5b5f80828403610100811215613dfd575f80fd5b60e0811215613e0a575f80fd5b5082915060e0830135613e1c81613dd6565b809150509250929050565b5f60208284031215613e37575f80fd5b610ec682613d6c565b5f8060408385031215613e51575f80fd5b613e5a83613d6c565b946020939093013593505050565b80356001600160401b0381168114613d7f575f80fd5b5f60208284031215613e8e575f80fd5b610ec682613e68565b634e487b7160e01b5f52604160045260245ffd5b604051606081016001600160401b0381118282101715613ecd57613ecd613e97565b60405290565b604051601f8201601f191681016001600160401b0381118282101715613efb57613efb613e97565b604052919050565b5f6001600160401b03821115613f1b57613f1b613e97565b50601f01601f191660200190565b5f805f8060808587031215613f3c575f80fd5b8435935060208501359250613f5360408601613e68565b915060608501356001600160401b03811115613f6d575f80fd5b8501601f81018713613f7d575f80fd5b8035613f90613f8b82613f03565b613ed3565b818152886020838501011115613fa4575f80fd5b816020840160208301375f6020838301015280935050505092959194509250565b5f8060408385031215613fd6575f80fd5b50508035926020909101359150565b634e487b7160e01b5f52602160045260245ffd5b634e487b7160e01b5f52601160045260245ffd5b6001600160401b0382811682821603908082111561402d5761402d613ff9565b5092915050565b600181811c9082168061404857607f821691505b60208210810361406657634e487b7160e01b5f52602260045260245ffd5b50919050565b601f8211156108b857805f5260205f20601f840160051c810160208510156140915750805b601f840160051c820191505b818110156140b0575f815560010161409d565b5050505050565b81516001600160401b038111156140d0576140d0613e97565b6140e4816140de8454614034565b8461406c565b602080601f831160018114614117575f84156141005750858301515b5f19600386901b1c1916600185901b17855561416e565b5f85815260208120601f198616915b8281101561414557888601518255948401946001909101908401614126565b508582101561416257878501515f19600388901b60f8161c191681555b505060018460011b0185555b505050505050565b5f5b83811015614190578181015183820152602001614178565b50505f910152565b602081525f82518060208401526141b6816040850160208701614176565b601f01601f19169190910160400192915050565b5f602082840312156141da575f80fd5b5051919050565b5f60208083525f84546141f381614034565b806020870152604060018084165f811461421457600181146142305761425d565b60ff19851660408a0152604084151560051b8a0101955061425d565b895f5260205f205f5b858110156142545781548b8201860152908301908801614239565b8a016040019650505b509398975050505050505050565b634e487b7160e01b5f52601260045260245ffd5b5f8261428d5761428d61426b565b500490565b60208082526022908201527f506f5356616c696461746f724d616e616765723a20696e76616c6964206e6f6e604082015261636560f01b606082015260800190565b60208082526029908201527f506f5356616c696461746f724d616e616765723a206e6f6e636520646f6573206040820152680dcdee840dac2e8c6d60bb1b606082015260800190565b8082028115828204841417610a1e57610a1e613ff9565b60208082526027908201527f56616c696461746f724d616e616765723a20696e76616c69642076616c6964616040820152661d1a5bdb88125160ca1b606082015260800190565b8051613d7f81613d5f565b5f8060408385031215614397575f80fd5b82516001600160401b03808211156143ad575f80fd5b90840190606082870312156143c0575f80fd5b6143c8613eab565b825181526020808401516143db81613dd6565b828201526040840151838111156143f0575f80fd5b80850194505087601f850112614404575f80fd5b83519250614414613f8b84613f03565b8381528882858701011115614427575f80fd5b61443684838301848801614176565b8060408401525081955061444b81880161437b565b9450505050509250929050565b5f6001600160401b0380831681810361447357614473613ff9565b6001019392505050565b81810381811115610a1e57610a1e613ff9565b634e487b7160e01b5f52603260045260245ffd5b80820180821115610a1e57610a1e613ff9565b60208082526029908201527f56616c696461746f724d657373616765733a20696e76616c6964206d657373616040820152680ceca40d8cadccee8d60bb1b606082015260800190565b60208082526023908201527f56616c696461746f724d657373616765733a20696e76616c696420636f64656360408201526208125160ea1b606082015260800190565b60208082526027908201527f56616c696461746f724d657373616765733a20696e76616c6964206d657373616040820152666765207479706560c81b606082015260800190565b6001600160401b0381811683821601908082111561402d5761402d613ff9565b5f602082840312156145ba575f80fd5b8135610ec681613dd6565b6001600160401b038181168382160280821691908281146145e8576145e8613ff9565b505092915050565b5f6001600160401b03808416806146095761460961426b565b92169190910492915050565b5f8251614626818460208701614176565b9190910192915050565b5f60208284031215614640575f80fd5b8151610ec681613d5f565b5f6020828403121561465b575f80fd5b813560ff81168114610ec6575f80fdfe4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d00506f5356616c696461746f724d616e616765723a2064656c65676174696f6e20e92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb009b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f00e92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb07a164736f6c6343000819000a", + Bin: "0x608060405234801561000f575f80fd5b5060405161498f38038061498f83398101604081905261002e91610107565b60018160018111156100425761004261012c565b0361004f5761004f610055565b50610140565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805468010000000000000000900460ff16156100a55760405163f92ee8a960e01b815260040160405180910390fd5b80546001600160401b03908116146101045780546001600160401b0319166001600160401b0390811782556040519081527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15b50565b5f60208284031215610117575f80fd5b815160028110610125575f80fd5b9392505050565b634e487b7160e01b5f52602160045260245ffd5b6148428061014d5f395ff3fe608060405234801561000f575f80fd5b5060043610610111575f3560e01c806366435abf1161009e57806398f3e2b41161006e57806398f3e2b4146102645780639e1bc4ef14610277578063a3a65e481461028a578063b771b3bc1461029d578063bee0a03f146102c3575f80fd5b806366435abf146102185780636d0e43fa1461022b57806376f786211461023e578063872fda6414610251575f80fd5b806327f39ca8116100e457806327f39ca8146101a15780632e2194d8146101b4578063467ef06f146101df5780635297fae6146101f25780636206585614610205575f80fd5b80630118acc4146101155780630322ed981461012a5780630cdd09851461013d578063162f1f611461018e575b5f80fd5b610128610123366004613e8e565b6102d6565b005b610128610138366004613ec9565b610761565b61017b61014b366004613ec9565b5f9081527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb08602052604090205490565b6040519081526020015b60405180910390f35b61012861019c366004613ec9565b6108bd565b6101286101af366004613ef4565b61092a565b6101c76101c2366004613ec9565b610a0e565b6040516001600160401b039091168152602001610185565b6101286101ed366004613f31565b610a24565b610128610200366004613f4a565b610b1e565b61017b610213366004613f88565b610d0f565b6101c7610226366004613ec9565b610d28565b610128610239366004613ec9565b610d3c565b61012861024c366004613e8e565b610da9565b61017b61025f366004614033565b610dc4565b610128610272366004613f4a565b610de9565b61017b6102853660046140cf565b610f89565b610128610298366004613f31565b610f9c565b6102ab6005600160991b0181565b6040516001600160a01b039091168152602001610185565b6101286102d1366004613ec9565b611159565b5f8381527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d0360205260408120600101545f80516020614796833981519152918415610328576103258285611228565b90505b5f868152600384016020526040808220815161010081019092528054829060ff16600481111561035a5761035a6140ef565b600481111561036b5761036b6140ef565b8152815461010090046001600160a01b03166020820152600182015460408201526002808301546001600160401b038082166060850152600160401b820481166080850152600160801b8204811660a0850152600160c01b909104811660c084015260039093015490921660e090910152909150815160048111156103f2576103f26140ef565b146104445760405162461bcd60e51b815260206004820152602a60248201525f805160206147b68339815191526044820152696e6f742061637469766560b01b60648201526084015b60405180910390fd5b60208101516001600160a01b031633146104a95760405162461bcd60e51b815260206004820152603360248201525f805160206147b68339815191526044820152723737ba1037bbb732b210313c9039b2b73232b960691b606482015260840161043b565b5f6104b3846114c4565b60038084526001600160401b0342811660a0860152821660e08501525f8a815290870160205260409020835181549293508492829060ff19166001836004811115610500576105006140ef565b021790555060208201518154610100600160a81b0319166101006001600160a01b0390921691909102178155604082015160018201556060820151600282018054608085015160a086015160c08701516001600160401b039586166001600160801b031990941693909317600160401b92861692909202919091176001600160801b0316600160801b918516919091026001600160c01b031617600160c01b9184169190910217905560e0909201516003909101805467ffffffffffffffff1916919092161790555f6105d285611538565b905082606001516001600160401b03168160a001516001600160401b0316116106495760405162461bcd60e51b815260206004820152602360248201527f506f5356616c696461746f724d616e616765723a20496e76616c69642077656960448201526219da1d60ea1b606482015260840161043b565b5f83606001518260a0015161065e9190614117565b905061066a8682611617565b5f61067687858461165f565b5f8c815260058a016020526040902090915061069282826141c1565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb906106bf9085906004016142a2565b6020604051808303815f875af11580156106db573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106ff91906142d4565b604080516001600160401b03868116825242602083015291810183905291925086169089908e907f5318ab4d7cdf77056db2db5b539a08fe7d1a63d6885ecee8236a0dbda2843b4e9060600160405180910390a4505050505050505050505050565b5f8181527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb066020526040812080545f805160206147d68339815191529291906107a99061413e565b90501180156107db575060035f83815260078301602052604090205460ff1660058111156107d9576107d96140ef565b145b61083f5760405162461bcd60e51b815260206004820152602f60248201527f56616c696461746f724d616e616765723a2056616c696461746f72206e6f742060448201526e1c195b991a5b99c81c995b5bdd985b608a1b606482015260840161043b565b5f82815260068201602052604090819020905163ee5b48eb60e01b81526005600160991b019163ee5b48eb9161087891906004016142eb565b6020604051808303815f875af1158015610894573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108b891906142d4565b505050565b6108c68161187c565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d05602052604090819020905163ee5b48eb60e01b81525f80516020614796833981519152916005600160991b019163ee5b48eb91610878916004016142eb565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805460029190600160401b900460ff1680610973575080546001600160401b03808416911610155b156109915760405163f92ee8a960e01b815260040160405180910390fd5b805468ffffffffffffffffff19166001600160401b03831617600160401b1781556109bc848461194f565b805468ff0000000000000000191681556040516001600160401b03831681527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a150505050565b5f610a1e64e8d4a5100083614389565b92915050565b5f610a2e82611969565b90505f5f80516020614796833981519152600281015460a084015160c085015160e0860151604051639d4ba9db60e01b81526001600160401b03938416600482015291831660248301529190911660448201525f6064820181905260848201819052929350600160401b9091046001600160a01b031690639d4ba9db9060a401602060405180830381865afa158015610ac9573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610aed91906142d4565b9050610afd836040015182611cf6565b610b188360a001516001600160401b03168460400151611d6c565b50505050565b5f805160206147968339815191525f610b3684611d8f565b90505f80610b478360400151611f70565b5091509150610b55856121ab565b5f8581526004850160205260408120610b6d91613dd6565b5f610b7783611538565b9050816001600160401b031681608001516001600160401b03161015610baf5760405162461bcd60e51b815260040161043b9061439c565b5f8681526003860160205260409020600201546001600160401b03808416600160c01b909204161115610bf45760405162461bcd60e51b815260040161043b906143de565b60015f87815260038701602052604090205460ff166004811115610c1a57610c1a6140ef565b14610c835760405162461bcd60e51b815260206004820152603360248201527f506f5356616c696461746f724d616e616765723a2064656c65676174696f6e4960448201527211081b9bdd081c195b991a5b99c81859191959606a1b606482015260840161043b565b5f868152600386016020908152604091829020805460ff1916600290811782550180546001600160401b0342818116600160401b0267ffffffffffffffff60401b19909316929092179092559251928352841691859189917f245fc69b36e168426e0306fc8d8300661b9af297c7958820dbf804f9f63e7064910160405180910390a450505050505050565b5f610a1e6001600160401b03831664e8d4a51000614427565b5f610d3282611538565b60a0015192915050565b610d45816121ab565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d04602052604090819020905163ee5b48eb60e01b81525f80516020614796833981519152916005600160991b019163ee5b48eb91610878916004016142eb565b8115610dbb57610db98382611228565b505b6108b883612284565b5f80610dcf8661263c565b9050610ddd858286866126e9565b9150505b949350505050565b5f805160206147968339815191525f610e0184611d8f565b90505f80610e128360400151611f70565b5091509150610e208561187c565b5f8581526005850160205260408120610e3891613dd6565b5f610e4283611538565b9050816001600160401b031681608001516001600160401b03161015610e7a5760405162461bcd60e51b815260040161043b9061439c565b5f8681526003808701602052604090912001546001600160401b0380841691161115610eb85760405162461bcd60e51b815260040161043b906143de565b60035f87815260038701602052604090205460ff166004811115610ede57610ede6140ef565b14610f325760405162461bcd60e51b815260206004820152603160248201525f805160206147b68339815191526044820152701b9bdd081c195b991a5b99c81859191959607a1b606482015260840161043b565b5f868152600386016020526040808220805460ff19166004179055516001600160401b03841691859189917f52e9b1eaef84d46cda83ccb9d427267bc4d04f756b4a32c8302722b79e5c65ab91a450505050505050565b5f610f95833384612b3e565b9392505050565b5f805160206147d68339815191525f610fb483611d8f565b90505f80610fc58360400151612ef9565b91509150806110275760405162461bcd60e51b815260206004820152602860248201527f56616c696461746f724d616e616765723a20526567697374726174696f6e206e6044820152671bdd081d985b1a5960c21b606482015260840161043b565b5f828152600585016020526040812080546110419061413e565b9050118015611073575060015f83815260078601602052604090205460ff166005811115611071576110716140ef565b145b61108f5760405162461bcd60e51b815260040161043b9061443e565b5f82815260058501602052604081206110a791613dd6565b5f8281526007850160208181526040808420805460ff191660021781556003810180546001600160401b0342818116600160801b0267ffffffffffffffff60801b19909316929092178355600190930154875260088b0185528387208990559588905293835292548151600160401b90910490931683529082019290925283917ff8fd1c90fb9cfa2ca2358fdf5806b086ad43315d92b221c929efc7f105ce7568910160405180910390a25050505050565b5f8181527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb056020526040812080545f805160206147d68339815191529291906111a19061413e565b90501180156111d3575060015f83815260078301602052604090205460ff1660058111156111d1576111d16140ef565b145b6111ef5760405162461bcd60e51b815260040161043b9061443e565b5f82815260058201602052604090819020905163ee5b48eb60e01b81526005600160991b019163ee5b48eb9161087891906004016142eb565b6040516306f8253560e41b815263ffffffff821660048201525f90819081906005600160991b0190636f825350906024015f60405180830381865afa158015611273573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f1916820160405261129a9190810190614490565b91509150806112fd5760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a20696e76616c69642077617260448201526870206d65737361676560b81b606482015260840161043b565b6005600160991b016001600160a01b0316634213cf786040518163ffffffff1660e01b8152600401602060405180830381865afa158015611340573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061136491906142d4565b8251146113c85760405162461bcd60e51b815260206004820152602c60248201527f506f5356616c696461746f724d616e616765723a20696e76616c696420736f7560448201526b1c98d94818da185a5b88125160a21b606482015260840161043b565b60208201516001600160a01b03161561143e5760405162461bcd60e51b815260206004820152603260248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964206f726960448201527167696e2073656e646572206164647265737360701b606482015260840161043b565b5f8061144d846040015161309a565b915091508187146114ba5760405162461bcd60e51b815260206004820152603160248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964207570746044820152701a5b59481d985b1a59185d1a5bdb881251607a1b606482015260840161043b565b9695505050505050565b5f8181525f805160206148168339815191526020526040812060030180545f805160206147d6833981519152916001600160401b039091169081908461150983614562565b91906101000a8154816001600160401b0302191690836001600160401b03160217905550508092505050919050565b611540613e0d565b5f8281525f805160206148168339815191526020526040908190208151610100810190925280545f805160206147d6833981519152929190829060ff16600581111561158e5761158e6140ef565b600581111561159f5761159f6140ef565b81526001820154602082015260028201546001600160a01b03811660408301526001600160401b03600160a01b909104811660608301526003909201548083166080830152600160401b8104831660a0830152600160801b8104831660c0830152600160c01b900490911660e0909101529392505050565b5f9182525f80516020614816833981519152602052604090912060030180546001600160401b03909216600160401b0267ffffffffffffffff60401b19909216919091179055565b60408051603680825260608281019093525f91906020820181803683370190505090505f5b60028110156116d857611698816001614587565b6116a3906008614427565b5081515f908390839081106116ba576116ba61459a565b60200101906001600160f81b03191690815f1a905350600101611684565b505f5b600481101561173b576116ef816003614587565b6116fa906008614427565b6001901c60f81b8261170d8360026145ae565b8151811061171d5761171d61459a565b60200101906001600160f81b03191690815f1a9053506001016116db565b505f5b602081101561179d5761175281601f614587565b61175d906008614427565b86901c60f81b8261176f8360066145ae565b8151811061177f5761177f61459a565b60200101906001600160f81b03191690815f1a90535060010161173e565b505f5b6008811015611808576117b4816007614587565b6117bf906008614427565b6001600160401b038616901c60f81b826117da8360266145ae565b815181106117ea576117ea61459a565b60200101906001600160f81b03191690815f1a9053506001016117a0565b505f5b60088110156118735761181f816007614587565b61182a906008614427565b6001600160401b038516901c60f81b8261184583602e6145ae565b815181106118555761185561459a565b60200101906001600160f81b03191690815f1a90535060010161180b565b50949350505050565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d056020526040812080545f805160206147968339815191529291906118c49061413e565b90501180156118f6575060035f83815260038301602052604090205460ff1660048111156118f4576118f46140ef565b145b61194b5760405162461bcd60e51b815260206004820152603360248201525f805160206147b683398151915260448201527272656d6f76616c206e6f742070656e64696e6760681b606482015260840161043b565b5050565b611957613272565b611960826132bd565b61194b81613303565b611971613e0d565b5f805160206147d68339815191525f61198984611d8f565b90505f8061199a8360400151612ef9565b9150915080156119ff5760405162461bcd60e51b815260206004820152602a60248201527f56616c696461746f724d616e616765723a20726567697374726174696f6e20736044820152691d1a5b1b081d985b1a5960b21b606482015260840161043b565b5f828152600785016020526040808220815161010081019092528054829060ff166005811115611a3157611a316140ef565b6005811115611a4257611a426140ef565b81526001820154602082015260028201546001600160a01b03811660408301526001600160401b03600160a01b909104811660608301526003928301548082166080840152600160401b8104821660a0840152600160801b8104821660c0840152600160c01b90041660e0909101529091505f9082516005811115611ac957611ac96140ef565b1480611ae75750600182516005811115611ae557611ae56140ef565b145b611b465760405162461bcd60e51b815260206004820152602a60248201527f56616c696461746f724d616e616765723a20696e76616c69642076616c696461604482015269746f722073746174757360b01b606482015260840161043b565b600382516005811115611b5b57611b5b6140ef565b03611b8257505f8381526006860160205260408120600491611b7d9190613dd6565b611b86565b5060055b6020808301515f90815260088801909152604081205581816005811115611baf57611baf6140ef565b90816005811115611bc257611bc26140ef565b9052505f84815260078701602052604090208251815484929190829060ff19166001836005811115611bf657611bf66140ef565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b0319909316959094169490941717929092161791909117905581516005811115611cc157611cc16140ef565b60405185907f1c08e59656f1a18dc2da76826cdc52805c43e897a17c50faefb8ab3c1526cc16905f90a3509695505050505050565b5f5f8051602061477683398151915280546040516340c10f1960e01b81526001600160a01b038681166004830152602482018690529293509116906340c10f19906044015f604051808303815f87803b158015611d51575f80fd5b505af1158015611d63573d5f803e3d5ffd5b50505050505050565b5f805160206147768339815191525461194b906001600160a01b031682846133a4565b60408051606080820183525f8083526020830181905292820152905f805160206147d68339815191526040516306f8253560e41b815263ffffffff851660048201529091505f9081906005600160991b0190636f825350906024015f60405180830381865afa158015611e04573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f19168201604052611e2b9190810190614490565b9150915080611e925760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20496e76696e76616c6964616c696460448201526c2077617270206d65737361676560981b606482015260840161043b565b8254825114611ef55760405162461bcd60e51b815260206004820152602960248201527f56616c696461746f724d616e616765723a20696e76616c696420736f757263656044820152680818da185a5b88125160ba1b606482015260840161043b565b60208201516001600160a01b031615611f685760405162461bcd60e51b815260206004820152602f60248201527f56616c696461746f724d616e616765723a20696e76616c6964206f726967696e60448201526e2073656e646572206164647265737360881b606482015260840161043b565b509392505050565b5f805f8351603614611f945760405162461bcd60e51b815260040161043b906145c1565b5f805b6002811015611fe357611fab816001614587565b611fb6906008614427565b61ffff16868281518110611fcc57611fcc61459a565b016020015160f81c901b9190911790600101611f97565b5061ffff8116156120065760405162461bcd60e51b815260040161043b9061460a565b5f805b60048110156120615761201d816003614587565b612028906008614427565b63ffffffff168761203a8360026145ae565b8151811061204a5761204a61459a565b016020015160f81c901b9190911790600101612009565b5063ffffffff81166003146120885760405162461bcd60e51b815260040161043b9061464d565b5f805b60208110156120dd5761209f81601f614587565b6120aa906008614427565b886120b68360066145ae565b815181106120c6576120c661459a565b016020015160f81c901b919091179060010161208b565b505f805b600881101561213c576120f5816007614587565b612100906008614427565b6001600160401b0316896121158360266145ae565b815181106121255761212561459a565b016020015160f81c901b91909117906001016120e1565b505f805b600881101561219b57612154816007614587565b61215f906008614427565b6001600160401b03168a61217483602e6145ae565b815181106121845761218461459a565b016020015160f81c901b9190911790600101612140565b5091989097509095509350505050565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d046020526040812080545f805160206147968339815191529291906121f39061413e565b9050118015612225575060015f83815260038301602052604090205460ff166004811115612223576122236140ef565b145b61194b5760405162461bcd60e51b815260206004820152603860248201525f805160206147b683398151915260448201527f726567697374726174696f6e206e6f742070656e64696e670000000000000000606482015260840161043b565b5f8181525f8051602061481683398151915260205260408082208151610100810190925280545f805160206147d683398151915293929190829060ff1660058111156122d2576122d26140ef565b60058111156122e3576122e36140ef565b8152600182015460208201526002808301546001600160a01b03811660408401526001600160401b03600160a01b909104811660608401526003909301548084166080840152600160401b8104841660a0840152600160801b8104841660c0840152600160c01b900490921660e0909101529091508151600581111561236b5761236b6140ef565b146123c75760405162461bcd60e51b815260206004820152602660248201527f56616c696461746f724d616e616765723a2076616c696461746f72206e6f742060448201526561637469766560d01b606482015260840161043b565b60408101516001600160a01b0316336001600160a01b0316146124415760405162461bcd60e51b815260206004820152602c60248201527f56616c696461746f724d616e616765723a2073656e646572206e6f742076616c60448201526b34b230ba37b91037bbb732b960a11b606482015260840161043b565b61244e8160a00151613403565b60038152426001600160401b031660e08201525f83815260078301602052604090208151815483929190829060ff19166001836005811115612492576124926140ef565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b031990931695909416949094171792909216179190911790555f61255e84612558816114c4565b5f61165f565b5f858152600685016020526040902090915061257a82826141c1565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb906125a79085906004016142a2565b6020604051808303815f875af11580156125c3573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906125e791906142d4565b60a0840151604080516001600160401b039092168252426020830152919250829187917f13d58394cf269d48bcf927959a29a5ffee7c9924dafff8927ecdf3c48ffa7c67910160405180910390a35050505050565b5f5f8051602061479683398151915281612655846135a4565b90505f61266182610a0e565b83549091506001600160401b0382161080159061268b57508260010154816001600160401b031611155b610de15760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964207374616044820152681ad948185b5bdd5b9d60ba1b606482015260840161043b565b5f6126f26135c7565b5f805160206147d6833981519152426001600160401b03851611801561272c57506001600160401b03841661272a426202a3006145ae565b115b61278e5760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20696e76616c69642072656769737460448201526c726174696f6e2065787069727960981b606482015260840161043b565b856127e55760405162461bcd60e51b815260206004820152602160248201527f56616c696461746f724d616e616765723a20696e76616c6964206e6f646520496044820152601160fa1b606482015260840161043b565b5f868152600882016020526040902054156128535760405162461bcd60e51b815260206004820152602860248201527f56616c696461746f724d616e616765723a206e6f646520494420616c72656164604482015267792061637469766560c01b606482015260840161043b565b82516030146128ba5760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20696e76616c696420626c7350756260448201526c0d8d2c696caf240d8cadccee8d609b1b606482015260840161043b565b6128c385613403565b5f8061290a6040518060a00160405280856001015481526020018a8152602001896001600160401b03168152602001886001600160401b03168152602001878152506135fe565b5f8281526005860160205260409020919350915061292882826141c1565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb906129559085906004016142a2565b6020604051808303815f875af1158015612971573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061299591906142d4565b604080516101008101825260018152602081018c90529192508101336001600160a01b031681526001600160401b038a1660208083018290525f604080850182905260608501939093526080840181905260a0909301839052868352600788019052902081518154829060ff19166001836005811115612a1757612a176140ef565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b03199093169590941694909417179290921617919091179055612ad8836114c4565b50604080516001600160401b03808b1682528916602082015282918b9186917f79b81620b81daf2c08cd5bb3dbb79e75d2d7a87f52171fde5aadc8c47823026e910160405180910390a4509092505050610de160015f805160206147f683398151915255565b5f612b476135c7565b5f612b546101c2846135a4565b90505f805160206147968339815191525f612b6e87611538565b9050600281516005811115612b8557612b856140ef565b14612be45760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a2076616c696461746f72206e6044820152686f742061637469766560b81b606482015260840161043b565b5f838260a00151612bf59190614694565b9050612c018882611617565b5f612c0b896114c4565b90505f898983604051602001612c539392919092835260609190911b6bffffffffffffffffffffffff1916602083015260c01b6001600160c01b0319166034820152603c0190565b604051602081830303815290604052805190602001209050612c7486613403565b5f612c808b848661165f565b5f8381526004880160205260409020909150612c9c82826141c1565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb90612cc99085906004016142a2565b6020604051808303815f875af1158015612ce5573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190612d0991906142d4565b60408051610100810190915290915080600181526020018c6001600160a01b031681526020018d8152602001896001600160401b031681526020015f6001600160401b031681526020015f6001600160401b03168152602001856001600160401b031681526020015f6001600160401b0316815250876003015f8581526020019081526020015f205f820151815f015f6101000a81548160ff02191690836004811115612db857612db86140ef565b02179055506020828101518254610100600160a81b0319166101006001600160a01b039283160217835560408085015160018501556060808601516002860180546080808a015160a08b015160c08c01516001600160401b039687166001600160801b031990951694909417600160401b92871692909202919091176001600160801b0316600160801b918616919091026001600160c01b031617600160c01b928516929092029190911790915560e0909701516003909601805467ffffffffffffffff19169682169690961790955581518a861681528b861694810194909452938d1690830152918101849052908d16918e9186917fb0024b263bc3a0b728a6edea50a69efa841189f8d32ee8af9d1c2b1a1a223426910160405180910390a450909650505050505050610f9560015f805160206147f683398151915255565b5f808251602714612f1c5760405162461bcd60e51b815260040161043b906145c1565b5f805b6002811015612f6b57612f33816001614587565b612f3e906008614427565b61ffff16858281518110612f5457612f5461459a565b016020015160f81c901b9190911790600101612f1f565b5061ffff811615612f8e5760405162461bcd60e51b815260040161043b9061460a565b5f805b6004811015612fe957612fa5816003614587565b612fb0906008614427565b63ffffffff1686612fc28360026145ae565b81518110612fd257612fd261459a565b016020015160f81c901b9190911790600101612f91565b5063ffffffff81166002146130105760405162461bcd60e51b815260040161043b9061464d565b5f805b60208110156130655761302781601f614587565b613032906008614427565b8761303e8360066145ae565b8151811061304e5761304e61459a565b016020015160f81c901b9190911790600101613013565b505f8660268151811061307a5761307a61459a565b016020015191976001600160f81b03199092161515965090945050505050565b5f808251602e146130bd5760405162461bcd60e51b815260040161043b906145c1565b5f805b600281101561310c576130d4816001614587565b6130df906008614427565b61ffff168582815181106130f5576130f561459a565b016020015160f81c901b91909117906001016130c0565b5061ffff81161561312f5760405162461bcd60e51b815260040161043b9061460a565b5f805b600481101561318a57613146816003614587565b613151906008614427565b63ffffffff16866131638360026145ae565b815181106131735761317361459a565b016020015160f81c901b9190911790600101613132565b5063ffffffff81166004146131b15760405162461bcd60e51b815260040161043b9061464d565b5f805b6020811015613206576131c881601f614587565b6131d3906008614427565b876131df8360066145ae565b815181106131ef576131ef61459a565b016020015160f81c901b91909117906001016131b4565b505f805b60088110156132655761321e816007614587565b613229906008614427565b6001600160401b03168861323e8360266145ae565b8151811061324e5761324e61459a565b016020015160f81c901b919091179060010161320a565b5090969095509350505050565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a0054600160401b900460ff166132bb57604051631afcd79f60e31b815260040160405180910390fd5b565b6132c5613272565b6132ce816139b6565b613300606082013560808301356132eb60c0850160a08601613f88565b6132fb60e0860160c087016146b4565b6139d7565b50565b61330b613272565b5f805160206147768339815191526001600160a01b0382166133845760405162461bcd60e51b815260206004820152602c60248201527f4552433230546f6b656e5374616b696e674d616e616765723a207a65726f207460448201526b6f6b656e206164647265737360a01b606482015260840161043b565b80546001600160a01b0319166001600160a01b0392909216919091179055565b6040516001600160a01b038381166024830152604482018390526108b891859182169063a9059cbb906064015b604051602081830303815290604052915060e01b6020820180516001600160e01b038381831617835250505050613a32565b7fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb02545f805160206147d68339815191529060ff165f03613441575050565b60408051606081018252600383015480825260048401546001600160401b038082166020850152600160401b9091041692820192909252904290610e10906134899083614587565b106134a5576001600160401b03841660408301528082526134c4565b83826040018181516134b79190614694565b6001600160401b03169052505b5f8260200151836040015160646134db91906146cf565b6134e591906146fa565b600285015490915060ff90811690821611156135605760405162461bcd60e51b815260206004820152603460248201527f56616c696461746f724d616e616765723a206d6178696d756d20686f75726c796044820152730818da1d5c9b881c985d1948195e18d95959195960621b606482015260840161043b565b5050805160038301556020810151600490920180546040909201516001600160401b03908116600160401b026001600160801b031990931693169290921717905550565b5f610a1e825f80516020614776833981519152546001600160a01b031690613a93565b5f805160206147f68339815191528054600119016135f857604051633ee5aeb560e01b815260040160405180910390fd5b60029055565b5f60608260800151516030146136685760405162461bcd60e51b815260206004820152602960248201527f5374616b696e674d657373616765733a20696e76616c6964207369676e6174756044820152680e4ca40d8cadccee8d60bb1b606482015260840161043b565b60408051608680825260c082019092525f916020820181803683370190505090505f5b60028110156136df5761369f816001614587565b6136aa906008614427565b5081515f908390839081106136c1576136c161459a565b60200101906001600160f81b03191690815f1a90535060010161368b565b505f5b600481101561373d576136f6816003614587565b613701906008614427565b505f8261370f8360026145ae565b8151811061371f5761371f61459a565b60200101906001600160f81b03191690815f1a9053506001016136e2565b505f5b602081101561379a578451816020811061375c5761375c61459a565b1a60f81b8261376c8360066145ae565b8151811061377c5761377c61459a565b60200101906001600160f81b03191690815f1a905350600101613740565b505f5b60208110156137fa57846020015181602081106137bc576137bc61459a565b1a60f81b826137cc8360266145ae565b815181106137dc576137dc61459a565b60200101906001600160f81b03191690815f1a90535060010161379d565b505f5b600881101561386e57613811816007614587565b61381c906008614427565b60ff1685604001516001600160401b0316901c60f81b8282604661384091906145ae565b815181106138505761385061459a565b60200101906001600160f81b03191690815f1a9053506001016137fd565b505f5b60308110156138d957846080015181815181106138905761389061459a565b01602001516001600160f81b031916826138ab83604e6145ae565b815181106138bb576138bb61459a565b60200101906001600160f81b03191690815f1a905350600101613871565b505f5b600881101561394b576138f0816007614587565b6138fb906008614427565b60608601516001600160401b0390811691161c60f81b8261391d83607e6145ae565b8151811061392d5761392d61459a565b60200101906001600160f81b03191690815f1a9053506001016138dc565b5060028160405161395c919061471f565b602060405180830381855afa158015613977573d5f803e3d5ffd5b5050506040513d601f19601f8201168201806040525081019061399a91906142d4565b94909350915050565b60015f805160206147f683398151915255565b6139be613272565b6139c6613bf5565b6139ce613c05565b61330081613c0d565b6139df613272565b5f5f80516020614796833981519152948555506001840192909255600290920180546001600160a01b03909216600160401b026001600160e01b03199092166001600160401b0390931692909217179055565b5f613a466001600160a01b03841683613c79565b905080515f14158015613a6a575080806020019051810190613a68919061473a565b155b156108b857604051635274afe760e01b81526001600160a01b038416600482015260240161043b565b6040516370a0823160e01b81523060048201525f9081906001600160a01b038516906370a0823190602401602060405180830381865afa158015613ad9573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190613afd91906142d4565b9050613b146001600160a01b038516333086613c86565b6040516370a0823160e01b81523060048201525f906001600160a01b038616906370a0823190602401602060405180830381865afa158015613b58573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190613b7c91906142d4565b9050818111613be25760405162461bcd60e51b815260206004820152602c60248201527f5361666545524332305472616e7366657246726f6d3a2062616c616e6365206e60448201526b1bdd081a5b98dc99585cd95960a21b606482015260840161043b565b613bec8282614587565b95945050505050565b613bfd613272565b6132bb613cbf565b6132bb613272565b613c15613272565b80355f805160206147d683398151915290815560208201357fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb0155613c5f6060830160408401614755565b600291909101805460ff191660ff90921691909117905550565b6060610f9583835f613cc7565b6040516001600160a01b038481166024830152838116604483015260648201839052610b189186918216906323b872dd906084016133d1565b6139a3613272565b606081471015613cec5760405163cd78605960e01b815230600482015260240161043b565b5f80856001600160a01b03168486604051613d07919061471f565b5f6040518083038185875af1925050503d805f8114613d41576040519150601f19603f3d011682016040523d82523d5f602084013e613d46565b606091505b50915091506114ba868383606082613d6657613d6182613dad565b610f95565b8151158015613d7d57506001600160a01b0384163b155b15613da657604051639996b31560e01b81526001600160a01b038516600482015260240161043b565b5080610f95565b805115613dbd5780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b508054613de29061413e565b5f825580601f10613df1575050565b601f0160209004905f5260205f20908101906133009190613e51565b604080516101008101909152805f81525f6020820181905260408201819052606082018190526080820181905260a0820181905260c0820181905260e09091015290565b5b80821115613e65575f8155600101613e52565b5090565b8015158114613300575f80fd5b803563ffffffff81168114613e89575f80fd5b919050565b5f805f60608486031215613ea0575f80fd5b833592506020840135613eb281613e69565b9150613ec060408501613e76565b90509250925092565b5f60208284031215613ed9575f80fd5b5035919050565b6001600160a01b0381168114613300575f80fd5b5f80828403610100811215613f07575f80fd5b60e0811215613f14575f80fd5b5082915060e0830135613f2681613ee0565b809150509250929050565b5f60208284031215613f41575f80fd5b610f9582613e76565b5f8060408385031215613f5b575f80fd5b613f6483613e76565b946020939093013593505050565b80356001600160401b0381168114613e89575f80fd5b5f60208284031215613f98575f80fd5b610f9582613f72565b634e487b7160e01b5f52604160045260245ffd5b604051606081016001600160401b0381118282101715613fd757613fd7613fa1565b60405290565b604051601f8201601f191681016001600160401b038111828210171561400557614005613fa1565b604052919050565b5f6001600160401b0382111561402557614025613fa1565b50601f01601f191660200190565b5f805f8060808587031215614046575f80fd5b843593506020850135925061405d60408601613f72565b915060608501356001600160401b03811115614077575f80fd5b8501601f81018713614087575f80fd5b803561409a6140958261400d565b613fdd565b8181528860208385010111156140ae575f80fd5b816020840160208301375f6020838301015280935050505092959194509250565b5f80604083850312156140e0575f80fd5b50508035926020909101359150565b634e487b7160e01b5f52602160045260245ffd5b634e487b7160e01b5f52601160045260245ffd5b6001600160401b0382811682821603908082111561413757614137614103565b5092915050565b600181811c9082168061415257607f821691505b60208210810361417057634e487b7160e01b5f52602260045260245ffd5b50919050565b601f8211156108b857805f5260205f20601f840160051c8101602085101561419b5750805b601f840160051c820191505b818110156141ba575f81556001016141a7565b5050505050565b81516001600160401b038111156141da576141da613fa1565b6141ee816141e8845461413e565b84614176565b602080601f831160018114614221575f841561420a5750858301515b5f19600386901b1c1916600185901b178555614278565b5f85815260208120601f198616915b8281101561424f57888601518255948401946001909101908401614230565b508582101561426c57878501515f19600388901b60f8161c191681555b505060018460011b0185555b505050505050565b5f5b8381101561429a578181015183820152602001614282565b50505f910152565b602081525f82518060208401526142c0816040850160208701614280565b601f01601f19169190910160400192915050565b5f602082840312156142e4575f80fd5b5051919050565b5f60208083525f84546142fd8161413e565b806020870152604060018084165f811461431e576001811461433a57614367565b60ff19851660408a0152604084151560051b8a01019550614367565b895f5260205f205f5b8581101561435e5781548b8201860152908301908801614343565b8a016040019650505b509398975050505050505050565b634e487b7160e01b5f52601260045260245ffd5b5f8261439757614397614375565b500490565b60208082526022908201527f506f5356616c696461746f724d616e616765723a20696e76616c6964206e6f6e604082015261636560f01b606082015260800190565b60208082526029908201527f506f5356616c696461746f724d616e616765723a206e6f6e636520646f6573206040820152680dcdee840dac2e8c6d60bb1b606082015260800190565b8082028115828204841417610a1e57610a1e614103565b60208082526027908201527f56616c696461746f724d616e616765723a20696e76616c69642076616c6964616040820152661d1a5bdb88125160ca1b606082015260800190565b8051613e8981613e69565b5f80604083850312156144a1575f80fd5b82516001600160401b03808211156144b7575f80fd5b90840190606082870312156144ca575f80fd5b6144d2613fb5565b825181526020808401516144e581613ee0565b828201526040840151838111156144fa575f80fd5b80850194505087601f85011261450e575f80fd5b8351925061451e6140958461400d565b8381528882858701011115614531575f80fd5b61454084838301848801614280565b80604084015250819550614555818801614485565b9450505050509250929050565b5f6001600160401b0380831681810361457d5761457d614103565b6001019392505050565b81810381811115610a1e57610a1e614103565b634e487b7160e01b5f52603260045260245ffd5b80820180821115610a1e57610a1e614103565b60208082526029908201527f56616c696461746f724d657373616765733a20696e76616c6964206d657373616040820152680ceca40d8cadccee8d60bb1b606082015260800190565b60208082526023908201527f56616c696461746f724d657373616765733a20696e76616c696420636f64656360408201526208125160ea1b606082015260800190565b60208082526027908201527f56616c696461746f724d657373616765733a20696e76616c6964206d657373616040820152666765207479706560c81b606082015260800190565b6001600160401b0381811683821601908082111561413757614137614103565b5f602082840312156146c4575f80fd5b8135610f9581613ee0565b6001600160401b038181168382160280821691908281146146f2576146f2614103565b505092915050565b5f6001600160401b038084168061471357614713614375565b92169190910492915050565b5f8251614730818460208701614280565b9190910192915050565b5f6020828403121561474a575f80fd5b8151610f9581613e69565b5f60208284031215614765575f80fd5b813560ff81168114610f95575f80fdfe6e5bdfcce15e53c3406ea67bfce37dcd26f5152d5492824e43fd5e3c8ac5ab004317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d00506f5356616c696461746f724d616e616765723a2064656c65676174696f6e20e92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb009b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f00e92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb07a164736f6c6343000819000a", } // ERC20TokenStakingManagerABI is the input ABI used to generate the binding from. diff --git a/abi-bindings/go/staking/NativeTokenStakingManager/NativeTokenStakingManager.go b/abi-bindings/go/staking/NativeTokenStakingManager/NativeTokenStakingManager.go index 47d994d9f..9ea25b8aa 100644 --- a/abi-bindings/go/staking/NativeTokenStakingManager/NativeTokenStakingManager.go +++ b/abi-bindings/go/staking/NativeTokenStakingManager/NativeTokenStakingManager.go @@ -48,7 +48,7 @@ type ValidatorManagerSettings struct { // NativeTokenStakingManagerMetaData contains all meta data concerning the NativeTokenStakingManager contract. var NativeTokenStakingManagerMetaData = &bind.MetaData{ ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"init\",\"type\":\"uint8\",\"internalType\":\"enumICMInitializable\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"WARP_MESSENGER\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIWarpMessenger\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"activeValidators\",\"inputs\":[{\"name\":\"nodeID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"completeDelegatorRegistration\",\"inputs\":[{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"completeEndDelegation\",\"inputs\":[{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"},{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"completeEndValidation\",\"inputs\":[{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"completeValidatorRegistration\",\"inputs\":[{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"getWeight\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"initialize\",\"inputs\":[{\"name\":\"settings\",\"type\":\"tuple\",\"internalType\":\"structPoSValidatorManagerSettings\",\"components\":[{\"name\":\"baseSettings\",\"type\":\"tuple\",\"internalType\":\"structValidatorManagerSettings\",\"components\":[{\"name\":\"pChainBlockchainID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"subnetID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"maximumHourlyChurn\",\"type\":\"uint8\",\"internalType\":\"uint8\"}]},{\"name\":\"minimumStakeAmount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"maximumStakeAmount\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"minimumStakeDuration\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"rewardCalculator\",\"type\":\"address\",\"internalType\":\"contractIRewardCalculator\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initializeDelegatorRegistration\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"initializeEndDelegation\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"includeUptimeProof\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initializeEndValidation\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"includeUptimeProof\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"messageIndex\",\"type\":\"uint32\",\"internalType\":\"uint32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"initializeValidatorRegistration\",\"inputs\":[{\"name\":\"nodeID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"registrationExpiry\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"blsPublicKey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"resendDelegatorRegistration\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"resendEndDelegation\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"resendEndValidatorMessage\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"resendRegisterValidatorMessage\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"valueToWeight\",\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"pure\"},{\"type\":\"function\",\"name\":\"weightToValue\",\"inputs\":[{\"name\":\"weight\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"pure\"},{\"type\":\"event\",\"name\":\"DelegationEnded\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"nonce\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DelegatorAdded\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"delegatorAddress\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"nonce\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"validatorWeight\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"delegatorWeight\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"setWeightMessageID\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DelegatorRegistered\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"nonce\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"},{\"name\":\"startTime\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"DelegatorRemovalInitialized\",\"inputs\":[{\"name\":\"delegationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"nonce\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"},{\"name\":\"validatorWeight\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"endTime\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"setWeightMessageID\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Initialized\",\"inputs\":[{\"name\":\"version\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidationPeriodCreated\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"nodeID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"registerValidationMessageID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"weight\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"registrationExpiry\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidationPeriodEnded\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"status\",\"type\":\"uint8\",\"indexed\":true,\"internalType\":\"enumValidatorStatus\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidationPeriodRegistered\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"weight\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"timestamp\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidatorRemovalInitialized\",\"inputs\":[{\"name\":\"validationID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"setWeightMessageID\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"weight\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"endTime\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"AddressInsufficientBalance\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"FailedInnerCall\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidInitialization\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"NotInitializing\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"ReentrancyGuardReentrantCall\",\"inputs\":[]}]", - Bin: "0x608060405234801561000f575f80fd5b5060405161449638038061449683398101604081905261002e91610107565b60018160018111156100425761004261012c565b0361004f5761004f610055565b50610140565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805468010000000000000000900460ff16156100a55760405163f92ee8a960e01b815260040160405180910390fd5b80546001600160401b03908116146101045780546001600160401b0319166001600160401b0390811782556040519081527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15b50565b5f60208284031215610117575f80fd5b815160028110610125575f80fd5b9392505050565b634e487b7160e01b5f52602160045260245ffd5b6143498061014d5f395ff3fe608060405260043610610104575f3560e01c806366435abf11610092578063a3a65e4811610062578063a3a65e48146102f3578063b771b3bc14610312578063bee0a03f14610344578063c599e24f14610363578063f40797d714610376575f80fd5b806366435abf146102775780636d0e43fa1461029657806376f78621146102b557806398f3e2b4146102d4575f80fd5b8063162f1f61116100d8578063162f1f61146101c45780632e2194d8146101e3578063467ef06f1461021a5780635297fae6146102395780636206585614610258575f80fd5b8062e41792146101085780630118acc4146101295780630322ed98146101485780630cdd098514610167575b5f80fd5b348015610113575f80fd5b50610127610122366004613a02565b610389565b005b348015610134575f80fd5b50610127610143366004613a3d565b61046b565b348015610153575f80fd5b50610127610162366004613a78565b6108f6565b348015610172575f80fd5b506101b1610181366004613a78565b5f9081527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb08602052604090205490565b6040519081526020015b60405180910390f35b3480156101cf575f80fd5b506101276101de366004613a78565b610a52565b3480156101ee575f80fd5b506102026101fd366004613a78565b610abf565b6040516001600160401b0390911681526020016101bb565b348015610225575f80fd5b50610127610234366004613a8f565b610ad5565b348015610244575f80fd5b50610127610253366004613aa8565b610b00565b348015610263575f80fd5b506101b1610272366004613ae6565b610cf1565b348015610282575f80fd5b50610202610291366004613a78565b610d0a565b3480156102a1575f80fd5b506101276102b0366004613a78565b610d1e565b3480156102c0575f80fd5b506101276102cf366004613a3d565b610d8b565b3480156102df575f80fd5b506101276102ee366004613aa8565b610da6565b3480156102fe575f80fd5b5061012761030d366004613a8f565b610f46565b34801561031d575f80fd5b5061032c6005600160991b0181565b6040516001600160a01b0390911681526020016101bb565b34801561034f575f80fd5b5061012761035e366004613a78565b611103565b6101b1610371366004613a78565b6111d2565b6101b1610384366004613b91565b6111de565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805460029190600160401b900460ff16806103d2575080546001600160401b03808416911610155b156103f05760405163f92ee8a960e01b815260040160405180910390fd5b805468ffffffffffffffffff19166001600160401b03831617600160401b17815561041a83611202565b805468ff0000000000000000191681556040516001600160401b03831681527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a1505050565b5f8381527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d0360205260408120600101545f8051602061429d8339815191529184156104bd576104ba8285611216565b90505b5f868152600384016020526040808220815161010081019092528054829060ff1660048111156104ef576104ef613c23565b600481111561050057610500613c23565b8152815461010090046001600160a01b03166020820152600182015460408201526002808301546001600160401b038082166060850152600160401b820481166080850152600160801b8204811660a0850152600160c01b909104811660c084015260039093015490921660e0909101529091508151600481111561058757610587613c23565b146105d95760405162461bcd60e51b815260206004820152602a60248201525f805160206142bd8339815191526044820152696e6f742061637469766560b01b60648201526084015b60405180910390fd5b60208101516001600160a01b0316331461063e5760405162461bcd60e51b815260206004820152603360248201525f805160206142bd8339815191526044820152723737ba1037bbb732b210313c9039b2b73232b960691b60648201526084016105d0565b5f610648846114b2565b60038084526001600160401b0342811660a0860152821660e08501525f8a815290870160205260409020835181549293508492829060ff1916600183600481111561069557610695613c23565b021790555060208201518154610100600160a81b0319166101006001600160a01b0390921691909102178155604082015160018201556060820151600282018054608085015160a086015160c08701516001600160401b039586166001600160801b031990941693909317600160401b92861692909202919091176001600160801b0316600160801b918516919091026001600160c01b031617600160c01b9184169190910217905560e0909201516003909101805467ffffffffffffffff1916919092161790555f61076785611526565b905082606001516001600160401b03168160a001516001600160401b0316116107de5760405162461bcd60e51b815260206004820152602360248201527f506f5356616c696461746f724d616e616765723a20496e76616c69642077656960448201526219da1d60ea1b60648201526084016105d0565b5f83606001518260a001516107f39190613c4b565b90506107ff8682611605565b5f61080b87858461164d565b5f8c815260058a01602052604090209091506108278282613cef565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb90610854908590600401613dd0565b6020604051808303815f875af1158015610870573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108949190613e02565b604080516001600160401b03868116825242602083015291810183905291925086169089908e907f5318ab4d7cdf77056db2db5b539a08fe7d1a63d6885ecee8236a0dbda2843b4e9060600160405180910390a4505050505050505050505050565b5f8181527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb066020526040812080545f805160206142dd83398151915292919061093e90613c72565b9050118015610970575060035f83815260078301602052604090205460ff16600581111561096e5761096e613c23565b145b6109d45760405162461bcd60e51b815260206004820152602f60248201527f56616c696461746f724d616e616765723a2056616c696461746f72206e6f742060448201526e1c195b991a5b99c81c995b5bdd985b608a1b60648201526084016105d0565b5f82815260068201602052604090819020905163ee5b48eb60e01b81526005600160991b019163ee5b48eb91610a0d9190600401613e19565b6020604051808303815f875af1158015610a29573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610a4d9190613e02565b505050565b610a5b8161186a565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d05602052604090819020905163ee5b48eb60e01b81525f8051602061429d833981519152916005600160991b019163ee5b48eb91610a0d91600401613e19565b5f610acf64e8d4a5100083613eb7565b92915050565b5f610adf82611939565b9050610afc8160a001516001600160401b03168260400151611cc6565b5050565b5f8051602061429d8339815191525f610b1884611cd9565b90505f80610b298360400151611eba565b5091509150610b37856120f5565b5f8581526004850160205260408120610b4f9161396f565b5f610b5983611526565b9050816001600160401b031681608001516001600160401b03161015610b915760405162461bcd60e51b81526004016105d090613eca565b5f8681526003860160205260409020600201546001600160401b03808416600160c01b909204161115610bd65760405162461bcd60e51b81526004016105d090613f0c565b60015f87815260038701602052604090205460ff166004811115610bfc57610bfc613c23565b14610c655760405162461bcd60e51b815260206004820152603360248201527f506f5356616c696461746f724d616e616765723a2064656c65676174696f6e4960448201527211081b9bdd081c195b991a5b99c81859191959606a1b60648201526084016105d0565b5f868152600386016020908152604091829020805460ff1916600290811782550180546001600160401b0342818116600160401b0267ffffffffffffffff60401b19909316929092179092559251928352841691859189917f245fc69b36e168426e0306fc8d8300661b9af297c7958820dbf804f9f63e7064910160405180910390a450505050505050565b5f610acf6001600160401b03831664e8d4a51000613f55565b5f610d1482611526565b60a0015192915050565b610d27816120f5565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d04602052604090819020905163ee5b48eb60e01b81525f8051602061429d833981519152916005600160991b019163ee5b48eb91610a0d91600401613e19565b8115610d9d57610d9b8382611216565b505b610a4d836121ce565b5f8051602061429d8339815191525f610dbe84611cd9565b90505f80610dcf8360400151611eba565b5091509150610ddd8561186a565b5f8581526005850160205260408120610df59161396f565b5f610dff83611526565b9050816001600160401b031681608001516001600160401b03161015610e375760405162461bcd60e51b81526004016105d090613eca565b5f8681526003808701602052604090912001546001600160401b0380841691161115610e755760405162461bcd60e51b81526004016105d090613f0c565b60035f87815260038701602052604090205460ff166004811115610e9b57610e9b613c23565b14610eef5760405162461bcd60e51b815260206004820152603160248201525f805160206142bd8339815191526044820152701b9bdd081c195b991a5b99c81859191959607a1b60648201526084016105d0565b5f868152600386016020526040808220805460ff19166004179055516001600160401b03841691859189917f52e9b1eaef84d46cda83ccb9d427267bc4d04f756b4a32c8302722b79e5c65ab91a450505050505050565b5f805160206142dd8339815191525f610f5e83611cd9565b90505f80610f6f8360400151612586565b9150915080610fd15760405162461bcd60e51b815260206004820152602860248201527f56616c696461746f724d616e616765723a20526567697374726174696f6e206e6044820152671bdd081d985b1a5960c21b60648201526084016105d0565b5f82815260058501602052604081208054610feb90613c72565b905011801561101d575060015f83815260078601602052604090205460ff16600581111561101b5761101b613c23565b145b6110395760405162461bcd60e51b81526004016105d090613f6c565b5f82815260058501602052604081206110519161396f565b5f8281526007850160208181526040808420805460ff191660021781556003810180546001600160401b0342818116600160801b0267ffffffffffffffff60801b19909316929092178355600190930154875260088b0185528387208990559588905293835292548151600160401b90910490931683529082019290925283917ff8fd1c90fb9cfa2ca2358fdf5806b086ad43315d92b221c929efc7f105ce7568910160405180910390a25050505050565b5f8181527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb056020526040812080545f805160206142dd83398151915292919061114b90613c72565b905011801561117d575060015f83815260078301602052604090205460ff16600581111561117b5761117b613c23565b145b6111995760405162461bcd60e51b81526004016105d090613f6c565b5f82815260058201602052604090819020905163ee5b48eb60e01b81526005600160991b019163ee5b48eb91610a0d9190600401613e19565b5f610acf823334612727565b5f806111e934612adf565b90506111f785828686612b89565b9150505b9392505050565b61120a612fde565b61121381613029565b50565b6040516306f8253560e41b815263ffffffff821660048201525f90819081906005600160991b0190636f825350906024015f60405180830381865afa158015611261573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f191682016040526112889190810190613fd2565b91509150806112eb5760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a20696e76616c69642077617260448201526870206d65737361676560b81b60648201526084016105d0565b6005600160991b016001600160a01b0316634213cf786040518163ffffffff1660e01b8152600401602060405180830381865afa15801561132e573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906113529190613e02565b8251146113b65760405162461bcd60e51b815260206004820152602c60248201527f506f5356616c696461746f724d616e616765723a20696e76616c696420736f7560448201526b1c98d94818da185a5b88125160a21b60648201526084016105d0565b60208201516001600160a01b03161561142c5760405162461bcd60e51b815260206004820152603260248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964206f726960448201527167696e2073656e646572206164647265737360701b60648201526084016105d0565b5f8061143b846040015161306c565b915091508187146114a85760405162461bcd60e51b815260206004820152603160248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964207570746044820152701a5b59481d985b1a59185d1a5bdb881251607a1b60648201526084016105d0565b9695505050505050565b5f8181525f8051602061431d8339815191526020526040812060030180545f805160206142dd833981519152916001600160401b03909116908190846114f7836140a4565b91906101000a8154816001600160401b0302191690836001600160401b03160217905550508092505050919050565b61152e6139a6565b5f8281525f8051602061431d8339815191526020526040908190208151610100810190925280545f805160206142dd833981519152929190829060ff16600581111561157c5761157c613c23565b600581111561158d5761158d613c23565b81526001820154602082015260028201546001600160a01b03811660408301526001600160401b03600160a01b909104811660608301526003909201548083166080830152600160401b8104831660a0830152600160801b8104831660c0830152600160c01b900490911660e0909101529392505050565b5f9182525f8051602061431d833981519152602052604090912060030180546001600160401b03909216600160401b0267ffffffffffffffff60401b19909216919091179055565b60408051603680825260608281019093525f91906020820181803683370190505090505f5b60028110156116c6576116868160016140c9565b611691906008613f55565b5081515f908390839081106116a8576116a86140dc565b60200101906001600160f81b03191690815f1a905350600101611672565b505f5b6004811015611729576116dd8160036140c9565b6116e8906008613f55565b6001901c60f81b826116fb8360026140f0565b8151811061170b5761170b6140dc565b60200101906001600160f81b03191690815f1a9053506001016116c9565b505f5b602081101561178b5761174081601f6140c9565b61174b906008613f55565b86901c60f81b8261175d8360066140f0565b8151811061176d5761176d6140dc565b60200101906001600160f81b03191690815f1a90535060010161172c565b505f5b60088110156117f6576117a28160076140c9565b6117ad906008613f55565b6001600160401b038616901c60f81b826117c88360266140f0565b815181106117d8576117d86140dc565b60200101906001600160f81b03191690815f1a90535060010161178e565b505f5b60088110156118615761180d8160076140c9565b611818906008613f55565b6001600160401b038516901c60f81b8261183383602e6140f0565b81518110611843576118436140dc565b60200101906001600160f81b03191690815f1a9053506001016117f9565b50949350505050565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d056020526040812080545f8051602061429d8339815191529291906118b290613c72565b90501180156118e4575060035f83815260038301602052604090205460ff1660048111156118e2576118e2613c23565b145b610afc5760405162461bcd60e51b815260206004820152603360248201525f805160206142bd83398151915260448201527272656d6f76616c206e6f742070656e64696e6760681b60648201526084016105d0565b6119416139a6565b5f805160206142dd8339815191525f61195984611cd9565b90505f8061196a8360400151612586565b9150915080156119cf5760405162461bcd60e51b815260206004820152602a60248201527f56616c696461746f724d616e616765723a20726567697374726174696f6e20736044820152691d1a5b1b081d985b1a5960b21b60648201526084016105d0565b5f828152600785016020526040808220815161010081019092528054829060ff166005811115611a0157611a01613c23565b6005811115611a1257611a12613c23565b81526001820154602082015260028201546001600160a01b03811660408301526001600160401b03600160a01b909104811660608301526003928301548082166080840152600160401b8104821660a0840152600160801b8104821660c0840152600160c01b90041660e0909101529091505f9082516005811115611a9957611a99613c23565b1480611ab75750600182516005811115611ab557611ab5613c23565b145b611b165760405162461bcd60e51b815260206004820152602a60248201527f56616c696461746f724d616e616765723a20696e76616c69642076616c696461604482015269746f722073746174757360b01b60648201526084016105d0565b600382516005811115611b2b57611b2b613c23565b03611b5257505f8381526006860160205260408120600491611b4d919061396f565b611b56565b5060055b6020808301515f90815260088801909152604081205581816005811115611b7f57611b7f613c23565b90816005811115611b9257611b92613c23565b9052505f84815260078701602052604090208251815484929190829060ff19166001836005811115611bc657611bc6613c23565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b0319909316959094169490941717929092161791909117905581516005811115611c9157611c91613c23565b60405185907f1c08e59656f1a18dc2da76826cdc52805c43e897a17c50faefb8ab3c1526cc16905f90a3509695505050505050565b610afc6001600160a01b03821683613244565b60408051606080820183525f8083526020830181905292820152905f805160206142dd8339815191526040516306f8253560e41b815263ffffffff851660048201529091505f9081906005600160991b0190636f825350906024015f60405180830381865afa158015611d4e573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f19168201604052611d759190810190613fd2565b9150915080611ddc5760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20496e76696e76616c6964616c696460448201526c2077617270206d65737361676560981b60648201526084016105d0565b8254825114611e3f5760405162461bcd60e51b815260206004820152602960248201527f56616c696461746f724d616e616765723a20696e76616c696420736f757263656044820152680818da185a5b88125160ba1b60648201526084016105d0565b60208201516001600160a01b031615611eb25760405162461bcd60e51b815260206004820152602f60248201527f56616c696461746f724d616e616765723a20696e76616c6964206f726967696e60448201526e2073656e646572206164647265737360881b60648201526084016105d0565b509392505050565b5f805f8351603614611ede5760405162461bcd60e51b81526004016105d090614103565b5f805b6002811015611f2d57611ef58160016140c9565b611f00906008613f55565b61ffff16868281518110611f1657611f166140dc565b016020015160f81c901b9190911790600101611ee1565b5061ffff811615611f505760405162461bcd60e51b81526004016105d09061414c565b5f805b6004811015611fab57611f678160036140c9565b611f72906008613f55565b63ffffffff1687611f848360026140f0565b81518110611f9457611f946140dc565b016020015160f81c901b9190911790600101611f53565b5063ffffffff8116600314611fd25760405162461bcd60e51b81526004016105d09061418f565b5f805b602081101561202757611fe981601f6140c9565b611ff4906008613f55565b886120008360066140f0565b81518110612010576120106140dc565b016020015160f81c901b9190911790600101611fd5565b505f805b60088110156120865761203f8160076140c9565b61204a906008613f55565b6001600160401b03168961205f8360266140f0565b8151811061206f5761206f6140dc565b016020015160f81c901b919091179060010161202b565b505f805b60088110156120e55761209e8160076140c9565b6120a9906008613f55565b6001600160401b03168a6120be83602e6140f0565b815181106120ce576120ce6140dc565b016020015160f81c901b919091179060010161208a565b5091989097509095509350505050565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d046020526040812080545f8051602061429d83398151915292919061213d90613c72565b905011801561216f575060015f83815260038301602052604090205460ff16600481111561216d5761216d613c23565b145b610afc5760405162461bcd60e51b815260206004820152603860248201525f805160206142bd83398151915260448201527f726567697374726174696f6e206e6f742070656e64696e67000000000000000060648201526084016105d0565b5f8181525f8051602061431d83398151915260205260408082208151610100810190925280545f805160206142dd83398151915293929190829060ff16600581111561221c5761221c613c23565b600581111561222d5761222d613c23565b8152600182015460208201526002808301546001600160a01b03811660408401526001600160401b03600160a01b909104811660608401526003909301548084166080840152600160401b8104841660a0840152600160801b8104841660c0840152600160c01b900490921660e090910152909150815160058111156122b5576122b5613c23565b146123115760405162461bcd60e51b815260206004820152602660248201527f56616c696461746f724d616e616765723a2076616c696461746f72206e6f742060448201526561637469766560d01b60648201526084016105d0565b60408101516001600160a01b0316336001600160a01b03161461238b5760405162461bcd60e51b815260206004820152602c60248201527f56616c696461746f724d616e616765723a2073656e646572206e6f742076616c60448201526b34b230ba37b91037bbb732b960a11b60648201526084016105d0565b6123988160a001516132d7565b60038152426001600160401b031660e08201525f83815260078301602052604090208151815483929190829060ff191660018360058111156123dc576123dc613c23565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b031990931695909416949094171792909216179190911790555f6124a8846124a2816114b2565b5f61164d565b5f85815260068501602052604090209091506124c48282613cef565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb906124f1908590600401613dd0565b6020604051808303815f875af115801561250d573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906125319190613e02565b60a0840151604080516001600160401b039092168252426020830152919250829187917f13d58394cf269d48bcf927959a29a5ffee7c9924dafff8927ecdf3c48ffa7c67910160405180910390a35050505050565b5f8082516027146125a95760405162461bcd60e51b81526004016105d090614103565b5f805b60028110156125f8576125c08160016140c9565b6125cb906008613f55565b61ffff168582815181106125e1576125e16140dc565b016020015160f81c901b91909117906001016125ac565b5061ffff81161561261b5760405162461bcd60e51b81526004016105d09061414c565b5f805b6004811015612676576126328160036140c9565b61263d906008613f55565b63ffffffff168661264f8360026140f0565b8151811061265f5761265f6140dc565b016020015160f81c901b919091179060010161261e565b5063ffffffff811660021461269d5760405162461bcd60e51b81526004016105d09061418f565b5f805b60208110156126f2576126b481601f6140c9565b6126bf906008613f55565b876126cb8360066140f0565b815181106126db576126db6140dc565b016020015160f81c901b91909117906001016126a0565b505f86602681518110612707576127076140dc565b016020015191976001600160f81b03199092161515965090945050505050565b5f612730613478565b5f61273a83610abf565b90505f8051602061429d8339815191525f61275487611526565b905060028151600581111561276b5761276b613c23565b146127ca5760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a2076616c696461746f72206e6044820152686f742061637469766560b81b60648201526084016105d0565b5f838260a001516127db91906141d6565b90506127e78882611605565b5f6127f1896114b2565b90505f8989836040516020016128399392919092835260609190911b6bffffffffffffffffffffffff1916602083015260c01b6001600160c01b0319166034820152603c0190565b60405160208183030381529060405280519060200120905061285a866132d7565b5f6128668b848661164d565b5f83815260048801602052604090209091506128828282613cef565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb906128af908590600401613dd0565b6020604051808303815f875af11580156128cb573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906128ef9190613e02565b60408051610100810190915290915080600181526020018c6001600160a01b031681526020018d8152602001896001600160401b031681526020015f6001600160401b031681526020015f6001600160401b03168152602001856001600160401b031681526020015f6001600160401b0316815250876003015f8581526020019081526020015f205f820151815f015f6101000a81548160ff0219169083600481111561299e5761299e613c23565b02179055506020828101518254610100600160a81b0319166101006001600160a01b039283160217835560408085015160018501556060808601516002860180546080808a015160a08b015160c08c01516001600160401b039687166001600160801b031990951694909417600160401b92871692909202919091176001600160801b0316600160801b918616919091026001600160c01b031617600160c01b928516929092029190911790915560e0909701516003909601805467ffffffffffffffff19169682169690961790955581518a861681528b861694810194909452938d1690830152918101849052908d16918e9186917fb0024b263bc3a0b728a6edea50a69efa841189f8d32ee8af9d1c2b1a1a223426910160405180910390a4509096505050505050506111fb60015f805160206142fd83398151915255565b5f5f8051602061429d8339815191528282612af982610abf565b83549091506001600160401b03821610801590612b2357508260010154816001600160401b031611155b612b815760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964207374616044820152681ad948185b5bdd5b9d60ba1b60648201526084016105d0565b949350505050565b5f612b92613478565b5f805160206142dd833981519152426001600160401b038516118015612bcc57506001600160401b038416612bca426202a3006140f0565b115b612c2e5760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20696e76616c69642072656769737460448201526c726174696f6e2065787069727960981b60648201526084016105d0565b85612c855760405162461bcd60e51b815260206004820152602160248201527f56616c696461746f724d616e616765723a20696e76616c6964206e6f646520496044820152601160fa1b60648201526084016105d0565b5f86815260088201602052604090205415612cf35760405162461bcd60e51b815260206004820152602860248201527f56616c696461746f724d616e616765723a206e6f646520494420616c72656164604482015267792061637469766560c01b60648201526084016105d0565b8251603014612d5a5760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20696e76616c696420626c7350756260448201526c0d8d2c696caf240d8cadccee8d609b1b60648201526084016105d0565b612d63856132d7565b5f80612daa6040518060a00160405280856001015481526020018a8152602001896001600160401b03168152602001886001600160401b03168152602001878152506134c2565b5f82815260058601602052604090209193509150612dc88282613cef565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb90612df5908590600401613dd0565b6020604051808303815f875af1158015612e11573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190612e359190613e02565b604080516101008101825260018152602081018c90529192508101336001600160a01b031681526001600160401b038a1660208083018290525f604080850182905260608501939093526080840181905260a0909301839052868352600788019052902081518154829060ff19166001836005811115612eb757612eb7613c23565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b03199093169590941694909417179290921617919091179055612f78836114b2565b50604080516001600160401b03808b1682528916602082015282918b9186917f79b81620b81daf2c08cd5bb3dbb79e75d2d7a87f52171fde5aadc8c47823026e910160405180910390a4509092505050612b8160015f805160206142fd83398151915255565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a0054600160401b900460ff1661302757604051631afcd79f60e31b815260040160405180910390fd5b565b613031612fde565b61303a81613867565b6112136060820135608083013561305760c0850160a08601613ae6565b61306760e0860160c087016141f6565b613888565b5f808251602e1461308f5760405162461bcd60e51b81526004016105d090614103565b5f805b60028110156130de576130a68160016140c9565b6130b1906008613f55565b61ffff168582815181106130c7576130c76140dc565b016020015160f81c901b9190911790600101613092565b5061ffff8116156131015760405162461bcd60e51b81526004016105d09061414c565b5f805b600481101561315c576131188160036140c9565b613123906008613f55565b63ffffffff16866131358360026140f0565b81518110613145576131456140dc565b016020015160f81c901b9190911790600101613104565b5063ffffffff81166004146131835760405162461bcd60e51b81526004016105d09061418f565b5f805b60208110156131d85761319a81601f6140c9565b6131a5906008613f55565b876131b18360066140f0565b815181106131c1576131c16140dc565b016020015160f81c901b9190911790600101613186565b505f805b6008811015613237576131f08160076140c9565b6131fb906008613f55565b6001600160401b0316886132108360266140f0565b81518110613220576132206140dc565b016020015160f81c901b91909117906001016131dc565b5090969095509350505050565b804710156132675760405163cd78605960e01b81523060048201526024016105d0565b5f826001600160a01b0316826040515f6040518083038185875af1925050503d805f81146132b0576040519150601f19603f3d011682016040523d82523d5f602084013e6132b5565b606091505b5050905080610a4d57604051630a12f52160e11b815260040160405180910390fd5b7fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb02545f805160206142dd8339815191529060ff165f03613315575050565b60408051606081018252600383015480825260048401546001600160401b038082166020850152600160401b9091041692820192909252904290610e109061335d90836140c9565b10613379576001600160401b0384166040830152808252613398565b838260400181815161338b91906141d6565b6001600160401b03169052505b5f8260200151836040015160646133af9190614211565b6133b9919061423c565b600285015490915060ff90811690821611156134345760405162461bcd60e51b815260206004820152603460248201527f56616c696461746f724d616e616765723a206d6178696d756d20686f75726c796044820152730818da1d5c9b881c985d1948195e18d95959195960621b60648201526084016105d0565b5050805160038301556020810151600490920180546040909201516001600160401b03908116600160401b026001600160801b031990931693169290921717905550565b5f805160206142fd8339815191528054600119016134a957604051633ee5aeb560e01b815260040160405180910390fd5b60029055565b60015f805160206142fd83398151915255565b5f606082608001515160301461352c5760405162461bcd60e51b815260206004820152602960248201527f5374616b696e674d657373616765733a20696e76616c6964207369676e6174756044820152680e4ca40d8cadccee8d60bb1b60648201526084016105d0565b60408051608680825260c082019092525f916020820181803683370190505090505f5b60028110156135a3576135638160016140c9565b61356e906008613f55565b5081515f90839083908110613585576135856140dc565b60200101906001600160f81b03191690815f1a90535060010161354f565b505f5b6004811015613601576135ba8160036140c9565b6135c5906008613f55565b505f826135d38360026140f0565b815181106135e3576135e36140dc565b60200101906001600160f81b03191690815f1a9053506001016135a6565b505f5b602081101561365e5784518160208110613620576136206140dc565b1a60f81b826136308360066140f0565b81518110613640576136406140dc565b60200101906001600160f81b03191690815f1a905350600101613604565b505f5b60208110156136be5784602001518160208110613680576136806140dc565b1a60f81b826136908360266140f0565b815181106136a0576136a06140dc565b60200101906001600160f81b03191690815f1a905350600101613661565b505f5b6008811015613732576136d58160076140c9565b6136e0906008613f55565b60ff1685604001516001600160401b0316901c60f81b8282604661370491906140f0565b81518110613714576137146140dc565b60200101906001600160f81b03191690815f1a9053506001016136c1565b505f5b603081101561379d5784608001518181518110613754576137546140dc565b01602001516001600160f81b0319168261376f83604e6140f0565b8151811061377f5761377f6140dc565b60200101906001600160f81b03191690815f1a905350600101613735565b505f5b600881101561380f576137b48160076140c9565b6137bf906008613f55565b60608601516001600160401b0390811691161c60f81b826137e183607e6140f0565b815181106137f1576137f16140dc565b60200101906001600160f81b03191690815f1a9053506001016137a0565b506002816040516138209190614261565b602060405180830381855afa15801561383b573d5f803e3d5ffd5b5050506040513d601f19601f8201168201806040525081019061385e9190613e02565b94909350915050565b61386f612fde565b6138776138e3565b61387f6138f3565b611213816138fb565b613890612fde565b5f5f8051602061429d833981519152948555506001840192909255600290920180546001600160a01b03909216600160401b026001600160e01b03199092166001600160401b0390931692909217179055565b6138eb612fde565b613027613967565b613027612fde565b613903612fde565b80355f805160206142dd83398151915290815560208201357fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb015561394d606083016040840161427c565b600291909101805460ff191660ff90921691909117905550565b6134af612fde565b50805461397b90613c72565b5f825580601f1061398a575050565b601f0160209004905f5260205f209081019061121391906139ea565b604080516101008101909152805f81525f6020820181905260408201819052606082018190526080820181905260a0820181905260c0820181905260e09091015290565b5b808211156139fe575f81556001016139eb565b5090565b5f60e08284031215613a12575f80fd5b50919050565b8015158114611213575f80fd5b803563ffffffff81168114613a38575f80fd5b919050565b5f805f60608486031215613a4f575f80fd5b833592506020840135613a6181613a18565b9150613a6f60408501613a25565b90509250925092565b5f60208284031215613a88575f80fd5b5035919050565b5f60208284031215613a9f575f80fd5b6111fb82613a25565b5f8060408385031215613ab9575f80fd5b613ac283613a25565b946020939093013593505050565b80356001600160401b0381168114613a38575f80fd5b5f60208284031215613af6575f80fd5b6111fb82613ad0565b634e487b7160e01b5f52604160045260245ffd5b604051606081016001600160401b0381118282101715613b3557613b35613aff565b60405290565b604051601f8201601f191681016001600160401b0381118282101715613b6357613b63613aff565b604052919050565b5f6001600160401b03821115613b8357613b83613aff565b50601f01601f191660200190565b5f805f60608486031215613ba3575f80fd5b83359250613bb360208501613ad0565b915060408401356001600160401b03811115613bcd575f80fd5b8401601f81018613613bdd575f80fd5b8035613bf0613beb82613b6b565b613b3b565b818152876020838501011115613c04575f80fd5b816020840160208301375f602083830101528093505050509250925092565b634e487b7160e01b5f52602160045260245ffd5b634e487b7160e01b5f52601160045260245ffd5b6001600160401b03828116828216039080821115613c6b57613c6b613c37565b5092915050565b600181811c90821680613c8657607f821691505b602082108103613a1257634e487b7160e01b5f52602260045260245ffd5b601f821115610a4d57805f5260205f20601f840160051c81016020851015613cc95750805b601f840160051c820191505b81811015613ce8575f8155600101613cd5565b5050505050565b81516001600160401b03811115613d0857613d08613aff565b613d1c81613d168454613c72565b84613ca4565b602080601f831160018114613d4f575f8415613d385750858301515b5f19600386901b1c1916600185901b178555613da6565b5f85815260208120601f198616915b82811015613d7d57888601518255948401946001909101908401613d5e565b5085821015613d9a57878501515f19600388901b60f8161c191681555b505060018460011b0185555b505050505050565b5f5b83811015613dc8578181015183820152602001613db0565b50505f910152565b602081525f8251806020840152613dee816040850160208701613dae565b601f01601f19169190910160400192915050565b5f60208284031215613e12575f80fd5b5051919050565b5f60208083525f8454613e2b81613c72565b806020870152604060018084165f8114613e4c5760018114613e6857613e95565b60ff19851660408a0152604084151560051b8a01019550613e95565b895f5260205f205f5b85811015613e8c5781548b8201860152908301908801613e71565b8a016040019650505b509398975050505050505050565b634e487b7160e01b5f52601260045260245ffd5b5f82613ec557613ec5613ea3565b500490565b60208082526022908201527f506f5356616c696461746f724d616e616765723a20696e76616c6964206e6f6e604082015261636560f01b606082015260800190565b60208082526029908201527f506f5356616c696461746f724d616e616765723a206e6f6e636520646f6573206040820152680dcdee840dac2e8c6d60bb1b606082015260800190565b8082028115828204841417610acf57610acf613c37565b60208082526027908201527f56616c696461746f724d616e616765723a20696e76616c69642076616c6964616040820152661d1a5bdb88125160ca1b606082015260800190565b6001600160a01b0381168114611213575f80fd5b8051613a3881613a18565b5f8060408385031215613fe3575f80fd5b82516001600160401b0380821115613ff9575f80fd5b908401906060828703121561400c575f80fd5b614014613b13565b8251815260208084015161402781613fb3565b8282015260408401518381111561403c575f80fd5b80850194505087601f850112614050575f80fd5b83519250614060613beb84613b6b565b8381528882858701011115614073575f80fd5b61408284838301848801613dae565b80604084015250819550614097818801613fc7565b9450505050509250929050565b5f6001600160401b038083168181036140bf576140bf613c37565b6001019392505050565b81810381811115610acf57610acf613c37565b634e487b7160e01b5f52603260045260245ffd5b80820180821115610acf57610acf613c37565b60208082526029908201527f56616c696461746f724d657373616765733a20696e76616c6964206d657373616040820152680ceca40d8cadccee8d60bb1b606082015260800190565b60208082526023908201527f56616c696461746f724d657373616765733a20696e76616c696420636f64656360408201526208125160ea1b606082015260800190565b60208082526027908201527f56616c696461746f724d657373616765733a20696e76616c6964206d657373616040820152666765207479706560c81b606082015260800190565b6001600160401b03818116838216019080821115613c6b57613c6b613c37565b5f60208284031215614206575f80fd5b81356111fb81613fb3565b6001600160401b0381811683821602808216919082811461423457614234613c37565b505092915050565b5f6001600160401b038084168061425557614255613ea3565b92169190910492915050565b5f8251614272818460208701613dae565b9190910192915050565b5f6020828403121561428c575f80fd5b813560ff811681146111fb575f80fdfe4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d00506f5356616c696461746f724d616e616765723a2064656c65676174696f6e20e92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb009b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f00e92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb07a164736f6c6343000819000a", + Bin: "0x608060405234801561000f575f80fd5b5060405161455b38038061455b83398101604081905261002e91610107565b60018160018111156100425761004261012c565b0361004f5761004f610055565b50610140565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805468010000000000000000900460ff16156100a55760405163f92ee8a960e01b815260040160405180910390fd5b80546001600160401b03908116146101045780546001600160401b0319166001600160401b0390811782556040519081527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15b50565b5f60208284031215610117575f80fd5b815160028110610125575f80fd5b9392505050565b634e487b7160e01b5f52602160045260245ffd5b61440e8061014d5f395ff3fe608060405260043610610104575f3560e01c806366435abf11610092578063a3a65e4811610062578063a3a65e48146102f3578063b771b3bc14610312578063bee0a03f14610344578063c599e24f14610363578063f40797d714610376575f80fd5b806366435abf146102775780636d0e43fa1461029657806376f78621146102b557806398f3e2b4146102d4575f80fd5b8063162f1f61116100d8578063162f1f61146101c45780632e2194d8146101e3578063467ef06f1461021a5780635297fae6146102395780636206585614610258575f80fd5b8062e41792146101085780630118acc4146101295780630322ed98146101485780630cdd098514610167575b5f80fd5b348015610113575f80fd5b50610127610122366004613ac7565b610389565b005b348015610134575f80fd5b50610127610143366004613b02565b61046b565b348015610153575f80fd5b50610127610162366004613b3d565b6108f6565b348015610172575f80fd5b506101b1610181366004613b3d565b5f9081527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb08602052604090205490565b6040519081526020015b60405180910390f35b3480156101cf575f80fd5b506101276101de366004613b3d565b610a52565b3480156101ee575f80fd5b506102026101fd366004613b3d565b610abf565b6040516001600160401b0390911681526020016101bb565b348015610225575f80fd5b50610127610234366004613b54565b610ad5565b348015610244575f80fd5b50610127610253366004613b6d565b610bc1565b348015610263575f80fd5b506101b1610272366004613bab565b610db2565b348015610282575f80fd5b50610202610291366004613b3d565b610dcb565b3480156102a1575f80fd5b506101276102b0366004613b3d565b610ddf565b3480156102c0575f80fd5b506101276102cf366004613b02565b610e4c565b3480156102df575f80fd5b506101276102ee366004613b6d565b610e67565b3480156102fe575f80fd5b5061012761030d366004613b54565b611007565b34801561031d575f80fd5b5061032c6005600160991b0181565b6040516001600160a01b0390911681526020016101bb565b34801561034f575f80fd5b5061012761035e366004613b3d565b6111c4565b6101b1610371366004613b3d565b611293565b6101b1610384366004613c56565b61129f565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805460029190600160401b900460ff16806103d2575080546001600160401b03808416911610155b156103f05760405163f92ee8a960e01b815260040160405180910390fd5b805468ffffffffffffffffff19166001600160401b03831617600160401b17815561041a836112c3565b805468ff0000000000000000191681556040516001600160401b03831681527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a1505050565b5f8381527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d0360205260408120600101545f805160206143628339815191529184156104bd576104ba82856112d7565b90505b5f868152600384016020526040808220815161010081019092528054829060ff1660048111156104ef576104ef613ce8565b600481111561050057610500613ce8565b8152815461010090046001600160a01b03166020820152600182015460408201526002808301546001600160401b038082166060850152600160401b820481166080850152600160801b8204811660a0850152600160c01b909104811660c084015260039093015490921660e0909101529091508151600481111561058757610587613ce8565b146105d95760405162461bcd60e51b815260206004820152602a60248201525f805160206143828339815191526044820152696e6f742061637469766560b01b60648201526084015b60405180910390fd5b60208101516001600160a01b0316331461063e5760405162461bcd60e51b815260206004820152603360248201525f805160206143828339815191526044820152723737ba1037bbb732b210313c9039b2b73232b960691b60648201526084016105d0565b5f61064884611573565b60038084526001600160401b0342811660a0860152821660e08501525f8a815290870160205260409020835181549293508492829060ff1916600183600481111561069557610695613ce8565b021790555060208201518154610100600160a81b0319166101006001600160a01b0390921691909102178155604082015160018201556060820151600282018054608085015160a086015160c08701516001600160401b039586166001600160801b031990941693909317600160401b92861692909202919091176001600160801b0316600160801b918516919091026001600160c01b031617600160c01b9184169190910217905560e0909201516003909101805467ffffffffffffffff1916919092161790555f610767856115e7565b905082606001516001600160401b03168160a001516001600160401b0316116107de5760405162461bcd60e51b815260206004820152602360248201527f506f5356616c696461746f724d616e616765723a20496e76616c69642077656960448201526219da1d60ea1b60648201526084016105d0565b5f83606001518260a001516107f39190613d10565b90506107ff86826116c6565b5f61080b87858461170e565b5f8c815260058a01602052604090209091506108278282613db4565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb90610854908590600401613e95565b6020604051808303815f875af1158015610870573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108949190613ec7565b604080516001600160401b03868116825242602083015291810183905291925086169089908e907f5318ab4d7cdf77056db2db5b539a08fe7d1a63d6885ecee8236a0dbda2843b4e9060600160405180910390a4505050505050505050505050565b5f8181527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb066020526040812080545f805160206143a283398151915292919061093e90613d37565b9050118015610970575060035f83815260078301602052604090205460ff16600581111561096e5761096e613ce8565b145b6109d45760405162461bcd60e51b815260206004820152602f60248201527f56616c696461746f724d616e616765723a2056616c696461746f72206e6f742060448201526e1c195b991a5b99c81c995b5bdd985b608a1b60648201526084016105d0565b5f82815260068201602052604090819020905163ee5b48eb60e01b81526005600160991b019163ee5b48eb91610a0d9190600401613ede565b6020604051808303815f875af1158015610a29573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610a4d9190613ec7565b505050565b610a5b8161192b565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d05602052604090819020905163ee5b48eb60e01b81525f80516020614362833981519152916005600160991b019163ee5b48eb91610a0d91600401613ede565b5f610acf64e8d4a5100083613f7c565b92915050565b5f610adf826119fe565b90505f5f80516020614362833981519152600281015460a084015160c085015160e0860151604051639d4ba9db60e01b81526001600160401b03938416600482015291831660248301529190911660448201525f6064820181905260848201819052929350600160401b9091046001600160a01b031690639d4ba9db9060a401602060405180830381865afa158015610b7a573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610b9e9190613ec7565b9050610bbb8360a001516001600160401b03168460400151611d8b565b50505050565b5f805160206143628339815191525f610bd984611d9e565b90505f80610bea8360400151611f7f565b5091509150610bf8856121ba565b5f8581526004850160205260408120610c1091613a34565b5f610c1a836115e7565b9050816001600160401b031681608001516001600160401b03161015610c525760405162461bcd60e51b81526004016105d090613f8f565b5f8681526003860160205260409020600201546001600160401b03808416600160c01b909204161115610c975760405162461bcd60e51b81526004016105d090613fd1565b60015f87815260038701602052604090205460ff166004811115610cbd57610cbd613ce8565b14610d265760405162461bcd60e51b815260206004820152603360248201527f506f5356616c696461746f724d616e616765723a2064656c65676174696f6e4960448201527211081b9bdd081c195b991a5b99c81859191959606a1b60648201526084016105d0565b5f868152600386016020908152604091829020805460ff1916600290811782550180546001600160401b0342818116600160401b0267ffffffffffffffff60401b19909316929092179092559251928352841691859189917f245fc69b36e168426e0306fc8d8300661b9af297c7958820dbf804f9f63e7064910160405180910390a450505050505050565b5f610acf6001600160401b03831664e8d4a5100061401a565b5f610dd5826115e7565b60a0015192915050565b610de8816121ba565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d04602052604090819020905163ee5b48eb60e01b81525f80516020614362833981519152916005600160991b019163ee5b48eb91610a0d91600401613ede565b8115610e5e57610e5c83826112d7565b505b610a4d83612293565b5f805160206143628339815191525f610e7f84611d9e565b90505f80610e908360400151611f7f565b5091509150610e9e8561192b565b5f8581526005850160205260408120610eb691613a34565b5f610ec0836115e7565b9050816001600160401b031681608001516001600160401b03161015610ef85760405162461bcd60e51b81526004016105d090613f8f565b5f8681526003808701602052604090912001546001600160401b0380841691161115610f365760405162461bcd60e51b81526004016105d090613fd1565b60035f87815260038701602052604090205460ff166004811115610f5c57610f5c613ce8565b14610fb05760405162461bcd60e51b815260206004820152603160248201525f805160206143828339815191526044820152701b9bdd081c195b991a5b99c81859191959607a1b60648201526084016105d0565b5f868152600386016020526040808220805460ff19166004179055516001600160401b03841691859189917f52e9b1eaef84d46cda83ccb9d427267bc4d04f756b4a32c8302722b79e5c65ab91a450505050505050565b5f805160206143a28339815191525f61101f83611d9e565b90505f80611030836040015161264b565b91509150806110925760405162461bcd60e51b815260206004820152602860248201527f56616c696461746f724d616e616765723a20526567697374726174696f6e206e6044820152671bdd081d985b1a5960c21b60648201526084016105d0565b5f828152600585016020526040812080546110ac90613d37565b90501180156110de575060015f83815260078601602052604090205460ff1660058111156110dc576110dc613ce8565b145b6110fa5760405162461bcd60e51b81526004016105d090614031565b5f828152600585016020526040812061111291613a34565b5f8281526007850160208181526040808420805460ff191660021781556003810180546001600160401b0342818116600160801b0267ffffffffffffffff60801b19909316929092178355600190930154875260088b0185528387208990559588905293835292548151600160401b90910490931683529082019290925283917ff8fd1c90fb9cfa2ca2358fdf5806b086ad43315d92b221c929efc7f105ce7568910160405180910390a25050505050565b5f8181527fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb056020526040812080545f805160206143a283398151915292919061120c90613d37565b905011801561123e575060015f83815260078301602052604090205460ff16600581111561123c5761123c613ce8565b145b61125a5760405162461bcd60e51b81526004016105d090614031565b5f82815260058201602052604090819020905163ee5b48eb60e01b81526005600160991b019163ee5b48eb91610a0d9190600401613ede565b5f610acf8233346127ec565b5f806112aa34612ba4565b90506112b885828686612c4e565b9150505b9392505050565b6112cb6130a3565b6112d4816130ee565b50565b6040516306f8253560e41b815263ffffffff821660048201525f90819081906005600160991b0190636f825350906024015f60405180830381865afa158015611322573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f191682016040526113499190810190614097565b91509150806113ac5760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a20696e76616c69642077617260448201526870206d65737361676560b81b60648201526084016105d0565b6005600160991b016001600160a01b0316634213cf786040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113ef573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906114139190613ec7565b8251146114775760405162461bcd60e51b815260206004820152602c60248201527f506f5356616c696461746f724d616e616765723a20696e76616c696420736f7560448201526b1c98d94818da185a5b88125160a21b60648201526084016105d0565b60208201516001600160a01b0316156114ed5760405162461bcd60e51b815260206004820152603260248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964206f726960448201527167696e2073656e646572206164647265737360701b60648201526084016105d0565b5f806114fc8460400151613131565b915091508187146115695760405162461bcd60e51b815260206004820152603160248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964207570746044820152701a5b59481d985b1a59185d1a5bdb881251607a1b60648201526084016105d0565b9695505050505050565b5f8181525f805160206143e28339815191526020526040812060030180545f805160206143a2833981519152916001600160401b03909116908190846115b883614169565b91906101000a8154816001600160401b0302191690836001600160401b03160217905550508092505050919050565b6115ef613a6b565b5f8281525f805160206143e28339815191526020526040908190208151610100810190925280545f805160206143a2833981519152929190829060ff16600581111561163d5761163d613ce8565b600581111561164e5761164e613ce8565b81526001820154602082015260028201546001600160a01b03811660408301526001600160401b03600160a01b909104811660608301526003909201548083166080830152600160401b8104831660a0830152600160801b8104831660c0830152600160c01b900490911660e0909101529392505050565b5f9182525f805160206143e2833981519152602052604090912060030180546001600160401b03909216600160401b0267ffffffffffffffff60401b19909216919091179055565b60408051603680825260608281019093525f91906020820181803683370190505090505f5b60028110156117875761174781600161418e565b61175290600861401a565b5081515f90839083908110611769576117696141a1565b60200101906001600160f81b03191690815f1a905350600101611733565b505f5b60048110156117ea5761179e81600361418e565b6117a990600861401a565b6001901c60f81b826117bc8360026141b5565b815181106117cc576117cc6141a1565b60200101906001600160f81b03191690815f1a90535060010161178a565b505f5b602081101561184c5761180181601f61418e565b61180c90600861401a565b86901c60f81b8261181e8360066141b5565b8151811061182e5761182e6141a1565b60200101906001600160f81b03191690815f1a9053506001016117ed565b505f5b60088110156118b75761186381600761418e565b61186e90600861401a565b6001600160401b038616901c60f81b826118898360266141b5565b81518110611899576118996141a1565b60200101906001600160f81b03191690815f1a90535060010161184f565b505f5b6008811015611922576118ce81600761418e565b6118d990600861401a565b6001600160401b038516901c60f81b826118f483602e6141b5565b81518110611904576119046141a1565b60200101906001600160f81b03191690815f1a9053506001016118ba565b50949350505050565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d056020526040812080545f8051602061436283398151915292919061197390613d37565b90501180156119a5575060035f83815260038301602052604090205460ff1660048111156119a3576119a3613ce8565b145b6119fa5760405162461bcd60e51b815260206004820152603360248201525f8051602061438283398151915260448201527272656d6f76616c206e6f742070656e64696e6760681b60648201526084016105d0565b5050565b611a06613a6b565b5f805160206143a28339815191525f611a1e84611d9e565b90505f80611a2f836040015161264b565b915091508015611a945760405162461bcd60e51b815260206004820152602a60248201527f56616c696461746f724d616e616765723a20726567697374726174696f6e20736044820152691d1a5b1b081d985b1a5960b21b60648201526084016105d0565b5f828152600785016020526040808220815161010081019092528054829060ff166005811115611ac657611ac6613ce8565b6005811115611ad757611ad7613ce8565b81526001820154602082015260028201546001600160a01b03811660408301526001600160401b03600160a01b909104811660608301526003928301548082166080840152600160401b8104821660a0840152600160801b8104821660c0840152600160c01b90041660e0909101529091505f9082516005811115611b5e57611b5e613ce8565b1480611b7c5750600182516005811115611b7a57611b7a613ce8565b145b611bdb5760405162461bcd60e51b815260206004820152602a60248201527f56616c696461746f724d616e616765723a20696e76616c69642076616c696461604482015269746f722073746174757360b01b60648201526084016105d0565b600382516005811115611bf057611bf0613ce8565b03611c1757505f8381526006860160205260408120600491611c129190613a34565b611c1b565b5060055b6020808301515f90815260088801909152604081205581816005811115611c4457611c44613ce8565b90816005811115611c5757611c57613ce8565b9052505f84815260078701602052604090208251815484929190829060ff19166001836005811115611c8b57611c8b613ce8565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b0319909316959094169490941717929092161791909117905581516005811115611d5657611d56613ce8565b60405185907f1c08e59656f1a18dc2da76826cdc52805c43e897a17c50faefb8ab3c1526cc16905f90a3509695505050505050565b6119fa6001600160a01b03821683613309565b60408051606080820183525f8083526020830181905292820152905f805160206143a28339815191526040516306f8253560e41b815263ffffffff851660048201529091505f9081906005600160991b0190636f825350906024015f60405180830381865afa158015611e13573d5f803e3d5ffd5b505050506040513d5f823e601f3d908101601f19168201604052611e3a9190810190614097565b9150915080611ea15760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20496e76696e76616c6964616c696460448201526c2077617270206d65737361676560981b60648201526084016105d0565b8254825114611f045760405162461bcd60e51b815260206004820152602960248201527f56616c696461746f724d616e616765723a20696e76616c696420736f757263656044820152680818da185a5b88125160ba1b60648201526084016105d0565b60208201516001600160a01b031615611f775760405162461bcd60e51b815260206004820152602f60248201527f56616c696461746f724d616e616765723a20696e76616c6964206f726967696e60448201526e2073656e646572206164647265737360881b60648201526084016105d0565b509392505050565b5f805f8351603614611fa35760405162461bcd60e51b81526004016105d0906141c8565b5f805b6002811015611ff257611fba81600161418e565b611fc590600861401a565b61ffff16868281518110611fdb57611fdb6141a1565b016020015160f81c901b9190911790600101611fa6565b5061ffff8116156120155760405162461bcd60e51b81526004016105d090614211565b5f805b60048110156120705761202c81600361418e565b61203790600861401a565b63ffffffff16876120498360026141b5565b81518110612059576120596141a1565b016020015160f81c901b9190911790600101612018565b5063ffffffff81166003146120975760405162461bcd60e51b81526004016105d090614254565b5f805b60208110156120ec576120ae81601f61418e565b6120b990600861401a565b886120c58360066141b5565b815181106120d5576120d56141a1565b016020015160f81c901b919091179060010161209a565b505f805b600881101561214b5761210481600761418e565b61210f90600861401a565b6001600160401b0316896121248360266141b5565b81518110612134576121346141a1565b016020015160f81c901b91909117906001016120f0565b505f805b60088110156121aa5761216381600761418e565b61216e90600861401a565b6001600160401b03168a61218383602e6141b5565b81518110612193576121936141a1565b016020015160f81c901b919091179060010161214f565b5091989097509095509350505050565b5f8181527f4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d046020526040812080545f8051602061436283398151915292919061220290613d37565b9050118015612234575060015f83815260038301602052604090205460ff16600481111561223257612232613ce8565b145b6119fa5760405162461bcd60e51b815260206004820152603860248201525f8051602061438283398151915260448201527f726567697374726174696f6e206e6f742070656e64696e67000000000000000060648201526084016105d0565b5f8181525f805160206143e283398151915260205260408082208151610100810190925280545f805160206143a283398151915293929190829060ff1660058111156122e1576122e1613ce8565b60058111156122f2576122f2613ce8565b8152600182015460208201526002808301546001600160a01b03811660408401526001600160401b03600160a01b909104811660608401526003909301548084166080840152600160401b8104841660a0840152600160801b8104841660c0840152600160c01b900490921660e0909101529091508151600581111561237a5761237a613ce8565b146123d65760405162461bcd60e51b815260206004820152602660248201527f56616c696461746f724d616e616765723a2076616c696461746f72206e6f742060448201526561637469766560d01b60648201526084016105d0565b60408101516001600160a01b0316336001600160a01b0316146124505760405162461bcd60e51b815260206004820152602c60248201527f56616c696461746f724d616e616765723a2073656e646572206e6f742076616c60448201526b34b230ba37b91037bbb732b960a11b60648201526084016105d0565b61245d8160a0015161339c565b60038152426001600160401b031660e08201525f83815260078301602052604090208151815483929190829060ff191660018360058111156124a1576124a1613ce8565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b031990931695909416949094171792909216179190911790555f61256d8461256781611573565b5f61170e565b5f85815260068501602052604090209091506125898282613db4565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb906125b6908590600401613e95565b6020604051808303815f875af11580156125d2573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906125f69190613ec7565b60a0840151604080516001600160401b039092168252426020830152919250829187917f13d58394cf269d48bcf927959a29a5ffee7c9924dafff8927ecdf3c48ffa7c67910160405180910390a35050505050565b5f80825160271461266e5760405162461bcd60e51b81526004016105d0906141c8565b5f805b60028110156126bd5761268581600161418e565b61269090600861401a565b61ffff168582815181106126a6576126a66141a1565b016020015160f81c901b9190911790600101612671565b5061ffff8116156126e05760405162461bcd60e51b81526004016105d090614211565b5f805b600481101561273b576126f781600361418e565b61270290600861401a565b63ffffffff16866127148360026141b5565b81518110612724576127246141a1565b016020015160f81c901b91909117906001016126e3565b5063ffffffff81166002146127625760405162461bcd60e51b81526004016105d090614254565b5f805b60208110156127b75761277981601f61418e565b61278490600861401a565b876127908360066141b5565b815181106127a0576127a06141a1565b016020015160f81c901b9190911790600101612765565b505f866026815181106127cc576127cc6141a1565b016020015191976001600160f81b03199092161515965090945050505050565b5f6127f561353d565b5f6127ff83610abf565b90505f805160206143628339815191525f612819876115e7565b905060028151600581111561283057612830613ce8565b1461288f5760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a2076616c696461746f72206e6044820152686f742061637469766560b81b60648201526084016105d0565b5f838260a001516128a0919061429b565b90506128ac88826116c6565b5f6128b689611573565b90505f8989836040516020016128fe9392919092835260609190911b6bffffffffffffffffffffffff1916602083015260c01b6001600160c01b0319166034820152603c0190565b60405160208183030381529060405280519060200120905061291f8661339c565b5f61292b8b848661170e565b5f83815260048801602052604090209091506129478282613db4565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb90612974908590600401613e95565b6020604051808303815f875af1158015612990573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906129b49190613ec7565b60408051610100810190915290915080600181526020018c6001600160a01b031681526020018d8152602001896001600160401b031681526020015f6001600160401b031681526020015f6001600160401b03168152602001856001600160401b031681526020015f6001600160401b0316815250876003015f8581526020019081526020015f205f820151815f015f6101000a81548160ff02191690836004811115612a6357612a63613ce8565b02179055506020828101518254610100600160a81b0319166101006001600160a01b039283160217835560408085015160018501556060808601516002860180546080808a015160a08b015160c08c01516001600160401b039687166001600160801b031990951694909417600160401b92871692909202919091176001600160801b0316600160801b918616919091026001600160c01b031617600160c01b928516929092029190911790915560e0909701516003909601805467ffffffffffffffff19169682169690961790955581518a861681528b861694810194909452938d1690830152918101849052908d16918e9186917fb0024b263bc3a0b728a6edea50a69efa841189f8d32ee8af9d1c2b1a1a223426910160405180910390a4509096505050505050506112bc60015f805160206143c283398151915255565b5f5f805160206143628339815191528282612bbe82610abf565b83549091506001600160401b03821610801590612be857508260010154816001600160401b031611155b612c465760405162461bcd60e51b815260206004820152602960248201527f506f5356616c696461746f724d616e616765723a20696e76616c6964207374616044820152681ad948185b5bdd5b9d60ba1b60648201526084016105d0565b949350505050565b5f612c5761353d565b5f805160206143a2833981519152426001600160401b038516118015612c9157506001600160401b038416612c8f426202a3006141b5565b115b612cf35760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20696e76616c69642072656769737460448201526c726174696f6e2065787069727960981b60648201526084016105d0565b85612d4a5760405162461bcd60e51b815260206004820152602160248201527f56616c696461746f724d616e616765723a20696e76616c6964206e6f646520496044820152601160fa1b60648201526084016105d0565b5f86815260088201602052604090205415612db85760405162461bcd60e51b815260206004820152602860248201527f56616c696461746f724d616e616765723a206e6f646520494420616c72656164604482015267792061637469766560c01b60648201526084016105d0565b8251603014612e1f5760405162461bcd60e51b815260206004820152602d60248201527f56616c696461746f724d616e616765723a20696e76616c696420626c7350756260448201526c0d8d2c696caf240d8cadccee8d609b1b60648201526084016105d0565b612e288561339c565b5f80612e6f6040518060a00160405280856001015481526020018a8152602001896001600160401b03168152602001886001600160401b0316815260200187815250613587565b5f82815260058601602052604090209193509150612e8d8282613db4565b5060405163ee5b48eb60e01b81525f906005600160991b019063ee5b48eb90612eba908590600401613e95565b6020604051808303815f875af1158015612ed6573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190612efa9190613ec7565b604080516101008101825260018152602081018c90529192508101336001600160a01b031681526001600160401b038a1660208083018290525f604080850182905260608501939093526080840181905260a0909301839052868352600788019052902081518154829060ff19166001836005811115612f7c57612f7c613ce8565b021790555060208201516001820155604082015160028201805460608501516001600160401b03908116600160a01b026001600160e01b03199092166001600160a01b039094169390931717905560808301516003909201805460a085015160c086015160e0909601518416600160c01b026001600160c01b03968516600160801b02969096166001600160801b03918516600160401b026001600160801b0319909316959094169490941717929092161791909117905561303d83611573565b50604080516001600160401b03808b1682528916602082015282918b9186917f79b81620b81daf2c08cd5bb3dbb79e75d2d7a87f52171fde5aadc8c47823026e910160405180910390a4509092505050612c4660015f805160206143c283398151915255565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a0054600160401b900460ff166130ec57604051631afcd79f60e31b815260040160405180910390fd5b565b6130f66130a3565b6130ff8161392c565b6112d46060820135608083013561311c60c0850160a08601613bab565b61312c60e0860160c087016142bb565b61394d565b5f808251602e146131545760405162461bcd60e51b81526004016105d0906141c8565b5f805b60028110156131a35761316b81600161418e565b61317690600861401a565b61ffff1685828151811061318c5761318c6141a1565b016020015160f81c901b9190911790600101613157565b5061ffff8116156131c65760405162461bcd60e51b81526004016105d090614211565b5f805b6004811015613221576131dd81600361418e565b6131e890600861401a565b63ffffffff16866131fa8360026141b5565b8151811061320a5761320a6141a1565b016020015160f81c901b91909117906001016131c9565b5063ffffffff81166004146132485760405162461bcd60e51b81526004016105d090614254565b5f805b602081101561329d5761325f81601f61418e565b61326a90600861401a565b876132768360066141b5565b81518110613286576132866141a1565b016020015160f81c901b919091179060010161324b565b505f805b60088110156132fc576132b581600761418e565b6132c090600861401a565b6001600160401b0316886132d58360266141b5565b815181106132e5576132e56141a1565b016020015160f81c901b91909117906001016132a1565b5090969095509350505050565b8047101561332c5760405163cd78605960e01b81523060048201526024016105d0565b5f826001600160a01b0316826040515f6040518083038185875af1925050503d805f8114613375576040519150601f19603f3d011682016040523d82523d5f602084013e61337a565b606091505b5050905080610a4d57604051630a12f52160e11b815260040160405180910390fd5b7fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb02545f805160206143a28339815191529060ff165f036133da575050565b60408051606081018252600383015480825260048401546001600160401b038082166020850152600160401b9091041692820192909252904290610e1090613422908361418e565b1061343e576001600160401b038416604083015280825261345d565b8382604001818151613450919061429b565b6001600160401b03169052505b5f82602001518360400151606461347491906142d6565b61347e9190614301565b600285015490915060ff90811690821611156134f95760405162461bcd60e51b815260206004820152603460248201527f56616c696461746f724d616e616765723a206d6178696d756d20686f75726c796044820152730818da1d5c9b881c985d1948195e18d95959195960621b60648201526084016105d0565b5050805160038301556020810151600490920180546040909201516001600160401b03908116600160401b026001600160801b031990931693169290921717905550565b5f805160206143c283398151915280546001190161356e57604051633ee5aeb560e01b815260040160405180910390fd5b60029055565b60015f805160206143c283398151915255565b5f60608260800151516030146135f15760405162461bcd60e51b815260206004820152602960248201527f5374616b696e674d657373616765733a20696e76616c6964207369676e6174756044820152680e4ca40d8cadccee8d60bb1b60648201526084016105d0565b60408051608680825260c082019092525f916020820181803683370190505090505f5b60028110156136685761362881600161418e565b61363390600861401a565b5081515f9083908390811061364a5761364a6141a1565b60200101906001600160f81b03191690815f1a905350600101613614565b505f5b60048110156136c65761367f81600361418e565b61368a90600861401a565b505f826136988360026141b5565b815181106136a8576136a86141a1565b60200101906001600160f81b03191690815f1a90535060010161366b565b505f5b602081101561372357845181602081106136e5576136e56141a1565b1a60f81b826136f58360066141b5565b81518110613705576137056141a1565b60200101906001600160f81b03191690815f1a9053506001016136c9565b505f5b60208110156137835784602001518160208110613745576137456141a1565b1a60f81b826137558360266141b5565b81518110613765576137656141a1565b60200101906001600160f81b03191690815f1a905350600101613726565b505f5b60088110156137f75761379a81600761418e565b6137a590600861401a565b60ff1685604001516001600160401b0316901c60f81b828260466137c991906141b5565b815181106137d9576137d96141a1565b60200101906001600160f81b03191690815f1a905350600101613786565b505f5b60308110156138625784608001518181518110613819576138196141a1565b01602001516001600160f81b0319168261383483604e6141b5565b81518110613844576138446141a1565b60200101906001600160f81b03191690815f1a9053506001016137fa565b505f5b60088110156138d45761387981600761418e565b61388490600861401a565b60608601516001600160401b0390811691161c60f81b826138a683607e6141b5565b815181106138b6576138b66141a1565b60200101906001600160f81b03191690815f1a905350600101613865565b506002816040516138e59190614326565b602060405180830381855afa158015613900573d5f803e3d5ffd5b5050506040513d601f19601f820116820180604052508101906139239190613ec7565b94909350915050565b6139346130a3565b61393c6139a8565b6139446139b8565b6112d4816139c0565b6139556130a3565b5f5f80516020614362833981519152948555506001840192909255600290920180546001600160a01b03909216600160401b026001600160e01b03199092166001600160401b0390931692909217179055565b6139b06130a3565b6130ec613a2c565b6130ec6130a3565b6139c86130a3565b80355f805160206143a283398151915290815560208201357fe92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb0155613a126060830160408401614341565b600291909101805460ff191660ff90921691909117905550565b6135746130a3565b508054613a4090613d37565b5f825580601f10613a4f575050565b601f0160209004905f5260205f20908101906112d49190613aaf565b604080516101008101909152805f81525f6020820181905260408201819052606082018190526080820181905260a0820181905260c0820181905260e09091015290565b5b80821115613ac3575f8155600101613ab0565b5090565b5f60e08284031215613ad7575f80fd5b50919050565b80151581146112d4575f80fd5b803563ffffffff81168114613afd575f80fd5b919050565b5f805f60608486031215613b14575f80fd5b833592506020840135613b2681613add565b9150613b3460408501613aea565b90509250925092565b5f60208284031215613b4d575f80fd5b5035919050565b5f60208284031215613b64575f80fd5b6112bc82613aea565b5f8060408385031215613b7e575f80fd5b613b8783613aea565b946020939093013593505050565b80356001600160401b0381168114613afd575f80fd5b5f60208284031215613bbb575f80fd5b6112bc82613b95565b634e487b7160e01b5f52604160045260245ffd5b604051606081016001600160401b0381118282101715613bfa57613bfa613bc4565b60405290565b604051601f8201601f191681016001600160401b0381118282101715613c2857613c28613bc4565b604052919050565b5f6001600160401b03821115613c4857613c48613bc4565b50601f01601f191660200190565b5f805f60608486031215613c68575f80fd5b83359250613c7860208501613b95565b915060408401356001600160401b03811115613c92575f80fd5b8401601f81018613613ca2575f80fd5b8035613cb5613cb082613c30565b613c00565b818152876020838501011115613cc9575f80fd5b816020840160208301375f602083830101528093505050509250925092565b634e487b7160e01b5f52602160045260245ffd5b634e487b7160e01b5f52601160045260245ffd5b6001600160401b03828116828216039080821115613d3057613d30613cfc565b5092915050565b600181811c90821680613d4b57607f821691505b602082108103613ad757634e487b7160e01b5f52602260045260245ffd5b601f821115610a4d57805f5260205f20601f840160051c81016020851015613d8e5750805b601f840160051c820191505b81811015613dad575f8155600101613d9a565b5050505050565b81516001600160401b03811115613dcd57613dcd613bc4565b613de181613ddb8454613d37565b84613d69565b602080601f831160018114613e14575f8415613dfd5750858301515b5f19600386901b1c1916600185901b178555613e6b565b5f85815260208120601f198616915b82811015613e4257888601518255948401946001909101908401613e23565b5085821015613e5f57878501515f19600388901b60f8161c191681555b505060018460011b0185555b505050505050565b5f5b83811015613e8d578181015183820152602001613e75565b50505f910152565b602081525f8251806020840152613eb3816040850160208701613e73565b601f01601f19169190910160400192915050565b5f60208284031215613ed7575f80fd5b5051919050565b5f60208083525f8454613ef081613d37565b806020870152604060018084165f8114613f115760018114613f2d57613f5a565b60ff19851660408a0152604084151560051b8a01019550613f5a565b895f5260205f205f5b85811015613f515781548b8201860152908301908801613f36565b8a016040019650505b509398975050505050505050565b634e487b7160e01b5f52601260045260245ffd5b5f82613f8a57613f8a613f68565b500490565b60208082526022908201527f506f5356616c696461746f724d616e616765723a20696e76616c6964206e6f6e604082015261636560f01b606082015260800190565b60208082526029908201527f506f5356616c696461746f724d616e616765723a206e6f6e636520646f6573206040820152680dcdee840dac2e8c6d60bb1b606082015260800190565b8082028115828204841417610acf57610acf613cfc565b60208082526027908201527f56616c696461746f724d616e616765723a20696e76616c69642076616c6964616040820152661d1a5bdb88125160ca1b606082015260800190565b6001600160a01b03811681146112d4575f80fd5b8051613afd81613add565b5f80604083850312156140a8575f80fd5b82516001600160401b03808211156140be575f80fd5b90840190606082870312156140d1575f80fd5b6140d9613bd8565b825181526020808401516140ec81614078565b82820152604084015183811115614101575f80fd5b80850194505087601f850112614115575f80fd5b83519250614125613cb084613c30565b8381528882858701011115614138575f80fd5b61414784838301848801613e73565b8060408401525081955061415c81880161408c565b9450505050509250929050565b5f6001600160401b0380831681810361418457614184613cfc565b6001019392505050565b81810381811115610acf57610acf613cfc565b634e487b7160e01b5f52603260045260245ffd5b80820180821115610acf57610acf613cfc565b60208082526029908201527f56616c696461746f724d657373616765733a20696e76616c6964206d657373616040820152680ceca40d8cadccee8d60bb1b606082015260800190565b60208082526023908201527f56616c696461746f724d657373616765733a20696e76616c696420636f64656360408201526208125160ea1b606082015260800190565b60208082526027908201527f56616c696461746f724d657373616765733a20696e76616c6964206d657373616040820152666765207479706560c81b606082015260800190565b6001600160401b03818116838216019080821115613d3057613d30613cfc565b5f602082840312156142cb575f80fd5b81356112bc81614078565b6001600160401b038181168382160280821691908281146142f9576142f9613cfc565b505092915050565b5f6001600160401b038084168061431a5761431a613f68565b92169190910492915050565b5f8251614337818460208701613e73565b9190910192915050565b5f60208284031215614351575f80fd5b813560ff811681146112bc575f80fdfe4317713f7ecbdddd4bc99e95d903adedaa883b2e7c2551610bd13e2c7e473d00506f5356616c696461746f724d616e616765723a2064656c65676174696f6e20e92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb009b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f00e92546d698950ddd38910d2e15ed1d923cd0a7b3dde9e2a6a3f380565559cb07a164736f6c6343000819000a", } // NativeTokenStakingManagerABI is the input ABI used to generate the binding from. diff --git a/contracts/staking/ERC20TokenStakingManager.sol b/contracts/staking/ERC20TokenStakingManager.sol index 046dce5c1..27145e00f 100644 --- a/contracts/staking/ERC20TokenStakingManager.sol +++ b/contracts/staking/ERC20TokenStakingManager.sol @@ -123,4 +123,9 @@ contract ERC20TokenStakingManager is function _unlock(uint256 value, address to) internal virtual override { _getERC20StakingManagerStorage()._token.safeTransfer(to, value); } + + function _reward(address account, uint256 amount) internal virtual override { + ERC20TokenStakingManagerStorage storage $ = _getERC20StakingManagerStorage(); + $._token.mint(account, amount); + } } diff --git a/contracts/staking/NativeTokenStakingManager.sol b/contracts/staking/NativeTokenStakingManager.sol index 8763d0e7f..9b1443a84 100644 --- a/contracts/staking/NativeTokenStakingManager.sol +++ b/contracts/staking/NativeTokenStakingManager.sol @@ -82,4 +82,9 @@ contract NativeTokenStakingManager is function _unlock(uint256 value, address to) internal virtual override { payable(to).sendValue(value); } + + // solhint-disable-next-line no-empty-blocks + function _reward(address account, uint256 amount) internal virtual override { + // TODO: call the native minter precompile to mint `amount` for `account` + } } diff --git a/contracts/staking/PoSValidatorManager.sol b/contracts/staking/PoSValidatorManager.sol index b65515031..60363edf9 100644 --- a/contracts/staking/PoSValidatorManager.sol +++ b/contracts/staking/PoSValidatorManager.sol @@ -98,6 +98,14 @@ abstract contract PoSValidatorManager is IPoSValidatorManager, ValidatorManager function completeEndValidation(uint32 messageIndex) external { Validator memory validator = _completeEndValidation(messageIndex); + + PoSValidatorManagerStorage storage $ = _getPoSValidatorManagerStorage(); + uint256 rewardAmount = $._rewardCalculator.calculateReward( + validator.weight, validator.startedAt, validator.endedAt, 0, 0 + ); + + _reward(validator.owner, rewardAmount); + _unlock(validator.weight, validator.owner); } @@ -376,4 +384,6 @@ abstract contract PoSValidatorManager is IPoSValidatorManager, ValidatorManager "PoSValidatorManager: delegation registration not pending" ); } + + function _reward(address account, uint256 amount) internal virtual; } diff --git a/contracts/staking/tests/ERC20TokenStakingManagerTests.t.sol b/contracts/staking/tests/ERC20TokenStakingManagerTests.t.sol index 0b1e6084a..f908010d6 100644 --- a/contracts/staking/tests/ERC20TokenStakingManagerTests.t.sol +++ b/contracts/staking/tests/ERC20TokenStakingManagerTests.t.sol @@ -10,6 +10,7 @@ import {ERC20TokenStakingManager} from "../ERC20TokenStakingManager.sol"; import {ValidatorManagerSettings} from "../interfaces/IValidatorManager.sol"; import {PoSValidatorManagerSettings} from "../interfaces/IPoSValidatorManager.sol"; import {IRewardCalculator} from "../interfaces/IRewardCalculator.sol"; +import {ExampleRewardCalculator} from "../ExampleRewardCalculator.sol"; import {ICMInitializable} from "../../utilities/ICMInitializable.sol"; import {ExampleERC20} from "@mocks/ExampleERC20.sol"; import {IERC20Mintable} from "../interfaces/IERC20Mintable.sol"; @@ -37,7 +38,7 @@ contract ERC20TokenStakingManagerTest is PoSValidatorManagerTest { minimumStakeAmount: DEFAULT_MINIMUM_STAKE, maximumStakeAmount: DEFAULT_MAXIMUM_STAKE, minimumStakeDuration: DEFAULT_MINIMUM_STAKE_DURATION, - rewardCalculator: IRewardCalculator(address(0)) + rewardCalculator: IRewardCalculator(new ExampleRewardCalculator(DEFAULT_REWARD_RATE)) }), token ); diff --git a/contracts/staking/tests/NativeTokenStakingManagerTests.t.sol b/contracts/staking/tests/NativeTokenStakingManagerTests.t.sol index cd97aee36..361bb9613 100644 --- a/contracts/staking/tests/NativeTokenStakingManagerTests.t.sol +++ b/contracts/staking/tests/NativeTokenStakingManagerTests.t.sol @@ -10,6 +10,7 @@ import {NativeTokenStakingManager} from "../NativeTokenStakingManager.sol"; import {ValidatorManagerSettings} from "../interfaces/IValidatorManager.sol"; import {PoSValidatorManagerSettings} from "../interfaces/IPoSValidatorManager.sol"; import {IRewardCalculator} from "../interfaces/IRewardCalculator.sol"; +import {ExampleRewardCalculator} from "../ExampleRewardCalculator.sol"; import {ICMInitializable} from "../../utilities/ICMInitializable.sol"; // TODO: Remove this once all unit tests implemented @@ -30,7 +31,7 @@ contract NativeTokenStakingManagerTest is PoSValidatorManagerTest { minimumStakeAmount: DEFAULT_MINIMUM_STAKE, maximumStakeAmount: DEFAULT_MAXIMUM_STAKE, minimumStakeDuration: DEFAULT_MINIMUM_STAKE_DURATION, - rewardCalculator: IRewardCalculator(address(0)) + rewardCalculator: IRewardCalculator(new ExampleRewardCalculator(DEFAULT_REWARD_RATE)) }) ); validatorManager = app; diff --git a/contracts/staking/tests/PoSValidatorManagerTests.t.sol b/contracts/staking/tests/PoSValidatorManagerTests.t.sol index 6dedd8b98..9fa4a9791 100644 --- a/contracts/staking/tests/PoSValidatorManagerTests.t.sol +++ b/contracts/staking/tests/PoSValidatorManagerTests.t.sol @@ -21,6 +21,7 @@ abstract contract PoSValidatorManagerTest is ValidatorManagerTest { uint64 public constant DEFAULT_DELEGATOR_END_DELEGATION_TIMESTAMP = uint64(4000); address public constant DEFAULT_DELEGATOR_ADDRESS = address(0x1234123412341234123412341234123412341234); + uint64 public constant DEFAULT_REWARD_RATE = uint64(10); PoSValidatorManager public posValidatorManager;