@keep-network/tbtc-v2 1.6.0-dev.15 → 1.6.0-dev.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/artifacts/BLS.json +1 -1
- package/artifacts/Bank.json +3 -3
- package/artifacts/BeaconAuthorization.json +1 -1
- package/artifacts/BeaconDkg.json +1 -1
- package/artifacts/BeaconDkgValidator.json +1 -1
- package/artifacts/BeaconInactivity.json +1 -1
- package/artifacts/BeaconSortitionPool.json +3 -3
- package/artifacts/Bridge.json +5 -5
- package/artifacts/BridgeGovernance.json +2 -2
- package/artifacts/BridgeGovernanceParameters.json +2 -2
- package/artifacts/Deposit.json +2 -2
- package/artifacts/DepositSweep.json +2 -2
- package/artifacts/DonationVault.json +3 -3
- package/artifacts/EcdsaDkgValidator.json +1 -1
- package/artifacts/EcdsaInactivity.json +1 -1
- package/artifacts/EcdsaSortitionPool.json +3 -3
- package/artifacts/Fraud.json +2 -2
- package/artifacts/LightRelay.json +18 -18
- package/artifacts/LightRelayMaintainerProxy.json +8 -8
- package/artifacts/MaintainerProxy.json +19 -19
- package/artifacts/MovingFunds.json +2 -2
- package/artifacts/NuCypherToken.json +2 -2
- package/artifacts/RandomBeacon.json +2 -2
- package/artifacts/RandomBeaconChaosnet.json +2 -2
- package/artifacts/RandomBeaconGovernance.json +2 -2
- package/artifacts/Redemption.json +2 -2
- package/artifacts/ReimbursementPool.json +2 -2
- package/artifacts/T.json +2 -2
- package/artifacts/TBTC.json +3 -3
- package/artifacts/TBTCToken.json +3 -3
- package/artifacts/TBTCVault.json +23 -23
- package/artifacts/TokenStaking.json +1 -1
- package/artifacts/TokenholderGovernor.json +9 -9
- package/artifacts/TokenholderTimelock.json +8 -8
- package/artifacts/VendingMachine.json +3 -3
- package/artifacts/VendingMachineNuCypher.json +1 -1
- package/artifacts/VendingMachineV2.json +3 -3
- package/artifacts/VendingMachineV3.json +3 -3
- package/artifacts/WalletProposalValidator.json +2 -2
- package/artifacts/WalletRegistry.json +5 -5
- package/artifacts/WalletRegistryGovernance.json +2 -2
- package/artifacts/Wallets.json +2 -2
- package/artifacts/solcInputs/{1788e81ec23cfa014c2c13441f296723.json → 8bdb4098420884547fe701093440e1b8.json} +12 -0
- package/build/contracts/GovernanceUtils.sol/GovernanceUtils.dbg.json +1 -1
- package/build/contracts/bank/Bank.sol/Bank.dbg.json +1 -1
- package/build/contracts/bank/IReceiveBalanceApproval.sol/IReceiveBalanceApproval.dbg.json +1 -1
- package/build/contracts/bridge/BitcoinTx.sol/BitcoinTx.dbg.json +1 -1
- package/build/contracts/bridge/Bridge.sol/Bridge.dbg.json +1 -1
- package/build/contracts/bridge/BridgeGovernanceParameters.sol/BridgeGovernanceParameters.dbg.json +1 -1
- package/build/contracts/bridge/BridgeState.sol/BridgeState.dbg.json +1 -1
- package/build/contracts/bridge/Deposit.sol/Deposit.dbg.json +1 -1
- package/build/contracts/bridge/DepositSweep.sol/DepositSweep.dbg.json +1 -1
- package/build/contracts/bridge/EcdsaLib.sol/EcdsaLib.dbg.json +1 -1
- package/build/contracts/bridge/Fraud.sol/Fraud.dbg.json +1 -1
- package/build/contracts/bridge/Heartbeat.sol/Heartbeat.dbg.json +1 -1
- package/build/contracts/bridge/IRelay.sol/IRelay.dbg.json +1 -1
- package/build/contracts/bridge/MovingFunds.sol/MovingFunds.dbg.json +1 -1
- package/build/contracts/bridge/Redemption.sol/OutboundTx.dbg.json +1 -1
- package/build/contracts/bridge/Redemption.sol/Redemption.dbg.json +1 -1
- package/build/contracts/bridge/VendingMachine.sol/VendingMachine.dbg.json +1 -1
- package/build/contracts/bridge/VendingMachineV2.sol/VendingMachineV2.dbg.json +1 -1
- package/build/contracts/bridge/VendingMachineV3.sol/VendingMachineV3.dbg.json +1 -1
- package/build/contracts/bridge/WalletProposalValidator.sol/WalletProposalValidator.dbg.json +1 -1
- package/build/contracts/bridge/Wallets.sol/Wallets.dbg.json +1 -1
- package/build/contracts/integrator/AbstractTBTCDepositor.sol/AbstractTBTCDepositor.dbg.json +4 -0
- package/build/contracts/integrator/AbstractTBTCDepositor.sol/AbstractTBTCDepositor.json +113 -0
- package/build/contracts/integrator/IBridge.sol/IBridge.dbg.json +4 -0
- package/build/contracts/integrator/IBridge.sol/IBridge.json +172 -0
- package/build/contracts/integrator/IBridge.sol/IBridgeTypes.dbg.json +4 -0
- package/build/contracts/integrator/IBridge.sol/IBridgeTypes.json +10 -0
- package/build/contracts/integrator/ITBTCVault.sol/ITBTCVault.dbg.json +4 -0
- package/build/contracts/integrator/ITBTCVault.sol/ITBTCVault.json +48 -0
- package/build/contracts/l2/L2TBTC.sol/L2TBTC.dbg.json +1 -1
- package/build/contracts/l2/L2WormholeGateway.sol/IWormholeTokenBridge.dbg.json +1 -1
- package/build/contracts/l2/L2WormholeGateway.sol/L2WormholeGateway.dbg.json +1 -1
- package/build/contracts/maintainer/MaintainerProxy.sol/MaintainerProxy.dbg.json +1 -1
- package/build/contracts/relay/LightRelay.sol/ILightRelay.dbg.json +1 -1
- package/build/contracts/relay/LightRelay.sol/LightRelay.dbg.json +1 -1
- package/build/contracts/relay/LightRelay.sol/RelayUtils.dbg.json +1 -1
- package/build/contracts/relay/LightRelayMaintainerProxy.sol/LightRelayMaintainerProxy.dbg.json +1 -1
- package/build/contracts/token/TBTC.sol/TBTC.dbg.json +1 -1
- package/build/contracts/vault/DonationVault.sol/DonationVault.dbg.json +1 -1
- package/build/contracts/vault/IVault.sol/IVault.dbg.json +1 -1
- package/build/contracts/vault/TBTCOptimisticMinting.sol/TBTCOptimisticMinting.dbg.json +1 -1
- package/build/contracts/vault/TBTCVault.sol/TBTCVault.dbg.json +1 -1
- package/contracts/integrator/AbstractTBTCDepositor.sol +308 -0
- package/contracts/integrator/IBridge.sol +80 -0
- package/contracts/integrator/ITBTCVault.sol +28 -0
- package/export/artifacts/@keep-network/bitcoin-spv-sol/contracts/BTCUtils.sol/BTCUtils.json +20 -20
- package/export/artifacts/@keep-network/ecdsa/contracts/EcdsaDkgValidator.sol/EcdsaDkgValidator.json +1986 -1986
- package/export/artifacts/@keep-network/ecdsa/contracts/libraries/EcdsaDkg.sol/EcdsaDkg.json +20 -20
- package/export/artifacts/@keep-network/ecdsa/contracts/libraries/EcdsaInactivity.sol/EcdsaInactivity.json +1836 -1836
- package/export/artifacts/@keep-network/random-beacon/contracts/ReimbursementPool.sol/ReimbursementPool.json +545 -545
- package/export/artifacts/@keep-network/sortition-pools/contracts/Chaosnet.sol/Chaosnet.json +506 -506
- package/export/artifacts/@keep-network/sortition-pools/contracts/Rewards.sol/Rewards.json +23 -23
- package/export/artifacts/@keep-network/sortition-pools/contracts/SortitionPool.sol/SortitionPool.json +2456 -2456
- package/export/artifacts/@keep-network/sortition-pools/contracts/SortitionTree.sol/SortitionTree.json +465 -465
- package/export/artifacts/@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol/ERC1967Proxy.json +568 -568
- package/export/artifacts/@openzeppelin/contracts/proxy/transparent/ProxyAdmin.sol/ProxyAdmin.json +603 -603
- package/export/artifacts/@openzeppelin/contracts/proxy/transparent/TransparentUpgradeableProxy.sol/TransparentUpgradeableProxy.json +1001 -1001
- package/export/artifacts/@openzeppelin/contracts/token/ERC721/ERC721.sol/ERC721.json +1877 -1877
- package/export/artifacts/@openzeppelin/contracts-upgradeable/token/ERC20/ERC20Upgradeable.sol/ERC20Upgradeable.json +654 -654
- package/export/artifacts/@thesis/solidity-contracts/contracts/token/ERC20WithPermit.sol/ERC20WithPermit.json +2534 -2534
- package/export/artifacts/@thesis/solidity-contracts/contracts/token/MisfundRecovery.sol/MisfundRecovery.json +736 -736
- package/export/artifacts/contracts/bank/Bank.sol/Bank.json +1872 -1872
- package/export/artifacts/contracts/bridge/Bridge.sol/Bridge.json +7234 -7234
- package/export/artifacts/contracts/bridge/VendingMachine.sol/VendingMachine.json +1257 -1257
- package/export/artifacts/contracts/bridge/VendingMachineV2.sol/VendingMachineV2.json +972 -972
- package/export/artifacts/contracts/bridge/VendingMachineV3.sol/VendingMachineV3.json +1122 -1122
- package/export/artifacts/contracts/bridge/WalletProposalValidator.sol/WalletProposalValidator.json +5028 -5028
- package/export/artifacts/contracts/l2/L2TBTC.sol/L2TBTC.json +3002 -3002
- package/export/artifacts/contracts/l2/L2WormholeGateway.sol/L2WormholeGateway.json +2490 -2490
- package/export/artifacts/contracts/maintainer/MaintainerProxy.sol/MaintainerProxy.json +2456 -2456
- package/export/artifacts/contracts/relay/LightRelay.sol/LightRelay.json +1922 -1922
- package/export/artifacts/contracts/relay/LightRelayMaintainerProxy.sol/LightRelayMaintainerProxy.json +1013 -1013
- package/export/artifacts/contracts/test/BankStub.sol/BankStub.json +1874 -1874
- package/export/artifacts/contracts/test/BridgeStub.sol/BridgeStub.json +8259 -8259
- package/export/artifacts/contracts/test/HeartbeatStub.sol/HeartbeatStub.json +130 -130
- package/export/artifacts/contracts/test/LightRelayStub.sol/LightRelayStub.json +2047 -2047
- package/export/artifacts/contracts/test/ReceiveApprovalStub.sol/ReceiveApprovalStub.json +354 -354
- package/export/artifacts/contracts/test/SepoliaLightRelay.sol/SepoliaLightRelay.json +1924 -1924
- package/export/artifacts/contracts/test/SystemTestRelay.sol/SystemTestRelay.json +568 -568
- package/export/artifacts/contracts/test/TestBitcoinTx.sol/TestBitcoinTx.json +1249 -1249
- package/export/artifacts/contracts/test/TestERC20.sol/TestERC20.json +2291 -2291
- package/export/artifacts/contracts/test/TestERC721.sol/TestERC721.json +1698 -1698
- package/export/artifacts/contracts/test/TestEcdsaLib.sol/TestEcdsaLib.json +189 -189
- package/export/artifacts/contracts/test/TestTBTCDepositor.sol/MockBridge.json +4871 -0
- package/export/artifacts/contracts/test/TestTBTCDepositor.sol/MockTBTCVault.json +1523 -0
- package/export/artifacts/contracts/test/TestTBTCDepositor.sol/TestTBTCDepositor.json +11101 -0
- package/export/artifacts/contracts/test/WormholeBridgeStub.sol/WormholeBridgeStub.json +1447 -1447
- package/export/artifacts/contracts/token/TBTC.sol/TBTC.json +2847 -2847
- package/export/artifacts/contracts/vault/DonationVault.sol/DonationVault.json +858 -858
- package/export/artifacts/contracts/vault/TBTCVault.sol/TBTCVault.json +3489 -3489
- package/export/typechain/AbstractTBTCDepositor.js +2 -0
- package/export/typechain/IBridge.js +2 -0
- package/export/typechain/ITBTCVault.js +2 -0
- package/export/typechain/MockBridge.js +2 -0
- package/export/typechain/MockTBTCVault.js +2 -0
- package/export/typechain/TestTBTCDepositor.js +2 -0
- package/export/typechain/factories/AbstractTBTCDepositor__factory.js +124 -0
- package/export/typechain/factories/IBridge__factory.js +183 -0
- package/export/typechain/factories/ITBTCVault__factory.js +59 -0
- package/export/typechain/factories/MockBridge__factory.js +290 -0
- package/export/typechain/factories/MockTBTCVault__factory.js +166 -0
- package/export/typechain/factories/TestTBTCDepositor__factory.js +356 -0
- package/export/typechain/index.js +14 -1
- package/package.json +1 -1
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* Autogenerated file. Do not edit manually. */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.AbstractTBTCDepositor__factory = void 0;
|
|
7
|
+
var ethers_1 = require("ethers");
|
|
8
|
+
var _abi = [
|
|
9
|
+
{
|
|
10
|
+
anonymous: false,
|
|
11
|
+
inputs: [
|
|
12
|
+
{
|
|
13
|
+
indexed: true,
|
|
14
|
+
internalType: "uint256",
|
|
15
|
+
name: "depositKey",
|
|
16
|
+
type: "uint256",
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
indexed: false,
|
|
20
|
+
internalType: "uint256",
|
|
21
|
+
name: "tbtcAmount",
|
|
22
|
+
type: "uint256",
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
indexed: false,
|
|
26
|
+
internalType: "uint32",
|
|
27
|
+
name: "finalizedAt",
|
|
28
|
+
type: "uint32",
|
|
29
|
+
},
|
|
30
|
+
],
|
|
31
|
+
name: "DepositFinalized",
|
|
32
|
+
type: "event",
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
anonymous: false,
|
|
36
|
+
inputs: [
|
|
37
|
+
{
|
|
38
|
+
indexed: true,
|
|
39
|
+
internalType: "uint256",
|
|
40
|
+
name: "depositKey",
|
|
41
|
+
type: "uint256",
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
indexed: false,
|
|
45
|
+
internalType: "uint32",
|
|
46
|
+
name: "initializedAt",
|
|
47
|
+
type: "uint32",
|
|
48
|
+
},
|
|
49
|
+
],
|
|
50
|
+
name: "DepositInitialized",
|
|
51
|
+
type: "event",
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
inputs: [],
|
|
55
|
+
name: "SATOSHI_MULTIPLIER",
|
|
56
|
+
outputs: [
|
|
57
|
+
{
|
|
58
|
+
internalType: "uint256",
|
|
59
|
+
name: "",
|
|
60
|
+
type: "uint256",
|
|
61
|
+
},
|
|
62
|
+
],
|
|
63
|
+
stateMutability: "view",
|
|
64
|
+
type: "function",
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
inputs: [],
|
|
68
|
+
name: "bridge",
|
|
69
|
+
outputs: [
|
|
70
|
+
{
|
|
71
|
+
internalType: "contract IBridge",
|
|
72
|
+
name: "",
|
|
73
|
+
type: "address",
|
|
74
|
+
},
|
|
75
|
+
],
|
|
76
|
+
stateMutability: "view",
|
|
77
|
+
type: "function",
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
inputs: [
|
|
81
|
+
{
|
|
82
|
+
internalType: "uint256",
|
|
83
|
+
name: "",
|
|
84
|
+
type: "uint256",
|
|
85
|
+
},
|
|
86
|
+
],
|
|
87
|
+
name: "pendingDeposits",
|
|
88
|
+
outputs: [
|
|
89
|
+
{
|
|
90
|
+
internalType: "bool",
|
|
91
|
+
name: "",
|
|
92
|
+
type: "bool",
|
|
93
|
+
},
|
|
94
|
+
],
|
|
95
|
+
stateMutability: "view",
|
|
96
|
+
type: "function",
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
inputs: [],
|
|
100
|
+
name: "tbtcVault",
|
|
101
|
+
outputs: [
|
|
102
|
+
{
|
|
103
|
+
internalType: "contract ITBTCVault",
|
|
104
|
+
name: "",
|
|
105
|
+
type: "address",
|
|
106
|
+
},
|
|
107
|
+
],
|
|
108
|
+
stateMutability: "view",
|
|
109
|
+
type: "function",
|
|
110
|
+
},
|
|
111
|
+
];
|
|
112
|
+
var AbstractTBTCDepositor__factory = /** @class */ (function () {
|
|
113
|
+
function AbstractTBTCDepositor__factory() {
|
|
114
|
+
}
|
|
115
|
+
AbstractTBTCDepositor__factory.createInterface = function () {
|
|
116
|
+
return new ethers_1.utils.Interface(_abi);
|
|
117
|
+
};
|
|
118
|
+
AbstractTBTCDepositor__factory.connect = function (address, signerOrProvider) {
|
|
119
|
+
return new ethers_1.Contract(address, _abi, signerOrProvider);
|
|
120
|
+
};
|
|
121
|
+
AbstractTBTCDepositor__factory.abi = _abi;
|
|
122
|
+
return AbstractTBTCDepositor__factory;
|
|
123
|
+
}());
|
|
124
|
+
exports.AbstractTBTCDepositor__factory = AbstractTBTCDepositor__factory;
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* Autogenerated file. Do not edit manually. */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.IBridge__factory = void 0;
|
|
7
|
+
var ethers_1 = require("ethers");
|
|
8
|
+
var _abi = [
|
|
9
|
+
{
|
|
10
|
+
inputs: [],
|
|
11
|
+
name: "depositParameters",
|
|
12
|
+
outputs: [
|
|
13
|
+
{
|
|
14
|
+
internalType: "uint64",
|
|
15
|
+
name: "depositDustThreshold",
|
|
16
|
+
type: "uint64",
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
internalType: "uint64",
|
|
20
|
+
name: "depositTreasuryFeeDivisor",
|
|
21
|
+
type: "uint64",
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
internalType: "uint64",
|
|
25
|
+
name: "depositTxMaxFee",
|
|
26
|
+
type: "uint64",
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
internalType: "uint32",
|
|
30
|
+
name: "depositRevealAheadPeriod",
|
|
31
|
+
type: "uint32",
|
|
32
|
+
},
|
|
33
|
+
],
|
|
34
|
+
stateMutability: "view",
|
|
35
|
+
type: "function",
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
inputs: [
|
|
39
|
+
{
|
|
40
|
+
internalType: "uint256",
|
|
41
|
+
name: "depositKey",
|
|
42
|
+
type: "uint256",
|
|
43
|
+
},
|
|
44
|
+
],
|
|
45
|
+
name: "deposits",
|
|
46
|
+
outputs: [
|
|
47
|
+
{
|
|
48
|
+
components: [
|
|
49
|
+
{
|
|
50
|
+
internalType: "address",
|
|
51
|
+
name: "depositor",
|
|
52
|
+
type: "address",
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
internalType: "uint64",
|
|
56
|
+
name: "amount",
|
|
57
|
+
type: "uint64",
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
internalType: "uint32",
|
|
61
|
+
name: "revealedAt",
|
|
62
|
+
type: "uint32",
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
internalType: "address",
|
|
66
|
+
name: "vault",
|
|
67
|
+
type: "address",
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
internalType: "uint64",
|
|
71
|
+
name: "treasuryFee",
|
|
72
|
+
type: "uint64",
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
internalType: "uint32",
|
|
76
|
+
name: "sweptAt",
|
|
77
|
+
type: "uint32",
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
internalType: "bytes32",
|
|
81
|
+
name: "extraData",
|
|
82
|
+
type: "bytes32",
|
|
83
|
+
},
|
|
84
|
+
],
|
|
85
|
+
internalType: "struct IBridgeTypes.DepositRequest",
|
|
86
|
+
name: "",
|
|
87
|
+
type: "tuple",
|
|
88
|
+
},
|
|
89
|
+
],
|
|
90
|
+
stateMutability: "view",
|
|
91
|
+
type: "function",
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
inputs: [
|
|
95
|
+
{
|
|
96
|
+
components: [
|
|
97
|
+
{
|
|
98
|
+
internalType: "bytes4",
|
|
99
|
+
name: "version",
|
|
100
|
+
type: "bytes4",
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
internalType: "bytes",
|
|
104
|
+
name: "inputVector",
|
|
105
|
+
type: "bytes",
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
internalType: "bytes",
|
|
109
|
+
name: "outputVector",
|
|
110
|
+
type: "bytes",
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
internalType: "bytes4",
|
|
114
|
+
name: "locktime",
|
|
115
|
+
type: "bytes4",
|
|
116
|
+
},
|
|
117
|
+
],
|
|
118
|
+
internalType: "struct IBridgeTypes.BitcoinTxInfo",
|
|
119
|
+
name: "fundingTx",
|
|
120
|
+
type: "tuple",
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
components: [
|
|
124
|
+
{
|
|
125
|
+
internalType: "uint32",
|
|
126
|
+
name: "fundingOutputIndex",
|
|
127
|
+
type: "uint32",
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
internalType: "bytes8",
|
|
131
|
+
name: "blindingFactor",
|
|
132
|
+
type: "bytes8",
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
internalType: "bytes20",
|
|
136
|
+
name: "walletPubKeyHash",
|
|
137
|
+
type: "bytes20",
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
internalType: "bytes20",
|
|
141
|
+
name: "refundPubKeyHash",
|
|
142
|
+
type: "bytes20",
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
internalType: "bytes4",
|
|
146
|
+
name: "refundLocktime",
|
|
147
|
+
type: "bytes4",
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
internalType: "address",
|
|
151
|
+
name: "vault",
|
|
152
|
+
type: "address",
|
|
153
|
+
},
|
|
154
|
+
],
|
|
155
|
+
internalType: "struct IBridgeTypes.DepositRevealInfo",
|
|
156
|
+
name: "reveal",
|
|
157
|
+
type: "tuple",
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
internalType: "bytes32",
|
|
161
|
+
name: "extraData",
|
|
162
|
+
type: "bytes32",
|
|
163
|
+
},
|
|
164
|
+
],
|
|
165
|
+
name: "revealDepositWithExtraData",
|
|
166
|
+
outputs: [],
|
|
167
|
+
stateMutability: "nonpayable",
|
|
168
|
+
type: "function",
|
|
169
|
+
},
|
|
170
|
+
];
|
|
171
|
+
var IBridge__factory = /** @class */ (function () {
|
|
172
|
+
function IBridge__factory() {
|
|
173
|
+
}
|
|
174
|
+
IBridge__factory.createInterface = function () {
|
|
175
|
+
return new ethers_1.utils.Interface(_abi);
|
|
176
|
+
};
|
|
177
|
+
IBridge__factory.connect = function (address, signerOrProvider) {
|
|
178
|
+
return new ethers_1.Contract(address, _abi, signerOrProvider);
|
|
179
|
+
};
|
|
180
|
+
IBridge__factory.abi = _abi;
|
|
181
|
+
return IBridge__factory;
|
|
182
|
+
}());
|
|
183
|
+
exports.IBridge__factory = IBridge__factory;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* Autogenerated file. Do not edit manually. */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.ITBTCVault__factory = void 0;
|
|
7
|
+
var ethers_1 = require("ethers");
|
|
8
|
+
var _abi = [
|
|
9
|
+
{
|
|
10
|
+
inputs: [],
|
|
11
|
+
name: "optimisticMintingFeeDivisor",
|
|
12
|
+
outputs: [
|
|
13
|
+
{
|
|
14
|
+
internalType: "uint32",
|
|
15
|
+
name: "",
|
|
16
|
+
type: "uint32",
|
|
17
|
+
},
|
|
18
|
+
],
|
|
19
|
+
stateMutability: "view",
|
|
20
|
+
type: "function",
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
inputs: [
|
|
24
|
+
{
|
|
25
|
+
internalType: "uint256",
|
|
26
|
+
name: "depositKey",
|
|
27
|
+
type: "uint256",
|
|
28
|
+
},
|
|
29
|
+
],
|
|
30
|
+
name: "optimisticMintingRequests",
|
|
31
|
+
outputs: [
|
|
32
|
+
{
|
|
33
|
+
internalType: "uint64",
|
|
34
|
+
name: "requestedAt",
|
|
35
|
+
type: "uint64",
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
internalType: "uint64",
|
|
39
|
+
name: "finalizedAt",
|
|
40
|
+
type: "uint64",
|
|
41
|
+
},
|
|
42
|
+
],
|
|
43
|
+
stateMutability: "nonpayable",
|
|
44
|
+
type: "function",
|
|
45
|
+
},
|
|
46
|
+
];
|
|
47
|
+
var ITBTCVault__factory = /** @class */ (function () {
|
|
48
|
+
function ITBTCVault__factory() {
|
|
49
|
+
}
|
|
50
|
+
ITBTCVault__factory.createInterface = function () {
|
|
51
|
+
return new ethers_1.utils.Interface(_abi);
|
|
52
|
+
};
|
|
53
|
+
ITBTCVault__factory.connect = function (address, signerOrProvider) {
|
|
54
|
+
return new ethers_1.Contract(address, _abi, signerOrProvider);
|
|
55
|
+
};
|
|
56
|
+
ITBTCVault__factory.abi = _abi;
|
|
57
|
+
return ITBTCVault__factory;
|
|
58
|
+
}());
|
|
59
|
+
exports.ITBTCVault__factory = ITBTCVault__factory;
|
|
@@ -0,0 +1,290 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
|
3
|
+
var extendStatics = function (d, b) {
|
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
|
+
return extendStatics(d, b);
|
|
8
|
+
};
|
|
9
|
+
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
12
|
+
extendStatics(d, b);
|
|
13
|
+
function __() { this.constructor = d; }
|
|
14
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
15
|
+
};
|
|
16
|
+
})();
|
|
17
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
18
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
19
|
+
if (!m) return o;
|
|
20
|
+
var i = m.call(o), r, ar = [], e;
|
|
21
|
+
try {
|
|
22
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
23
|
+
}
|
|
24
|
+
catch (error) { e = { error: error }; }
|
|
25
|
+
finally {
|
|
26
|
+
try {
|
|
27
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
28
|
+
}
|
|
29
|
+
finally { if (e) throw e.error; }
|
|
30
|
+
}
|
|
31
|
+
return ar;
|
|
32
|
+
};
|
|
33
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
34
|
+
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
35
|
+
if (ar || !(i in from)) {
|
|
36
|
+
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
37
|
+
ar[i] = from[i];
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
return to.concat(ar || Array.prototype.slice.call(from));
|
|
41
|
+
};
|
|
42
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
43
|
+
exports.MockBridge__factory = void 0;
|
|
44
|
+
/* Autogenerated file. Do not edit manually. */
|
|
45
|
+
/* tslint:disable */
|
|
46
|
+
/* eslint-disable */
|
|
47
|
+
var ethers_1 = require("ethers");
|
|
48
|
+
var _abi = [
|
|
49
|
+
{
|
|
50
|
+
anonymous: false,
|
|
51
|
+
inputs: [
|
|
52
|
+
{
|
|
53
|
+
indexed: false,
|
|
54
|
+
internalType: "uint256",
|
|
55
|
+
name: "depositKey",
|
|
56
|
+
type: "uint256",
|
|
57
|
+
},
|
|
58
|
+
],
|
|
59
|
+
name: "DepositRevealed",
|
|
60
|
+
type: "event",
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
inputs: [],
|
|
64
|
+
name: "depositParameters",
|
|
65
|
+
outputs: [
|
|
66
|
+
{
|
|
67
|
+
internalType: "uint64",
|
|
68
|
+
name: "depositDustThreshold",
|
|
69
|
+
type: "uint64",
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
internalType: "uint64",
|
|
73
|
+
name: "depositTreasuryFeeDivisor",
|
|
74
|
+
type: "uint64",
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
internalType: "uint64",
|
|
78
|
+
name: "depositTxMaxFee",
|
|
79
|
+
type: "uint64",
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
internalType: "uint32",
|
|
83
|
+
name: "depositRevealAheadPeriod",
|
|
84
|
+
type: "uint32",
|
|
85
|
+
},
|
|
86
|
+
],
|
|
87
|
+
stateMutability: "view",
|
|
88
|
+
type: "function",
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
inputs: [
|
|
92
|
+
{
|
|
93
|
+
internalType: "uint256",
|
|
94
|
+
name: "depositKey",
|
|
95
|
+
type: "uint256",
|
|
96
|
+
},
|
|
97
|
+
],
|
|
98
|
+
name: "deposits",
|
|
99
|
+
outputs: [
|
|
100
|
+
{
|
|
101
|
+
components: [
|
|
102
|
+
{
|
|
103
|
+
internalType: "address",
|
|
104
|
+
name: "depositor",
|
|
105
|
+
type: "address",
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
internalType: "uint64",
|
|
109
|
+
name: "amount",
|
|
110
|
+
type: "uint64",
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
internalType: "uint32",
|
|
114
|
+
name: "revealedAt",
|
|
115
|
+
type: "uint32",
|
|
116
|
+
},
|
|
117
|
+
{
|
|
118
|
+
internalType: "address",
|
|
119
|
+
name: "vault",
|
|
120
|
+
type: "address",
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
internalType: "uint64",
|
|
124
|
+
name: "treasuryFee",
|
|
125
|
+
type: "uint64",
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
internalType: "uint32",
|
|
129
|
+
name: "sweptAt",
|
|
130
|
+
type: "uint32",
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
internalType: "bytes32",
|
|
134
|
+
name: "extraData",
|
|
135
|
+
type: "bytes32",
|
|
136
|
+
},
|
|
137
|
+
],
|
|
138
|
+
internalType: "struct IBridgeTypes.DepositRequest",
|
|
139
|
+
name: "",
|
|
140
|
+
type: "tuple",
|
|
141
|
+
},
|
|
142
|
+
],
|
|
143
|
+
stateMutability: "view",
|
|
144
|
+
type: "function",
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
inputs: [
|
|
148
|
+
{
|
|
149
|
+
components: [
|
|
150
|
+
{
|
|
151
|
+
internalType: "bytes4",
|
|
152
|
+
name: "version",
|
|
153
|
+
type: "bytes4",
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
internalType: "bytes",
|
|
157
|
+
name: "inputVector",
|
|
158
|
+
type: "bytes",
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
internalType: "bytes",
|
|
162
|
+
name: "outputVector",
|
|
163
|
+
type: "bytes",
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
internalType: "bytes4",
|
|
167
|
+
name: "locktime",
|
|
168
|
+
type: "bytes4",
|
|
169
|
+
},
|
|
170
|
+
],
|
|
171
|
+
internalType: "struct IBridgeTypes.BitcoinTxInfo",
|
|
172
|
+
name: "fundingTx",
|
|
173
|
+
type: "tuple",
|
|
174
|
+
},
|
|
175
|
+
{
|
|
176
|
+
components: [
|
|
177
|
+
{
|
|
178
|
+
internalType: "uint32",
|
|
179
|
+
name: "fundingOutputIndex",
|
|
180
|
+
type: "uint32",
|
|
181
|
+
},
|
|
182
|
+
{
|
|
183
|
+
internalType: "bytes8",
|
|
184
|
+
name: "blindingFactor",
|
|
185
|
+
type: "bytes8",
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
internalType: "bytes20",
|
|
189
|
+
name: "walletPubKeyHash",
|
|
190
|
+
type: "bytes20",
|
|
191
|
+
},
|
|
192
|
+
{
|
|
193
|
+
internalType: "bytes20",
|
|
194
|
+
name: "refundPubKeyHash",
|
|
195
|
+
type: "bytes20",
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
internalType: "bytes4",
|
|
199
|
+
name: "refundLocktime",
|
|
200
|
+
type: "bytes4",
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
internalType: "address",
|
|
204
|
+
name: "vault",
|
|
205
|
+
type: "address",
|
|
206
|
+
},
|
|
207
|
+
],
|
|
208
|
+
internalType: "struct IBridgeTypes.DepositRevealInfo",
|
|
209
|
+
name: "reveal",
|
|
210
|
+
type: "tuple",
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
internalType: "bytes32",
|
|
214
|
+
name: "extraData",
|
|
215
|
+
type: "bytes32",
|
|
216
|
+
},
|
|
217
|
+
],
|
|
218
|
+
name: "revealDepositWithExtraData",
|
|
219
|
+
outputs: [],
|
|
220
|
+
stateMutability: "nonpayable",
|
|
221
|
+
type: "function",
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
inputs: [
|
|
225
|
+
{
|
|
226
|
+
internalType: "uint64",
|
|
227
|
+
name: "value",
|
|
228
|
+
type: "uint64",
|
|
229
|
+
},
|
|
230
|
+
],
|
|
231
|
+
name: "setDepositTxMaxFee",
|
|
232
|
+
outputs: [],
|
|
233
|
+
stateMutability: "nonpayable",
|
|
234
|
+
type: "function",
|
|
235
|
+
},
|
|
236
|
+
{
|
|
237
|
+
inputs: [
|
|
238
|
+
{
|
|
239
|
+
internalType: "uint256",
|
|
240
|
+
name: "depositKey",
|
|
241
|
+
type: "uint256",
|
|
242
|
+
},
|
|
243
|
+
],
|
|
244
|
+
name: "sweepDeposit",
|
|
245
|
+
outputs: [],
|
|
246
|
+
stateMutability: "nonpayable",
|
|
247
|
+
type: "function",
|
|
248
|
+
},
|
|
249
|
+
];
|
|
250
|
+
var _bytecode = "0x6080604052600180546001600160401b0319166298968017905534801561002557600080fd5b50610926806100356000396000f3fe608060405234801561001057600080fd5b50600436106100675760003560e01c8063b036c1ee11610050578063b036c1ee146101ec578063bc8d07ca1461021e578063c42b64d01461023157600080fd5b806386f014391461006c578063b02c43d014610081575b600080fd5b61007f61007a366004610704565b610267565b005b61016361008f36600461076d565b6040805160e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c08101919091525060009081526020818152604091829020825160e08101845281546001600160a01b03808216835267ffffffffffffffff7401000000000000000000000000000000000000000080840482169685019690965263ffffffff600160e01b9384900481169785019790975260018501549182166060850152948104909416608083015290920490921660a082015260029091015460c082015290565b6040516101e39190600060e0820190506001600160a01b03808451168352602084015167ffffffffffffffff80821660208601526040860151915063ffffffff80831660408701528360608801511660608701528160808801511660808701528060a08801511660a08701525050505060c083015160c083015292915050565b60405180910390f35b61007f6101fa366004610786565b6001805467ffffffffffffffff191667ffffffffffffffff92909216919091179055565b61007f61022c36600461076d565b6105c4565b6001546040805160008082526020820181905267ffffffffffffffff9093169181019190915260608101919091526080016101e3565b60006102cc61027960208601866107b7565b61028660208701876107f9565b61029360408901896107f9565b6102a360808b0160608c016107b7565b6040516020016102b896959493929190610847565b6040516020818303038152906040526106dd565b90506000816102de60208601866108a1565b60405160200161031d92919091825260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016602082015260240190565b60408051808303601f190181529181528151602092830120600081815292839052912054909150600160e01b900463ffffffff16156103a35760405162461bcd60e51b815260206004820152601860248201527f4465706f73697420616c72656164792072657665616c6564000000000000000060448201526064015b60405180910390fd5b6040805160e0810182526000606082018190526080820181905260a080830182905260c080840192909252338352633b9aca0060208401524263ffffffff169383019390935290916103f99187019087016108c7565b81606001906001600160a01b031690816001600160a01b0316815250506305f5e100816080019067ffffffffffffffff16908167ffffffffffffffff168152505060008160a0019063ffffffff16908163ffffffff1681525050838160c00181815250508060008084815260200190815260200160002060008201518160000160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060208201518160000160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550604082015181600001601c6101000a81548163ffffffff021916908363ffffffff16021790555060608201518160010160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060808201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060a082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060c082015181600201559050507f629cb19e19d844f2e8dd8aa5de26f5072bb49e6286c5206ebd7302da1dabc417826040516105b491815260200190565b60405180910390a1505050505050565b600081815260208190526040812054600160e01b900463ffffffff16900361062e5760405162461bcd60e51b815260206004820152601460248201527f4465706f736974206e6f742072657665616c6564000000000000000000000000604482015260640161039a565b600081815260208190526040902060010154600160e01b900463ffffffff161561069a5760405162461bcd60e51b815260206004820152601560248201527f4465706f73697420616c72656164792073776570740000000000000000000000604482015260640161039a565b600090815260208190526040902060010180547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16600160e01b4263ffffffff1602179055565b60006020600083516020850160025afa50602060006020600060025afa5050600051919050565b600080600083850361010081121561071b57600080fd5b843567ffffffffffffffff81111561073257600080fd5b85016080818803121561074457600080fd5b935060c0601f198201121561075857600080fd5b5060208401915060e084013590509250925092565b60006020828403121561077f57600080fd5b5035919050565b60006020828403121561079857600080fd5b813567ffffffffffffffff811681146107b057600080fd5b9392505050565b6000602082840312156107c957600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146107b057600080fd5b6000808335601e1984360301811261081057600080fd5b83018035915067ffffffffffffffff82111561082b57600080fd5b60200191503681900382131561084057600080fd5b9250929050565b60007fffffffff000000000000000000000000000000000000000000000000000000008089168352868860048501378683016004810160008152868882375093169390920160048101939093525050600801949350505050565b6000602082840312156108b357600080fd5b813563ffffffff811681146107b057600080fd5b6000602082840312156108d957600080fd5b81356001600160a01b03811681146107b057600080fdfea2646970667358221220137c793e3b06ddf0962845ecb22752b8aeb78491e72c5f4f5b70849a47efa1e164736f6c63430008110033";
|
|
251
|
+
var isSuperArgs = function (xs) { return xs.length > 1; };
|
|
252
|
+
var MockBridge__factory = /** @class */ (function (_super) {
|
|
253
|
+
__extends(MockBridge__factory, _super);
|
|
254
|
+
function MockBridge__factory() {
|
|
255
|
+
var args = [];
|
|
256
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
257
|
+
args[_i] = arguments[_i];
|
|
258
|
+
}
|
|
259
|
+
var _this = this;
|
|
260
|
+
if (isSuperArgs(args)) {
|
|
261
|
+
_this = _super.apply(this, __spreadArray([], __read(args), false)) || this;
|
|
262
|
+
}
|
|
263
|
+
else {
|
|
264
|
+
_this = _super.call(this, _abi, _bytecode, args[0]) || this;
|
|
265
|
+
}
|
|
266
|
+
return _this;
|
|
267
|
+
}
|
|
268
|
+
MockBridge__factory.prototype.deploy = function (overrides) {
|
|
269
|
+
return _super.prototype.deploy.call(this, overrides || {});
|
|
270
|
+
};
|
|
271
|
+
MockBridge__factory.prototype.getDeployTransaction = function (overrides) {
|
|
272
|
+
return _super.prototype.getDeployTransaction.call(this, overrides || {});
|
|
273
|
+
};
|
|
274
|
+
MockBridge__factory.prototype.attach = function (address) {
|
|
275
|
+
return _super.prototype.attach.call(this, address);
|
|
276
|
+
};
|
|
277
|
+
MockBridge__factory.prototype.connect = function (signer) {
|
|
278
|
+
return _super.prototype.connect.call(this, signer);
|
|
279
|
+
};
|
|
280
|
+
MockBridge__factory.createInterface = function () {
|
|
281
|
+
return new ethers_1.utils.Interface(_abi);
|
|
282
|
+
};
|
|
283
|
+
MockBridge__factory.connect = function (address, signerOrProvider) {
|
|
284
|
+
return new ethers_1.Contract(address, _abi, signerOrProvider);
|
|
285
|
+
};
|
|
286
|
+
MockBridge__factory.bytecode = _bytecode;
|
|
287
|
+
MockBridge__factory.abi = _abi;
|
|
288
|
+
return MockBridge__factory;
|
|
289
|
+
}(ethers_1.ContractFactory));
|
|
290
|
+
exports.MockBridge__factory = MockBridge__factory;
|