1
0

lnmsg: rewrite LN msg encoding/decoding

This commit is contained in:
SomberNight
2020-03-12 01:44:42 +01:00
parent 371f55a0f9
commit 4c10a830f3
8 changed files with 477 additions and 1036 deletions

View File

@@ -0,0 +1,5 @@
These files are generated from the BOLT repository:
```
$ python3 tools/extract-formats.py 01-*.md 02-*.md 07-*.md > peer_wire.csv
$ python3 tools/extract-formats.py 04-*.md > onion_wire.csv
```

View File

@@ -0,0 +1,53 @@
tlvtype,tlv_payload,amt_to_forward,2
tlvdata,tlv_payload,amt_to_forward,amt_to_forward,tu64,
tlvtype,tlv_payload,outgoing_cltv_value,4
tlvdata,tlv_payload,outgoing_cltv_value,outgoing_cltv_value,tu32,
tlvtype,tlv_payload,short_channel_id,6
tlvdata,tlv_payload,short_channel_id,short_channel_id,short_channel_id,
tlvtype,tlv_payload,payment_data,8
tlvdata,tlv_payload,payment_data,payment_secret,byte,32
tlvdata,tlv_payload,payment_data,total_msat,tu64,
msgtype,invalid_realm,PERM|1
msgtype,temporary_node_failure,NODE|2
msgtype,permanent_node_failure,PERM|NODE|2
msgtype,required_node_feature_missing,PERM|NODE|3
msgtype,invalid_onion_version,BADONION|PERM|4
msgdata,invalid_onion_version,sha256_of_onion,sha256,
msgtype,invalid_onion_hmac,BADONION|PERM|5
msgdata,invalid_onion_hmac,sha256_of_onion,sha256,
msgtype,invalid_onion_key,BADONION|PERM|6
msgdata,invalid_onion_key,sha256_of_onion,sha256,
msgtype,temporary_channel_failure,UPDATE|7
msgdata,temporary_channel_failure,len,u16,
msgdata,temporary_channel_failure,channel_update,byte,len
msgtype,permanent_channel_failure,PERM|8
msgtype,required_channel_feature_missing,PERM|9
msgtype,unknown_next_peer,PERM|10
msgtype,amount_below_minimum,UPDATE|11
msgdata,amount_below_minimum,htlc_msat,u64,
msgdata,amount_below_minimum,len,u16,
msgdata,amount_below_minimum,channel_update,byte,len
msgtype,fee_insufficient,UPDATE|12
msgdata,fee_insufficient,htlc_msat,u64,
msgdata,fee_insufficient,len,u16,
msgdata,fee_insufficient,channel_update,byte,len
msgtype,incorrect_cltv_expiry,UPDATE|13
msgdata,incorrect_cltv_expiry,cltv_expiry,u32,
msgdata,incorrect_cltv_expiry,len,u16,
msgdata,incorrect_cltv_expiry,channel_update,byte,len
msgtype,expiry_too_soon,UPDATE|14
msgdata,expiry_too_soon,len,u16,
msgdata,expiry_too_soon,channel_update,byte,len
msgtype,incorrect_or_unknown_payment_details,PERM|15
msgdata,incorrect_or_unknown_payment_details,htlc_msat,u64,
msgdata,incorrect_or_unknown_payment_details,height,u32,
msgtype,final_incorrect_cltv_expiry,18
msgdata,final_incorrect_cltv_expiry,cltv_expiry,u32,
msgtype,final_incorrect_htlc_amount,19
msgdata,final_incorrect_htlc_amount,incoming_htlc_amt,u64,
msgtype,channel_disabled,UPDATE|20
msgtype,expiry_too_far,21
msgtype,invalid_onion_payload,PERM|22
msgdata,invalid_onion_payload,type,varint,
msgdata,invalid_onion_payload,offset,u16,
msgtype,mpp_timeout,23
1 tlvtype,tlv_payload,amt_to_forward,2
2 tlvdata,tlv_payload,amt_to_forward,amt_to_forward,tu64,
3 tlvtype,tlv_payload,outgoing_cltv_value,4
4 tlvdata,tlv_payload,outgoing_cltv_value,outgoing_cltv_value,tu32,
5 tlvtype,tlv_payload,short_channel_id,6
6 tlvdata,tlv_payload,short_channel_id,short_channel_id,short_channel_id,
7 tlvtype,tlv_payload,payment_data,8
8 tlvdata,tlv_payload,payment_data,payment_secret,byte,32
9 tlvdata,tlv_payload,payment_data,total_msat,tu64,
10 msgtype,invalid_realm,PERM|1
11 msgtype,temporary_node_failure,NODE|2
12 msgtype,permanent_node_failure,PERM|NODE|2
13 msgtype,required_node_feature_missing,PERM|NODE|3
14 msgtype,invalid_onion_version,BADONION|PERM|4
15 msgdata,invalid_onion_version,sha256_of_onion,sha256,
16 msgtype,invalid_onion_hmac,BADONION|PERM|5
17 msgdata,invalid_onion_hmac,sha256_of_onion,sha256,
18 msgtype,invalid_onion_key,BADONION|PERM|6
19 msgdata,invalid_onion_key,sha256_of_onion,sha256,
20 msgtype,temporary_channel_failure,UPDATE|7
21 msgdata,temporary_channel_failure,len,u16,
22 msgdata,temporary_channel_failure,channel_update,byte,len
23 msgtype,permanent_channel_failure,PERM|8
24 msgtype,required_channel_feature_missing,PERM|9
25 msgtype,unknown_next_peer,PERM|10
26 msgtype,amount_below_minimum,UPDATE|11
27 msgdata,amount_below_minimum,htlc_msat,u64,
28 msgdata,amount_below_minimum,len,u16,
29 msgdata,amount_below_minimum,channel_update,byte,len
30 msgtype,fee_insufficient,UPDATE|12
31 msgdata,fee_insufficient,htlc_msat,u64,
32 msgdata,fee_insufficient,len,u16,
33 msgdata,fee_insufficient,channel_update,byte,len
34 msgtype,incorrect_cltv_expiry,UPDATE|13
35 msgdata,incorrect_cltv_expiry,cltv_expiry,u32,
36 msgdata,incorrect_cltv_expiry,len,u16,
37 msgdata,incorrect_cltv_expiry,channel_update,byte,len
38 msgtype,expiry_too_soon,UPDATE|14
39 msgdata,expiry_too_soon,len,u16,
40 msgdata,expiry_too_soon,channel_update,byte,len
41 msgtype,incorrect_or_unknown_payment_details,PERM|15
42 msgdata,incorrect_or_unknown_payment_details,htlc_msat,u64,
43 msgdata,incorrect_or_unknown_payment_details,height,u32,
44 msgtype,final_incorrect_cltv_expiry,18
45 msgdata,final_incorrect_cltv_expiry,cltv_expiry,u32,
46 msgtype,final_incorrect_htlc_amount,19
47 msgdata,final_incorrect_htlc_amount,incoming_htlc_amt,u64,
48 msgtype,channel_disabled,UPDATE|20
49 msgtype,expiry_too_far,21
50 msgtype,invalid_onion_payload,PERM|22
51 msgdata,invalid_onion_payload,type,varint,
52 msgdata,invalid_onion_payload,offset,u16,
53 msgtype,mpp_timeout,23

View File

@@ -0,0 +1,210 @@
msgtype,init,16
msgdata,init,gflen,u16,
msgdata,init,globalfeatures,byte,gflen
msgdata,init,flen,u16,
msgdata,init,features,byte,flen
msgdata,init,tlvs,init_tlvs,
tlvtype,init_tlvs,networks,1
tlvdata,init_tlvs,networks,chains,chain_hash,...
msgtype,error,17
msgdata,error,channel_id,channel_id,
msgdata,error,len,u16,
msgdata,error,data,byte,len
msgtype,ping,18
msgdata,ping,num_pong_bytes,u16,
msgdata,ping,byteslen,u16,
msgdata,ping,ignored,byte,byteslen
msgtype,pong,19
msgdata,pong,byteslen,u16,
msgdata,pong,ignored,byte,byteslen
tlvtype,n1,tlv1,1
tlvdata,n1,tlv1,amount_msat,tu64,
tlvtype,n1,tlv2,2
tlvdata,n1,tlv2,scid,short_channel_id,
tlvtype,n1,tlv3,3
tlvdata,n1,tlv3,node_id,point,
tlvdata,n1,tlv3,amount_msat_1,u64,
tlvdata,n1,tlv3,amount_msat_2,u64,
tlvtype,n1,tlv4,254
tlvdata,n1,tlv4,cltv_delta,u16,
tlvtype,n2,tlv1,0
tlvdata,n2,tlv1,amount_msat,tu64,
tlvtype,n2,tlv2,11
tlvdata,n2,tlv2,cltv_expiry,tu32,
msgtype,open_channel,32
msgdata,open_channel,chain_hash,chain_hash,
msgdata,open_channel,temporary_channel_id,byte,32
msgdata,open_channel,funding_satoshis,u64,
msgdata,open_channel,push_msat,u64,
msgdata,open_channel,dust_limit_satoshis,u64,
msgdata,open_channel,max_htlc_value_in_flight_msat,u64,
msgdata,open_channel,channel_reserve_satoshis,u64,
msgdata,open_channel,htlc_minimum_msat,u64,
msgdata,open_channel,feerate_per_kw,u32,
msgdata,open_channel,to_self_delay,u16,
msgdata,open_channel,max_accepted_htlcs,u16,
msgdata,open_channel,funding_pubkey,point,
msgdata,open_channel,revocation_basepoint,point,
msgdata,open_channel,payment_basepoint,point,
msgdata,open_channel,delayed_payment_basepoint,point,
msgdata,open_channel,htlc_basepoint,point,
msgdata,open_channel,first_per_commitment_point,point,
msgdata,open_channel,channel_flags,byte,
msgdata,open_channel,shutdown_len,u16,,option_upfront_shutdown_script
msgdata,open_channel,shutdown_scriptpubkey,byte,shutdown_len,option_upfront_shutdown_script
msgtype,accept_channel,33
msgdata,accept_channel,temporary_channel_id,byte,32
msgdata,accept_channel,dust_limit_satoshis,u64,
msgdata,accept_channel,max_htlc_value_in_flight_msat,u64,
msgdata,accept_channel,channel_reserve_satoshis,u64,
msgdata,accept_channel,htlc_minimum_msat,u64,
msgdata,accept_channel,minimum_depth,u32,
msgdata,accept_channel,to_self_delay,u16,
msgdata,accept_channel,max_accepted_htlcs,u16,
msgdata,accept_channel,funding_pubkey,point,
msgdata,accept_channel,revocation_basepoint,point,
msgdata,accept_channel,payment_basepoint,point,
msgdata,accept_channel,delayed_payment_basepoint,point,
msgdata,accept_channel,htlc_basepoint,point,
msgdata,accept_channel,first_per_commitment_point,point,
msgdata,accept_channel,shutdown_len,u16,,option_upfront_shutdown_script
msgdata,accept_channel,shutdown_scriptpubkey,byte,shutdown_len,option_upfront_shutdown_script
msgtype,funding_created,34
msgdata,funding_created,temporary_channel_id,byte,32
msgdata,funding_created,funding_txid,sha256,
msgdata,funding_created,funding_output_index,u16,
msgdata,funding_created,signature,signature,
msgtype,funding_signed,35
msgdata,funding_signed,channel_id,channel_id,
msgdata,funding_signed,signature,signature,
msgtype,funding_locked,36
msgdata,funding_locked,channel_id,channel_id,
msgdata,funding_locked,next_per_commitment_point,point,
msgtype,shutdown,38
msgdata,shutdown,channel_id,channel_id,
msgdata,shutdown,len,u16,
msgdata,shutdown,scriptpubkey,byte,len
msgtype,closing_signed,39
msgdata,closing_signed,channel_id,channel_id,
msgdata,closing_signed,fee_satoshis,u64,
msgdata,closing_signed,signature,signature,
msgtype,update_add_htlc,128
msgdata,update_add_htlc,channel_id,channel_id,
msgdata,update_add_htlc,id,u64,
msgdata,update_add_htlc,amount_msat,u64,
msgdata,update_add_htlc,payment_hash,sha256,
msgdata,update_add_htlc,cltv_expiry,u32,
msgdata,update_add_htlc,onion_routing_packet,byte,1366
msgtype,update_fulfill_htlc,130
msgdata,update_fulfill_htlc,channel_id,channel_id,
msgdata,update_fulfill_htlc,id,u64,
msgdata,update_fulfill_htlc,payment_preimage,byte,32
msgtype,update_fail_htlc,131
msgdata,update_fail_htlc,channel_id,channel_id,
msgdata,update_fail_htlc,id,u64,
msgdata,update_fail_htlc,len,u16,
msgdata,update_fail_htlc,reason,byte,len
msgtype,update_fail_malformed_htlc,135
msgdata,update_fail_malformed_htlc,channel_id,channel_id,
msgdata,update_fail_malformed_htlc,id,u64,
msgdata,update_fail_malformed_htlc,sha256_of_onion,sha256,
msgdata,update_fail_malformed_htlc,failure_code,u16,
msgtype,commitment_signed,132
msgdata,commitment_signed,channel_id,channel_id,
msgdata,commitment_signed,signature,signature,
msgdata,commitment_signed,num_htlcs,u16,
msgdata,commitment_signed,htlc_signature,signature,num_htlcs
msgtype,revoke_and_ack,133
msgdata,revoke_and_ack,channel_id,channel_id,
msgdata,revoke_and_ack,per_commitment_secret,byte,32
msgdata,revoke_and_ack,next_per_commitment_point,point,
msgtype,update_fee,134
msgdata,update_fee,channel_id,channel_id,
msgdata,update_fee,feerate_per_kw,u32,
msgtype,channel_reestablish,136
msgdata,channel_reestablish,channel_id,channel_id,
msgdata,channel_reestablish,next_commitment_number,u64,
msgdata,channel_reestablish,next_revocation_number,u64,
msgdata,channel_reestablish,your_last_per_commitment_secret,byte,32,option_data_loss_protect,option_static_remotekey
msgdata,channel_reestablish,my_current_per_commitment_point,point,,option_data_loss_protect,option_static_remotekey
msgtype,announcement_signatures,259
msgdata,announcement_signatures,channel_id,channel_id,
msgdata,announcement_signatures,short_channel_id,short_channel_id,
msgdata,announcement_signatures,node_signature,signature,
msgdata,announcement_signatures,bitcoin_signature,signature,
msgtype,channel_announcement,256
msgdata,channel_announcement,node_signature_1,signature,
msgdata,channel_announcement,node_signature_2,signature,
msgdata,channel_announcement,bitcoin_signature_1,signature,
msgdata,channel_announcement,bitcoin_signature_2,signature,
msgdata,channel_announcement,len,u16,
msgdata,channel_announcement,features,byte,len
msgdata,channel_announcement,chain_hash,chain_hash,
msgdata,channel_announcement,short_channel_id,short_channel_id,
msgdata,channel_announcement,node_id_1,point,
msgdata,channel_announcement,node_id_2,point,
msgdata,channel_announcement,bitcoin_key_1,point,
msgdata,channel_announcement,bitcoin_key_2,point,
msgtype,node_announcement,257
msgdata,node_announcement,signature,signature,
msgdata,node_announcement,flen,u16,
msgdata,node_announcement,features,byte,flen
msgdata,node_announcement,timestamp,u32,
msgdata,node_announcement,node_id,point,
msgdata,node_announcement,rgb_color,byte,3
msgdata,node_announcement,alias,byte,32
msgdata,node_announcement,addrlen,u16,
msgdata,node_announcement,addresses,byte,addrlen
msgtype,channel_update,258
msgdata,channel_update,signature,signature,
msgdata,channel_update,chain_hash,chain_hash,
msgdata,channel_update,short_channel_id,short_channel_id,
msgdata,channel_update,timestamp,u32,
msgdata,channel_update,message_flags,byte,
msgdata,channel_update,channel_flags,byte,
msgdata,channel_update,cltv_expiry_delta,u16,
msgdata,channel_update,htlc_minimum_msat,u64,
msgdata,channel_update,fee_base_msat,u32,
msgdata,channel_update,fee_proportional_millionths,u32,
msgdata,channel_update,htlc_maximum_msat,u64,,option_channel_htlc_max
msgtype,query_short_channel_ids,261,gossip_queries
msgdata,query_short_channel_ids,chain_hash,chain_hash,
msgdata,query_short_channel_ids,len,u16,
msgdata,query_short_channel_ids,encoded_short_ids,byte,len
msgdata,query_short_channel_ids,tlvs,query_short_channel_ids_tlvs,
tlvtype,query_short_channel_ids_tlvs,query_flags,1
tlvdata,query_short_channel_ids_tlvs,query_flags,encoding_type,u8,
tlvdata,query_short_channel_ids_tlvs,query_flags,encoded_query_flags,byte,...
msgtype,reply_short_channel_ids_end,262,gossip_queries
msgdata,reply_short_channel_ids_end,chain_hash,chain_hash,
msgdata,reply_short_channel_ids_end,complete,byte,
msgtype,query_channel_range,263,gossip_queries
msgdata,query_channel_range,chain_hash,chain_hash,
msgdata,query_channel_range,first_blocknum,u32,
msgdata,query_channel_range,number_of_blocks,u32,
msgdata,query_channel_range,tlvs,query_channel_range_tlvs,
tlvtype,query_channel_range_tlvs,query_option,1
tlvdata,query_channel_range_tlvs,query_option,query_option_flags,varint,
msgtype,reply_channel_range,264,gossip_queries
msgdata,reply_channel_range,chain_hash,chain_hash,
msgdata,reply_channel_range,first_blocknum,u32,
msgdata,reply_channel_range,number_of_blocks,u32,
msgdata,reply_channel_range,complete,byte,
msgdata,reply_channel_range,len,u16,
msgdata,reply_channel_range,encoded_short_ids,byte,len
msgdata,reply_channel_range,tlvs,reply_channel_range_tlvs,
tlvtype,reply_channel_range_tlvs,timestamps_tlv,1
tlvdata,reply_channel_range_tlvs,timestamps_tlv,encoding_type,u8,
tlvdata,reply_channel_range_tlvs,timestamps_tlv,encoded_timestamps,byte,...
tlvtype,reply_channel_range_tlvs,checksums_tlv,3
tlvdata,reply_channel_range_tlvs,checksums_tlv,checksums,channel_update_checksums,...
subtype,channel_update_timestamps
subtypedata,channel_update_timestamps,timestamp_node_id_1,u32,
subtypedata,channel_update_timestamps,timestamp_node_id_2,u32,
subtype,channel_update_checksums
subtypedata,channel_update_checksums,checksum_node_id_1,u32,
subtypedata,channel_update_checksums,checksum_node_id_2,u32,
msgtype,gossip_timestamp_filter,265,gossip_queries
msgdata,gossip_timestamp_filter,chain_hash,chain_hash,
msgdata,gossip_timestamp_filter,first_timestamp,u32,
msgdata,gossip_timestamp_filter,timestamp_range,u32,
1 msgtype,init,16
2 msgdata,init,gflen,u16,
3 msgdata,init,globalfeatures,byte,gflen
4 msgdata,init,flen,u16,
5 msgdata,init,features,byte,flen
6 msgdata,init,tlvs,init_tlvs,
7 tlvtype,init_tlvs,networks,1
8 tlvdata,init_tlvs,networks,chains,chain_hash,...
9 msgtype,error,17
10 msgdata,error,channel_id,channel_id,
11 msgdata,error,len,u16,
12 msgdata,error,data,byte,len
13 msgtype,ping,18
14 msgdata,ping,num_pong_bytes,u16,
15 msgdata,ping,byteslen,u16,
16 msgdata,ping,ignored,byte,byteslen
17 msgtype,pong,19
18 msgdata,pong,byteslen,u16,
19 msgdata,pong,ignored,byte,byteslen
20 tlvtype,n1,tlv1,1
21 tlvdata,n1,tlv1,amount_msat,tu64,
22 tlvtype,n1,tlv2,2
23 tlvdata,n1,tlv2,scid,short_channel_id,
24 tlvtype,n1,tlv3,3
25 tlvdata,n1,tlv3,node_id,point,
26 tlvdata,n1,tlv3,amount_msat_1,u64,
27 tlvdata,n1,tlv3,amount_msat_2,u64,
28 tlvtype,n1,tlv4,254
29 tlvdata,n1,tlv4,cltv_delta,u16,
30 tlvtype,n2,tlv1,0
31 tlvdata,n2,tlv1,amount_msat,tu64,
32 tlvtype,n2,tlv2,11
33 tlvdata,n2,tlv2,cltv_expiry,tu32,
34 msgtype,open_channel,32
35 msgdata,open_channel,chain_hash,chain_hash,
36 msgdata,open_channel,temporary_channel_id,byte,32
37 msgdata,open_channel,funding_satoshis,u64,
38 msgdata,open_channel,push_msat,u64,
39 msgdata,open_channel,dust_limit_satoshis,u64,
40 msgdata,open_channel,max_htlc_value_in_flight_msat,u64,
41 msgdata,open_channel,channel_reserve_satoshis,u64,
42 msgdata,open_channel,htlc_minimum_msat,u64,
43 msgdata,open_channel,feerate_per_kw,u32,
44 msgdata,open_channel,to_self_delay,u16,
45 msgdata,open_channel,max_accepted_htlcs,u16,
46 msgdata,open_channel,funding_pubkey,point,
47 msgdata,open_channel,revocation_basepoint,point,
48 msgdata,open_channel,payment_basepoint,point,
49 msgdata,open_channel,delayed_payment_basepoint,point,
50 msgdata,open_channel,htlc_basepoint,point,
51 msgdata,open_channel,first_per_commitment_point,point,
52 msgdata,open_channel,channel_flags,byte,
53 msgdata,open_channel,shutdown_len,u16,,option_upfront_shutdown_script
54 msgdata,open_channel,shutdown_scriptpubkey,byte,shutdown_len,option_upfront_shutdown_script
55 msgtype,accept_channel,33
56 msgdata,accept_channel,temporary_channel_id,byte,32
57 msgdata,accept_channel,dust_limit_satoshis,u64,
58 msgdata,accept_channel,max_htlc_value_in_flight_msat,u64,
59 msgdata,accept_channel,channel_reserve_satoshis,u64,
60 msgdata,accept_channel,htlc_minimum_msat,u64,
61 msgdata,accept_channel,minimum_depth,u32,
62 msgdata,accept_channel,to_self_delay,u16,
63 msgdata,accept_channel,max_accepted_htlcs,u16,
64 msgdata,accept_channel,funding_pubkey,point,
65 msgdata,accept_channel,revocation_basepoint,point,
66 msgdata,accept_channel,payment_basepoint,point,
67 msgdata,accept_channel,delayed_payment_basepoint,point,
68 msgdata,accept_channel,htlc_basepoint,point,
69 msgdata,accept_channel,first_per_commitment_point,point,
70 msgdata,accept_channel,shutdown_len,u16,,option_upfront_shutdown_script
71 msgdata,accept_channel,shutdown_scriptpubkey,byte,shutdown_len,option_upfront_shutdown_script
72 msgtype,funding_created,34
73 msgdata,funding_created,temporary_channel_id,byte,32
74 msgdata,funding_created,funding_txid,sha256,
75 msgdata,funding_created,funding_output_index,u16,
76 msgdata,funding_created,signature,signature,
77 msgtype,funding_signed,35
78 msgdata,funding_signed,channel_id,channel_id,
79 msgdata,funding_signed,signature,signature,
80 msgtype,funding_locked,36
81 msgdata,funding_locked,channel_id,channel_id,
82 msgdata,funding_locked,next_per_commitment_point,point,
83 msgtype,shutdown,38
84 msgdata,shutdown,channel_id,channel_id,
85 msgdata,shutdown,len,u16,
86 msgdata,shutdown,scriptpubkey,byte,len
87 msgtype,closing_signed,39
88 msgdata,closing_signed,channel_id,channel_id,
89 msgdata,closing_signed,fee_satoshis,u64,
90 msgdata,closing_signed,signature,signature,
91 msgtype,update_add_htlc,128
92 msgdata,update_add_htlc,channel_id,channel_id,
93 msgdata,update_add_htlc,id,u64,
94 msgdata,update_add_htlc,amount_msat,u64,
95 msgdata,update_add_htlc,payment_hash,sha256,
96 msgdata,update_add_htlc,cltv_expiry,u32,
97 msgdata,update_add_htlc,onion_routing_packet,byte,1366
98 msgtype,update_fulfill_htlc,130
99 msgdata,update_fulfill_htlc,channel_id,channel_id,
100 msgdata,update_fulfill_htlc,id,u64,
101 msgdata,update_fulfill_htlc,payment_preimage,byte,32
102 msgtype,update_fail_htlc,131
103 msgdata,update_fail_htlc,channel_id,channel_id,
104 msgdata,update_fail_htlc,id,u64,
105 msgdata,update_fail_htlc,len,u16,
106 msgdata,update_fail_htlc,reason,byte,len
107 msgtype,update_fail_malformed_htlc,135
108 msgdata,update_fail_malformed_htlc,channel_id,channel_id,
109 msgdata,update_fail_malformed_htlc,id,u64,
110 msgdata,update_fail_malformed_htlc,sha256_of_onion,sha256,
111 msgdata,update_fail_malformed_htlc,failure_code,u16,
112 msgtype,commitment_signed,132
113 msgdata,commitment_signed,channel_id,channel_id,
114 msgdata,commitment_signed,signature,signature,
115 msgdata,commitment_signed,num_htlcs,u16,
116 msgdata,commitment_signed,htlc_signature,signature,num_htlcs
117 msgtype,revoke_and_ack,133
118 msgdata,revoke_and_ack,channel_id,channel_id,
119 msgdata,revoke_and_ack,per_commitment_secret,byte,32
120 msgdata,revoke_and_ack,next_per_commitment_point,point,
121 msgtype,update_fee,134
122 msgdata,update_fee,channel_id,channel_id,
123 msgdata,update_fee,feerate_per_kw,u32,
124 msgtype,channel_reestablish,136
125 msgdata,channel_reestablish,channel_id,channel_id,
126 msgdata,channel_reestablish,next_commitment_number,u64,
127 msgdata,channel_reestablish,next_revocation_number,u64,
128 msgdata,channel_reestablish,your_last_per_commitment_secret,byte,32,option_data_loss_protect,option_static_remotekey
129 msgdata,channel_reestablish,my_current_per_commitment_point,point,,option_data_loss_protect,option_static_remotekey
130 msgtype,announcement_signatures,259
131 msgdata,announcement_signatures,channel_id,channel_id,
132 msgdata,announcement_signatures,short_channel_id,short_channel_id,
133 msgdata,announcement_signatures,node_signature,signature,
134 msgdata,announcement_signatures,bitcoin_signature,signature,
135 msgtype,channel_announcement,256
136 msgdata,channel_announcement,node_signature_1,signature,
137 msgdata,channel_announcement,node_signature_2,signature,
138 msgdata,channel_announcement,bitcoin_signature_1,signature,
139 msgdata,channel_announcement,bitcoin_signature_2,signature,
140 msgdata,channel_announcement,len,u16,
141 msgdata,channel_announcement,features,byte,len
142 msgdata,channel_announcement,chain_hash,chain_hash,
143 msgdata,channel_announcement,short_channel_id,short_channel_id,
144 msgdata,channel_announcement,node_id_1,point,
145 msgdata,channel_announcement,node_id_2,point,
146 msgdata,channel_announcement,bitcoin_key_1,point,
147 msgdata,channel_announcement,bitcoin_key_2,point,
148 msgtype,node_announcement,257
149 msgdata,node_announcement,signature,signature,
150 msgdata,node_announcement,flen,u16,
151 msgdata,node_announcement,features,byte,flen
152 msgdata,node_announcement,timestamp,u32,
153 msgdata,node_announcement,node_id,point,
154 msgdata,node_announcement,rgb_color,byte,3
155 msgdata,node_announcement,alias,byte,32
156 msgdata,node_announcement,addrlen,u16,
157 msgdata,node_announcement,addresses,byte,addrlen
158 msgtype,channel_update,258
159 msgdata,channel_update,signature,signature,
160 msgdata,channel_update,chain_hash,chain_hash,
161 msgdata,channel_update,short_channel_id,short_channel_id,
162 msgdata,channel_update,timestamp,u32,
163 msgdata,channel_update,message_flags,byte,
164 msgdata,channel_update,channel_flags,byte,
165 msgdata,channel_update,cltv_expiry_delta,u16,
166 msgdata,channel_update,htlc_minimum_msat,u64,
167 msgdata,channel_update,fee_base_msat,u32,
168 msgdata,channel_update,fee_proportional_millionths,u32,
169 msgdata,channel_update,htlc_maximum_msat,u64,,option_channel_htlc_max
170 msgtype,query_short_channel_ids,261,gossip_queries
171 msgdata,query_short_channel_ids,chain_hash,chain_hash,
172 msgdata,query_short_channel_ids,len,u16,
173 msgdata,query_short_channel_ids,encoded_short_ids,byte,len
174 msgdata,query_short_channel_ids,tlvs,query_short_channel_ids_tlvs,
175 tlvtype,query_short_channel_ids_tlvs,query_flags,1
176 tlvdata,query_short_channel_ids_tlvs,query_flags,encoding_type,u8,
177 tlvdata,query_short_channel_ids_tlvs,query_flags,encoded_query_flags,byte,...
178 msgtype,reply_short_channel_ids_end,262,gossip_queries
179 msgdata,reply_short_channel_ids_end,chain_hash,chain_hash,
180 msgdata,reply_short_channel_ids_end,complete,byte,
181 msgtype,query_channel_range,263,gossip_queries
182 msgdata,query_channel_range,chain_hash,chain_hash,
183 msgdata,query_channel_range,first_blocknum,u32,
184 msgdata,query_channel_range,number_of_blocks,u32,
185 msgdata,query_channel_range,tlvs,query_channel_range_tlvs,
186 tlvtype,query_channel_range_tlvs,query_option,1
187 tlvdata,query_channel_range_tlvs,query_option,query_option_flags,varint,
188 msgtype,reply_channel_range,264,gossip_queries
189 msgdata,reply_channel_range,chain_hash,chain_hash,
190 msgdata,reply_channel_range,first_blocknum,u32,
191 msgdata,reply_channel_range,number_of_blocks,u32,
192 msgdata,reply_channel_range,complete,byte,
193 msgdata,reply_channel_range,len,u16,
194 msgdata,reply_channel_range,encoded_short_ids,byte,len
195 msgdata,reply_channel_range,tlvs,reply_channel_range_tlvs,
196 tlvtype,reply_channel_range_tlvs,timestamps_tlv,1
197 tlvdata,reply_channel_range_tlvs,timestamps_tlv,encoding_type,u8,
198 tlvdata,reply_channel_range_tlvs,timestamps_tlv,encoded_timestamps,byte,...
199 tlvtype,reply_channel_range_tlvs,checksums_tlv,3
200 tlvdata,reply_channel_range_tlvs,checksums_tlv,checksums,channel_update_checksums,...
201 subtype,channel_update_timestamps
202 subtypedata,channel_update_timestamps,timestamp_node_id_1,u32,
203 subtypedata,channel_update_timestamps,timestamp_node_id_2,u32,
204 subtype,channel_update_checksums
205 subtypedata,channel_update_checksums,checksum_node_id_1,u32,
206 subtypedata,channel_update_checksums,checksum_node_id_2,u32,
207 msgtype,gossip_timestamp_filter,265,gossip_queries
208 msgdata,gossip_timestamp_filter,chain_hash,chain_hash,
209 msgdata,gossip_timestamp_filter,first_timestamp,u32,
210 msgdata,gossip_timestamp_filter,timestamp_range,u32,