Skip to content

Commit 947590c

Browse files
committed
fix OnionPacket comments
1 parent 5d38217 commit 947590c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lightning/src/ln/msgs.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1674,20 +1674,20 @@ pub use self::fuzzy_internal_msgs::*;
16741674
#[cfg(not(fuzzing))]
16751675
pub(crate) use self::fuzzy_internal_msgs::*;
16761676

1677-
/// Full Bolt04 OnionPacket including next hop data
1677+
/// BOLT 4 onion packet including hop data for the next peer.
16781678
#[derive(Clone)]
16791679
pub struct OnionPacket {
1680-
/// Bolt 04 version
1680+
/// BOLT 4 version number.
16811681
pub version: u8,
16821682
/// In order to ensure we always return an error on onion decode in compliance with [BOLT
16831683
/// #4](https://github.com/lightning/bolts/blob/master/04-onion-routing.md), we have to
16841684
/// deserialize `OnionPacket`s contained in [`UpdateAddHTLC`] messages even if the ephemeral
16851685
/// public key (here) is bogus, so we hold a [`Result`] instead of a [`PublicKey`] as we'd
16861686
/// like.
16871687
pub public_key: Result<PublicKey, secp256k1::Error>,
1688-
/// Encrypted data for the next hop
1688+
/// 1300 bytes encrypted payload for the next hop.
16891689
pub hop_data: [u8; 20*65],
1690-
/// HMAC to validate hop_date
1690+
/// HMAC to verify the integrity of hop_data.
16911691
pub hmac: [u8; 32],
16921692
}
16931693

0 commit comments

Comments
 (0)