pub enum HTLCHandlingFailureType {
Forward {
node_id: Option<PublicKey>,
channel_id: ChannelId,
},
UnknownNextHop {
requested_forward_scid: u64,
},
InvalidForward {
requested_forward_scid: u64,
},
InvalidOnion,
Receive {
payment_hash: PaymentHash,
},
}Expand description
The type of HTLC handling performed in Event::HTLCHandlingFailed.
Variants§
Forward
We tried forwarding to a channel but failed to do so. An example of such an instance is when there is insufficient capacity in our outbound channel.
Fields
UnknownNextHop
Scenario where we are unsure of the next node to forward the HTLC to.
Deprecated: will only be used in versions before LDK v0.2.0. Downgrades will result in
this type being represented as Self::InvalidForward.
InvalidForward
We couldn’t forward to the outgoing scid. An example would be attempting to send a duplicate intercept HTLC.
In LDK v0.2.0 and greater, this variant replaces Self::UnknownNextHop.
InvalidOnion
We couldn’t decode the incoming onion to obtain the forwarding details.
Receive
Failure scenario where an HTLC may have been forwarded to be intended for us, but is invalid for some reason, so we reject it.
Some of the reasons may include:
- HTLC Timeouts
- Excess HTLCs for a payment that we have already fully received, over-paying for the payment,
- The counterparty node modified the HTLC in transit,
- A probing attack where an intermediary node is trying to detect if we are the ultimate recipient for a payment.
Fields
payment_hash: PaymentHashThe payment hash of the payment we attempted to process.
Trait Implementations§
Source§impl Clone for HTLCHandlingFailureType
impl Clone for HTLCHandlingFailureType
Source§fn clone(&self) -> HTLCHandlingFailureType
fn clone(&self) -> HTLCHandlingFailureType
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more