Skip to content

Commit

Permalink
debug: NewTxSighash
Browse files Browse the repository at this point in the history
  • Loading branch information
DhananjayPurohit committed Jan 16, 2024
1 parent 756380f commit 35c9803
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions attestation/attestclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -494,6 +494,8 @@ func (w *AttestClient) SignTransaction(hash chainhash.Hash, msgTx wire.MsgTx) (
a := txscript.NewMultiPrevOutFetcher(map[wire.OutPoint]*wire.TxOut{
*outPoint: {},
})
log.Infof("msgTx %v", msgTx)
log.Infof("prevout fetcher %v", a)
sigHashes := txscript.NewTxSigHashes(&msgTx, a)
signature, err := txscript.WitnessSignature(&msgTx, sigHashes, 0, prevTx.MsgTx().TxOut[0].Value, witnessProgram, txscript.SigHashAll, key.PrivKey, true)
if err != nil {
Expand Down

0 comments on commit 35c9803

Please sign in to comment.