verifyScripts

fun verifyScripts(scriptSig: ByteArray, scriptPubKey: ByteArray): Boolean
fun verifyScripts(    scriptSig: ByteVector,     scriptPubKey: ByteVector,     witness: ScriptWitness): Boolean


fun verifyScripts(    scriptSig: ByteArray,     scriptPubKey: ByteArray,     witness: ScriptWitness): Boolean

verify a script sig/script pubkey pair:

  • parse and run script sig
  • parse and run script pubkey using the stack generated by the previous step
  • check the final stack
  • extract and run embedded pay2sh scripts if any and check the stack again

Return

true if the scripts were successfully verified

Parameters

scriptSig

signature script

scriptPubKey

public key script