@babylonlabs-io/ts-sdk 4.0.0 → 5.0.0
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/dist/PayoutManager-BXzFIZK6.cjs +2 -0
- package/dist/PayoutManager-BXzFIZK6.cjs.map +1 -0
- package/dist/{PayoutManager-BUWP-H-q.js → PayoutManager-Cjkozmnn.js} +9 -9
- package/dist/PayoutManager-Cjkozmnn.js.map +1 -0
- package/dist/{PeginManager-CMbRRTnr.cjs → PeginManager-BipOU_e4.cjs} +2 -2
- package/dist/PeginManager-BipOU_e4.cjs.map +1 -0
- package/dist/{PeginManager-Cas6_j7t.js → PeginManager-Cd5pHNTO.js} +2 -2
- package/dist/PeginManager-Cd5pHNTO.js.map +1 -0
- package/dist/{buildAndBroadcastReclaim-CVmG3ldA.cjs → buildAndBroadcastReclaim-B00roO6R.cjs} +2 -2
- package/dist/buildAndBroadcastReclaim-B00roO6R.cjs.map +1 -0
- package/dist/{buildAndBroadcastReclaim-XRWuJWVL.js → buildAndBroadcastReclaim-DU8iOtbn.js} +368 -331
- package/dist/buildAndBroadcastReclaim-DU8iOtbn.js.map +1 -0
- package/dist/challengeAssert-eUMgmpMk.cjs +2 -0
- package/dist/challengeAssert-eUMgmpMk.cjs.map +1 -0
- package/dist/{challengeAssert-DUKSjirl.js → challengeAssert-pJP7MKhG.js} +164 -164
- package/dist/challengeAssert-pJP7MKhG.js.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +61 -60
- package/dist/{primeVpAuth-C-ET0XF4.js → primeVpAuth-B0noJdcy.js} +5 -3
- package/dist/{primeVpAuth-C-ET0XF4.js.map → primeVpAuth-B0noJdcy.js.map} +1 -1
- package/dist/primeVpAuth-Ch-ig2My.cjs.map +1 -1
- package/dist/signer-set-reader-CJfV-GDz.cjs.map +1 -1
- package/dist/signer-set-reader-DiwLeqik.js.map +1 -1
- package/dist/tbv/core/clients/eth/operation-key-reader.d.ts +5 -1
- package/dist/tbv/core/clients/eth/operation-key-reader.d.ts.map +1 -1
- package/dist/tbv/core/clients/eth/signer-set-reader.d.ts.map +1 -1
- package/dist/tbv/core/clients/eth/types.d.ts +20 -0
- package/dist/tbv/core/clients/eth/types.d.ts.map +1 -1
- package/dist/tbv/core/clients/index.d.ts +4 -2
- package/dist/tbv/core/clients/index.d.ts.map +1 -1
- package/dist/tbv/core/clients/index.js +1 -1
- package/dist/tbv/core/clients/vault-provider/auth/tokenRegistry.d.ts +4 -2
- package/dist/tbv/core/clients/vault-provider/auth/tokenRegistry.d.ts.map +1 -1
- package/dist/tbv/core/deposit-terms/depositTerms.d.ts +13 -10
- package/dist/tbv/core/deposit-terms/depositTerms.d.ts.map +1 -1
- package/dist/tbv/core/deposit-terms/prePeginApproval.d.ts +3 -2
- package/dist/tbv/core/deposit-terms/prePeginApproval.d.ts.map +1 -1
- package/dist/tbv/core/index.cjs +1 -1
- package/dist/tbv/core/index.js +62 -61
- package/dist/tbv/core/managers/PayoutManager.d.ts +9 -3
- package/dist/tbv/core/managers/PayoutManager.d.ts.map +1 -1
- package/dist/tbv/core/managers/PeginManager.d.ts +13 -3
- package/dist/tbv/core/managers/PeginManager.d.ts.map +1 -1
- package/dist/tbv/core/managers/index.cjs +1 -1
- package/dist/tbv/core/managers/index.js +2 -2
- package/dist/tbv/core/primitives/challengers.d.ts +12 -5
- package/dist/tbv/core/primitives/challengers.d.ts.map +1 -1
- package/dist/tbv/core/primitives/index.cjs +1 -1
- package/dist/tbv/core/primitives/index.d.ts +1 -1
- package/dist/tbv/core/primitives/index.js +1 -1
- package/dist/tbv/core/primitives/psbt/pegin.d.ts +26 -4
- package/dist/tbv/core/primitives/psbt/pegin.d.ts.map +1 -1
- package/dist/tbv/core/primitives/psbt/refund.d.ts.map +1 -1
- package/dist/tbv/core/services/delegated-claim/challengerBinding.d.ts +3 -3
- package/dist/tbv/core/services/delegated-claim/challengerBinding.d.ts.map +1 -1
- package/dist/tbv/core/services/delegated-claim/types.d.ts +3 -3
- package/dist/tbv/core/services/delegated-claim/types.d.ts.map +1 -1
- package/dist/tbv/core/services/deposit/runDepositorPresignFlow.d.ts +19 -4
- package/dist/tbv/core/services/deposit/runDepositorPresignFlow.d.ts.map +1 -1
- package/dist/tbv/core/services/deposit/signDepositorGraph.d.ts +17 -3
- package/dist/tbv/core/services/deposit/signDepositorGraph.d.ts.map +1 -1
- package/dist/tbv/core/services/index.cjs +1 -1
- package/dist/tbv/core/services/index.js +44 -43
- package/dist/tbv/core/services/participants/readStampedParticipantKeys.d.ts +19 -7
- package/dist/tbv/core/services/participants/readStampedParticipantKeys.d.ts.map +1 -1
- package/dist/tbv/core/services/refund/__tests__/readRefundPrePeginContext.test.d.ts +12 -0
- package/dist/tbv/core/services/refund/__tests__/readRefundPrePeginContext.test.d.ts.map +1 -0
- package/dist/tbv/core/services/refund/buildAndBroadcastRefund.d.ts +41 -12
- package/dist/tbv/core/services/refund/buildAndBroadcastRefund.d.ts.map +1 -1
- package/dist/tbv/core/services/refund/index.d.ts +1 -0
- package/dist/tbv/core/services/refund/index.d.ts.map +1 -1
- package/dist/tbv/core/services/refund/readRefundPrePeginContext.d.ts +41 -0
- package/dist/tbv/core/services/refund/readRefundPrePeginContext.d.ts.map +1 -0
- package/dist/tbv/index.cjs +1 -1
- package/dist/tbv/index.js +62 -61
- package/dist/{toRefundInputs-BbbvPb2A.js → toRefundInputs-BrJrmOvY.js} +3 -3
- package/dist/{toRefundInputs-BbbvPb2A.js.map → toRefundInputs-BrJrmOvY.js.map} +1 -1
- package/dist/{toRefundInputs-BSQjDOK9.cjs → toRefundInputs-CR7vtHMa.cjs} +2 -2
- package/dist/{toRefundInputs-BSQjDOK9.cjs.map → toRefundInputs-CR7vtHMa.cjs.map} +1 -1
- package/dist/types-BnZIbDHb.cjs.map +1 -1
- package/dist/types-K_aM5GZO.js.map +1 -1
- package/dist/verifyScriptPathSchnorrSignature-CgDa9Rcg.cjs.map +1 -1
- package/dist/verifyScriptPathSchnorrSignature-D-fdi-sG.js.map +1 -1
- package/package.json +3 -3
- package/dist/PayoutManager-BUWP-H-q.js.map +0 -1
- package/dist/PayoutManager-Dopxq_Jv.cjs +0 -2
- package/dist/PayoutManager-Dopxq_Jv.cjs.map +0 -1
- package/dist/PeginManager-CMbRRTnr.cjs.map +0 -1
- package/dist/PeginManager-Cas6_j7t.js.map +0 -1
- package/dist/buildAndBroadcastReclaim-CVmG3ldA.cjs.map +0 -1
- package/dist/buildAndBroadcastReclaim-XRWuJWVL.js.map +0 -1
- package/dist/challengeAssert-BE6Wm4x1.cjs +0 -2
- package/dist/challengeAssert-BE6Wm4x1.cjs.map +0 -1
- package/dist/challengeAssert-DUKSjirl.js.map +0 -1
|
@@ -4,7 +4,8 @@ import { DepositTerms } from '../../deposit-terms';
|
|
|
4
4
|
import { PeginStatusReader, PresignClient } from './interfaces';
|
|
5
5
|
/**
|
|
6
6
|
* Context required for signing payout transactions.
|
|
7
|
-
* Caller builds this from on-chain
|
|
7
|
+
* Caller builds this from on-chain contract reads; the participant keys must
|
|
8
|
+
* be the ones the vault's graph was built with (see each key field).
|
|
8
9
|
*/
|
|
9
10
|
export interface PayoutSigningContext {
|
|
10
11
|
/**
|
|
@@ -16,11 +17,25 @@ export interface PayoutSigningContext {
|
|
|
16
17
|
vaultCoreVersion: number;
|
|
17
18
|
/** Raw pegin BTC transaction hex (for PSBT construction) */
|
|
18
19
|
peginTxHex: string;
|
|
19
|
-
/**
|
|
20
|
+
/**
|
|
21
|
+
* Vault provider's RFC-006 operation key (x-only hex, no prefix) at the
|
|
22
|
+
* vault's frozen `vpKeyEpoch`. Straight after registering, the key from
|
|
23
|
+
* `validateOnChainParticipantKeys` is that key; on a resume, read it with
|
|
24
|
+
* `readStampedParticipantKeys`. Never the registration key or the indexer's.
|
|
25
|
+
*/
|
|
20
26
|
vaultProviderBtcPubkey: string;
|
|
21
|
-
/**
|
|
27
|
+
/**
|
|
28
|
+
* Sorted vault keeper operation keys (x-only hex, no prefix) at the vault's
|
|
29
|
+
* frozen `appKeeperKeyEpoch`: from `validateOnChainParticipantKeys` straight
|
|
30
|
+
* after registering, from `readStampedParticipantKeys` on a resume. The
|
|
31
|
+
* roster holds registration keys, which differ from these for a vault
|
|
32
|
+
* registered after a keeper had rotated.
|
|
33
|
+
*/
|
|
22
34
|
vaultKeeperBtcPubkeys: string[];
|
|
23
|
-
/**
|
|
35
|
+
/**
|
|
36
|
+
* Sorted universal challenger operation keys (x-only hex, no prefix) at the
|
|
37
|
+
* vault's frozen `ucKeyEpoch`, sourced as for `vaultKeeperBtcPubkeys`.
|
|
38
|
+
*/
|
|
24
39
|
universalChallengerBtcPubkeys: string[];
|
|
25
40
|
/** Depositor's BTC public key (x-only hex, no prefix) */
|
|
26
41
|
depositorBtcPubkey: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runDepositorPresignFlow.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/deposit/runDepositorPresignFlow.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAErE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,uCAAuC,CAAC;AAM3E,OAAO,EAEL,KAAK,YAAY,EAClB,MAAM,qBAAqB,CAAC;AAU7B,OAAO,KAAK,EAAE,iBAAiB,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAYrE
|
|
1
|
+
{"version":3,"file":"runDepositorPresignFlow.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/deposit/runDepositorPresignFlow.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAErE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,uCAAuC,CAAC;AAM3E,OAAO,EAEL,KAAK,YAAY,EAClB,MAAM,qBAAqB,CAAC;AAU7B,OAAO,KAAK,EAAE,iBAAiB,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAYrE;;;;GAIG;AACH,MAAM,WAAW,oBAAoB;IACnC;;;;;OAKG;IACH,gBAAgB,EAAE,MAAM,CAAC;IACzB,4DAA4D;IAC5D,UAAU,EAAE,MAAM,CAAC;IACnB;;;;;OAKG;IACH,sBAAsB,EAAE,MAAM,CAAC;IAC/B;;;;;;OAMG;IACH,qBAAqB,EAAE,MAAM,EAAE,CAAC;IAChC;;;OAGG;IACH,6BAA6B,EAAE,MAAM,EAAE,CAAC;IACxC,yDAAyD;IACzD,kBAAkB,EAAE,MAAM,CAAC;IAC3B,6DAA6D;IAC7D,aAAa,EAAE,MAAM,CAAC;IACtB;;;;;OAKG;IACH,cAAc,EAAE,MAAM,CAAC;IACvB;;;;;OAKG;IACH,uBAAuB,EAAE,MAAM,CAAC;IAChC;;;;;OAKG;IACH,cAAc,EAAE,MAAM,EAAE,CAAC;IACzB;;;;;OAKG;IACH,aAAa,EAAE,MAAM,CAAC;IACtB,2CAA2C;IAC3C,OAAO,EAAE,OAAO,CAAC;IACjB,8DAA8D;IAC9D,4BAA4B,EAAE,MAAM,CAAC;IACrC,iGAAiG;IACjG,aAAa,EAAE,MAAM,CAAC;IACtB;;;;OAIG;IACH,eAAe,EAAE,MAAM,CAAC;IAExB;;;OAGG;IACH,4BAA4B,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IAC/D;;;OAGG;IACH,wBAAwB,EAAE,MAAM,CAAC;CAClC;AAED,MAAM,WAAW,6BAA6B;IAC5C,yDAAyD;IACzD,YAAY,EAAE,iBAAiB,CAAC;IAChC,oEAAoE;IACpE,aAAa,EAAE,aAAa,CAAC;IAC7B,iCAAiC;IACjC,SAAS,EAAE,aAAa,CAAC;IACzB,+EAA+E;IAC/E,OAAO,EAAE,MAAM,CAAC;IAChB,qFAAqF;IACrF,SAAS,EAAE,MAAM,CAAC;IAClB,mEAAmE;IACnE,WAAW,EAAE,MAAM,CAAC;IACpB,+CAA+C;IAC/C,cAAc,EAAE,oBAAoB,CAAC;IACrC;;;;OAIG;IACH,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,gEAAgE;IAChE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,mCAAmC;IACnC,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,sEAAsE;IACtE,UAAU,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACxD;;;;;;;;;OASG;IACH,sBAAsB,EAAE,CAAC,WAAW,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CACvE;AAoRD;;;;;;;GAOG;AACH,wBAAsB,uBAAuB,CAC3C,MAAM,EAAE,6BAA6B,GACpC,OAAO,CAAC,IAAI,CAAC,CAgNf"}
|
|
@@ -55,11 +55,25 @@ export interface DepositorGraphSigningContext {
|
|
|
55
55
|
peginTxHex: string;
|
|
56
56
|
/** Depositor's BTC public key (x-only, 64-char hex, no 0x prefix) */
|
|
57
57
|
depositorBtcPubkey: string;
|
|
58
|
-
/**
|
|
58
|
+
/**
|
|
59
|
+
* Vault provider's RFC-006 operation key (x-only hex, no prefix) at the
|
|
60
|
+
* vault's frozen `vpKeyEpoch`. Straight after registering, the key from
|
|
61
|
+
* `validateOnChainParticipantKeys` is that key; on a resume, read it with
|
|
62
|
+
* `readStampedParticipantKeys`. Never the registration key or the indexer's.
|
|
63
|
+
*/
|
|
59
64
|
vaultProviderBtcPubkey: string;
|
|
60
|
-
/**
|
|
65
|
+
/**
|
|
66
|
+
* Sorted vault keeper operation keys (x-only hex, no prefix) at the vault's
|
|
67
|
+
* frozen `appKeeperKeyEpoch`: from `validateOnChainParticipantKeys` straight
|
|
68
|
+
* after registering, from `readStampedParticipantKeys` on a resume. The
|
|
69
|
+
* roster holds registration keys, which differ from these for a vault
|
|
70
|
+
* registered after a keeper had rotated.
|
|
71
|
+
*/
|
|
61
72
|
vaultKeeperBtcPubkeys: string[];
|
|
62
|
-
/**
|
|
73
|
+
/**
|
|
74
|
+
* Sorted universal challenger operation keys (x-only hex, no prefix) at the
|
|
75
|
+
* vault's frozen `ucKeyEpoch`, sourced as for `vaultKeeperBtcPubkeys`.
|
|
76
|
+
*/
|
|
63
77
|
universalChallengerBtcPubkeys: string[];
|
|
64
78
|
/** Pegin CSV timelock from the locked offchain params version (blocks) */
|
|
65
79
|
timelockPegin: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"signDepositorGraph.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/deposit/signDepositorGraph.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAGrE,OAAO,KAAK,EACV,aAAa,EAEd,MAAM,uCAAuC,CAAC;AAC/C,OAAO,KAAK,EACV,+BAA+B,EAC/B,0BAA0B,EAE1B,wBAAwB,EACzB,MAAM,oCAAoC,CAAC;AAoJ5C,wEAAwE;AACxE,MAAM,WAAW,eAAe;IAC9B,gDAAgD;IAChD,UAAU,EAAE,wBAAwB,CAAC;IACrC,sDAAsD;IACtD,gBAAgB,EAAE,MAAM,CAAC;IACzB,mFAAmF;IACnF,QAAQ,EAAE,KAAK,CAAC;QAAE,aAAa,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CAC3D;AAED,0EAA0E;AAC1E,MAAM,WAAW,8BAA8B;IAC7C,6EAA6E;IAC7E,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAC3B,kDAAkD;IAClD,SAAS,EAAE,eAAe,EAAE,CAAC;CAC9B;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAsB,sCAAsC,CAC1D,cAAc,EAAE,0BAA0B,EAC1C,GAAG,EAAE,4BAA4B,GAChC,OAAO,CAAC,8BAA8B,CAAC,CAuCzC;AAyRD;;;;;GAKG;AACH,MAAM,WAAW,4BAA4B;IAC3C;;;;OAIG;IACH,gBAAgB,EAAE,MAAM,CAAC;IACzB,8EAA8E;IAC9E,UAAU,EAAE,MAAM,CAAC;IACnB,qEAAqE;IACrE,kBAAkB,EAAE,MAAM,CAAC;IAC3B
|
|
1
|
+
{"version":3,"file":"signDepositorGraph.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/deposit/signDepositorGraph.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAGrE,OAAO,KAAK,EACV,aAAa,EAEd,MAAM,uCAAuC,CAAC;AAC/C,OAAO,KAAK,EACV,+BAA+B,EAC/B,0BAA0B,EAE1B,wBAAwB,EACzB,MAAM,oCAAoC,CAAC;AAoJ5C,wEAAwE;AACxE,MAAM,WAAW,eAAe;IAC9B,gDAAgD;IAChD,UAAU,EAAE,wBAAwB,CAAC;IACrC,sDAAsD;IACtD,gBAAgB,EAAE,MAAM,CAAC;IACzB,mFAAmF;IACnF,QAAQ,EAAE,KAAK,CAAC;QAAE,aAAa,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CAC3D;AAED,0EAA0E;AAC1E,MAAM,WAAW,8BAA8B;IAC7C,6EAA6E;IAC7E,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAC3B,kDAAkD;IAClD,SAAS,EAAE,eAAe,EAAE,CAAC;CAC9B;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAsB,sCAAsC,CAC1D,cAAc,EAAE,0BAA0B,EAC1C,GAAG,EAAE,4BAA4B,GAChC,OAAO,CAAC,8BAA8B,CAAC,CAuCzC;AAyRD;;;;;GAKG;AACH,MAAM,WAAW,4BAA4B;IAC3C;;;;OAIG;IACH,gBAAgB,EAAE,MAAM,CAAC;IACzB,8EAA8E;IAC9E,UAAU,EAAE,MAAM,CAAC;IACnB,qEAAqE;IACrE,kBAAkB,EAAE,MAAM,CAAC;IAC3B;;;;;OAKG;IACH,sBAAsB,EAAE,MAAM,CAAC;IAC/B;;;;;;OAMG;IACH,qBAAqB,EAAE,MAAM,EAAE,CAAC;IAChC;;;OAGG;IACH,6BAA6B,EAAE,MAAM,EAAE,CAAC;IACxC,0EAA0E;IAC1E,aAAa,EAAE,MAAM,CAAC;IACtB;;;OAGG;IACH,eAAe,EAAE,MAAM,CAAC;IACxB;;;;OAIG;IACH,cAAc,EAAE,MAAM,CAAC;IACvB;;;;;;OAMG;IACH,uBAAuB,EAAE,MAAM,CAAC;IAChC;;;;OAIG;IACH,cAAc,EAAE,MAAM,EAAE,CAAC;IACzB;;;OAGG;IACH,aAAa,EAAE,MAAM,CAAC;IACtB,2CAA2C;IAC3C,OAAO,EAAE,OAAO,CAAC;IACjB;;;;OAIG;IACH,4BAA4B,EAAE,MAAM,CAAC;IACrC;;;;;OAKG;IACH,4BAA4B,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IAC/D,uEAAuE;IACvE,wBAAwB,EAAE,MAAM,CAAC;CAClC;AAED,MAAM,WAAW,wBAAwB;IACvC,2CAA2C;IAC3C,cAAc,EAAE,0BAA0B,CAAC;IAC3C,iCAAiC;IACjC,SAAS,EAAE,aAAa,CAAC;IACzB,8DAA8D;IAC9D,cAAc,EAAE,4BAA4B,CAAC;CAC9C;AAED;;;;;;;;GAQG;AACH,wBAAsB,kBAAkB,CACtC,MAAM,EAAE,wBAAwB,GAC/B,OAAO,CAAC,+BAA+B,CAAC,CAiD1C"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../../../PayoutManager-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../../../PayoutManager-BXzFIZK6.cjs"),t=require("../../../buildAndBroadcastReclaim-B00roO6R.cjs"),i=require("../wasm/index.cjs"),e=require("../../../peginState-IyE22wWh.cjs"),a=require("../../../state-C4WoNCy1.cjs");exports.computeHashlock=r.computeHashlock;exports.validateSecretAgainstHashlock=r.validateSecretAgainstHashlock;exports.ApplicationEntryPointMismatchError=t.ApplicationEntryPointMismatchError;exports.ArtifactsVaultMismatchError=t.ArtifactsVaultMismatchError;exports.AssertBindingError=t.AssertBindingError;exports.BIP68NotMatureError=t.BIP68NotMatureError;exports.ChallengerSetMismatchError=t.ChallengerSetMismatchError;exports.DELEGATED_CLAIM_TX_GRAPH_VERSION=t.DELEGATED_CLAIM_TX_GRAPH_VERSION;exports.DelegatedClaimSigningIncompleteError=t.DelegatedClaimSigningIncompleteError;exports.GraphFingerprintError=t.GraphFingerprintError;exports.PEGIN_ETH_CONFIRMATIONS=t.PEGIN_ETH_CONFIRMATIONS;exports.ParticipantKeyDriftError=t.ParticipantKeyDriftError;exports.PayoutDestinationError=t.PayoutDestinationError;exports.PayoutInputLeafError=t.PayoutInputLeafError;exports.PeginRegistrationMissingError=t.PeginRegistrationMissingError;exports.PeginRegistrationNotFinalError=t.PeginRegistrationNotFinalError;exports.RECLAIM_MAX_FEE_FRACTION_DENOMINATOR=t.RECLAIM_MAX_FEE_FRACTION_DENOMINATOR;exports.RECLAIM_MAX_FEE_FRACTION_NUMERATOR=t.RECLAIM_MAX_FEE_FRACTION_NUMERATOR;exports.RECLAIM_MAX_FEE_RATE_SATS_VB=t.RECLAIM_MAX_FEE_RATE_SATS_VB;exports.RECLAIM_WARN_FEE_FRACTION_NUMERATOR=t.RECLAIM_WARN_FEE_FRACTION_NUMERATOR;exports.REFUND_MAX_FEE_FRACTION_DENOMINATOR=t.REFUND_MAX_FEE_FRACTION_DENOMINATOR;exports.REFUND_MAX_FEE_FRACTION_NUMERATOR=t.REFUND_MAX_FEE_FRACTION_NUMERATOR;exports.REFUND_MAX_FEE_RATE_SATS_VB=t.REFUND_MAX_FEE_RATE_SATS_VB;exports.REFUND_VSIZE=t.REFUND_VSIZE;exports.ReclaimUneconomicalError=t.ReclaimUneconomicalError;exports.RegisteredVaultVersionMismatchError=t.RegisteredVaultVersionMismatchError;exports.SigningPlanMismatchError=t.SigningPlanMismatchError;exports.VaultIdBindingError=t.VaultIdBindingError;exports.activateVault=t.activateVault;exports.activateVaultAndRedeem=t.activateVaultAndRedeem;exports.assembleWatchtowerArtifacts=t.assembleWatchtowerArtifacts;exports.assembleWatchtowerArtifactsFromSignatures=t.assembleWatchtowerArtifactsFromSignatures;exports.assertArtifactsUsableForVault=t.assertArtifactsUsableForVault;exports.assertAssertBindsClaimAndPayout=t.assertAssertBindsClaimAndPayout;exports.assertChallengerSetMatchesVault=t.assertChallengerSetMatchesVault;exports.assertClaimSpendsVault=t.assertClaimSpendsVault;exports.assertPayoutPaysRegisteredScript=t.assertPayoutPaysRegisteredScript;exports.assertReturnedGraphMatchesFingerprint=t.assertReturnedGraphMatchesFingerprint;exports.assertTermsMatchVault=t.assertTermsMatchVault;exports.assertVaultProviderHintAccepted=t.assertVaultProviderHintAccepted;exports.buildAndBroadcastReclaim=t.buildAndBroadcastReclaim;exports.buildAndBroadcastRefund=t.buildAndBroadcastRefund;exports.claimExpiredVault=t.claimExpiredVault;exports.copyAssertConnectorLeaf=t.copyAssertConnectorLeaf;exports.deriveClaimerWotsKeypair=t.deriveClaimerWotsKeypair;exports.estimateRefundFeeSats=t.estimateRefundFeeSats;exports.fingerprintReturnedGraph=t.fingerprintReturnedGraph;exports.isApplicationEntryPointMismatchError=t.isApplicationEntryPointMismatchError;exports.isDepositAmountValid=t.isDepositAmountValid;exports.isHintAccepted=t.isHintAccepted;exports.isParticipantKeyDriftError=t.isParticipantKeyDriftError;exports.isPeginRegistrationMissingError=t.isPeginRegistrationMissingError;exports.isPeginRegistrationNotFinalError=t.isPeginRegistrationNotFinalError;exports.isRegisteredVaultVersionMismatchError=t.isRegisteredVaultVersionMismatchError;exports.matchKeyHint=t.matchKeyHint;exports.matchKeySetHint=t.matchKeySetHint;exports.planDelegatedClaimSigning=t.planDelegatedClaimSigning;exports.readDelegatedClaimVaultContext=t.readDelegatedClaimVaultContext;exports.readRefundPrePeginContext=t.readRefundPrePeginContext;exports.readStampedParticipantKeys=t.readStampedParticipantKeys;exports.resolveCurrentParticipantKeys=t.resolveCurrentParticipantKeys;exports.resolveParticipantKeysAtEpochs=t.resolveParticipantKeysAtEpochs;exports.runDepositorPresignFlow=t.runDepositorPresignFlow;exports.signDelegatedClaimPlan=t.signDelegatedClaimPlan;exports.signDepositorGraph=t.signDepositorGraph;exports.submitWotsPublicKey=t.submitWotsPublicKey;exports.summarizeWatchtowerArtifacts=t.summarizeWatchtowerArtifacts;exports.validateDepositAmount=t.validateDepositAmount;exports.validateMultiVaultDepositInputs=t.validateMultiVaultDepositInputs;exports.validateOnChainParticipantKeys=t.validateOnChainParticipantKeys;exports.validateProviderSelection=t.validateProviderSelection;exports.validateRemainingCapacity=t.validateRemainingCapacity;exports.validateVaultAmounts=t.validateVaultAmounts;exports.validateVaultProviderPubkey=t.validateVaultProviderPubkey;exports.verifyRegisteredParticipantKeys=t.verifyRegisteredParticipantKeys;exports.verifyRegisteredVaultVersions=t.verifyRegisteredVaultVersions;exports.waitForPeginRegistrationDepth=t.waitForPeginRegistrationDepth;exports.waitForPeginStatus=t.waitForPeginStatus;exports.attachFinalizedAssert=i.attachFinalizedAssert;exports.finalizePayout=i.finalizePayout;exports.finalizeWronglyChallenged=i.finalizeWronglyChallenged;exports.pinPegoutProof=i.pinPegoutProof;exports.ContractStatus=e.ContractStatus;exports.PeginAction=e.PeginAction;exports.activationDeadlineBlocksRemaining=e.activationDeadlineBlocksRemaining;exports.canPerformAction=e.canPerformAction;exports.getPeginProtocolState=e.getPeginProtocolState;exports.isActivationDeadlinePassedOnChain=e.isActivationDeadlinePassedOnChain;exports.ClaimerPegoutStatusValue=a.ClaimerPegoutStatusValue;exports.isPegoutTerminalStatus=a.isPegoutTerminalStatus;exports.isRecognizedPegoutStatus=a.isRecognizedPegoutStatus;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { c as s, v as e } from "../../../PayoutManager-
|
|
2
|
-
import { J as r, l as n, A as o, a8 as l, C as c, D as E, n as g, G as
|
|
3
|
-
import { attachFinalizedAssert as
|
|
4
|
-
import { C as
|
|
5
|
-
import { C as La, g as
|
|
1
|
+
import { c as s, v as e } from "../../../PayoutManager-Cjkozmnn.js";
|
|
2
|
+
import { J as r, l as n, A as o, a8 as l, C as c, D as E, n as g, G as d, u, W as A, P as R, j as m, v as p, w as P, ai as _, aj as C, ak as M, al as h, ab as F, ac as f, ad as S, ae as V, ag as y, Z as N, S as D, V as I, a as v, b as T, d as O, e as K, m as b, f as B, g as U, t as x, i as H, B as L, o as G, a1 as W, ah as X, a9 as w, c as k, k as z, h as j, aa as Z, E as q, K as J, M as Q, a2 as Y, X as $, x as aa, y as ta, _ as sa, a3 as ea, a4 as ia, p as ra, r as na, af as oa, a5 as la, a6 as ca, a7 as Ea, F as ga, q as da, H as ua, I as Aa, s as Ra, N as ma, O as pa, L as Pa, Q as _a, R as Ca, T as Ma, U as ha, Y as Fa, $ as fa, z as Sa, a0 as Va } from "../../../buildAndBroadcastReclaim-DU8iOtbn.js";
|
|
3
|
+
import { attachFinalizedAssert as Na, finalizePayout as Da, finalizeWronglyChallenged as Ia, pinPegoutProof as va } from "../wasm/index.js";
|
|
4
|
+
import { C as Oa, P as Ka, a as ba, c as Ba, g as Ua, i as xa } from "../../../peginState-CIibG9S_.js";
|
|
5
|
+
import { C as La, g as Ga, f as Wa } from "../../../state-CFn1rT74.js";
|
|
6
6
|
export {
|
|
7
7
|
r as ApplicationEntryPointMismatchError,
|
|
8
8
|
n as ArtifactsVaultMismatchError,
|
|
@@ -10,15 +10,15 @@ export {
|
|
|
10
10
|
l as BIP68NotMatureError,
|
|
11
11
|
c as ChallengerSetMismatchError,
|
|
12
12
|
La as ClaimerPegoutStatusValue,
|
|
13
|
-
|
|
13
|
+
Oa as ContractStatus,
|
|
14
14
|
E as DELEGATED_CLAIM_TX_GRAPH_VERSION,
|
|
15
15
|
g as DelegatedClaimSigningIncompleteError,
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
d as GraphFingerprintError,
|
|
17
|
+
u as PEGIN_ETH_CONFIRMATIONS,
|
|
18
|
+
A as ParticipantKeyDriftError,
|
|
19
19
|
R as PayoutDestinationError,
|
|
20
20
|
m as PayoutInputLeafError,
|
|
21
|
-
|
|
21
|
+
Ka as PeginAction,
|
|
22
22
|
p as PeginRegistrationMissingError,
|
|
23
23
|
P as PeginRegistrationNotFinalError,
|
|
24
24
|
_ as RECLAIM_MAX_FEE_FRACTION_DENOMINATOR,
|
|
@@ -26,72 +26,73 @@ export {
|
|
|
26
26
|
M as RECLAIM_MAX_FEE_RATE_SATS_VB,
|
|
27
27
|
h as RECLAIM_WARN_FEE_FRACTION_NUMERATOR,
|
|
28
28
|
F as REFUND_MAX_FEE_FRACTION_DENOMINATOR,
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
29
|
+
f as REFUND_MAX_FEE_FRACTION_NUMERATOR,
|
|
30
|
+
S as REFUND_MAX_FEE_RATE_SATS_VB,
|
|
31
|
+
V as REFUND_VSIZE,
|
|
32
32
|
y as ReclaimUneconomicalError,
|
|
33
33
|
N as RegisteredVaultVersionMismatchError,
|
|
34
34
|
D as SigningPlanMismatchError,
|
|
35
35
|
I as VaultIdBindingError,
|
|
36
36
|
v as activateVault,
|
|
37
37
|
T as activateVaultAndRedeem,
|
|
38
|
-
|
|
38
|
+
ba as activationDeadlineBlocksRemaining,
|
|
39
39
|
O as assembleWatchtowerArtifacts,
|
|
40
40
|
K as assembleWatchtowerArtifactsFromSignatures,
|
|
41
41
|
b as assertArtifactsUsableForVault,
|
|
42
42
|
B as assertAssertBindsClaimAndPayout,
|
|
43
43
|
U as assertChallengerSetMatchesVault,
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
44
|
+
x as assertClaimSpendsVault,
|
|
45
|
+
H as assertPayoutPaysRegisteredScript,
|
|
46
|
+
L as assertReturnedGraphMatchesFingerprint,
|
|
47
47
|
G as assertTermsMatchVault,
|
|
48
48
|
W as assertVaultProviderHintAccepted,
|
|
49
|
-
|
|
49
|
+
Na as attachFinalizedAssert,
|
|
50
50
|
X as buildAndBroadcastReclaim,
|
|
51
51
|
w as buildAndBroadcastRefund,
|
|
52
|
-
|
|
52
|
+
Ba as canPerformAction,
|
|
53
53
|
k as claimExpiredVault,
|
|
54
54
|
s as computeHashlock,
|
|
55
55
|
z as copyAssertConnectorLeaf,
|
|
56
56
|
j as deriveClaimerWotsKeypair,
|
|
57
57
|
Z as estimateRefundFeeSats,
|
|
58
|
-
|
|
59
|
-
|
|
58
|
+
Da as finalizePayout,
|
|
59
|
+
Ia as finalizeWronglyChallenged,
|
|
60
60
|
q as fingerprintReturnedGraph,
|
|
61
|
-
|
|
62
|
-
|
|
61
|
+
Ua as getPeginProtocolState,
|
|
62
|
+
xa as isActivationDeadlinePassedOnChain,
|
|
63
63
|
J as isApplicationEntryPointMismatchError,
|
|
64
64
|
Q as isDepositAmountValid,
|
|
65
65
|
Y as isHintAccepted,
|
|
66
66
|
$ as isParticipantKeyDriftError,
|
|
67
67
|
aa as isPeginRegistrationMissingError,
|
|
68
68
|
ta as isPeginRegistrationNotFinalError,
|
|
69
|
-
|
|
70
|
-
|
|
69
|
+
Ga as isPegoutTerminalStatus,
|
|
70
|
+
Wa as isRecognizedPegoutStatus,
|
|
71
71
|
sa as isRegisteredVaultVersionMismatchError,
|
|
72
72
|
ea as matchKeyHint,
|
|
73
73
|
ia as matchKeySetHint,
|
|
74
|
-
|
|
74
|
+
va as pinPegoutProof,
|
|
75
75
|
ra as planDelegatedClaimSigning,
|
|
76
76
|
na as readDelegatedClaimVaultContext,
|
|
77
|
-
oa as
|
|
78
|
-
la as
|
|
79
|
-
ca as
|
|
80
|
-
Ea as
|
|
81
|
-
ga as
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
Ra as
|
|
86
|
-
ma as
|
|
87
|
-
pa as
|
|
88
|
-
Pa as
|
|
89
|
-
_a as
|
|
77
|
+
oa as readRefundPrePeginContext,
|
|
78
|
+
la as readStampedParticipantKeys,
|
|
79
|
+
ca as resolveCurrentParticipantKeys,
|
|
80
|
+
Ea as resolveParticipantKeysAtEpochs,
|
|
81
|
+
ga as runDepositorPresignFlow,
|
|
82
|
+
da as signDelegatedClaimPlan,
|
|
83
|
+
ua as signDepositorGraph,
|
|
84
|
+
Aa as submitWotsPublicKey,
|
|
85
|
+
Ra as summarizeWatchtowerArtifacts,
|
|
86
|
+
ma as validateDepositAmount,
|
|
87
|
+
pa as validateMultiVaultDepositInputs,
|
|
88
|
+
Pa as validateOnChainParticipantKeys,
|
|
89
|
+
_a as validateProviderSelection,
|
|
90
|
+
Ca as validateRemainingCapacity,
|
|
90
91
|
e as validateSecretAgainstHashlock,
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
92
|
+
Ma as validateVaultAmounts,
|
|
93
|
+
ha as validateVaultProviderPubkey,
|
|
94
|
+
Fa as verifyRegisteredParticipantKeys,
|
|
95
|
+
fa as verifyRegisteredVaultVersions,
|
|
95
96
|
Sa as waitForPeginRegistrationDepth,
|
|
96
97
|
Va as waitForPeginStatus
|
|
97
98
|
};
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import { Hex } from 'viem';
|
|
2
|
-
import { OperationKeyReader, UniversalChallengerReader,
|
|
2
|
+
import { OperationKeyReader, UniversalChallengerReader, VaultBasicInfo, VaultKeeperReader, VaultProtocolInfo, VaultRegistryReader } from '../../clients/eth/types';
|
|
3
3
|
import { ParticipantKeySet } from './types';
|
|
4
4
|
/**
|
|
5
5
|
* The reads this needs, as `Pick`s so a caller can pass the SDK's viem readers
|
|
6
6
|
* or a narrower implementation.
|
|
7
|
-
*
|
|
8
|
-
* @experimental
|
|
9
7
|
*/
|
|
10
8
|
export interface StampedParticipantKeyReaders {
|
|
11
9
|
registryReader: Pick<VaultRegistryReader, "getVaultProviderGenesisBtcPubKey" | "getVaultKeyEpochs">;
|
|
@@ -13,17 +11,31 @@ export interface StampedParticipantKeyReaders {
|
|
|
13
11
|
universalChallengerReader: Pick<UniversalChallengerReader, "getUniversalChallengersByVersion">;
|
|
14
12
|
operationKeyReader: Pick<OperationKeyReader, "getOperationKeysAtEpochs">;
|
|
15
13
|
}
|
|
16
|
-
/** @
|
|
14
|
+
/** Input to {@link readStampedParticipantKeys}. */
|
|
17
15
|
export interface ReadStampedParticipantKeysParams {
|
|
16
|
+
/** The vault whose frozen key epochs to resolve at. */
|
|
18
17
|
vaultId: Hex;
|
|
19
|
-
/**
|
|
20
|
-
|
|
18
|
+
/**
|
|
19
|
+
* The vault's stamped provider, application and membership versions, read
|
|
20
|
+
* from the registry. A full `VaultData` from `VaultRegistryReader.getVaultData`
|
|
21
|
+
* satisfies it; a caller holding only these four fields can pass them alone.
|
|
22
|
+
*/
|
|
23
|
+
vault: {
|
|
24
|
+
/** The vault's provider and application entry point. */
|
|
25
|
+
basic: Pick<VaultBasicInfo, "vaultProvider" | "applicationEntryPoint">;
|
|
26
|
+
/** The membership versions the vault's rosters are read at. */
|
|
27
|
+
protocol: Pick<VaultProtocolInfo, "appVaultKeepersVersion" | "universalChallengersVersion">;
|
|
28
|
+
};
|
|
29
|
+
/** The on-chain reads; the SDK's viem readers satisfy every one. */
|
|
21
30
|
readers: StampedParticipantKeyReaders;
|
|
22
31
|
}
|
|
23
32
|
/**
|
|
33
|
+
* Read the operation keys an existing vault's scripts were built with: the
|
|
34
|
+
* rosters at its stamped membership versions, resolved at its frozen key
|
|
35
|
+
* epochs.
|
|
36
|
+
*
|
|
24
37
|
* @throws When either stamped roster is empty, or key resolution fails
|
|
25
38
|
* (`resolveParticipantKeysAtEpochs`).
|
|
26
|
-
* @experimental
|
|
27
39
|
*/
|
|
28
40
|
export declare function readStampedParticipantKeys(params: ReadStampedParticipantKeysParams): Promise<ParticipantKeySet>;
|
|
29
41
|
//# sourceMappingURL=readStampedParticipantKeys.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"readStampedParticipantKeys.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/participants/readStampedParticipantKeys.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"readStampedParticipantKeys.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/participants/readStampedParticipantKeys.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AAEhC,OAAO,KAAK,EACV,kBAAkB,EAClB,yBAAyB,EACzB,cAAc,EACd,iBAAiB,EACjB,iBAAiB,EACjB,mBAAmB,EACpB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAEjD;;;GAGG;AACH,MAAM,WAAW,4BAA4B;IAC3C,cAAc,EAAE,IAAI,CAClB,mBAAmB,EACnB,kCAAkC,GAAG,mBAAmB,CACzD,CAAC;IACF,iBAAiB,EAAE,IAAI,CAAC,iBAAiB,EAAE,0BAA0B,CAAC,CAAC;IACvE,yBAAyB,EAAE,IAAI,CAC7B,yBAAyB,EACzB,kCAAkC,CACnC,CAAC;IACF,kBAAkB,EAAE,IAAI,CAAC,kBAAkB,EAAE,0BAA0B,CAAC,CAAC;CAC1E;AAED,mDAAmD;AACnD,MAAM,WAAW,gCAAgC;IAC/C,uDAAuD;IACvD,OAAO,EAAE,GAAG,CAAC;IACb;;;;OAIG;IACH,KAAK,EAAE;QACL,wDAAwD;QACxD,KAAK,EAAE,IAAI,CAAC,cAAc,EAAE,eAAe,GAAG,uBAAuB,CAAC,CAAC;QACvE,+DAA+D;QAC/D,QAAQ,EAAE,IAAI,CACZ,iBAAiB,EACjB,wBAAwB,GAAG,6BAA6B,CACzD,CAAC;KACH,CAAC;IACF,oEAAoE;IACpE,OAAO,EAAE,4BAA4B,CAAC;CACvC;AAED;;;;;;;GAOG;AACH,wBAAsB,0BAA0B,CAC9C,MAAM,EAAE,gCAAgC,GACvC,OAAO,CAAC,iBAAiB,CAAC,CAiD5B"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tests for readRefundPrePeginContext — the refund context for an existing
|
|
3
|
+
* vault, read at the vault's frozen RFC-006 key epochs.
|
|
4
|
+
*
|
|
5
|
+
* Every participant in this fixture rotated its operation key before the
|
|
6
|
+
* vault registered, so the vault's frozen epochs point at the rotated keys
|
|
7
|
+
* while the rosters still list the registration keys. That is the case this
|
|
8
|
+
* module exists for: a refund built from the roster keys is refused, and one
|
|
9
|
+
* built from the frozen-epoch keys spends the funded HTLC.
|
|
10
|
+
*/
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=readRefundPrePeginContext.test.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"readRefundPrePeginContext.test.d.ts","sourceRoot":"","sources":["../../../../../../src/tbv/core/services/refund/__tests__/readRefundPrePeginContext.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG"}
|
|
@@ -77,27 +77,53 @@ export interface VaultRefundData {
|
|
|
77
77
|
batch: ReadonlyArray<VaultBatchEntry>;
|
|
78
78
|
}
|
|
79
79
|
/**
|
|
80
|
-
*
|
|
81
|
-
*
|
|
82
|
-
*
|
|
83
|
-
*
|
|
84
|
-
*
|
|
85
|
-
* `
|
|
86
|
-
*
|
|
87
|
-
*
|
|
88
|
-
*
|
|
89
|
-
*
|
|
80
|
+
* The protocol context the refund rebuilds the vault's Pre-PegIn HTLC from.
|
|
81
|
+
* This is the trust boundary: every field must come from the chain, and
|
|
82
|
+
* {@link readRefundPrePeginContext} reads all of it.
|
|
83
|
+
*
|
|
84
|
+
* The three key fields must be the RFC-006 *operation* keys at the vault's
|
|
85
|
+
* frozen epochs (`vpKeyEpoch`, `appKeeperKeyEpoch`, `ucKeyEpoch`), and the
|
|
86
|
+
* numeric fields must be the offchain params at the vault's
|
|
87
|
+
* `offchainParamsVersion`. The rosters (`getVaultKeepersByVersion`,
|
|
88
|
+
* `getUniversalChallengersByVersion`) hold *registration* keys, which differ
|
|
89
|
+
* from the keys committed by any vault registered after a participant had
|
|
90
|
+
* rotated; a refund rebuilt from them for such a vault no longer matches the
|
|
91
|
+
* funded output and is refused. The indexer's vault-provider key is only a
|
|
92
|
+
* hint (the registration key, or the current operation key once the indexer
|
|
93
|
+
* tracks rotations) and is never the key to build with. Current operation
|
|
94
|
+
* keys are no substitute either: they fail for any vault registered before a
|
|
95
|
+
* participant's latest rotation. A vault's frozen epochs never move, so
|
|
96
|
+
* rotations after it registered do not change its HTLC.
|
|
90
97
|
*/
|
|
91
98
|
export interface RefundPrePeginContext {
|
|
99
|
+
/** The vault provider's operation key at the vault's `vpKeyEpoch` (x-only hex). */
|
|
92
100
|
vaultProviderPubkey: string;
|
|
101
|
+
/** The vault keepers' operation keys at the vault's `appKeeperKeyEpoch`, sorted (x-only hex). */
|
|
93
102
|
vaultKeeperPubkeys: readonly string[];
|
|
103
|
+
/** The universal challengers' operation keys at the vault's `ucKeyEpoch`, sorted (x-only hex). */
|
|
94
104
|
universalChallengerPubkeys: readonly string[];
|
|
105
|
+
/** The refund CSV timelock in blocks: `tRefund` at the vault's `offchainParamsVersion`. */
|
|
95
106
|
timelockRefund: number;
|
|
107
|
+
/**
|
|
108
|
+
* The protocol fee rate (sat/vB) at the vault's `offchainParamsVersion`. It
|
|
109
|
+
* sized the HTLC value; the refund transaction's own fee is
|
|
110
|
+
* `RefundInput.feeRate`.
|
|
111
|
+
*/
|
|
96
112
|
feeRate: bigint;
|
|
113
|
+
/** The minimum peg-in fee rate (sat/vB) at the vault's `offchainParamsVersion`. */
|
|
97
114
|
minPeginFeeRate: bigint;
|
|
115
|
+
/**
|
|
116
|
+
* The number of local challengers in the depositor's own claim graph, which
|
|
117
|
+
* this value sizes: the vault keeper count. (A vault provider's or a
|
|
118
|
+
* keeper's claim graph uses a different rule: the vault provider and the
|
|
119
|
+
* keepers, minus the claimer.)
|
|
120
|
+
*/
|
|
98
121
|
numLocalChallengers: number;
|
|
122
|
+
/** The security council quorum at the vault's `offchainParamsVersion`. */
|
|
99
123
|
councilQuorum: number;
|
|
124
|
+
/** The security council size: the number of `securityCouncilKeys` at the vault's `offchainParamsVersion`. */
|
|
100
125
|
councilSize: number;
|
|
126
|
+
/** The Bitcoin network the vault lives on. */
|
|
101
127
|
network: Network;
|
|
102
128
|
}
|
|
103
129
|
/** Minimum shape required from a broadcast result. */
|
|
@@ -115,8 +141,11 @@ export interface RefundInput<R extends BtcBroadcastResult = BtcBroadcastResult>
|
|
|
115
141
|
*/
|
|
116
142
|
readVault: () => Promise<VaultRefundData>;
|
|
117
143
|
/**
|
|
118
|
-
* Fetch the
|
|
119
|
-
*
|
|
144
|
+
* Fetch the protocol context the refund rebuilds the HTLC from. Use
|
|
145
|
+
* {@link readRefundPrePeginContext}, closing over `vaultId`:
|
|
146
|
+
* `(vault) => readRefundPrePeginContext({ vaultId, vault, readers, network })`.
|
|
147
|
+
* A hand-written implementation must return the operation keys at the
|
|
148
|
+
* vault's frozen epochs; see {@link RefundPrePeginContext}.
|
|
120
149
|
*/
|
|
121
150
|
readPrePeginContext: (vault: VaultRefundData) => Promise<RefundPrePeginContext>;
|
|
122
151
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"buildAndBroadcastRefund.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/refund/buildAndBroadcastRefund.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAErE,OAAO,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AAEzC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qDAAqD,CAAC;AA+B3F,eAAO,MAAM,YAAY,MAAM,CAAC;AAgBhC,eAAO,MAAM,2BAA2B,OAAO,CAAC;AAQhD,eAAO,MAAM,iCAAiC,MAAM,CAAC;AACrD,eAAO,MAAM,mCAAmC,OAAO,CAAC;AAExD;;;;;GAKG;AACH,wBAAgB,qBAAqB,CAAC,aAAa,EAAE,MAAM,GAAG,MAAM,CAOnE;AAqBD;;;;GAIG;AACH,MAAM,WAAW,eAAe;IAC9B,yEAAyE;IACzE,QAAQ,EAAE,GAAG,CAAC;IACd;;;;;;OAMG;IACH,MAAM,EAAE,MAAM,CAAC;IACf,oEAAoE;IACpE,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,WAAW,eAAe;IAC9B;;;;OAIG;IACH,gBAAgB,EAAE,MAAM,CAAC;IACzB,QAAQ,EAAE,GAAG,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,qBAAqB,EAAE,MAAM,CAAC;IAC9B,sBAAsB,EAAE,MAAM,CAAC;IAC/B,2BAA2B,EAAE,MAAM,CAAC;IACpC,aAAa,EAAE,OAAO,CAAC;IACvB,qBAAqB,EAAE,OAAO,CAAC;IAC/B,+EAA+E;IAC/E,MAAM,EAAE,MAAM,CAAC;IACf;;;;OAIG;IACH,qBAAqB,EAAE,MAAM,CAAC;IAC9B,iFAAiF;IACjF,kBAAkB,EAAE,MAAM,CAAC;IAC3B;;;;;OAKG;IACH,KAAK,EAAE,aAAa,CAAC,eAAe,CAAC,CAAC;CACvC;AAED
|
|
1
|
+
{"version":3,"file":"buildAndBroadcastRefund.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/refund/buildAndBroadcastRefund.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAErE,OAAO,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AAEzC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qDAAqD,CAAC;AA+B3F,eAAO,MAAM,YAAY,MAAM,CAAC;AAgBhC,eAAO,MAAM,2BAA2B,OAAO,CAAC;AAQhD,eAAO,MAAM,iCAAiC,MAAM,CAAC;AACrD,eAAO,MAAM,mCAAmC,OAAO,CAAC;AAExD;;;;;GAKG;AACH,wBAAgB,qBAAqB,CAAC,aAAa,EAAE,MAAM,GAAG,MAAM,CAOnE;AAqBD;;;;GAIG;AACH,MAAM,WAAW,eAAe;IAC9B,yEAAyE;IACzE,QAAQ,EAAE,GAAG,CAAC;IACd;;;;;;OAMG;IACH,MAAM,EAAE,MAAM,CAAC;IACf,oEAAoE;IACpE,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,WAAW,eAAe;IAC9B;;;;OAIG;IACH,gBAAgB,EAAE,MAAM,CAAC;IACzB,QAAQ,EAAE,GAAG,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,qBAAqB,EAAE,MAAM,CAAC;IAC9B,sBAAsB,EAAE,MAAM,CAAC;IAC/B,2BAA2B,EAAE,MAAM,CAAC;IACpC,aAAa,EAAE,OAAO,CAAC;IACvB,qBAAqB,EAAE,OAAO,CAAC;IAC/B,+EAA+E;IAC/E,MAAM,EAAE,MAAM,CAAC;IACf;;;;OAIG;IACH,qBAAqB,EAAE,MAAM,CAAC;IAC9B,iFAAiF;IACjF,kBAAkB,EAAE,MAAM,CAAC;IAC3B;;;;;OAKG;IACH,KAAK,EAAE,aAAa,CAAC,eAAe,CAAC,CAAC;CACvC;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,WAAW,qBAAqB;IACpC,mFAAmF;IACnF,mBAAmB,EAAE,MAAM,CAAC;IAC5B,iGAAiG;IACjG,kBAAkB,EAAE,SAAS,MAAM,EAAE,CAAC;IACtC,kGAAkG;IAClG,0BAA0B,EAAE,SAAS,MAAM,EAAE,CAAC;IAC9C,2FAA2F;IAC3F,cAAc,EAAE,MAAM,CAAC;IACvB;;;;OAIG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB,mFAAmF;IACnF,eAAe,EAAE,MAAM,CAAC;IACxB;;;;;OAKG;IACH,mBAAmB,EAAE,MAAM,CAAC;IAC5B,0EAA0E;IAC1E,aAAa,EAAE,MAAM,CAAC;IACtB,6GAA6G;IAC7G,WAAW,EAAE,MAAM,CAAC;IACpB,8CAA8C;IAC9C,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,sDAAsD;AACtD,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,MAAM,cAAc,CAAC,CAAC,SAAS,kBAAkB,GAAG,kBAAkB,IAC1E,CAAC,WAAW,EAAE,MAAM,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;AAEtC,MAAM,MAAM,gBAAgB,GAAG,CAC7B,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,eAAe,KAClB,OAAO,CAAC,MAAM,CAAC,CAAC;AAErB,MAAM,WAAW,WAAW,CAC1B,CAAC,SAAS,kBAAkB,GAAG,kBAAkB;IAEjD,OAAO,EAAE,GAAG,CAAC;IACb;;;;OAIG;IACH,SAAS,EAAE,MAAM,OAAO,CAAC,eAAe,CAAC,CAAC;IAC1C;;;;;;OAMG;IACH,mBAAmB,EAAE,CACnB,KAAK,EAAE,eAAe,KACnB,OAAO,CAAC,qBAAqB,CAAC,CAAC;IACpC;;;;;OAKG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB,4EAA4E;IAC5E,QAAQ,EAAE,gBAAgB,CAAC;IAC3B,oEAAoE;IACpE,WAAW,EAAE,cAAc,CAAC,CAAC,CAAC,CAAC;IAC/B,uCAAuC;IACvC,MAAM,CAAC,EAAE,WAAW,CAAC;CACtB;AAmID;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAsB,uBAAuB,CAC3C,CAAC,SAAS,kBAAkB,GAAG,kBAAkB,EACjD,KAAK,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAqLnC"}
|
|
@@ -5,4 +5,5 @@
|
|
|
5
5
|
*/
|
|
6
6
|
export { BIP68NotMatureError } from './errors';
|
|
7
7
|
export { buildAndBroadcastRefund, estimateRefundFeeSats, REFUND_MAX_FEE_FRACTION_DENOMINATOR, REFUND_MAX_FEE_FRACTION_NUMERATOR, REFUND_MAX_FEE_RATE_SATS_VB, REFUND_VSIZE, type BtcBroadcastResult, type BtcBroadcaster, type RefundInput, type RefundPrePeginContext, type RefundPsbtSigner, type VaultBatchEntry, type VaultRefundData, } from './buildAndBroadcastRefund';
|
|
8
|
+
export { readRefundPrePeginContext, type ReadRefundPrePeginContextParams, type RefundPrePeginContextReaders, } from './readRefundPrePeginContext';
|
|
8
9
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/refund/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,EACL,uBAAuB,EACvB,qBAAqB,EACrB,mCAAmC,EACnC,iCAAiC,EACjC,2BAA2B,EAC3B,YAAY,EACZ,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,qBAAqB,EAC1B,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,KAAK,eAAe,GACrB,MAAM,2BAA2B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/refund/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,EACL,uBAAuB,EACvB,qBAAqB,EACrB,mCAAmC,EACnC,iCAAiC,EACjC,2BAA2B,EAC3B,YAAY,EACZ,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,qBAAqB,EAC1B,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,KAAK,eAAe,GACrB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EACL,yBAAyB,EACzB,KAAK,+BAA+B,EACpC,KAAK,4BAA4B,GAClC,MAAM,6BAA6B,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { Network } from '@babylonlabs-io/babylon-tbv-rust-wasm';
|
|
2
|
+
import { Hex } from 'viem';
|
|
3
|
+
import { ProtocolParamsReader } from '../../clients/eth/types';
|
|
4
|
+
import { StampedParticipantKeyReaders } from '../participants/readStampedParticipantKeys';
|
|
5
|
+
import { RefundPrePeginContext, VaultRefundData } from './buildAndBroadcastRefund';
|
|
6
|
+
/**
|
|
7
|
+
* The reads {@link readRefundPrePeginContext} needs: the stamped participant
|
|
8
|
+
* key reads plus the versioned offchain params.
|
|
9
|
+
*/
|
|
10
|
+
export interface RefundPrePeginContextReaders extends StampedParticipantKeyReaders {
|
|
11
|
+
/** Reads the offchain params at the vault's `offchainParamsVersion`. */
|
|
12
|
+
protocolParamsReader: Pick<ProtocolParamsReader, "getOffchainParamsByVersion">;
|
|
13
|
+
}
|
|
14
|
+
/** Input to {@link readRefundPrePeginContext}. */
|
|
15
|
+
export interface ReadRefundPrePeginContextParams {
|
|
16
|
+
/** The vault being refunded: the same id passed to `buildAndBroadcastRefund`. */
|
|
17
|
+
vaultId: Hex;
|
|
18
|
+
/** The record `readVault` returned. Its stamped versions select the rosters and the params. */
|
|
19
|
+
vault: VaultRefundData;
|
|
20
|
+
/** The on-chain reads; the SDK's viem readers satisfy every one. */
|
|
21
|
+
readers: RefundPrePeginContextReaders;
|
|
22
|
+
/** The Bitcoin network the vault lives on, passed through to the context. */
|
|
23
|
+
network: Network;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Read the {@link RefundPrePeginContext} for an existing vault: participant
|
|
27
|
+
* operation keys at the vault's frozen epochs, and numeric params at its
|
|
28
|
+
* `offchainParamsVersion`.
|
|
29
|
+
*
|
|
30
|
+
* Pass it to `buildAndBroadcastRefund`, closing over the vault id:
|
|
31
|
+
*
|
|
32
|
+
* ```ts
|
|
33
|
+
* readPrePeginContext: (vault) =>
|
|
34
|
+
* readRefundPrePeginContext({ vaultId, vault, readers, network }),
|
|
35
|
+
* ```
|
|
36
|
+
*
|
|
37
|
+
* @throws When either stamped roster is empty, key resolution fails
|
|
38
|
+
* (`readStampedParticipantKeys`), or the offchain params read fails.
|
|
39
|
+
*/
|
|
40
|
+
export declare function readRefundPrePeginContext(params: ReadRefundPrePeginContextParams): Promise<RefundPrePeginContext>;
|
|
41
|
+
//# sourceMappingURL=readRefundPrePeginContext.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"readRefundPrePeginContext.d.ts","sourceRoot":"","sources":["../../../../../src/tbv/core/services/refund/readRefundPrePeginContext.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AACrE,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AAEhC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AACpE,OAAO,EAEL,KAAK,4BAA4B,EAClC,MAAM,4CAA4C,CAAC;AACpD,OAAO,KAAK,EACV,qBAAqB,EACrB,eAAe,EAChB,MAAM,2BAA2B,CAAC;AAEnC;;;GAGG;AACH,MAAM,WAAW,4BACf,SAAQ,4BAA4B;IACpC,wEAAwE;IACxE,oBAAoB,EAAE,IAAI,CAAC,oBAAoB,EAAE,4BAA4B,CAAC,CAAC;CAChF;AAED,kDAAkD;AAClD,MAAM,WAAW,+BAA+B;IAC9C,iFAAiF;IACjF,OAAO,EAAE,GAAG,CAAC;IACb,+FAA+F;IAC/F,KAAK,EAAE,eAAe,CAAC;IACvB,oEAAoE;IACpE,OAAO,EAAE,4BAA4B,CAAC;IACtC,6EAA6E;IAC7E,OAAO,EAAE,OAAO,CAAC;CAClB;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,yBAAyB,CAC7C,MAAM,EAAE,+BAA+B,GACtC,OAAO,CAAC,qBAAqB,CAAC,CAuChC"}
|
package/dist/tbv/index.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("../verifyScriptPathSchnorrSignature-CgDa9Rcg.cjs"),O=require("../secp256k1-DDHQ1_za.cjs"),o=require("./core/wasm/index.cjs"),R=require("../verifyKeyPathSchnorrSignature-DcxCojp0.cjs"),E=require("../challengeAssert-BE6Wm4x1.cjs"),r=require("../bitcoin-D-O2GjbC.cjs"),F=require("../abortSignals-msbmbqFe.cjs"),I=require("../signing-DvISftFk.cjs"),P=require("../validation-C6XTfZak.cjs"),V=require("./core/utils/eth/index.cjs"),_=require("../PeginManager-CMbRRTnr.cjs"),d=require("../PayoutManager-Dopxq_Jv.cjs"),s=require("./core/clients/mempool/index.cjs"),l=require("../registration-records-CKc0OVuK.cjs"),C=require("../signer-set-reader-CJfV-GDz.cjs"),A=require("../pegin-registration-client-DLlaZbsZ.cjs"),h=require("../types-BnZIbDHb.cjs"),y=require("../ApplicationRegistry.abi-sMiTWmnL.cjs"),N=require("../BTCVaultRegistry.abi-DzbfZ9_s.cjs"),u=require("../BTCVaultRegistryKeyEpochs.abi-CReWFJdu.cjs"),M=require("../ProtocolParams.abi-DWfIh6VH.cjs"),b=require("../VaultErrors.abi-Hjn1CdLs.cjs"),v=require("../buildVaultContextInputForClaim-9XZaqIiw.cjs"),S=require("../deriveVaultRoot-C3uqnJto.cjs"),D=require("../parseFundingOutpoints-C_-PT9BT.cjs"),B=require("../btcTxHash-CGb5BqFL.cjs"),c=require("../psbtInputFields-BrV_ZfL_.cjs"),i=require("../fundPeginTransaction-54-Rwb2k.cjs"),T=require("../reservation-CA5knoQ0.cjs"),m=require("../index-Dn7RlsKK.cjs"),a=require("../state-C4WoNCy1.cjs"),g=require("../primeVpAuth-Ch-ig2My.cjs"),t=require("../toRefundInputs-BSQjDOK9.cjs"),e=require("../buildAndBroadcastReclaim-CVmG3ldA.cjs"),p=require("../peginState-IyE22wWh.cjs");exports.PEGIN_DEPOSITOR_CLAIM_VOUT=n.PEGIN_DEPOSITOR_CLAIM_VOUT;exports.PsbtSubstitutionError=n.PsbtSubstitutionError;exports.assertPsbtUnsignedTxMatches=n.assertPsbtUnsignedTxMatches;exports.assertScriptPathSchnorrSignature=n.assertScriptPathSchnorrSignature;exports.buildPayoutPsbt=n.buildPayoutPsbt;exports.buildPeginTxFromFundedPrePegin=n.buildPeginTxFromFundedPrePegin;exports.buildPrePeginPsbt=n.buildPrePeginPsbt;exports.computeNumLocalChallengers=n.computeNumLocalChallengers;exports.createPayoutScript=n.createPayoutScript;exports.deriveDepositorClaimDescriptor=n.deriveDepositorClaimDescriptor;exports.deriveDepositorClaimScriptPubKey=n.deriveDepositorClaimScriptPubKey;exports.extractPayoutSignature=n.extractPayoutSignature;exports.assertValidVaultCoreVersion=O.assertValidVaultCoreVersion;exports.attachFinalizedAssert=o.attachFinalizedAssert;exports.computeMinClaimValue=o.computeMinClaimValue;exports.computeMinPeginFee=o.computeMinPeginFee;exports.deriveVaultId=o.deriveVaultId;exports.expandAuthAnchor=o.expandAuthAnchor;exports.expandHashlockSecret=o.expandHashlockSecret;exports.expandWotsSeed=o.expandWotsSeed;exports.finalizePayout=o.finalizePayout;exports.finalizeWronglyChallenged=o.finalizeWronglyChallenged;exports.peginP2aAnchorOutput=o.peginP2aAnchorOutput;exports.pinPegoutProof=o.pinPegoutProof;exports.supportedTxGraphVersions=o.supportedTxGraphVersions;exports.validatePeginP2aAnchor=o.validatePeginP2aAnchor;exports.assertKeyPathSchnorrSignature=R.assertKeyPathSchnorrSignature;exports.assertReturnedKeyPathSignatures=R.assertReturnedKeyPathSignatures;exports.buildPeginInputPsbt=R.buildPeginInputPsbt;exports.extractPeginInputSignature=R.extractPeginInputSignature;exports.finalizePeginInputPsbt=R.finalizePeginInputPsbt;exports.buildChallengeAssertPsbt=E.buildChallengeAssertPsbt;exports.buildNoPayoutPsbt=E.buildNoPayoutPsbt;exports.buildReclaimPsbt=E.buildReclaimPsbt;exports.buildRefundPsbt=E.buildRefundPsbt;exports.estimateReclaimFeeSats=E.estimateReclaimFeeSats;exports.finalizeScriptPathWithSignatures=E.finalizeScriptPathWithSignatures;exports.reclaimVsize=E.reclaimVsize;exports.canonicalizeBtcPubkey=r.canonicalizeBtcPubkey;exports.deriveBip86ScriptPubKeyHex=r.deriveBip86ScriptPubKeyHex;exports.deriveNativeSegwitAddress=r.deriveNativeSegwitAddress;exports.deriveTaprootAddress=r.deriveTaprootAddress;exports.ensureHexPrefix=r.ensureHexPrefix;exports.formatSatoshisToBtc=r.formatSatoshisToBtc;exports.getNetwork=r.getNetwork;exports.getSortedXOnlyPubkeys=r.getSortedXOnlyPubkeys;exports.hexToUint8Array=r.hexToUint8Array;exports.isAddressFromPublicKey=r.isAddressFromPublicKey;exports.isValidHex=r.isValidHex;exports.processPublicKeyToXOnly=r.processPublicKeyToXOnly;exports.stripHexPrefix=r.stripHexPrefix;exports.toXOnly=r.toXOnly;exports.uint8ArrayToHex=r.uint8ArrayToHex;exports.validateWalletPubkey=r.validateWalletPubkey;exports.combineAbortSignals=F.combineAbortSignals;exports.createTaprootScriptPathSignOptions=I.createTaprootScriptPathSignOptions;exports.createTaprootScriptPathSignOptionsForInput=I.createTaprootScriptPathSignOptionsForInput;exports.BITCOIN_ADDRESS_RE=P.BITCOIN_ADDRESS_RE;exports.COMPRESSED_PUBKEY_HEX_LEN=P.COMPRESSED_PUBKEY_HEX_LEN;exports.HEX_RE=P.HEX_RE;exports.KNOWN_SCRIPT_PREFIXES=P.KNOWN_SCRIPT_PREFIXES;exports.MAX_REASONABLE_FEE_SATS=P.MAX_REASONABLE_FEE_SATS;exports.TXID_RE=P.TXID_RE;exports.X_ONLY_PUBKEY_HEX_LEN=P.X_ONLY_PUBKEY_HEX_LEN;exports.waitForTransactionReceiptSmartAware=V.waitForTransactionReceiptSmartAware;exports.PeginManager=_.PeginManager;exports.buildDepositTerms=_.buildDepositTerms;exports.computeWotsBlockPublicKeysHash=_.computeWotsBlockPublicKeysHash;exports.deriveWotsBlocksFromSeed=_.deriveWotsBlocksFromSeed;exports.ensurePrePeginTermsApproval=_.ensurePrePeginTermsApproval;exports.PayoutManager=d.PayoutManager;exports.computeHashlock=d.computeHashlock;exports.forwardDepositApproval=d.forwardDepositApproval;exports.requireChangeAddress=d.requireChangeAddress;exports.supportsDepositApproval=d.supportsDepositApproval;exports.validateSecretAgainstHashlock=d.validateSecretAgainstHashlock;exports.MEMPOOL_API_URLS=s.MEMPOOL_API_URLS;exports.MempoolNotFoundError=s.MempoolNotFoundError;exports.getAddressTxs=s.getAddressTxs;exports.getAddressUtxos=s.getAddressUtxos;exports.getMempoolApiUrl=s.getMempoolApiUrl;exports.getNetworkFees=s.getNetworkFees;exports.getOutspend=s.getOutspend;exports.getTipHeight=s.getTipHeight;exports.getTxHex=s.getTxHex;exports.getTxInfo=s.getTxInfo;exports.getUtxoInfo=s.getUtxoInfo;exports.pushTx=s.pushTx;exports.RegistrationLogsUnavailableError=l.RegistrationLogsUnavailableError;exports.VaultClaimableByNotFoundError=l.VaultClaimableByNotFoundError;exports.assertOnChainBtcPubkey=l.assertOnChainBtcPubkey;exports.assertRegisteredPayoutScriptBounds=l.assertRegisteredPayoutScriptBounds;exports.derivePeginVaultId=l.derivePeginVaultId;exports.findRegistrationRecord=l.findRegistrationRecord;exports.isRegistrationLogsUnavailableError=l.isRegistrationLogsUnavailableError;exports.isVaultClaimableByNotFoundError=l.isVaultClaimableByNotFoundError;exports.registrationPrePeginTxHash=l.registrationPrePeginTxHash;exports.validateOffchainParams=l.validateOffchainParams;exports.validatePegInConfiguration=l.validatePegInConfiguration;exports.validateTBVProtocolParams=l.validateTBVProtocolParams;exports.ViemOperationKeyReader=C.ViemOperationKeyReader;exports.ViemUniversalChallengerReader=C.ViemUniversalChallengerReader;exports.ViemVaultKeeperReader=C.ViemVaultKeeperReader;exports.resolveProtocolAddresses=C.resolveProtocolAddresses;exports.COMMISSION_BPS_HEADROOM=A.COMMISSION_BPS_HEADROOM;exports.MAX_ACCEPTABLE_COMMISSION_BPS_CAP=A.MAX_ACCEPTABLE_COMMISSION_BPS_CAP;exports.ViemPeginRegistrationClient=A.ViemPeginRegistrationClient;exports.ViemVaultRegistryReader=A.ViemVaultRegistryReader;exports.capMaxAcceptableCommissionBps=A.capMaxAcceptableCommissionBps;exports.OnChainBtcVaultStatus=h.OnChainBtcVaultStatus;exports.ViemProtocolParamsReader=h.ViemProtocolParamsReader;exports.ApplicationRegistryABI=y.ApplicationRegistryABI;exports.BTCVaultRegistryABI=N.BTCVaultRegistryABI;exports.BTCVaultRegistryKeyEpochsABI=u.BTCVaultRegistryKeyEpochsABI;exports.CONTRACT_ERRORS=u.CONTRACT_ERRORS;exports.EMPTY_REVERT_MESSAGE=u.EMPTY_REVERT_MESSAGE;exports.PEGIN_FINGERPRINT_CHANGED_SELECTOR=u.PEGIN_FINGERPRINT_CHANGED_SELECTOR;exports.PeginFingerprintChangedError=u.PeginFingerprintChangedError;exports.extractErrorData=u.extractErrorData;exports.getContractErrorMessage=u.getContractErrorMessage;exports.handleContractError=u.handleContractError;exports.isKnownContractError=u.isKnownContractError;exports.isPeginFingerprintChangedError=u.isPeginFingerprintChangedError;exports.ProtocolParamsABI=M.ProtocolParamsABI;exports.VAULT_ERROR_ABI=b.VAULT_ERROR_ABI;exports.buildVaultContextInputForClaim=v.buildVaultContextInputForClaim;exports.VAULT_APP_NAME=S.VAULT_APP_NAME;exports.buildFundingOutpointsCommitment=S.buildFundingOutpointsCommitment;exports.buildVaultContext=S.buildVaultContext;exports.deriveVaultRoot=S.deriveVaultRoot;exports.forwardDeriveContextHash=S.forwardDeriveContextHash;exports.parseFundingOutpointsFromTx=D.parseFundingOutpointsFromTx;exports.calculateBtcTxHash=B.calculateBtcTxHash;exports.BitcoinScriptType=c.BitcoinScriptType;exports.applyChangeOutputPolicy=c.applyChangeOutputPolicy;exports.computeChangeOutputFeeSats=c.computeChangeOutputFeeSats;exports.computeMaxDeposit=c.computeMaxDeposit;exports.computePeginBaseFeeSats=c.computePeginBaseFeeSats;exports.getDustThreshold=c.getDustThreshold;exports.getPsbtInputFields=c.getPsbtInputFields;exports.getScriptType=c.getScriptType;exports.selectUtxosForPegin=c.selectUtxosForPegin;exports.shouldAddChangeOutput=c.shouldAddChangeOutput;exports.BTC_DUST_SAT=i.BTC_DUST_SAT;exports.DUST_THRESHOLD=i.DUST_THRESHOLD;exports.LOW_RATE_ESTIMATION_ACCURACY_BUFFER=i.LOW_RATE_ESTIMATION_ACCURACY_BUFFER;exports.MAX_NON_LEGACY_OUTPUT_SIZE=i.MAX_NON_LEGACY_OUTPUT_SIZE;exports.MAX_REASONABLE_PEGIN_VBYTES=i.MAX_REASONABLE_PEGIN_VBYTES;exports.P2TR_INPUT_SIZE=i.P2TR_INPUT_SIZE;exports.PEGIN_AUTH_ANCHOR_OUTPUTS=i.PEGIN_AUTH_ANCHOR_OUTPUTS;exports.PEGIN_FIXED_OUTPUTS=i.PEGIN_FIXED_OUTPUTS;exports.SPLIT_TX_FEE_SAFETY_MULTIPLIER=i.SPLIT_TX_FEE_SAFETY_MULTIPLIER;exports.TX_BUFFER_SIZE_OVERHEAD=i.TX_BUFFER_SIZE_OVERHEAD;exports.WALLET_RELAY_FEE_RATE_THRESHOLD=i.WALLET_RELAY_FEE_RATE_THRESHOLD;exports.fundPeginTransaction=i.fundPeginTransaction;exports.parseUnfundedWasmTransaction=i.parseUnfundedWasmTransaction;exports.peginOutputCount=i.peginOutputCount;exports.rateBasedTxBufferFee=i.rateBasedTxBufferFee;exports.UtxoNotAvailableError=T.UtxoNotAvailableError;exports.assertUtxosAvailable=T.assertUtxosAvailable;exports.extractInputsFromTransaction=T.extractInputsFromTransaction;exports.findOverlappingPendingVaults=T.findOverlappingPendingVaults;exports.validateUtxosAvailable=T.validateUtxosAvailable;exports.VaultProviderRpcClient=m.VaultProviderRpcClient;exports.VpResponseValidationError=m.VpResponseValidationError;exports.batchPollByProvider=m.batchPollByProvider;exports.isUnrecognizedDaemonStatusError=m.isUnrecognizedDaemonStatusError;exports.validateRequestDepositorClaimerArtifactsResponse=m.validateRequestDepositorClaimerArtifactsResponse;exports.AUTH_REJECTED_RPC_CODE=a.AUTH_REJECTED_RPC_CODE;exports.ClaimerPegoutStatusValue=a.ClaimerPegoutStatusValue;exports.DaemonStatus=a.DaemonStatus;exports.JSON_RPC_ERROR_CODES=a.JSON_RPC_ERROR_CODES;exports.JsonRpcClient=a.JsonRpcClient;exports.JsonRpcError=a.JsonRpcError;exports.POST_WOTS_STATUSES=a.POST_WOTS_STATUSES;exports.PRE_DEPOSITOR_SIGNATURES_STATES=a.PRE_DEPOSITOR_SIGNATURES_STATES;exports.RpcErrorCode=a.RpcErrorCode;exports.VP_BATCH_MAX_SIZE=a.VP_BATCH_MAX_SIZE;exports.VP_TERMINAL_FAILURE_STATUSES=a.VP_TERMINAL_FAILURE_STATUSES;exports.VP_TRANSIENT_STATUSES=a.VP_TRANSIENT_STATUSES;exports.isAuthRejectedError=a.isAuthRejectedError;exports.isPegoutTerminalStatus=a.isPegoutTerminalStatus;exports.isRecognizedPegoutStatus=a.isRecognizedPegoutStatus;exports.ServerIdentityError=g.ServerIdentityError;exports.VpTokenRegistry=g.VpTokenRegistry;exports.createAuthenticatedVpClient=g.createAuthenticatedVpClient;exports.primeVpTokenRegistry=g.primeVpTokenRegistry;exports.verifyServerIdentity=g.verifyServerIdentity;exports.vpTokenRegistry=g.vpTokenRegistry;exports.DEPOSIT_TERMS_REJECTED_ERROR_NAME=t.DEPOSIT_TERMS_REJECTED_ERROR_NAME;exports.DepositTermsRejectedError=t.DepositTermsRejectedError;exports.PEGIN_FINGERPRINT_DOMAIN=t.PEGIN_FINGERPRINT_DOMAIN;exports.PEGIN_FINGERPRINT_DOMAIN_PREIMAGE=t.PEGIN_FINGERPRINT_DOMAIN_PREIMAGE;exports.PeginFingerprintInputError=t.PeginFingerprintInputError;exports.PeginParamsAmbiguousError=t.PeginParamsAmbiguousError;exports.PeginParamsIncompleteSpaceError=t.PeginParamsIncompleteSpaceError;exports.PeginParamsNotFoundError=t.PeginParamsNotFoundError;exports.PeginSizingIntegrityError=t.PeginSizingIntegrityError;exports.UnanchoredPrePeginError=t.UnanchoredPrePeginError;exports.VaultRootMismatchError=t.VaultRootMismatchError;exports.assertClaimBatchHomogeneous=t.assertClaimBatchHomogeneous;exports.buildPeginParamsCandidates=t.buildPeginParamsCandidates;exports.computeFundedPrePeginFee=t.computeFundedPrePeginFee;exports.computePeginFingerprint=t.computePeginFingerprint;exports.deriveHashlocksFromPrePegin=t.deriveHashlocksFromPrePegin;exports.describePeginParamsCandidate=t.describePeginParamsCandidate;exports.describeUnresolvedVersion=t.describeUnresolvedVersion;exports.encodePeginFingerprintPreimage=t.encodePeginFingerprintPreimage;exports.isDepositTermsRejectedError=t.isDepositTermsRejectedError;exports.isPeginFingerprintInputError=t.isPeginFingerprintInputError;exports.isWotsMismatchError=t.isWotsMismatchError;exports.orderClaimBatchByHtlcVout=t.orderClaimBatchByHtlcVout;exports.rebuildDepositTermsCore=t.rebuildDepositTermsCore;exports.rebuildDepositTermsForClaim=t.rebuildDepositTermsForClaim;exports.reconstructPeginParams=t.reconstructPeginParams;exports.selectSiblingRegistrations=t.selectSiblingRegistrations;exports.toRefundInputs=t.toRefundInputs;exports.ApplicationEntryPointMismatchError=e.ApplicationEntryPointMismatchError;exports.ArtifactsVaultMismatchError=e.ArtifactsVaultMismatchError;exports.AssertBindingError=e.AssertBindingError;exports.BIP68NotMatureError=e.BIP68NotMatureError;exports.ChallengerSetMismatchError=e.ChallengerSetMismatchError;exports.DELEGATED_CLAIM_TX_GRAPH_VERSION=e.DELEGATED_CLAIM_TX_GRAPH_VERSION;exports.DelegatedClaimSigningIncompleteError=e.DelegatedClaimSigningIncompleteError;exports.GraphFingerprintError=e.GraphFingerprintError;exports.PEGIN_ETH_CONFIRMATIONS=e.PEGIN_ETH_CONFIRMATIONS;exports.ParticipantKeyDriftError=e.ParticipantKeyDriftError;exports.PayoutDestinationError=e.PayoutDestinationError;exports.PayoutInputLeafError=e.PayoutInputLeafError;exports.PeginRegistrationMissingError=e.PeginRegistrationMissingError;exports.PeginRegistrationNotFinalError=e.PeginRegistrationNotFinalError;exports.RECLAIM_MAX_FEE_FRACTION_DENOMINATOR=e.RECLAIM_MAX_FEE_FRACTION_DENOMINATOR;exports.RECLAIM_MAX_FEE_FRACTION_NUMERATOR=e.RECLAIM_MAX_FEE_FRACTION_NUMERATOR;exports.RECLAIM_MAX_FEE_RATE_SATS_VB=e.RECLAIM_MAX_FEE_RATE_SATS_VB;exports.RECLAIM_WARN_FEE_FRACTION_NUMERATOR=e.RECLAIM_WARN_FEE_FRACTION_NUMERATOR;exports.REFUND_MAX_FEE_FRACTION_DENOMINATOR=e.REFUND_MAX_FEE_FRACTION_DENOMINATOR;exports.REFUND_MAX_FEE_FRACTION_NUMERATOR=e.REFUND_MAX_FEE_FRACTION_NUMERATOR;exports.REFUND_MAX_FEE_RATE_SATS_VB=e.REFUND_MAX_FEE_RATE_SATS_VB;exports.REFUND_VSIZE=e.REFUND_VSIZE;exports.ReclaimUneconomicalError=e.ReclaimUneconomicalError;exports.RegisteredVaultVersionMismatchError=e.RegisteredVaultVersionMismatchError;exports.SigningPlanMismatchError=e.SigningPlanMismatchError;exports.VaultIdBindingError=e.VaultIdBindingError;exports.activateVault=e.activateVault;exports.activateVaultAndRedeem=e.activateVaultAndRedeem;exports.assembleWatchtowerArtifacts=e.assembleWatchtowerArtifacts;exports.assembleWatchtowerArtifactsFromSignatures=e.assembleWatchtowerArtifactsFromSignatures;exports.assertArtifactsUsableForVault=e.assertArtifactsUsableForVault;exports.assertAssertBindsClaimAndPayout=e.assertAssertBindsClaimAndPayout;exports.assertChallengerSetMatchesVault=e.assertChallengerSetMatchesVault;exports.assertClaimSpendsVault=e.assertClaimSpendsVault;exports.assertPayoutPaysRegisteredScript=e.assertPayoutPaysRegisteredScript;exports.assertReturnedGraphMatchesFingerprint=e.assertReturnedGraphMatchesFingerprint;exports.assertTermsMatchVault=e.assertTermsMatchVault;exports.assertVaultProviderHintAccepted=e.assertVaultProviderHintAccepted;exports.buildAndBroadcastReclaim=e.buildAndBroadcastReclaim;exports.buildAndBroadcastRefund=e.buildAndBroadcastRefund;exports.claimExpiredVault=e.claimExpiredVault;exports.copyAssertConnectorLeaf=e.copyAssertConnectorLeaf;exports.deriveClaimerWotsKeypair=e.deriveClaimerWotsKeypair;exports.estimateRefundFeeSats=e.estimateRefundFeeSats;exports.fingerprintReturnedGraph=e.fingerprintReturnedGraph;exports.isApplicationEntryPointMismatchError=e.isApplicationEntryPointMismatchError;exports.isDepositAmountValid=e.isDepositAmountValid;exports.isHintAccepted=e.isHintAccepted;exports.isParticipantKeyDriftError=e.isParticipantKeyDriftError;exports.isPeginRegistrationMissingError=e.isPeginRegistrationMissingError;exports.isPeginRegistrationNotFinalError=e.isPeginRegistrationNotFinalError;exports.isRegisteredVaultVersionMismatchError=e.isRegisteredVaultVersionMismatchError;exports.matchKeyHint=e.matchKeyHint;exports.matchKeySetHint=e.matchKeySetHint;exports.planDelegatedClaimSigning=e.planDelegatedClaimSigning;exports.readDelegatedClaimVaultContext=e.readDelegatedClaimVaultContext;exports.readStampedParticipantKeys=e.readStampedParticipantKeys;exports.resolveCurrentParticipantKeys=e.resolveCurrentParticipantKeys;exports.resolveParticipantKeysAtEpochs=e.resolveParticipantKeysAtEpochs;exports.runDepositorPresignFlow=e.runDepositorPresignFlow;exports.signDelegatedClaimPlan=e.signDelegatedClaimPlan;exports.signDepositorGraph=e.signDepositorGraph;exports.submitWotsPublicKey=e.submitWotsPublicKey;exports.summarizeWatchtowerArtifacts=e.summarizeWatchtowerArtifacts;exports.validateDepositAmount=e.validateDepositAmount;exports.validateMultiVaultDepositInputs=e.validateMultiVaultDepositInputs;exports.validateOnChainParticipantKeys=e.validateOnChainParticipantKeys;exports.validateProviderSelection=e.validateProviderSelection;exports.validateRemainingCapacity=e.validateRemainingCapacity;exports.validateVaultAmounts=e.validateVaultAmounts;exports.validateVaultProviderPubkey=e.validateVaultProviderPubkey;exports.verifyRegisteredParticipantKeys=e.verifyRegisteredParticipantKeys;exports.verifyRegisteredVaultVersions=e.verifyRegisteredVaultVersions;exports.waitForPeginRegistrationDepth=e.waitForPeginRegistrationDepth;exports.waitForPeginStatus=e.waitForPeginStatus;exports.ContractStatus=p.ContractStatus;exports.PeginAction=p.PeginAction;exports.activationDeadlineBlocksRemaining=p.activationDeadlineBlocksRemaining;exports.canPerformAction=p.canPerformAction;exports.getPeginProtocolState=p.getPeginProtocolState;exports.isActivationDeadlinePassedOnChain=p.isActivationDeadlinePassedOnChain;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../verifyScriptPathSchnorrSignature-CgDa9Rcg.cjs"),O=require("../secp256k1-DDHQ1_za.cjs"),n=require("./core/wasm/index.cjs"),R=require("../verifyKeyPathSchnorrSignature-DcxCojp0.cjs"),E=require("../challengeAssert-eUMgmpMk.cjs"),r=require("../bitcoin-D-O2GjbC.cjs"),F=require("../abortSignals-msbmbqFe.cjs"),I=require("../signing-DvISftFk.cjs"),P=require("../validation-C6XTfZak.cjs"),V=require("./core/utils/eth/index.cjs"),_=require("../PeginManager-BipOU_e4.cjs"),d=require("../PayoutManager-BXzFIZK6.cjs"),s=require("./core/clients/mempool/index.cjs"),l=require("../registration-records-CKc0OVuK.cjs"),C=require("../signer-set-reader-CJfV-GDz.cjs"),A=require("../pegin-registration-client-DLlaZbsZ.cjs"),h=require("../types-BnZIbDHb.cjs"),y=require("../ApplicationRegistry.abi-sMiTWmnL.cjs"),N=require("../BTCVaultRegistry.abi-DzbfZ9_s.cjs"),u=require("../BTCVaultRegistryKeyEpochs.abi-CReWFJdu.cjs"),M=require("../ProtocolParams.abi-DWfIh6VH.cjs"),b=require("../VaultErrors.abi-Hjn1CdLs.cjs"),v=require("../buildVaultContextInputForClaim-9XZaqIiw.cjs"),S=require("../deriveVaultRoot-C3uqnJto.cjs"),D=require("../parseFundingOutpoints-C_-PT9BT.cjs"),B=require("../btcTxHash-CGb5BqFL.cjs"),c=require("../psbtInputFields-BrV_ZfL_.cjs"),i=require("../fundPeginTransaction-54-Rwb2k.cjs"),T=require("../reservation-CA5knoQ0.cjs"),m=require("../index-Dn7RlsKK.cjs"),a=require("../state-C4WoNCy1.cjs"),g=require("../primeVpAuth-Ch-ig2My.cjs"),t=require("../toRefundInputs-CR7vtHMa.cjs"),e=require("../buildAndBroadcastReclaim-B00roO6R.cjs"),p=require("../peginState-IyE22wWh.cjs");exports.PEGIN_DEPOSITOR_CLAIM_VOUT=o.PEGIN_DEPOSITOR_CLAIM_VOUT;exports.PsbtSubstitutionError=o.PsbtSubstitutionError;exports.assertPsbtUnsignedTxMatches=o.assertPsbtUnsignedTxMatches;exports.assertScriptPathSchnorrSignature=o.assertScriptPathSchnorrSignature;exports.buildPayoutPsbt=o.buildPayoutPsbt;exports.buildPeginTxFromFundedPrePegin=o.buildPeginTxFromFundedPrePegin;exports.buildPrePeginPsbt=o.buildPrePeginPsbt;exports.computeNumLocalChallengers=o.computeNumLocalChallengers;exports.createPayoutScript=o.createPayoutScript;exports.deriveDepositorClaimDescriptor=o.deriveDepositorClaimDescriptor;exports.deriveDepositorClaimScriptPubKey=o.deriveDepositorClaimScriptPubKey;exports.extractPayoutSignature=o.extractPayoutSignature;exports.assertValidVaultCoreVersion=O.assertValidVaultCoreVersion;exports.attachFinalizedAssert=n.attachFinalizedAssert;exports.computeMinClaimValue=n.computeMinClaimValue;exports.computeMinPeginFee=n.computeMinPeginFee;exports.deriveVaultId=n.deriveVaultId;exports.expandAuthAnchor=n.expandAuthAnchor;exports.expandHashlockSecret=n.expandHashlockSecret;exports.expandWotsSeed=n.expandWotsSeed;exports.finalizePayout=n.finalizePayout;exports.finalizeWronglyChallenged=n.finalizeWronglyChallenged;exports.peginP2aAnchorOutput=n.peginP2aAnchorOutput;exports.pinPegoutProof=n.pinPegoutProof;exports.supportedTxGraphVersions=n.supportedTxGraphVersions;exports.validatePeginP2aAnchor=n.validatePeginP2aAnchor;exports.assertKeyPathSchnorrSignature=R.assertKeyPathSchnorrSignature;exports.assertReturnedKeyPathSignatures=R.assertReturnedKeyPathSignatures;exports.buildPeginInputPsbt=R.buildPeginInputPsbt;exports.extractPeginInputSignature=R.extractPeginInputSignature;exports.finalizePeginInputPsbt=R.finalizePeginInputPsbt;exports.buildChallengeAssertPsbt=E.buildChallengeAssertPsbt;exports.buildNoPayoutPsbt=E.buildNoPayoutPsbt;exports.buildReclaimPsbt=E.buildReclaimPsbt;exports.buildRefundPsbt=E.buildRefundPsbt;exports.estimateReclaimFeeSats=E.estimateReclaimFeeSats;exports.finalizeScriptPathWithSignatures=E.finalizeScriptPathWithSignatures;exports.reclaimVsize=E.reclaimVsize;exports.canonicalizeBtcPubkey=r.canonicalizeBtcPubkey;exports.deriveBip86ScriptPubKeyHex=r.deriveBip86ScriptPubKeyHex;exports.deriveNativeSegwitAddress=r.deriveNativeSegwitAddress;exports.deriveTaprootAddress=r.deriveTaprootAddress;exports.ensureHexPrefix=r.ensureHexPrefix;exports.formatSatoshisToBtc=r.formatSatoshisToBtc;exports.getNetwork=r.getNetwork;exports.getSortedXOnlyPubkeys=r.getSortedXOnlyPubkeys;exports.hexToUint8Array=r.hexToUint8Array;exports.isAddressFromPublicKey=r.isAddressFromPublicKey;exports.isValidHex=r.isValidHex;exports.processPublicKeyToXOnly=r.processPublicKeyToXOnly;exports.stripHexPrefix=r.stripHexPrefix;exports.toXOnly=r.toXOnly;exports.uint8ArrayToHex=r.uint8ArrayToHex;exports.validateWalletPubkey=r.validateWalletPubkey;exports.combineAbortSignals=F.combineAbortSignals;exports.createTaprootScriptPathSignOptions=I.createTaprootScriptPathSignOptions;exports.createTaprootScriptPathSignOptionsForInput=I.createTaprootScriptPathSignOptionsForInput;exports.BITCOIN_ADDRESS_RE=P.BITCOIN_ADDRESS_RE;exports.COMPRESSED_PUBKEY_HEX_LEN=P.COMPRESSED_PUBKEY_HEX_LEN;exports.HEX_RE=P.HEX_RE;exports.KNOWN_SCRIPT_PREFIXES=P.KNOWN_SCRIPT_PREFIXES;exports.MAX_REASONABLE_FEE_SATS=P.MAX_REASONABLE_FEE_SATS;exports.TXID_RE=P.TXID_RE;exports.X_ONLY_PUBKEY_HEX_LEN=P.X_ONLY_PUBKEY_HEX_LEN;exports.waitForTransactionReceiptSmartAware=V.waitForTransactionReceiptSmartAware;exports.PeginManager=_.PeginManager;exports.buildDepositTerms=_.buildDepositTerms;exports.computeWotsBlockPublicKeysHash=_.computeWotsBlockPublicKeysHash;exports.deriveWotsBlocksFromSeed=_.deriveWotsBlocksFromSeed;exports.ensurePrePeginTermsApproval=_.ensurePrePeginTermsApproval;exports.PayoutManager=d.PayoutManager;exports.computeHashlock=d.computeHashlock;exports.forwardDepositApproval=d.forwardDepositApproval;exports.requireChangeAddress=d.requireChangeAddress;exports.supportsDepositApproval=d.supportsDepositApproval;exports.validateSecretAgainstHashlock=d.validateSecretAgainstHashlock;exports.MEMPOOL_API_URLS=s.MEMPOOL_API_URLS;exports.MempoolNotFoundError=s.MempoolNotFoundError;exports.getAddressTxs=s.getAddressTxs;exports.getAddressUtxos=s.getAddressUtxos;exports.getMempoolApiUrl=s.getMempoolApiUrl;exports.getNetworkFees=s.getNetworkFees;exports.getOutspend=s.getOutspend;exports.getTipHeight=s.getTipHeight;exports.getTxHex=s.getTxHex;exports.getTxInfo=s.getTxInfo;exports.getUtxoInfo=s.getUtxoInfo;exports.pushTx=s.pushTx;exports.RegistrationLogsUnavailableError=l.RegistrationLogsUnavailableError;exports.VaultClaimableByNotFoundError=l.VaultClaimableByNotFoundError;exports.assertOnChainBtcPubkey=l.assertOnChainBtcPubkey;exports.assertRegisteredPayoutScriptBounds=l.assertRegisteredPayoutScriptBounds;exports.derivePeginVaultId=l.derivePeginVaultId;exports.findRegistrationRecord=l.findRegistrationRecord;exports.isRegistrationLogsUnavailableError=l.isRegistrationLogsUnavailableError;exports.isVaultClaimableByNotFoundError=l.isVaultClaimableByNotFoundError;exports.registrationPrePeginTxHash=l.registrationPrePeginTxHash;exports.validateOffchainParams=l.validateOffchainParams;exports.validatePegInConfiguration=l.validatePegInConfiguration;exports.validateTBVProtocolParams=l.validateTBVProtocolParams;exports.ViemOperationKeyReader=C.ViemOperationKeyReader;exports.ViemUniversalChallengerReader=C.ViemUniversalChallengerReader;exports.ViemVaultKeeperReader=C.ViemVaultKeeperReader;exports.resolveProtocolAddresses=C.resolveProtocolAddresses;exports.COMMISSION_BPS_HEADROOM=A.COMMISSION_BPS_HEADROOM;exports.MAX_ACCEPTABLE_COMMISSION_BPS_CAP=A.MAX_ACCEPTABLE_COMMISSION_BPS_CAP;exports.ViemPeginRegistrationClient=A.ViemPeginRegistrationClient;exports.ViemVaultRegistryReader=A.ViemVaultRegistryReader;exports.capMaxAcceptableCommissionBps=A.capMaxAcceptableCommissionBps;exports.OnChainBtcVaultStatus=h.OnChainBtcVaultStatus;exports.ViemProtocolParamsReader=h.ViemProtocolParamsReader;exports.ApplicationRegistryABI=y.ApplicationRegistryABI;exports.BTCVaultRegistryABI=N.BTCVaultRegistryABI;exports.BTCVaultRegistryKeyEpochsABI=u.BTCVaultRegistryKeyEpochsABI;exports.CONTRACT_ERRORS=u.CONTRACT_ERRORS;exports.EMPTY_REVERT_MESSAGE=u.EMPTY_REVERT_MESSAGE;exports.PEGIN_FINGERPRINT_CHANGED_SELECTOR=u.PEGIN_FINGERPRINT_CHANGED_SELECTOR;exports.PeginFingerprintChangedError=u.PeginFingerprintChangedError;exports.extractErrorData=u.extractErrorData;exports.getContractErrorMessage=u.getContractErrorMessage;exports.handleContractError=u.handleContractError;exports.isKnownContractError=u.isKnownContractError;exports.isPeginFingerprintChangedError=u.isPeginFingerprintChangedError;exports.ProtocolParamsABI=M.ProtocolParamsABI;exports.VAULT_ERROR_ABI=b.VAULT_ERROR_ABI;exports.buildVaultContextInputForClaim=v.buildVaultContextInputForClaim;exports.VAULT_APP_NAME=S.VAULT_APP_NAME;exports.buildFundingOutpointsCommitment=S.buildFundingOutpointsCommitment;exports.buildVaultContext=S.buildVaultContext;exports.deriveVaultRoot=S.deriveVaultRoot;exports.forwardDeriveContextHash=S.forwardDeriveContextHash;exports.parseFundingOutpointsFromTx=D.parseFundingOutpointsFromTx;exports.calculateBtcTxHash=B.calculateBtcTxHash;exports.BitcoinScriptType=c.BitcoinScriptType;exports.applyChangeOutputPolicy=c.applyChangeOutputPolicy;exports.computeChangeOutputFeeSats=c.computeChangeOutputFeeSats;exports.computeMaxDeposit=c.computeMaxDeposit;exports.computePeginBaseFeeSats=c.computePeginBaseFeeSats;exports.getDustThreshold=c.getDustThreshold;exports.getPsbtInputFields=c.getPsbtInputFields;exports.getScriptType=c.getScriptType;exports.selectUtxosForPegin=c.selectUtxosForPegin;exports.shouldAddChangeOutput=c.shouldAddChangeOutput;exports.BTC_DUST_SAT=i.BTC_DUST_SAT;exports.DUST_THRESHOLD=i.DUST_THRESHOLD;exports.LOW_RATE_ESTIMATION_ACCURACY_BUFFER=i.LOW_RATE_ESTIMATION_ACCURACY_BUFFER;exports.MAX_NON_LEGACY_OUTPUT_SIZE=i.MAX_NON_LEGACY_OUTPUT_SIZE;exports.MAX_REASONABLE_PEGIN_VBYTES=i.MAX_REASONABLE_PEGIN_VBYTES;exports.P2TR_INPUT_SIZE=i.P2TR_INPUT_SIZE;exports.PEGIN_AUTH_ANCHOR_OUTPUTS=i.PEGIN_AUTH_ANCHOR_OUTPUTS;exports.PEGIN_FIXED_OUTPUTS=i.PEGIN_FIXED_OUTPUTS;exports.SPLIT_TX_FEE_SAFETY_MULTIPLIER=i.SPLIT_TX_FEE_SAFETY_MULTIPLIER;exports.TX_BUFFER_SIZE_OVERHEAD=i.TX_BUFFER_SIZE_OVERHEAD;exports.WALLET_RELAY_FEE_RATE_THRESHOLD=i.WALLET_RELAY_FEE_RATE_THRESHOLD;exports.fundPeginTransaction=i.fundPeginTransaction;exports.parseUnfundedWasmTransaction=i.parseUnfundedWasmTransaction;exports.peginOutputCount=i.peginOutputCount;exports.rateBasedTxBufferFee=i.rateBasedTxBufferFee;exports.UtxoNotAvailableError=T.UtxoNotAvailableError;exports.assertUtxosAvailable=T.assertUtxosAvailable;exports.extractInputsFromTransaction=T.extractInputsFromTransaction;exports.findOverlappingPendingVaults=T.findOverlappingPendingVaults;exports.validateUtxosAvailable=T.validateUtxosAvailable;exports.VaultProviderRpcClient=m.VaultProviderRpcClient;exports.VpResponseValidationError=m.VpResponseValidationError;exports.batchPollByProvider=m.batchPollByProvider;exports.isUnrecognizedDaemonStatusError=m.isUnrecognizedDaemonStatusError;exports.validateRequestDepositorClaimerArtifactsResponse=m.validateRequestDepositorClaimerArtifactsResponse;exports.AUTH_REJECTED_RPC_CODE=a.AUTH_REJECTED_RPC_CODE;exports.ClaimerPegoutStatusValue=a.ClaimerPegoutStatusValue;exports.DaemonStatus=a.DaemonStatus;exports.JSON_RPC_ERROR_CODES=a.JSON_RPC_ERROR_CODES;exports.JsonRpcClient=a.JsonRpcClient;exports.JsonRpcError=a.JsonRpcError;exports.POST_WOTS_STATUSES=a.POST_WOTS_STATUSES;exports.PRE_DEPOSITOR_SIGNATURES_STATES=a.PRE_DEPOSITOR_SIGNATURES_STATES;exports.RpcErrorCode=a.RpcErrorCode;exports.VP_BATCH_MAX_SIZE=a.VP_BATCH_MAX_SIZE;exports.VP_TERMINAL_FAILURE_STATUSES=a.VP_TERMINAL_FAILURE_STATUSES;exports.VP_TRANSIENT_STATUSES=a.VP_TRANSIENT_STATUSES;exports.isAuthRejectedError=a.isAuthRejectedError;exports.isPegoutTerminalStatus=a.isPegoutTerminalStatus;exports.isRecognizedPegoutStatus=a.isRecognizedPegoutStatus;exports.ServerIdentityError=g.ServerIdentityError;exports.VpTokenRegistry=g.VpTokenRegistry;exports.createAuthenticatedVpClient=g.createAuthenticatedVpClient;exports.primeVpTokenRegistry=g.primeVpTokenRegistry;exports.verifyServerIdentity=g.verifyServerIdentity;exports.vpTokenRegistry=g.vpTokenRegistry;exports.DEPOSIT_TERMS_REJECTED_ERROR_NAME=t.DEPOSIT_TERMS_REJECTED_ERROR_NAME;exports.DepositTermsRejectedError=t.DepositTermsRejectedError;exports.PEGIN_FINGERPRINT_DOMAIN=t.PEGIN_FINGERPRINT_DOMAIN;exports.PEGIN_FINGERPRINT_DOMAIN_PREIMAGE=t.PEGIN_FINGERPRINT_DOMAIN_PREIMAGE;exports.PeginFingerprintInputError=t.PeginFingerprintInputError;exports.PeginParamsAmbiguousError=t.PeginParamsAmbiguousError;exports.PeginParamsIncompleteSpaceError=t.PeginParamsIncompleteSpaceError;exports.PeginParamsNotFoundError=t.PeginParamsNotFoundError;exports.PeginSizingIntegrityError=t.PeginSizingIntegrityError;exports.UnanchoredPrePeginError=t.UnanchoredPrePeginError;exports.VaultRootMismatchError=t.VaultRootMismatchError;exports.assertClaimBatchHomogeneous=t.assertClaimBatchHomogeneous;exports.buildPeginParamsCandidates=t.buildPeginParamsCandidates;exports.computeFundedPrePeginFee=t.computeFundedPrePeginFee;exports.computePeginFingerprint=t.computePeginFingerprint;exports.deriveHashlocksFromPrePegin=t.deriveHashlocksFromPrePegin;exports.describePeginParamsCandidate=t.describePeginParamsCandidate;exports.describeUnresolvedVersion=t.describeUnresolvedVersion;exports.encodePeginFingerprintPreimage=t.encodePeginFingerprintPreimage;exports.isDepositTermsRejectedError=t.isDepositTermsRejectedError;exports.isPeginFingerprintInputError=t.isPeginFingerprintInputError;exports.isWotsMismatchError=t.isWotsMismatchError;exports.orderClaimBatchByHtlcVout=t.orderClaimBatchByHtlcVout;exports.rebuildDepositTermsCore=t.rebuildDepositTermsCore;exports.rebuildDepositTermsForClaim=t.rebuildDepositTermsForClaim;exports.reconstructPeginParams=t.reconstructPeginParams;exports.selectSiblingRegistrations=t.selectSiblingRegistrations;exports.toRefundInputs=t.toRefundInputs;exports.ApplicationEntryPointMismatchError=e.ApplicationEntryPointMismatchError;exports.ArtifactsVaultMismatchError=e.ArtifactsVaultMismatchError;exports.AssertBindingError=e.AssertBindingError;exports.BIP68NotMatureError=e.BIP68NotMatureError;exports.ChallengerSetMismatchError=e.ChallengerSetMismatchError;exports.DELEGATED_CLAIM_TX_GRAPH_VERSION=e.DELEGATED_CLAIM_TX_GRAPH_VERSION;exports.DelegatedClaimSigningIncompleteError=e.DelegatedClaimSigningIncompleteError;exports.GraphFingerprintError=e.GraphFingerprintError;exports.PEGIN_ETH_CONFIRMATIONS=e.PEGIN_ETH_CONFIRMATIONS;exports.ParticipantKeyDriftError=e.ParticipantKeyDriftError;exports.PayoutDestinationError=e.PayoutDestinationError;exports.PayoutInputLeafError=e.PayoutInputLeafError;exports.PeginRegistrationMissingError=e.PeginRegistrationMissingError;exports.PeginRegistrationNotFinalError=e.PeginRegistrationNotFinalError;exports.RECLAIM_MAX_FEE_FRACTION_DENOMINATOR=e.RECLAIM_MAX_FEE_FRACTION_DENOMINATOR;exports.RECLAIM_MAX_FEE_FRACTION_NUMERATOR=e.RECLAIM_MAX_FEE_FRACTION_NUMERATOR;exports.RECLAIM_MAX_FEE_RATE_SATS_VB=e.RECLAIM_MAX_FEE_RATE_SATS_VB;exports.RECLAIM_WARN_FEE_FRACTION_NUMERATOR=e.RECLAIM_WARN_FEE_FRACTION_NUMERATOR;exports.REFUND_MAX_FEE_FRACTION_DENOMINATOR=e.REFUND_MAX_FEE_FRACTION_DENOMINATOR;exports.REFUND_MAX_FEE_FRACTION_NUMERATOR=e.REFUND_MAX_FEE_FRACTION_NUMERATOR;exports.REFUND_MAX_FEE_RATE_SATS_VB=e.REFUND_MAX_FEE_RATE_SATS_VB;exports.REFUND_VSIZE=e.REFUND_VSIZE;exports.ReclaimUneconomicalError=e.ReclaimUneconomicalError;exports.RegisteredVaultVersionMismatchError=e.RegisteredVaultVersionMismatchError;exports.SigningPlanMismatchError=e.SigningPlanMismatchError;exports.VaultIdBindingError=e.VaultIdBindingError;exports.activateVault=e.activateVault;exports.activateVaultAndRedeem=e.activateVaultAndRedeem;exports.assembleWatchtowerArtifacts=e.assembleWatchtowerArtifacts;exports.assembleWatchtowerArtifactsFromSignatures=e.assembleWatchtowerArtifactsFromSignatures;exports.assertArtifactsUsableForVault=e.assertArtifactsUsableForVault;exports.assertAssertBindsClaimAndPayout=e.assertAssertBindsClaimAndPayout;exports.assertChallengerSetMatchesVault=e.assertChallengerSetMatchesVault;exports.assertClaimSpendsVault=e.assertClaimSpendsVault;exports.assertPayoutPaysRegisteredScript=e.assertPayoutPaysRegisteredScript;exports.assertReturnedGraphMatchesFingerprint=e.assertReturnedGraphMatchesFingerprint;exports.assertTermsMatchVault=e.assertTermsMatchVault;exports.assertVaultProviderHintAccepted=e.assertVaultProviderHintAccepted;exports.buildAndBroadcastReclaim=e.buildAndBroadcastReclaim;exports.buildAndBroadcastRefund=e.buildAndBroadcastRefund;exports.claimExpiredVault=e.claimExpiredVault;exports.copyAssertConnectorLeaf=e.copyAssertConnectorLeaf;exports.deriveClaimerWotsKeypair=e.deriveClaimerWotsKeypair;exports.estimateRefundFeeSats=e.estimateRefundFeeSats;exports.fingerprintReturnedGraph=e.fingerprintReturnedGraph;exports.isApplicationEntryPointMismatchError=e.isApplicationEntryPointMismatchError;exports.isDepositAmountValid=e.isDepositAmountValid;exports.isHintAccepted=e.isHintAccepted;exports.isParticipantKeyDriftError=e.isParticipantKeyDriftError;exports.isPeginRegistrationMissingError=e.isPeginRegistrationMissingError;exports.isPeginRegistrationNotFinalError=e.isPeginRegistrationNotFinalError;exports.isRegisteredVaultVersionMismatchError=e.isRegisteredVaultVersionMismatchError;exports.matchKeyHint=e.matchKeyHint;exports.matchKeySetHint=e.matchKeySetHint;exports.planDelegatedClaimSigning=e.planDelegatedClaimSigning;exports.readDelegatedClaimVaultContext=e.readDelegatedClaimVaultContext;exports.readRefundPrePeginContext=e.readRefundPrePeginContext;exports.readStampedParticipantKeys=e.readStampedParticipantKeys;exports.resolveCurrentParticipantKeys=e.resolveCurrentParticipantKeys;exports.resolveParticipantKeysAtEpochs=e.resolveParticipantKeysAtEpochs;exports.runDepositorPresignFlow=e.runDepositorPresignFlow;exports.signDelegatedClaimPlan=e.signDelegatedClaimPlan;exports.signDepositorGraph=e.signDepositorGraph;exports.submitWotsPublicKey=e.submitWotsPublicKey;exports.summarizeWatchtowerArtifacts=e.summarizeWatchtowerArtifacts;exports.validateDepositAmount=e.validateDepositAmount;exports.validateMultiVaultDepositInputs=e.validateMultiVaultDepositInputs;exports.validateOnChainParticipantKeys=e.validateOnChainParticipantKeys;exports.validateProviderSelection=e.validateProviderSelection;exports.validateRemainingCapacity=e.validateRemainingCapacity;exports.validateVaultAmounts=e.validateVaultAmounts;exports.validateVaultProviderPubkey=e.validateVaultProviderPubkey;exports.verifyRegisteredParticipantKeys=e.verifyRegisteredParticipantKeys;exports.verifyRegisteredVaultVersions=e.verifyRegisteredVaultVersions;exports.waitForPeginRegistrationDepth=e.waitForPeginRegistrationDepth;exports.waitForPeginStatus=e.waitForPeginStatus;exports.ContractStatus=p.ContractStatus;exports.PeginAction=p.PeginAction;exports.activationDeadlineBlocksRemaining=p.activationDeadlineBlocksRemaining;exports.canPerformAction=p.canPerformAction;exports.getPeginProtocolState=p.getPeginProtocolState;exports.isActivationDeadlinePassedOnChain=p.isActivationDeadlinePassedOnChain;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|