#[cfg(anchors)]
pub use bump_transaction::BumpTransactionEvent;
-use crate::chain::keysinterface::SpendableOutputDescriptor;
+use crate::sign::SpendableOutputDescriptor;
use crate::ln::channelmanager::{InterceptId, PaymentId, RecipientOnionFields};
use crate::ln::channel::FUNDING_CONF_DEADLINE_BLOCKS;
use crate::ln::features::ChannelTypeFeatures;
/// Be careful about printing the peer_msg, a well-crafted message could exploit
/// a security vulnerability in the terminal emulator or the logging subsystem.
/// To be safe, use `Display` on `UntrustedString`
- ///
+ ///
/// [`UntrustedString`]: crate::util::string::UntrustedString
peer_msg: UntrustedString,
},
/// This field will always be filled in when the event was generated by LDK versions
/// 0.0.113 and above.
///
- /// [phantom nodes]: crate::chain::keysinterface::PhantomKeysManager
+ /// [phantom nodes]: crate::sign::PhantomKeysManager
receiver_node_id: Option<PublicKey>,
/// The hash for which the preimage should be handed to the ChannelManager. Note that LDK will
/// not stop you from registering duplicate payment hashes for inbound payments.
/// This field will always be filled in when the event was generated by LDK versions
/// 0.0.113 and above.
///
- /// [phantom nodes]: crate::chain::keysinterface::PhantomKeysManager
+ /// [phantom nodes]: crate::sign::PhantomKeysManager
receiver_node_id: Option<PublicKey>,
/// The payment hash of the claimed payment. Note that LDK will not stop you from
/// registering duplicate payment hashes for inbound payments.
payment_id: PaymentId,
/// The hash that was given to [`ChannelManager::send_payment`].
///
+ /// This will be `Some` for all payments which completed on LDK 0.0.104 or later.
+ ///
/// [`ChannelManager::send_payment`]: crate::ln::channelmanager::ChannelManager::send_payment
payment_hash: Option<PaymentHash>,
/// The payment path that was successful.
PaymentPathFailed {
/// The `payment_id` passed to [`ChannelManager::send_payment`].
///
+ /// This will be `Some` for all payment paths which failed on LDK 0.0.103 or later.
+ ///
/// [`ChannelManager::send_payment`]: crate::ln::channelmanager::ChannelManager::send_payment
/// [`ChannelManager::abandon_payment`]: crate::ln::channelmanager::ChannelManager::abandon_payment
payment_id: Option<PaymentId>,
/// The message which should be sent.
msg: msgs::AcceptChannel,
},
+ /// Used to indicate that we've accepted a V2 channel open and should send the accept_channel2
+ /// message provided to the given peer.
+ SendAcceptChannelV2 {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::AcceptChannelV2,
+ },
/// Used to indicate that we've initiated a channel open and should send the open_channel
/// message provided to the given peer.
SendOpenChannel {
/// The message which should be sent.
msg: msgs::OpenChannel,
},
+ /// Used to indicate that we've initiated a V2 channel open and should send the open_channel2
+ /// message provided to the given peer.
+ SendOpenChannelV2 {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::OpenChannelV2,
+ },
/// Used to indicate that a funding_created message should be sent to the peer with the given node_id.
SendFundingCreated {
/// The node_id of the node which should receive this message
/// The message which should be sent.
msg: msgs::FundingSigned,
},
+ /// Used to indicate that a tx_add_input message should be sent to the peer with the given node_id.
+ SendTxAddInput {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::TxAddInput,
+ },
+ /// Used to indicate that a tx_add_output message should be sent to the peer with the given node_id.
+ SendTxAddOutput {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::TxAddOutput,
+ },
+ /// Used to indicate that a tx_remove_input message should be sent to the peer with the given node_id.
+ SendTxRemoveInput {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::TxRemoveInput,
+ },
+ /// Used to indicate that a tx_remove_output message should be sent to the peer with the given node_id.
+ SendTxRemoveOutput {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::TxRemoveOutput,
+ },
+ /// Used to indicate that a tx_complete message should be sent to the peer with the given node_id.
+ SendTxComplete {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::TxComplete,
+ },
+ /// Used to indicate that a tx_signatures message should be sent to the peer with the given node_id.
+ SendTxSignatures {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::TxSignatures,
+ },
+ /// Used to indicate that a tx_init_rbf message should be sent to the peer with the given node_id.
+ SendTxInitRbf {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::TxInitRbf,
+ },
+ /// Used to indicate that a tx_ack_rbf message should be sent to the peer with the given node_id.
+ SendTxAckRbf {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::TxAckRbf,
+ },
+ /// Used to indicate that a tx_abort message should be sent to the peer with the given node_id.
+ SendTxAbort {
+ /// The node_id of the node which should receive this message
+ node_id: PublicKey,
+ /// The message which should be sent.
+ msg: msgs::TxAddInput,
+ },
/// Used to indicate that a channel_ready message should be sent to the peer with the given node_id.
SendChannelReady {
/// The node_id of the node which should receive these message(s)