X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Fln%2Fmsgs.rs;h=0e5b2e07e7a4cea649bc44939a67f2c940f71779;hb=a551a6219c06d4ed149dcecc4553bc8a85e408f0;hp=9007f3f2ea7d59aaa820c0999e5c069be3718935;hpb=a82067d3595a782d656f18d544145b547e27abc4;p=rust-lightning diff --git a/lightning/src/ln/msgs.rs b/lightning/src/ln/msgs.rs index 9007f3f2..0e5b2e07 100644 --- a/lightning/src/ln/msgs.rs +++ b/lightning/src/ln/msgs.rs @@ -24,8 +24,8 @@ //! raw socket events into your non-internet-facing system and then send routing events back to //! track the network on the less-secure system. -use bitcoin::secp256k1::key::PublicKey; -use bitcoin::secp256k1::Signature; +use bitcoin::secp256k1::PublicKey; +use bitcoin::secp256k1::ecdsa::Signature; use bitcoin::secp256k1; use bitcoin::blockdata::script::Script; use bitcoin::hash_types::{Txid, BlockHash}; @@ -75,6 +75,11 @@ pub enum DecodeError { pub struct Init { /// The relevant features which the sender supports pub features: InitFeatures, + /// The receipient's network address. This adds the option to report a remote IP address + /// back to a connecting peer using the init message. A node can decide to use that information + /// to discover a potential update to its public IPv4 address (NAT) and use + /// that for a node_announcement update message containing the new address. + pub remote_network_address: Option, } /// An error message to be sent or received from a peer @@ -204,6 +209,12 @@ pub struct AcceptChannel { pub first_per_commitment_point: PublicKey, /// Optionally, a request to pre-set the to-sender output's scriptPubkey for when we collaboratively close pub shutdown_scriptpubkey: OptionalField