mirror of
https://github.com/aljazceru/ark.git
synced 2025-12-18 12:44:19 +01:00
Move redeem transactions creation client-side (#388)
* move OOR transaction creation client-side * robust redeem tx checks * optimize GetVtxos db call * rename CompleteAsyncPayment --> SubmitRedeemTx * fix permissions.go
This commit is contained in:
@@ -9,7 +9,6 @@ import (
|
||||
"github.com/ark-network/ark/common/bitcointree"
|
||||
"github.com/ark-network/ark/common/tree"
|
||||
"github.com/btcsuite/btcd/btcec/v2/schnorr"
|
||||
"github.com/btcsuite/btcd/chaincfg/chainhash"
|
||||
"github.com/decred/dcrd/dcrec/secp256k1/v4"
|
||||
"github.com/lightningnetwork/lnd/lnwallet/chainfee"
|
||||
)
|
||||
@@ -47,12 +46,9 @@ type ASPClient interface {
|
||||
ctx context.Context, paymentID string,
|
||||
) (<-chan RoundEventChannel, func(), error)
|
||||
Ping(ctx context.Context, paymentID string) error
|
||||
CreatePayment(
|
||||
ctx context.Context, inputs []AsyncPaymentInput, outputs []Output,
|
||||
) (string, error)
|
||||
CompletePayment(
|
||||
SubmitRedeemTx(
|
||||
ctx context.Context, signedRedeemTx string,
|
||||
) error
|
||||
) (string, error)
|
||||
ListVtxos(ctx context.Context, addr string) ([]Vtxo, []Vtxo, error)
|
||||
GetRound(ctx context.Context, txID string) (*Round, error)
|
||||
GetRoundByID(ctx context.Context, roundID string) (*Round, error)
|
||||
@@ -92,11 +88,6 @@ type Input struct {
|
||||
Tapscripts []string
|
||||
}
|
||||
|
||||
type AsyncPaymentInput struct {
|
||||
Input
|
||||
ForfeitLeafHash chainhash.Hash
|
||||
}
|
||||
|
||||
type Vtxo struct {
|
||||
Outpoint
|
||||
Pubkey string
|
||||
|
||||
Reference in New Issue
Block a user