calcTxSigHash

abstract fun calcTxSigHash(txData: ByteArray, sigHashType: ByteArray, inputIdx: Long, inputAmount: Long, prevoutScript: ByteArray): ByteArray

Calculate the signature hash (sighash) for the passed transaction.

Return

The hash to use when signing this input in binary format. signTxOneInputUsingSchnorr calculates this automatically. This function is used for external signers.

Parameters

txData

transaction serialized for signing

sigHashType

signature hash algorithm selection

inputIdx

what input to sign

inputAmount

how many satoshis this input contains

prevoutScript

the input's constraint script