You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: lightning/src/ln/channel.rs
+6-5Lines changed: 6 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -7636,7 +7636,6 @@ where
7636
7636
let all_prevouts = sighash::Prevouts::All(&prev_outputs[..]);
7637
7637
7638
7638
let mut cache = SighashCache::new(&built_tx);
7639
-
let secp = Secp256k1::verification_only();
7640
7639
7641
7640
let script_pubkeys = unsigned_tx
7642
7641
.inputs()
@@ -7677,10 +7676,12 @@ where
7677
7676
.expect("Sighash is a SHA256 which is 32 bytes long");
7678
7677
let pubkey = PublicKey::from_slice(&witness[1]).map_err(|_| APIError::APIMisuseError { err: format!("The witness for input at index {input_idx} contains an invalid ECDSA public key") })?;
7679
7678
let sig = bitcoin::ecdsa::Signature::from_slice(&witness[0]).map_err(|_| APIError::APIMisuseError { err: format!("The witness for input at index {input_idx} contains an invalid signature") })?;
format!("Failed signature verification for input at index {input_idx} for P2WPKH spend.") }
7683
-
})?;
7683
+
},
7684
+
)?;
7684
7685
continue 'inputs;
7685
7686
}
7686
7687
@@ -7717,7 +7718,7 @@ where
7717
7718
_ => return Err(APIError::APIMisuseError { err: format!("The scriptPubKey of the previous output for input at index {input_idx} for a P2TR key path spend is invalid") }),
7718
7719
}.map_err(|_| APIError::APIMisuseError { err: format!("The scriptPubKey of the previous output for input at index {input_idx} for a P2TR key path spend has an invalid public key") })?;
7719
7720
let sig = bitcoin::taproot::Signature::from_slice(&witness[0]).map_err(|_| APIError::APIMisuseError { err: format!("The witness for input at index {input_idx} for a P2TR key path spend has an invalid signature") })?;
0 commit comments