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
let payment_preimage = match inbound_payment::verify(payment_hash, payment_data.clone(),self.highest_seen_timestamp.load(Ordering::Acquire)asu64,&self.inbound_payment_key,&self.logger){
3277
+
let payment_preimage = match inbound_payment::verify(payment_hash,&payment_data,self.highest_seen_timestamp.load(Ordering::Acquire)asu64,&self.inbound_payment_key,&self.logger){
3278
3278
Ok(payment_preimage) => payment_preimage,
3279
3279
Err(()) => {
3280
3280
fail_htlc!(claimable_htlc);
@@ -7126,15 +7126,15 @@ mod tests {
7126
7126
// payment verification fails as expected.
7127
7127
letmut bad_payment_hash = payment_hash.clone();
7128
7128
bad_payment_hash.0[0] += 1;
7129
-
match inbound_payment::verify(bad_payment_hash, payment_data.clone(), nodes[0].node.highest_seen_timestamp.load(Ordering::Acquire)asu64,&nodes[0].node.inbound_payment_key,&nodes[0].logger){
7129
+
match inbound_payment::verify(bad_payment_hash,&payment_data, nodes[0].node.highest_seen_timestamp.load(Ordering::Acquire)asu64,&nodes[0].node.inbound_payment_key,&nodes[0].logger){
7130
7130
Ok(_) => panic!("Unexpected ok"),
7131
7131
Err(()) => {
7132
7132
nodes[0].logger.assert_log_contains("lightning::ln::channelmanager::inbound_payment".to_string(),"Failing HTLC with user-generated payment_hash".to_string(),1);
7133
7133
}
7134
7134
}
7135
7135
7136
7136
// Check that using the original payment hash succeeds.
0 commit comments