Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@gooddollar/bridge-app

Package Overview
Dependencies
Maintainers
3
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@gooddollar/bridge-app - npm Package Compare versions

Comparing version 1.2.18 to 1.2.19

dist/types/bridge-app/__tests__/relayer.e2e.test.d.ts

2

dist/types/bridge-app/src/sdk.d.ts

@@ -20,3 +20,3 @@ import { JsonRpcBatchProvider, JsonRpcProvider } from '@ethersproject/providers';

[key: string]: string;
}, rpcs?: any, logger?: typeof Logger);
}, rpcs?: any, logger?: import("js-logger").GlobalLogger);
getChainRpc: (chainId: number) => Promise<JsonRpcBatchProvider>;

@@ -23,0 +23,0 @@ getBridgeContract: (chainId: number, provider?: JsonRpcProvider) => Promise<Contract>;

@@ -56,3 +56,3 @@ import * as ethers from 'ethers';

export declare const index2key: (index: any, proofLength: any) => string;
export declare const receiptProof: (txHash: string, provider: ethers.providers.JsonRpcProvider, chainId?: number) => Promise<{
export declare const receiptProof: (txHash: string, provider: ethers.providers.JsonRpcProvider, chainId: number) => Promise<{
receipt: any;

@@ -59,0 +59,0 @@ receiptsRoot: string;

{
"name": "@gooddollar/bridge-app",
"version": "1.2.18",
"version": "1.2.19",
"description": "Minimalistic bridge",

@@ -5,0 +5,0 @@ "engines": {

@@ -220,36 +220,5 @@ {

{
"internalType": "bytes",
"name": "rlpHeader",
"type": "bytes"
}
],
"name": "parseRLPToHeader",
"outputs": [
{
"components": [
{
"internalType": "bytes32",
"name": "parentHash",
"type": "bytes32"
},
{
"internalType": "uint256",
"name": "number",
"type": "uint256"
}
],
"internalType": "struct BridgeCore.BlockHeader",
"name": "header",
"type": "tuple"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"components": [
{
"internalType": "uint256",
"name": "chainId",

@@ -256,0 +225,0 @@ "type": "uint256"

@@ -289,33 +289,2 @@ {

{
"inputs": [
{
"internalType": "bytes",
"name": "rlpHeader",
"type": "bytes"
}
],
"name": "parseRLPToHeader",
"outputs": [
{
"components": [
{
"internalType": "bytes32",
"name": "parentHash",
"type": "bytes32"
},
{
"internalType": "uint256",
"name": "number",
"type": "uint256"
}
],
"internalType": "struct BridgeCore.BlockHeader",
"name": "header",
"type": "tuple"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [],

@@ -322,0 +291,0 @@ "name": "renounceOwnership",

@@ -6,6 +6,6 @@ {

"abi": [],
"bytecode": "0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220e934519fadc9499d461f2800304ab3fc174877a9188fa517fb558c53576a3b7b64736f6c634300080a0033",
"deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220e934519fadc9499d461f2800304ab3fc174877a9188fa517fb558c53576a3b7b64736f6c634300080a0033",
"bytecode": "0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122021d2c8a0532d59fa9ac7a2ff0a63875b4f9ce971889ecf8d5a2c54cbf4b560ac64736f6c634300080a0033",
"deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122021d2c8a0532d59fa9ac7a2ff0a63875b4f9ce971889ecf8d5a2c54cbf4b560ac64736f6c634300080a0033",
"linkReferences": {},
"deployedLinkReferences": {}
}

@@ -116,6 +116,6 @@ {

],
"bytecode": "0x608060405234801561001057600080fd5b50611a47806100206000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c80632af4108b1461003b578063aa3eb63a14610063575b600080fd5b61004e610049366004611405565b610083565b60405190151581526020015b60405180910390f35b61007661007136600461143f565b61009c565b60405161005a91906114fd565b60006100966100918361177c565b610110565b92915050565b6100ca6040518060800160405280600060ff1681526020016000815260200160608152602001606081525090565b61010983838080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061030992505050565b9392505050565b600080826040015183608001518151811061012d5761012d61182b565b60200260200101519050600061017261016d8360408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b610503565b90508360600151600014156101f057835182516020840120146101eb5760405162461bcd60e51b815260206004820152602660248201527f7665726966795472696550726f6f6620726f6f74206e6f6465206861736820696044820152651b9d985b1a5960d21b60648201526084015b60405180910390fd5b6102aa565b60208251101561025d57600061020d6102088361056f565b6105cc565b855190915081146102575760405162461bcd60e51b81526020600482015260146024820152733b32b934b33caa3934b2a83937b7b3101e10199960611b60448201526064016101e2565b506102aa565b835182516020840120146102aa5760405162461bcd60e51b81526020600482015260146024820152737665726966795472696550726f6f6620656c736560601b60448201526064016101e2565b60006102b9826000015161061a565b905080601114156102d6576102cd8561069d565b95945050505050565b80600214156102e9576102cd8286610825565b60a0850151516102fe57506001949350505050565b506000949350505050565b6103376040518060800160405280600060ff1681526020016000815260200160608152602001606081525090565b8151600090607f60f81b90849083906103525761035261182b565b01602001516001600160f81b0319161161036a575060015b600061037e6103798584610afa565b610b46565b90506103a3816000815181106103965761039661182b565b60200260200101516105cc565b60ff16835280516103c190829060019081106103965761039661182b565b602084015280516103ec90829060029081106103df576103df61182b565b6020026020010151610c5b565b836040018190525060006104198260038151811061040c5761040c61182b565b6020026020010151610b46565b905080516001600160401b0381111561043457610434611601565b60405190808252806020026020018201604052801561049257816020015b61047f604051806060016040528060006001600160a01b0316815260200160608152602001606081525090565b8152602001906001900390816104525790505b50606085015260005b81518110156104fa576104c68282815181106104b9576104b961182b565b6020026020010151610cd8565b856060015182815181106104dc576104dc61182b565b602002602001018190525080806104f290611857565b91505061049b565b50505050919050565b604080516080810182526000918101828152606082018390528152602081019190915261052f82610e27565b61053857600080fd5b60006105478360200151610e60565b83602001516105569190611872565b6040805180820190915293845260208401525090919050565b604080518082019091526000808252602082015261058c82610edb565b61059557600080fd5b602082015160006105a582610eff565b90506105b18183611872565b60209485015260408051808201909152908152928301525090565b8051600090158015906105e157508151602110155b6105ea57600080fd5b6000806105f684610fa8565b8151919350915060208210156106125760208290036101000a90045b949350505050565b805160009061062b57506000919050565b60008061063b8460200151610e60565b846020015161064a9190611872565b90506000846000015185602001516106629190611872565b90505b808210156106945761067682610eff565b6106809083611872565b91508261068c81611857565b935050610665565b50909392505050565b60008082604001518360800151815181106106ba576106ba61182b565b6020026020010151905082602001515183606001511061074b57600061071f61070d6103798460408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b6010815181106103df576103df61182b565b90508360a001518051906020012081805190602001201415610745575060019392505050565b50610809565b600083602001518460600151815181106107675761076761182b565b016020015160f81c905060006107bb6107aa6103798560408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b83815181106103df576103df61182b565b905080516000146108065760208101518552606085018051600191906107e2908390611872565b905250608085018051600191906107fa908390611872565b9052506102cd85610110565b50505b60a08301515161081c5750600192915050565b50600092915050565b6000806108396108348561056f565b610c5b565b905060006108496108348661056f565b602083015190915060fc1c600281141561090d5760006001845161086d919061188a565b9050600061087f856001846000610fef565b9050600061089888602001518960600151856000610fef565b905084805190602001208860a00151805190602001201415610905578080519060200120828051906020012014156108d95760019650505050505050610096565b805160208201206108e9836110d3565b8051906020012014156109055760019650505050505050610096565b505050610ad8565b80600314156109c357600061092784600086516001610fef565b60208701516060880151815192935060009261095192919061094a90829061188a565b6000610fef565b905083805190602001208760a001518051906020012014156109bc5780805190602001208280519060200120141561099157600195505050505050610096565b805160208201206109a18361120a565b8051906020012014156109bc57600195505050505050610096565b5050610ad8565b80610a86576000600184516109d8919061188a565b905060006109ea856001846000610fef565b90506000610a0388602001518960600151856000610fef565b9050808051906020012082805190602001201480610a35575080516020820120610a2c836110d3565b80519060200120145b156109055760208501518852606088018051849190610a55908390611872565b90525060808801805160019190610a6d908390611872565b905250610a7988610110565b9650505050505050610096565b8060011415610aa057825160006109ea8582846001610fef565b60405162461bcd60e51b815260206004820152600d60248201526c24b73b30b634b210383937b7b360991b60448201526064016101e2565b60a085015151610aee5760019350505050610096565b60009350505050610096565b604080518082019091526000808252602082015260208301610b1c8382611872565b90506040518060400160405280848651610b36919061188a565b8152602001919091529392505050565b6060610b5182610e27565b610b5a57600080fd5b6000610b658361061a565b90506000816001600160401b03811115610b8157610b81611601565b604051908082528060200260200182016040528015610bc657816020015b6040805180820190915260008082526020820152815260200190600190039081610b9f5790505b5090506000610bd88560200151610e60565b8560200151610be79190611872565b90506000805b84811015610c5057610bfe83610eff565b9150604051806040016040528083815260200184815250848281518110610c2757610c2761182b565b6020908102919091010152610c3c8284611872565b925080610c4881611857565b915050610bed565b509195945050505050565b8051606090610c6957600080fd5b600080610c7584610fa8565b915091506000816001600160401b03811115610c9357610c93611601565b6040519080825280601f01601f191660200182016040528015610cbd576020820181803683370190505b50905060208101610ccf84828561136b565b50949350505050565b610d05604051806060016040528060006001600160a01b0316815260200160608152602001606081525090565b6000610d1083610b46565b9050610d3581600081518110610d2857610d2861182b565b60200260200101516113eb565b6001600160a01b031682528051600090610d5c908390600190811061040c5761040c61182b565b905080516001600160401b03811115610d7757610d77611601565b604051908082528060200260200182016040528015610da0578160200160208202803683370190505b50602084015260005b8151811015610e03576000610dc98383815181106103965761039661182b565b60001b90508085602001518381518110610de557610de561182b565b60209081029190910101525080610dfb81611857565b915050610da9565b50610e1a826002815181106103df576103df61182b565b6040840152509092915050565b8051600090610e3857506000919050565b6020820151805160001a9060c0821015610e56575060009392505050565b5060019392505050565b8051600090811a6080811015610e795750600092915050565b60b8811080610e94575060c08110801590610e94575060f881105b15610ea25750600192915050565b60c0811015610ecf57610eb7600160b86118a1565b610ec49060ff168261188a565b610109906001611872565b610eb7600160f86118a1565b80518051602082015160009291610ef191611872565b836020015110915050919050565b80516000908190811a6080811015610f1a5760019150610fa1565b60b8811015610f4057610f2e60808261188a565b610f39906001611872565b9150610fa1565b60c0811015610f6d5760b78103600185019450806020036101000a85510460018201810193505050610fa1565b60f8811015610f8157610f2e60c08261188a565b60f78103600185019450806020036101000a855104600182018101935050505b5092915050565b6000806000610fba8460200151610e60565b90506000818560200151610fce9190611872565b90506000828660000151610fe2919061188a565b9196919550909350505050565b60606000610ffe6020856118da565b9050600061100d6020866118ee565b611018906008611902565b6110249061010061188a565b9050602060008080886001600160401b0381111561104457611044611601565b6040519080825280601f01601f19166020018201604052801561106e576020820181803683370190505b5090508a8a019150871561109857818401516001600160fc1b031681850152602090930192600192505b825b868110156110b857828501518286015260209094019360010161109a565b5083820151851c851b84820152505050505050949350505050565b60606000825160026110e59190611902565b90506000816001600160401b0381111561110157611101611601565b6040519080825280601f01601f19166020018201604052801561112b576020820181803683370190505b50905060005b8451811015611202576000806111758784815181106111525761115261182b565b01602001516001600160f81b031916600481901c916001600160fc1b0390911690565b90925090508184611187856002611902565b815181106111975761119761182b565b60200101906001600160f81b031916908160001a90535080846111bb856002611902565b6111c6906001611872565b815181106111d6576111d661182b565b60200101906001600160f81b031916908160001a905350505080806111fa90611857565b915050611131565b509392505050565b6060600060018351600261121e9190611902565b611228919061188a565b90506000816001600160401b0381111561124457611244611601565b6040519080825280601f01601f19166020018201604052801561126e576020820181803683370190505b509050836000815181106112845761128461182b565b602001015160f81c60f81b816000815181106112a2576112a261182b565b60200101906001600160f81b031916908160001a90535060015b8451811015611202576000806112dd8784815181106111525761115261182b565b9092509050818460016112f1866002611902565b6112fb919061188a565b8151811061130b5761130b61182b565b60200101906001600160f81b031916908160001a905350808461132f856002611902565b8151811061133f5761133f61182b565b60200101906001600160f81b031916908160001a9053505050808061136390611857565b9150506112bc565b8061137557505050565b602081106113ad578251825261138c602084611872565b9250611399602083611872565b91506113a660208261188a565b9050611375565b80156113e657600060016113c283602061188a565b6113ce90610100611a05565b6113d8919061188a565b845184518216911916178352505b505050565b80516000906015146113fc57600080fd5b610096826105cc565b60006020828403121561141757600080fd5b81356001600160401b0381111561142d57600080fd5b820160c0818503121561010957600080fd5b6000806020838503121561145257600080fd5b82356001600160401b038082111561146957600080fd5b818501915085601f83011261147d57600080fd5b81358181111561148c57600080fd5b86602082850101111561149e57600080fd5b60209290920196919550909350505050565b6000815180845260005b818110156114d6576020818501810151868301820152016114ba565b818111156114e8576000602083870101525b50601f01601f19169290920160200192915050565b6000602080835260ff845116818401528084015160408181860152808601519150606060808187015261153360a08701846114b0565b81880151601f19888303810160808a015281518084529295509086019186860190600581901b870188016000805b838110156115ef5789830386018552865180516001600160a01b031684528b8101518c85018a905280518a8601819052908d0190849060808701905b808310156115bd5783518252928f019260019290920191908f019061159d565b50928c0151868403878e0152926115d481856114b0565b9650505050508a870196508a85019450600181019050611561565b50909c9b505050505050505050505050565b634e487b7160e01b600052604160045260246000fd5b60405160c081016001600160401b038111828210171561163957611639611601565b60405290565b604051601f8201601f191681016001600160401b038111828210171561166757611667611601565b604052919050565b600082601f83011261168057600080fd5b81356001600160401b0381111561169957611699611601565b6116ac601f8201601f191660200161163f565b8181528460208386010111156116c157600080fd5b816020850160208301376000918101602001919091529392505050565b600082601f8301126116ef57600080fd5b813560206001600160401b038083111561170b5761170b611601565b8260051b61171a83820161163f565b938452858101830193838101908886111561173457600080fd5b84880192505b85831015611770578235848111156117525760008081fd5b6117608a87838c010161166f565b835250918401919084019061173a565b98975050505050505050565b600060c0823603121561178e57600080fd5b611796611617565b8235815260208301356001600160401b03808211156117b457600080fd5b6117c03683870161166f565b602084015260408501359150808211156117d957600080fd5b6117e5368387016116de565b6040840152606085013560608401526080850135608084015260a085013591508082111561181257600080fd5b5061181f3682860161166f565b60a08301525092915050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060001982141561186b5761186b611841565b5060010190565b6000821982111561188557611885611841565b500190565b60008282101561189c5761189c611841565b500390565b600060ff821660ff8416808210156118bb576118bb611841565b90039392505050565b634e487b7160e01b600052601260045260246000fd5b6000826118e9576118e96118c4565b500490565b6000826118fd576118fd6118c4565b500690565b600081600019048311821515161561191c5761191c611841565b500290565b600181815b8085111561195c57816000190482111561194257611942611841565b8085161561194f57918102915b93841c9390800290611926565b509250929050565b60008261197357506001610096565b8161198057506000610096565b816001811461199657600281146119a0576119bc565b6001915050610096565b60ff8411156119b1576119b1611841565b50506001821b610096565b5060208310610133831016604e8410600b84101617156119df575081810a610096565b6119e98383611921565b80600019048211156119fd576119fd611841565b029392505050565b6000610109838361196456fea26469706673582212208ebe0c5a8594d94aa349c56d1a38b28ce155d29527be7cd54b80e5294241b2e964736f6c634300080a0033",
"deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100365760003560e01c80632af4108b1461003b578063aa3eb63a14610063575b600080fd5b61004e610049366004611405565b610083565b60405190151581526020015b60405180910390f35b61007661007136600461143f565b61009c565b60405161005a91906114fd565b60006100966100918361177c565b610110565b92915050565b6100ca6040518060800160405280600060ff1681526020016000815260200160608152602001606081525090565b61010983838080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061030992505050565b9392505050565b600080826040015183608001518151811061012d5761012d61182b565b60200260200101519050600061017261016d8360408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b610503565b90508360600151600014156101f057835182516020840120146101eb5760405162461bcd60e51b815260206004820152602660248201527f7665726966795472696550726f6f6620726f6f74206e6f6465206861736820696044820152651b9d985b1a5960d21b60648201526084015b60405180910390fd5b6102aa565b60208251101561025d57600061020d6102088361056f565b6105cc565b855190915081146102575760405162461bcd60e51b81526020600482015260146024820152733b32b934b33caa3934b2a83937b7b3101e10199960611b60448201526064016101e2565b506102aa565b835182516020840120146102aa5760405162461bcd60e51b81526020600482015260146024820152737665726966795472696550726f6f6620656c736560601b60448201526064016101e2565b60006102b9826000015161061a565b905080601114156102d6576102cd8561069d565b95945050505050565b80600214156102e9576102cd8286610825565b60a0850151516102fe57506001949350505050565b506000949350505050565b6103376040518060800160405280600060ff1681526020016000815260200160608152602001606081525090565b8151600090607f60f81b90849083906103525761035261182b565b01602001516001600160f81b0319161161036a575060015b600061037e6103798584610afa565b610b46565b90506103a3816000815181106103965761039661182b565b60200260200101516105cc565b60ff16835280516103c190829060019081106103965761039661182b565b602084015280516103ec90829060029081106103df576103df61182b565b6020026020010151610c5b565b836040018190525060006104198260038151811061040c5761040c61182b565b6020026020010151610b46565b905080516001600160401b0381111561043457610434611601565b60405190808252806020026020018201604052801561049257816020015b61047f604051806060016040528060006001600160a01b0316815260200160608152602001606081525090565b8152602001906001900390816104525790505b50606085015260005b81518110156104fa576104c68282815181106104b9576104b961182b565b6020026020010151610cd8565b856060015182815181106104dc576104dc61182b565b602002602001018190525080806104f290611857565b91505061049b565b50505050919050565b604080516080810182526000918101828152606082018390528152602081019190915261052f82610e27565b61053857600080fd5b60006105478360200151610e60565b83602001516105569190611872565b6040805180820190915293845260208401525090919050565b604080518082019091526000808252602082015261058c82610edb565b61059557600080fd5b602082015160006105a582610eff565b90506105b18183611872565b60209485015260408051808201909152908152928301525090565b8051600090158015906105e157508151602110155b6105ea57600080fd5b6000806105f684610fa8565b8151919350915060208210156106125760208290036101000a90045b949350505050565b805160009061062b57506000919050565b60008061063b8460200151610e60565b846020015161064a9190611872565b90506000846000015185602001516106629190611872565b90505b808210156106945761067682610eff565b6106809083611872565b91508261068c81611857565b935050610665565b50909392505050565b60008082604001518360800151815181106106ba576106ba61182b565b6020026020010151905082602001515183606001511061074b57600061071f61070d6103798460408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b6010815181106103df576103df61182b565b90508360a001518051906020012081805190602001201415610745575060019392505050565b50610809565b600083602001518460600151815181106107675761076761182b565b016020015160f81c905060006107bb6107aa6103798560408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b83815181106103df576103df61182b565b905080516000146108065760208101518552606085018051600191906107e2908390611872565b905250608085018051600191906107fa908390611872565b9052506102cd85610110565b50505b60a08301515161081c5750600192915050565b50600092915050565b6000806108396108348561056f565b610c5b565b905060006108496108348661056f565b602083015190915060fc1c600281141561090d5760006001845161086d919061188a565b9050600061087f856001846000610fef565b9050600061089888602001518960600151856000610fef565b905084805190602001208860a00151805190602001201415610905578080519060200120828051906020012014156108d95760019650505050505050610096565b805160208201206108e9836110d3565b8051906020012014156109055760019650505050505050610096565b505050610ad8565b80600314156109c357600061092784600086516001610fef565b60208701516060880151815192935060009261095192919061094a90829061188a565b6000610fef565b905083805190602001208760a001518051906020012014156109bc5780805190602001208280519060200120141561099157600195505050505050610096565b805160208201206109a18361120a565b8051906020012014156109bc57600195505050505050610096565b5050610ad8565b80610a86576000600184516109d8919061188a565b905060006109ea856001846000610fef565b90506000610a0388602001518960600151856000610fef565b9050808051906020012082805190602001201480610a35575080516020820120610a2c836110d3565b80519060200120145b156109055760208501518852606088018051849190610a55908390611872565b90525060808801805160019190610a6d908390611872565b905250610a7988610110565b9650505050505050610096565b8060011415610aa057825160006109ea8582846001610fef565b60405162461bcd60e51b815260206004820152600d60248201526c24b73b30b634b210383937b7b360991b60448201526064016101e2565b60a085015151610aee5760019350505050610096565b60009350505050610096565b604080518082019091526000808252602082015260208301610b1c8382611872565b90506040518060400160405280848651610b36919061188a565b8152602001919091529392505050565b6060610b5182610e27565b610b5a57600080fd5b6000610b658361061a565b90506000816001600160401b03811115610b8157610b81611601565b604051908082528060200260200182016040528015610bc657816020015b6040805180820190915260008082526020820152815260200190600190039081610b9f5790505b5090506000610bd88560200151610e60565b8560200151610be79190611872565b90506000805b84811015610c5057610bfe83610eff565b9150604051806040016040528083815260200184815250848281518110610c2757610c2761182b565b6020908102919091010152610c3c8284611872565b925080610c4881611857565b915050610bed565b509195945050505050565b8051606090610c6957600080fd5b600080610c7584610fa8565b915091506000816001600160401b03811115610c9357610c93611601565b6040519080825280601f01601f191660200182016040528015610cbd576020820181803683370190505b50905060208101610ccf84828561136b565b50949350505050565b610d05604051806060016040528060006001600160a01b0316815260200160608152602001606081525090565b6000610d1083610b46565b9050610d3581600081518110610d2857610d2861182b565b60200260200101516113eb565b6001600160a01b031682528051600090610d5c908390600190811061040c5761040c61182b565b905080516001600160401b03811115610d7757610d77611601565b604051908082528060200260200182016040528015610da0578160200160208202803683370190505b50602084015260005b8151811015610e03576000610dc98383815181106103965761039661182b565b60001b90508085602001518381518110610de557610de561182b565b60209081029190910101525080610dfb81611857565b915050610da9565b50610e1a826002815181106103df576103df61182b565b6040840152509092915050565b8051600090610e3857506000919050565b6020820151805160001a9060c0821015610e56575060009392505050565b5060019392505050565b8051600090811a6080811015610e795750600092915050565b60b8811080610e94575060c08110801590610e94575060f881105b15610ea25750600192915050565b60c0811015610ecf57610eb7600160b86118a1565b610ec49060ff168261188a565b610109906001611872565b610eb7600160f86118a1565b80518051602082015160009291610ef191611872565b836020015110915050919050565b80516000908190811a6080811015610f1a5760019150610fa1565b60b8811015610f4057610f2e60808261188a565b610f39906001611872565b9150610fa1565b60c0811015610f6d5760b78103600185019450806020036101000a85510460018201810193505050610fa1565b60f8811015610f8157610f2e60c08261188a565b60f78103600185019450806020036101000a855104600182018101935050505b5092915050565b6000806000610fba8460200151610e60565b90506000818560200151610fce9190611872565b90506000828660000151610fe2919061188a565b9196919550909350505050565b60606000610ffe6020856118da565b9050600061100d6020866118ee565b611018906008611902565b6110249061010061188a565b9050602060008080886001600160401b0381111561104457611044611601565b6040519080825280601f01601f19166020018201604052801561106e576020820181803683370190505b5090508a8a019150871561109857818401516001600160fc1b031681850152602090930192600192505b825b868110156110b857828501518286015260209094019360010161109a565b5083820151851c851b84820152505050505050949350505050565b60606000825160026110e59190611902565b90506000816001600160401b0381111561110157611101611601565b6040519080825280601f01601f19166020018201604052801561112b576020820181803683370190505b50905060005b8451811015611202576000806111758784815181106111525761115261182b565b01602001516001600160f81b031916600481901c916001600160fc1b0390911690565b90925090508184611187856002611902565b815181106111975761119761182b565b60200101906001600160f81b031916908160001a90535080846111bb856002611902565b6111c6906001611872565b815181106111d6576111d661182b565b60200101906001600160f81b031916908160001a905350505080806111fa90611857565b915050611131565b509392505050565b6060600060018351600261121e9190611902565b611228919061188a565b90506000816001600160401b0381111561124457611244611601565b6040519080825280601f01601f19166020018201604052801561126e576020820181803683370190505b509050836000815181106112845761128461182b565b602001015160f81c60f81b816000815181106112a2576112a261182b565b60200101906001600160f81b031916908160001a90535060015b8451811015611202576000806112dd8784815181106111525761115261182b565b9092509050818460016112f1866002611902565b6112fb919061188a565b8151811061130b5761130b61182b565b60200101906001600160f81b031916908160001a905350808461132f856002611902565b8151811061133f5761133f61182b565b60200101906001600160f81b031916908160001a9053505050808061136390611857565b9150506112bc565b8061137557505050565b602081106113ad578251825261138c602084611872565b9250611399602083611872565b91506113a660208261188a565b9050611375565b80156113e657600060016113c283602061188a565b6113ce90610100611a05565b6113d8919061188a565b845184518216911916178352505b505050565b80516000906015146113fc57600080fd5b610096826105cc565b60006020828403121561141757600080fd5b81356001600160401b0381111561142d57600080fd5b820160c0818503121561010957600080fd5b6000806020838503121561145257600080fd5b82356001600160401b038082111561146957600080fd5b818501915085601f83011261147d57600080fd5b81358181111561148c57600080fd5b86602082850101111561149e57600080fd5b60209290920196919550909350505050565b6000815180845260005b818110156114d6576020818501810151868301820152016114ba565b818111156114e8576000602083870101525b50601f01601f19169290920160200192915050565b6000602080835260ff845116818401528084015160408181860152808601519150606060808187015261153360a08701846114b0565b81880151601f19888303810160808a015281518084529295509086019186860190600581901b870188016000805b838110156115ef5789830386018552865180516001600160a01b031684528b8101518c85018a905280518a8601819052908d0190849060808701905b808310156115bd5783518252928f019260019290920191908f019061159d565b50928c0151868403878e0152926115d481856114b0565b9650505050508a870196508a85019450600181019050611561565b50909c9b505050505050505050505050565b634e487b7160e01b600052604160045260246000fd5b60405160c081016001600160401b038111828210171561163957611639611601565b60405290565b604051601f8201601f191681016001600160401b038111828210171561166757611667611601565b604052919050565b600082601f83011261168057600080fd5b81356001600160401b0381111561169957611699611601565b6116ac601f8201601f191660200161163f565b8181528460208386010111156116c157600080fd5b816020850160208301376000918101602001919091529392505050565b600082601f8301126116ef57600080fd5b813560206001600160401b038083111561170b5761170b611601565b8260051b61171a83820161163f565b938452858101830193838101908886111561173457600080fd5b84880192505b85831015611770578235848111156117525760008081fd5b6117608a87838c010161166f565b835250918401919084019061173a565b98975050505050505050565b600060c0823603121561178e57600080fd5b611796611617565b8235815260208301356001600160401b03808211156117b457600080fd5b6117c03683870161166f565b602084015260408501359150808211156117d957600080fd5b6117e5368387016116de565b6040840152606085013560608401526080850135608084015260a085013591508082111561181257600080fd5b5061181f3682860161166f565b60a08301525092915050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060001982141561186b5761186b611841565b5060010190565b6000821982111561188557611885611841565b500190565b60008282101561189c5761189c611841565b500390565b600060ff821660ff8416808210156118bb576118bb611841565b90039392505050565b634e487b7160e01b600052601260045260246000fd5b6000826118e9576118e96118c4565b500490565b6000826118fd576118fd6118c4565b500690565b600081600019048311821515161561191c5761191c611841565b500290565b600181815b8085111561195c57816000190482111561194257611942611841565b8085161561194f57918102915b93841c9390800290611926565b509250929050565b60008261197357506001610096565b8161198057506000610096565b816001811461199657600281146119a0576119bc565b6001915050610096565b60ff8411156119b1576119b1611841565b50506001821b610096565b5060208310610133831016604e8410600b84101617156119df575081810a610096565b6119e98383611921565b80600019048211156119fd576119fd611841565b029392505050565b6000610109838361196456fea26469706673582212208ebe0c5a8594d94aa349c56d1a38b28ce155d29527be7cd54b80e5294241b2e964736f6c634300080a0033",
"bytecode": "0x608060405234801561001057600080fd5b50611a47806100206000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c80632af4108b1461003b578063aa3eb63a14610063575b600080fd5b61004e610049366004611405565b610083565b60405190151581526020015b60405180910390f35b61007661007136600461143f565b61009c565b60405161005a91906114fd565b60006100966100918361177c565b610110565b92915050565b6100ca6040518060800160405280600060ff1681526020016000815260200160608152602001606081525090565b61010983838080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061030992505050565b9392505050565b600080826040015183608001518151811061012d5761012d61182b565b60200260200101519050600061017261016d8360408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b610503565b90508360600151600014156101f057835182516020840120146101eb5760405162461bcd60e51b815260206004820152602660248201527f7665726966795472696550726f6f6620726f6f74206e6f6465206861736820696044820152651b9d985b1a5960d21b60648201526084015b60405180910390fd5b6102aa565b60208251101561025d57600061020d6102088361056f565b6105cc565b855190915081146102575760405162461bcd60e51b81526020600482015260146024820152733b32b934b33caa3934b2a83937b7b3101e10199960611b60448201526064016101e2565b506102aa565b835182516020840120146102aa5760405162461bcd60e51b81526020600482015260146024820152737665726966795472696550726f6f6620656c736560601b60448201526064016101e2565b60006102b9826000015161061a565b905080601114156102d6576102cd8561069d565b95945050505050565b80600214156102e9576102cd8286610825565b60a0850151516102fe57506001949350505050565b506000949350505050565b6103376040518060800160405280600060ff1681526020016000815260200160608152602001606081525090565b8151600090607f60f81b90849083906103525761035261182b565b01602001516001600160f81b0319161161036a575060015b600061037e6103798584610afa565b610b46565b90506103a3816000815181106103965761039661182b565b60200260200101516105cc565b60ff16835280516103c190829060019081106103965761039661182b565b602084015280516103ec90829060029081106103df576103df61182b565b6020026020010151610c5b565b836040018190525060006104198260038151811061040c5761040c61182b565b6020026020010151610b46565b905080516001600160401b0381111561043457610434611601565b60405190808252806020026020018201604052801561049257816020015b61047f604051806060016040528060006001600160a01b0316815260200160608152602001606081525090565b8152602001906001900390816104525790505b50606085015260005b81518110156104fa576104c68282815181106104b9576104b961182b565b6020026020010151610cd8565b856060015182815181106104dc576104dc61182b565b602002602001018190525080806104f290611857565b91505061049b565b50505050919050565b604080516080810182526000918101828152606082018390528152602081019190915261052f82610e27565b61053857600080fd5b60006105478360200151610e60565b83602001516105569190611872565b6040805180820190915293845260208401525090919050565b604080518082019091526000808252602082015261058c82610edb565b61059557600080fd5b602082015160006105a582610eff565b90506105b18183611872565b60209485015260408051808201909152908152928301525090565b8051600090158015906105e157508151602110155b6105ea57600080fd5b6000806105f684610fa8565b8151919350915060208210156106125760208290036101000a90045b949350505050565b805160009061062b57506000919050565b60008061063b8460200151610e60565b846020015161064a9190611872565b90506000846000015185602001516106629190611872565b90505b808210156106945761067682610eff565b6106809083611872565b91508261068c81611857565b935050610665565b50909392505050565b60008082604001518360800151815181106106ba576106ba61182b565b6020026020010151905082602001515183606001511061074b57600061071f61070d6103798460408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b6010815181106103df576103df61182b565b90508360a001518051906020012081805190602001201415610745575060019392505050565b50610809565b600083602001518460600151815181106107675761076761182b565b016020015160f81c905060006107bb6107aa6103798560408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b83815181106103df576103df61182b565b905080516000146108065760208101518552606085018051600191906107e2908390611872565b905250608085018051600191906107fa908390611872565b9052506102cd85610110565b50505b60a08301515161081c5750600192915050565b50600092915050565b6000806108396108348561056f565b610c5b565b905060006108496108348661056f565b602083015190915060fc1c600281141561090d5760006001845161086d919061188a565b9050600061087f856001846000610fef565b9050600061089888602001518960600151856000610fef565b905084805190602001208860a00151805190602001201415610905578080519060200120828051906020012014156108d95760019650505050505050610096565b805160208201206108e9836110d3565b8051906020012014156109055760019650505050505050610096565b505050610ad8565b80600314156109c357600061092784600086516001610fef565b60208701516060880151815192935060009261095192919061094a90829061188a565b6000610fef565b905083805190602001208760a001518051906020012014156109bc5780805190602001208280519060200120141561099157600195505050505050610096565b805160208201206109a18361120a565b8051906020012014156109bc57600195505050505050610096565b5050610ad8565b80610a86576000600184516109d8919061188a565b905060006109ea856001846000610fef565b90506000610a0388602001518960600151856000610fef565b9050808051906020012082805190602001201480610a35575080516020820120610a2c836110d3565b80519060200120145b156109055760208501518852606088018051849190610a55908390611872565b90525060808801805160019190610a6d908390611872565b905250610a7988610110565b9650505050505050610096565b8060011415610aa057825160006109ea8582846001610fef565b60405162461bcd60e51b815260206004820152600d60248201526c24b73b30b634b210383937b7b360991b60448201526064016101e2565b60a085015151610aee5760019350505050610096565b60009350505050610096565b604080518082019091526000808252602082015260208301610b1c8382611872565b90506040518060400160405280848651610b36919061188a565b8152602001919091529392505050565b6060610b5182610e27565b610b5a57600080fd5b6000610b658361061a565b90506000816001600160401b03811115610b8157610b81611601565b604051908082528060200260200182016040528015610bc657816020015b6040805180820190915260008082526020820152815260200190600190039081610b9f5790505b5090506000610bd88560200151610e60565b8560200151610be79190611872565b90506000805b84811015610c5057610bfe83610eff565b9150604051806040016040528083815260200184815250848281518110610c2757610c2761182b565b6020908102919091010152610c3c8284611872565b925080610c4881611857565b915050610bed565b509195945050505050565b8051606090610c6957600080fd5b600080610c7584610fa8565b915091506000816001600160401b03811115610c9357610c93611601565b6040519080825280601f01601f191660200182016040528015610cbd576020820181803683370190505b50905060208101610ccf84828561136b565b50949350505050565b610d05604051806060016040528060006001600160a01b0316815260200160608152602001606081525090565b6000610d1083610b46565b9050610d3581600081518110610d2857610d2861182b565b60200260200101516113eb565b6001600160a01b031682528051600090610d5c908390600190811061040c5761040c61182b565b905080516001600160401b03811115610d7757610d77611601565b604051908082528060200260200182016040528015610da0578160200160208202803683370190505b50602084015260005b8151811015610e03576000610dc98383815181106103965761039661182b565b60001b90508085602001518381518110610de557610de561182b565b60209081029190910101525080610dfb81611857565b915050610da9565b50610e1a826002815181106103df576103df61182b565b6040840152509092915050565b8051600090610e3857506000919050565b6020820151805160001a9060c0821015610e56575060009392505050565b5060019392505050565b8051600090811a6080811015610e795750600092915050565b60b8811080610e94575060c08110801590610e94575060f881105b15610ea25750600192915050565b60c0811015610ecf57610eb7600160b86118a1565b610ec49060ff168261188a565b610109906001611872565b610eb7600160f86118a1565b80518051602082015160009291610ef191611872565b836020015110915050919050565b80516000908190811a6080811015610f1a5760019150610fa1565b60b8811015610f4057610f2e60808261188a565b610f39906001611872565b9150610fa1565b60c0811015610f6d5760b78103600185019450806020036101000a85510460018201810193505050610fa1565b60f8811015610f8157610f2e60c08261188a565b60f78103600185019450806020036101000a855104600182018101935050505b5092915050565b6000806000610fba8460200151610e60565b90506000818560200151610fce9190611872565b90506000828660000151610fe2919061188a565b9196919550909350505050565b60606000610ffe6020856118da565b9050600061100d6020866118ee565b611018906008611902565b6110249061010061188a565b9050602060008080886001600160401b0381111561104457611044611601565b6040519080825280601f01601f19166020018201604052801561106e576020820181803683370190505b5090508a8a019150871561109857818401516001600160fc1b031681850152602090930192600192505b825b868110156110b857828501518286015260209094019360010161109a565b5083820151851c851b84820152505050505050949350505050565b60606000825160026110e59190611902565b90506000816001600160401b0381111561110157611101611601565b6040519080825280601f01601f19166020018201604052801561112b576020820181803683370190505b50905060005b8451811015611202576000806111758784815181106111525761115261182b565b01602001516001600160f81b031916600481901c916001600160fc1b0390911690565b90925090508184611187856002611902565b815181106111975761119761182b565b60200101906001600160f81b031916908160001a90535080846111bb856002611902565b6111c6906001611872565b815181106111d6576111d661182b565b60200101906001600160f81b031916908160001a905350505080806111fa90611857565b915050611131565b509392505050565b6060600060018351600261121e9190611902565b611228919061188a565b90506000816001600160401b0381111561124457611244611601565b6040519080825280601f01601f19166020018201604052801561126e576020820181803683370190505b509050836000815181106112845761128461182b565b602001015160f81c60f81b816000815181106112a2576112a261182b565b60200101906001600160f81b031916908160001a90535060015b8451811015611202576000806112dd8784815181106111525761115261182b565b9092509050818460016112f1866002611902565b6112fb919061188a565b8151811061130b5761130b61182b565b60200101906001600160f81b031916908160001a905350808461132f856002611902565b8151811061133f5761133f61182b565b60200101906001600160f81b031916908160001a9053505050808061136390611857565b9150506112bc565b8061137557505050565b602081106113ad578251825261138c602084611872565b9250611399602083611872565b91506113a660208261188a565b9050611375565b80156113e657600060016113c283602061188a565b6113ce90610100611a05565b6113d8919061188a565b845184518216911916178352505b505050565b80516000906015146113fc57600080fd5b610096826105cc565b60006020828403121561141757600080fd5b81356001600160401b0381111561142d57600080fd5b820160c0818503121561010957600080fd5b6000806020838503121561145257600080fd5b82356001600160401b038082111561146957600080fd5b818501915085601f83011261147d57600080fd5b81358181111561148c57600080fd5b86602082850101111561149e57600080fd5b60209290920196919550909350505050565b6000815180845260005b818110156114d6576020818501810151868301820152016114ba565b818111156114e8576000602083870101525b50601f01601f19169290920160200192915050565b6000602080835260ff845116818401528084015160408181860152808601519150606060808187015261153360a08701846114b0565b81880151601f19888303810160808a015281518084529295509086019186860190600581901b870188016000805b838110156115ef5789830386018552865180516001600160a01b031684528b8101518c85018a905280518a8601819052908d0190849060808701905b808310156115bd5783518252928f019260019290920191908f019061159d565b50928c0151868403878e0152926115d481856114b0565b9650505050508a870196508a85019450600181019050611561565b50909c9b505050505050505050505050565b634e487b7160e01b600052604160045260246000fd5b60405160c081016001600160401b038111828210171561163957611639611601565b60405290565b604051601f8201601f191681016001600160401b038111828210171561166757611667611601565b604052919050565b600082601f83011261168057600080fd5b81356001600160401b0381111561169957611699611601565b6116ac601f8201601f191660200161163f565b8181528460208386010111156116c157600080fd5b816020850160208301376000918101602001919091529392505050565b600082601f8301126116ef57600080fd5b813560206001600160401b038083111561170b5761170b611601565b8260051b61171a83820161163f565b938452858101830193838101908886111561173457600080fd5b84880192505b85831015611770578235848111156117525760008081fd5b6117608a87838c010161166f565b835250918401919084019061173a565b98975050505050505050565b600060c0823603121561178e57600080fd5b611796611617565b8235815260208301356001600160401b03808211156117b457600080fd5b6117c03683870161166f565b602084015260408501359150808211156117d957600080fd5b6117e5368387016116de565b6040840152606085013560608401526080850135608084015260a085013591508082111561181257600080fd5b5061181f3682860161166f565b60a08301525092915050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060001982141561186b5761186b611841565b5060010190565b6000821982111561188557611885611841565b500190565b60008282101561189c5761189c611841565b500390565b600060ff821660ff8416808210156118bb576118bb611841565b90039392505050565b634e487b7160e01b600052601260045260246000fd5b6000826118e9576118e96118c4565b500490565b6000826118fd576118fd6118c4565b500690565b600081600019048311821515161561191c5761191c611841565b500290565b600181815b8085111561195c57816000190482111561194257611942611841565b8085161561194f57918102915b93841c9390800290611926565b509250929050565b60008261197357506001610096565b8161198057506000610096565b816001811461199657600281146119a0576119bc565b6001915050610096565b60ff8411156119b1576119b1611841565b50506001821b610096565b5060208310610133831016604e8410600b84101617156119df575081810a610096565b6119e98383611921565b80600019048211156119fd576119fd611841565b029392505050565b6000610109838361196456fea2646970667358221220b466fbf83915a98f81c6859ebbd8117db04bf0485c818ca73cd7b26837e21cbc64736f6c634300080a0033",
"deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100365760003560e01c80632af4108b1461003b578063aa3eb63a14610063575b600080fd5b61004e610049366004611405565b610083565b60405190151581526020015b60405180910390f35b61007661007136600461143f565b61009c565b60405161005a91906114fd565b60006100966100918361177c565b610110565b92915050565b6100ca6040518060800160405280600060ff1681526020016000815260200160608152602001606081525090565b61010983838080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061030992505050565b9392505050565b600080826040015183608001518151811061012d5761012d61182b565b60200260200101519050600061017261016d8360408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b610503565b90508360600151600014156101f057835182516020840120146101eb5760405162461bcd60e51b815260206004820152602660248201527f7665726966795472696550726f6f6620726f6f74206e6f6465206861736820696044820152651b9d985b1a5960d21b60648201526084015b60405180910390fd5b6102aa565b60208251101561025d57600061020d6102088361056f565b6105cc565b855190915081146102575760405162461bcd60e51b81526020600482015260146024820152733b32b934b33caa3934b2a83937b7b3101e10199960611b60448201526064016101e2565b506102aa565b835182516020840120146102aa5760405162461bcd60e51b81526020600482015260146024820152737665726966795472696550726f6f6620656c736560601b60448201526064016101e2565b60006102b9826000015161061a565b905080601114156102d6576102cd8561069d565b95945050505050565b80600214156102e9576102cd8286610825565b60a0850151516102fe57506001949350505050565b506000949350505050565b6103376040518060800160405280600060ff1681526020016000815260200160608152602001606081525090565b8151600090607f60f81b90849083906103525761035261182b565b01602001516001600160f81b0319161161036a575060015b600061037e6103798584610afa565b610b46565b90506103a3816000815181106103965761039661182b565b60200260200101516105cc565b60ff16835280516103c190829060019081106103965761039661182b565b602084015280516103ec90829060029081106103df576103df61182b565b6020026020010151610c5b565b836040018190525060006104198260038151811061040c5761040c61182b565b6020026020010151610b46565b905080516001600160401b0381111561043457610434611601565b60405190808252806020026020018201604052801561049257816020015b61047f604051806060016040528060006001600160a01b0316815260200160608152602001606081525090565b8152602001906001900390816104525790505b50606085015260005b81518110156104fa576104c68282815181106104b9576104b961182b565b6020026020010151610cd8565b856060015182815181106104dc576104dc61182b565b602002602001018190525080806104f290611857565b91505061049b565b50505050919050565b604080516080810182526000918101828152606082018390528152602081019190915261052f82610e27565b61053857600080fd5b60006105478360200151610e60565b83602001516105569190611872565b6040805180820190915293845260208401525090919050565b604080518082019091526000808252602082015261058c82610edb565b61059557600080fd5b602082015160006105a582610eff565b90506105b18183611872565b60209485015260408051808201909152908152928301525090565b8051600090158015906105e157508151602110155b6105ea57600080fd5b6000806105f684610fa8565b8151919350915060208210156106125760208290036101000a90045b949350505050565b805160009061062b57506000919050565b60008061063b8460200151610e60565b846020015161064a9190611872565b90506000846000015185602001516106629190611872565b90505b808210156106945761067682610eff565b6106809083611872565b91508261068c81611857565b935050610665565b50909392505050565b60008082604001518360800151815181106106ba576106ba61182b565b6020026020010151905082602001515183606001511061074b57600061071f61070d6103798460408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b6010815181106103df576103df61182b565b90508360a001518051906020012081805190602001201415610745575060019392505050565b50610809565b600083602001518460600151815181106107675761076761182b565b016020015160f81c905060006107bb6107aa6103798560408051808201825260008082526020918201528151808301909252825182529182019181019190915290565b83815181106103df576103df61182b565b905080516000146108065760208101518552606085018051600191906107e2908390611872565b905250608085018051600191906107fa908390611872565b9052506102cd85610110565b50505b60a08301515161081c5750600192915050565b50600092915050565b6000806108396108348561056f565b610c5b565b905060006108496108348661056f565b602083015190915060fc1c600281141561090d5760006001845161086d919061188a565b9050600061087f856001846000610fef565b9050600061089888602001518960600151856000610fef565b905084805190602001208860a00151805190602001201415610905578080519060200120828051906020012014156108d95760019650505050505050610096565b805160208201206108e9836110d3565b8051906020012014156109055760019650505050505050610096565b505050610ad8565b80600314156109c357600061092784600086516001610fef565b60208701516060880151815192935060009261095192919061094a90829061188a565b6000610fef565b905083805190602001208760a001518051906020012014156109bc5780805190602001208280519060200120141561099157600195505050505050610096565b805160208201206109a18361120a565b8051906020012014156109bc57600195505050505050610096565b5050610ad8565b80610a86576000600184516109d8919061188a565b905060006109ea856001846000610fef565b90506000610a0388602001518960600151856000610fef565b9050808051906020012082805190602001201480610a35575080516020820120610a2c836110d3565b80519060200120145b156109055760208501518852606088018051849190610a55908390611872565b90525060808801805160019190610a6d908390611872565b905250610a7988610110565b9650505050505050610096565b8060011415610aa057825160006109ea8582846001610fef565b60405162461bcd60e51b815260206004820152600d60248201526c24b73b30b634b210383937b7b360991b60448201526064016101e2565b60a085015151610aee5760019350505050610096565b60009350505050610096565b604080518082019091526000808252602082015260208301610b1c8382611872565b90506040518060400160405280848651610b36919061188a565b8152602001919091529392505050565b6060610b5182610e27565b610b5a57600080fd5b6000610b658361061a565b90506000816001600160401b03811115610b8157610b81611601565b604051908082528060200260200182016040528015610bc657816020015b6040805180820190915260008082526020820152815260200190600190039081610b9f5790505b5090506000610bd88560200151610e60565b8560200151610be79190611872565b90506000805b84811015610c5057610bfe83610eff565b9150604051806040016040528083815260200184815250848281518110610c2757610c2761182b565b6020908102919091010152610c3c8284611872565b925080610c4881611857565b915050610bed565b509195945050505050565b8051606090610c6957600080fd5b600080610c7584610fa8565b915091506000816001600160401b03811115610c9357610c93611601565b6040519080825280601f01601f191660200182016040528015610cbd576020820181803683370190505b50905060208101610ccf84828561136b565b50949350505050565b610d05604051806060016040528060006001600160a01b0316815260200160608152602001606081525090565b6000610d1083610b46565b9050610d3581600081518110610d2857610d2861182b565b60200260200101516113eb565b6001600160a01b031682528051600090610d5c908390600190811061040c5761040c61182b565b905080516001600160401b03811115610d7757610d77611601565b604051908082528060200260200182016040528015610da0578160200160208202803683370190505b50602084015260005b8151811015610e03576000610dc98383815181106103965761039661182b565b60001b90508085602001518381518110610de557610de561182b565b60209081029190910101525080610dfb81611857565b915050610da9565b50610e1a826002815181106103df576103df61182b565b6040840152509092915050565b8051600090610e3857506000919050565b6020820151805160001a9060c0821015610e56575060009392505050565b5060019392505050565b8051600090811a6080811015610e795750600092915050565b60b8811080610e94575060c08110801590610e94575060f881105b15610ea25750600192915050565b60c0811015610ecf57610eb7600160b86118a1565b610ec49060ff168261188a565b610109906001611872565b610eb7600160f86118a1565b80518051602082015160009291610ef191611872565b836020015110915050919050565b80516000908190811a6080811015610f1a5760019150610fa1565b60b8811015610f4057610f2e60808261188a565b610f39906001611872565b9150610fa1565b60c0811015610f6d5760b78103600185019450806020036101000a85510460018201810193505050610fa1565b60f8811015610f8157610f2e60c08261188a565b60f78103600185019450806020036101000a855104600182018101935050505b5092915050565b6000806000610fba8460200151610e60565b90506000818560200151610fce9190611872565b90506000828660000151610fe2919061188a565b9196919550909350505050565b60606000610ffe6020856118da565b9050600061100d6020866118ee565b611018906008611902565b6110249061010061188a565b9050602060008080886001600160401b0381111561104457611044611601565b6040519080825280601f01601f19166020018201604052801561106e576020820181803683370190505b5090508a8a019150871561109857818401516001600160fc1b031681850152602090930192600192505b825b868110156110b857828501518286015260209094019360010161109a565b5083820151851c851b84820152505050505050949350505050565b60606000825160026110e59190611902565b90506000816001600160401b0381111561110157611101611601565b6040519080825280601f01601f19166020018201604052801561112b576020820181803683370190505b50905060005b8451811015611202576000806111758784815181106111525761115261182b565b01602001516001600160f81b031916600481901c916001600160fc1b0390911690565b90925090508184611187856002611902565b815181106111975761119761182b565b60200101906001600160f81b031916908160001a90535080846111bb856002611902565b6111c6906001611872565b815181106111d6576111d661182b565b60200101906001600160f81b031916908160001a905350505080806111fa90611857565b915050611131565b509392505050565b6060600060018351600261121e9190611902565b611228919061188a565b90506000816001600160401b0381111561124457611244611601565b6040519080825280601f01601f19166020018201604052801561126e576020820181803683370190505b509050836000815181106112845761128461182b565b602001015160f81c60f81b816000815181106112a2576112a261182b565b60200101906001600160f81b031916908160001a90535060015b8451811015611202576000806112dd8784815181106111525761115261182b565b9092509050818460016112f1866002611902565b6112fb919061188a565b8151811061130b5761130b61182b565b60200101906001600160f81b031916908160001a905350808461132f856002611902565b8151811061133f5761133f61182b565b60200101906001600160f81b031916908160001a9053505050808061136390611857565b9150506112bc565b8061137557505050565b602081106113ad578251825261138c602084611872565b9250611399602083611872565b91506113a660208261188a565b9050611375565b80156113e657600060016113c283602061188a565b6113ce90610100611a05565b6113d8919061188a565b845184518216911916178352505b505050565b80516000906015146113fc57600080fd5b610096826105cc565b60006020828403121561141757600080fd5b81356001600160401b0381111561142d57600080fd5b820160c0818503121561010957600080fd5b6000806020838503121561145257600080fd5b82356001600160401b038082111561146957600080fd5b818501915085601f83011261147d57600080fd5b81358181111561148c57600080fd5b86602082850101111561149e57600080fd5b60209290920196919550909350505050565b6000815180845260005b818110156114d6576020818501810151868301820152016114ba565b818111156114e8576000602083870101525b50601f01601f19169290920160200192915050565b6000602080835260ff845116818401528084015160408181860152808601519150606060808187015261153360a08701846114b0565b81880151601f19888303810160808a015281518084529295509086019186860190600581901b870188016000805b838110156115ef5789830386018552865180516001600160a01b031684528b8101518c85018a905280518a8601819052908d0190849060808701905b808310156115bd5783518252928f019260019290920191908f019061159d565b50928c0151868403878e0152926115d481856114b0565b9650505050508a870196508a85019450600181019050611561565b50909c9b505050505050505050505050565b634e487b7160e01b600052604160045260246000fd5b60405160c081016001600160401b038111828210171561163957611639611601565b60405290565b604051601f8201601f191681016001600160401b038111828210171561166757611667611601565b604052919050565b600082601f83011261168057600080fd5b81356001600160401b0381111561169957611699611601565b6116ac601f8201601f191660200161163f565b8181528460208386010111156116c157600080fd5b816020850160208301376000918101602001919091529392505050565b600082601f8301126116ef57600080fd5b813560206001600160401b038083111561170b5761170b611601565b8260051b61171a83820161163f565b938452858101830193838101908886111561173457600080fd5b84880192505b85831015611770578235848111156117525760008081fd5b6117608a87838c010161166f565b835250918401919084019061173a565b98975050505050505050565b600060c0823603121561178e57600080fd5b611796611617565b8235815260208301356001600160401b03808211156117b457600080fd5b6117c03683870161166f565b602084015260408501359150808211156117d957600080fd5b6117e5368387016116de565b6040840152606085013560608401526080850135608084015260a085013591508082111561181257600080fd5b5061181f3682860161166f565b60a08301525092915050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060001982141561186b5761186b611841565b5060010190565b6000821982111561188557611885611841565b500190565b60008282101561189c5761189c611841565b500390565b600060ff821660ff8416808210156118bb576118bb611841565b90039392505050565b634e487b7160e01b600052601260045260246000fd5b6000826118e9576118e96118c4565b500490565b6000826118fd576118fd6118c4565b500690565b600081600019048311821515161561191c5761191c611841565b500290565b600181815b8085111561195c57816000190482111561194257611942611841565b8085161561194f57918102915b93841c9390800290611926565b509250929050565b60008261197357506001610096565b8161198057506000610096565b816001811461199657600281146119a0576119bc565b6001915050610096565b60ff8411156119b1576119b1611841565b50506001821b610096565b5060208310610133831016604e8410600b84101617156119df575081810a610096565b6119e98383611921565b80600019048211156119fd576119fd611841565b029392505050565b6000610109838361196456fea2646970667358221220b466fbf83915a98f81c6859ebbd8117db04bf0485c818ca73cd7b26837e21cbc64736f6c634300080a0033",
"linkReferences": {},
"deployedLinkReferences": {}
}

@@ -36,3 +36,3 @@ import logger from 'js-logger';

const logLevel = logger['info'.toUpperCase()];
const logLevel = logger[(process.env.LOG_LEVEL || 'info').toUpperCase()];
logger.setLevel(logLevel);

@@ -39,0 +39,0 @@

@@ -92,3 +92,7 @@ /* eslint-disable @typescript-eslint/no-explicit-any */

if (lastProcessedA < checkpointBlockA || lastProcessedB < checkpointBlockB) hasMore = true;
if (
(lastProcessedA && lastProcessedA < checkpointBlockA) ||
(lastProcessedB && lastProcessedB < checkpointBlockB)
)
hasMore = true;

@@ -116,2 +120,3 @@ const txsA = eventsA.map((_) => _.transactionHash);

]);
txsA.length && logger.info('relaying:', { bridgeA, relayHash: relays?.[0]?.relayTxHash, txs: txsA.length });

@@ -131,7 +136,7 @@ txsB.length && logger.info('relaying:', { bridgeB, relayHash: relays?.[1]?.relayTxHash, txs: txsB.length });

if (lastProcessedA && (relays[0]?.status === 1 || txsA.length === 0)) {
if (lastProcessedA && (results[0]?.status === 1 || txsA.length === 0)) {
lastProcessed[bridgeA] = lastProcessedA;
logger.info('relay success updating last processed block:', { bridgeA, lastProcessedA, fetchEventsFromBlockA });
}
if (lastProcessedB && (relays[1]?.status === 1 || txsB.length === 0)) {
if (lastProcessedB && (results[1]?.status === 1 || txsB.length === 0)) {
lastProcessed[bridgeB] = lastProcessedB;

@@ -165,5 +170,6 @@ logger.info('relay success updating last processed block:', { bridgeB, lastProcessedB, fetchEventsFromBlockB });

});
fs.writeFileSync(path.join(configDir, 'lastprocessed.json'), JSON.stringify(lastProcessed));
}
fs.writeFileSync(path.join(configDir, 'lastprocessed.json'), JSON.stringify(lastProcessed));
//if one of the bridges has possibly more requests we didnt process run again immediatly, otherwise wait for interval

@@ -170,0 +176,0 @@ if (shouldRun) {

@@ -32,3 +32,3 @@ import { JsonRpcBatchProvider, JsonRpcProvider } from '@ethersproject/providers';

rpcs = undefined,
logger?: typeof Logger,
logger = Logger,
) {

@@ -75,3 +75,8 @@ this.registryContract = new ethers.Contract(registryAddress, RegistryABI, new JsonRpcBatchProvider(registryRpc));

);
// console.log({ bestCheckpoint });
this.logger.debug('getCheckpointBlockFromEvents', {
sourceChainId,
checkpointBlockNumber,
bestCheckpoint,
checkpointArgs: bestCheckpoint[0].args,
});
return (

@@ -121,2 +126,3 @@ bestCheckpoint && {

}
this.logger.debug('got checkpoint block:', { checkPointBlockNumber, getCheckpointFromEvents, signedCheckPoint });
if (!signedCheckPoint) throw new Error(`checkpoint block ${checkPointBlockNumber} does not exists yet`);

@@ -130,2 +136,4 @@ }

);
parentAndCheckpointBlocks.forEach((b) => this.logger.debug('getBlocksToSubmit parentAndCheckpointBlocks:', b));
const checkpointBlock = last(parentAndCheckpointBlocks);

@@ -152,2 +160,3 @@

);
this.logger.debug('getChainBlockHeaders', { sourceChainId, startBlock, endBlock, fetchedBlocks: blocks.length });
return blocks.map((_) => SignUtils.prepareBlock(_, sourceChainId));

@@ -176,3 +185,8 @@ };

});
this.logger.debug('submitBlocksAndExecute got blocks to submit:', {
checkPointBlockNumber,
signedBlock,
parentAndCheckpointBlocks: parentAndCheckpointBlocks.length,
receiptProofs,
});
const blockToReceipts = groupBy(receiptProofs, (_) => Number(_.receipt.blockNumber));

@@ -219,2 +233,4 @@ const mptProofs = Object.entries(blockToReceipts).map(([k, receiptProofs]) => {

// });
mptProofs.forEach((proof) => this.logger.debug('submitBlocksAndExecute proof:', JSON.stringify(proof)));
return targetBridgeContract

@@ -221,0 +237,0 @@ .connect(signer)

@@ -179,3 +179,2 @@ import * as ethers from 'ethers';

const blockHash = ethers.utils.keccak256(rlpHeader);
// console.log({block,header,rlpHeader, blockHash})
if (blockHash !== block.hash) {

@@ -208,3 +207,3 @@ throw new Error(`rlp hash doesnt match expected blockhash ${block.number}`);

export const receiptProof = async (txHash: string, provider: ethers.providers.JsonRpcProvider, chainId?: number) => {
export const receiptProof = async (txHash: string, provider: ethers.providers.JsonRpcProvider, chainId: number) => {
const targetReceipt = await provider.send('eth_getTransactionReceipt', [txHash]);

@@ -211,0 +210,0 @@ if (!targetReceipt) {

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc