import { DeriveContextHashCapableWallet } from '../vault-secrets'; export interface DeriveHashlocksFromPrePeginInput { /** Any wallet implementing `deriveContextHash` — the depositor's own. */ wallet: DeriveContextHashCapableWallet; /** * Depositor BTC public key, read from the CONNECTED WALLET. The reorg * destroyed the row that would normally supply it, and taking it from any * chain read would defeat the recovery. * * Accepted in whatever form the wallet hands back — x-only, 33-byte * compressed or 65-byte uncompressed, `0x` optional — and narrowed to x-only * here. Wallets return the compressed form from `getPublicKey`, so requiring * x-only would make the common case an error. */ depositorBtcPubkey: string; /** Funded (broadcast) Pre-PegIn transaction hex, `0x` optional. */ fundedPrePeginTxHex: string; } export interface DeriveHashlocksFromPrePeginResult { /** Number of HTLC outputs the transaction funds, from the anchor's vout. */ vaultCount: number; /** 32-byte hex hashlocks (no `0x`), indexed by `htlcVout`. */ hashlocks: readonly string[]; /** The transaction's auth-anchor commitment, `SHA256(authAnchor)` as hex. */ authAnchorHash: string; } /** * Derive the per-vault hashlocks committed by a funded Pre-PegIn. * * Validates the re-derived root against the transaction's auth-anchor * OP_RETURN before expanding anything else. That check costs one HKDF call, * needs zero protocol parameters, and is what separates "wrong wallet, * account or network" from "right wallet, no candidate matched" — otherwise * both surface as a fruitless parameter search. * * @throws {UnanchoredPrePeginError} If the transaction carries no single, * unambiguous auth-anchor OP_RETURN. * @throws {VaultRootMismatchError} If the derived root does not commit to the * transaction's anchor. */ export declare function deriveHashlocksFromPrePegin(input: DeriveHashlocksFromPrePeginInput): Promise; //# sourceMappingURL=deriveHashlocksFromPrePegin.d.ts.map