From 62ab7424affdd87fa7bc25048a380b65dc20d40a Mon Sep 17 00:00:00 2001 From: Olaoluwa Osuntokun Date: Tue, 17 Jul 2018 19:26:53 -0700 Subject: [PATCH] breacharbiter: update second level pkScript as well In this commit, we update the convertToSecondLevelRevoke function to also upgrade the second level pkScript as well. This is required as we'll need to use this for a confirmation notification once we sweep the output in the case that the remote party goes to the second layer. --- breacharbiter.go | 1 + 1 file changed, 1 insertion(+) diff --git a/breacharbiter.go b/breacharbiter.go index 950fc497b..132477d47 100644 --- a/breacharbiter.go +++ b/breacharbiter.go @@ -298,6 +298,7 @@ func convertToSecondLevelRevoke(bo *breachedOutput, breachInfo *retributionInfo, newAmt := spendingTx.TxOut[0].Value bo.amt = btcutil.Amount(newAmt) bo.signDesc.Output.Value = newAmt + bo.signDesc.Output.PkScript = spendingTx.TxOut[0].PkScript // Finally, we'll need to adjust the witness program in the // SignDescriptor.