core-lightning/wire/peer_wire.csv
Rusty Russell a7c5a1f1d2 lightningd: implement receiving warnings.
This takes from the draft spec at https://github.com/lightningnetwork/lightning-rfc/pull/834

Note that if this draft does not get included, the peer will simply
ignore the warning message (we always close the connection afterwards
anyway).

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Changelog-Added: Protocol: we now report the new (draft) warning message.
2021-02-04 12:02:52 +10:30

9.7 KiB

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