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
These use onion encoding for simple one-way messaging: there are no error returns.
Any reply is done with an enclosed blinded path.
Note that this defines the message system, not the contents of messages
(e.g. invoice requests from offers).
Signed-off-by: Rusty Russell <[email protected]>
Copy file name to clipboardExpand all lines: 01-messaging.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -49,7 +49,7 @@ The messages are grouped logically into five groups, ordered by the most signifi
49
49
- Setup & Control (types `0`-`31`): messages related to connection setup, control, supported features, and error reporting (described below)
50
50
- Channel (types `32`-`127`): messages used to setup and tear down micropayment channels (described in [BOLT #2](02-peer-protocol.md))
51
51
- Commitment (types `128`-`255`): messages related to updating the current commitment transaction, which includes adding, revoking, and settling HTLCs as well as updating fees and exchanging signatures (described in [BOLT #2](02-peer-protocol.md))
52
-
- Routing (types `256`-`511`): messages containing node and channel announcements, as well as any active route exploration (described in [BOLT #7](07-routing-gossip.md))
52
+
- Routing (types `256`-`511`): messages containing node and channel announcements, as well as any active route exploration or messaging (described in [BOLT #7](07-routing-gossip.md))
53
53
- Custom (types `32768`-`65535`): experimental and application-specific messages
54
54
55
55
The size of the message is required by the transport layer to fit into a 2-byte unsigned int; therefore, the maximum possible size is 65535 bytes.
Copy file name to clipboardExpand all lines: 07-routing-gossip.md
+54-2Lines changed: 54 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,4 @@
1
-
# BOLT #7: P2P Node and Channel Discovery
1
+
# BOLT #7: P2P Node and Channel Discovery and Onion Messages
2
2
3
3
This specification describes simple node discovery, channel discovery, and channel update mechanisms that do not rely on a third-party to disseminate the information.
4
4
@@ -33,6 +33,7 @@ To support channel and node discovery, three *gossip messages* are supported:
33
33
*[HTLC Fees](#htlc-fees)
34
34
*[Pruning the Network View](#pruning-the-network-view)
35
35
*[Recommendations for Routing](#recommendations-for-routing)
36
+
*[Onion Messages](#onion-messages)
36
37
*[References](#references)
37
38
38
39
## Definition of `short_channel_id`
@@ -1119,7 +1120,58 @@ A->D's `update_add_htlc` message would be:
1119
1120
And D->C's `update_add_htlc` would again be the same as B->C's direct payment
1120
1121
above.
1121
1122
1122
-
## References
1123
+
# Onion Messages
1124
+
1125
+
Onion messages allow peers to use existing connections to query for
1126
+
invoices (see [BOLT 12](12-offer-encoding.md)). Like gossip messages,
1127
+
they are not associated with a particular local channel. Like HTLCs,
1128
+
they use [BOLT 4](04-onion-routing.md#onion-messages) protocol for
1129
+
end-to-end encryption.
1130
+
1131
+
Onion messages are unreliable: in particular, they are designed to
1132
+
be cheap to process and require no storage to forward. As a result,
1133
+
there is no error returned from intermediary nodes.
1134
+
1135
+
To enable messaging via blinded paths, there is an optional `blinding`
1136
+
parameter which allows decryption of the `enctlv` field inside the
Copy file name to clipboardExpand all lines: 09-features.md
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -40,6 +40,7 @@ The Context column decodes as follows:
40
40
| 18/19 |`option_support_large_channel`| Can create large channels | IN ||[BOLT #2](02-peer-protocol.md#the-open_channel-message)|
41
41
| 20/21 |`option_anchor_outputs`| Anchor outputs | IN |`option_static_remotekey`|[BOLT #3](03-transactions.md)|
42
42
| 22/23 |`option_anchors_zero_fee_htlc_tx`| Anchor commitment type with zero fee HTLC transactions | IN ||[BOLT #3][bolt03-htlc-tx], [lightning-dev][ml-sighash-single-harmful]|
0 commit comments