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
We should be less strict with our backup storage peers, they only provide
this feature as a best effort. In particular, this lets peers safely store
backups for each other without risking channel closure.
Copy file name to clipboardExpand all lines: 02-peer-protocol.md
+4-12Lines changed: 4 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1428,32 +1428,24 @@ describes how this allows storing per-node data, and the following section
1428
1428
describes how this allows storing per-channel data.
1429
1429
1430
1430
A node with `want_peer_backup_storage` activated:
1431
-
- MUST NOT activate `provide_peer_backup_storage`
1432
1431
- if its peer doesn't support `provide_peer_backup_storage`:
1433
1432
- MUST NOT send their `channel_backup`
1434
1433
- otherwise:
1435
1434
- when it sends a message that completes an update of the channel state (`funding_signed`, `commitment_signed`, `revoke_and_ack`, `shutdown` or `closing_signed`):
1436
1435
- MAY include an optional `channel_backup` TLV field
1437
1436
- MUST limit its `channel_backup` to 32000 bytes
1438
1437
- when it receives `channel_reestablish` with an outdated or missing `channel_backup`:
1439
-
- SHOULD send a warning
1440
-
- MAY disconnect
1441
-
- MAY fail the channel
1438
+
- MAY send a warning
1442
1439
1443
1440
A node with `provide_peer_backup_storage` activated:
1444
-
- MUST NOT activate `want_peer_backup_storage`
1445
1441
- when it receives a `channel_backup`:
1446
-
- if its peer also has activated the `provide_peer_backup_storage` feature:
1442
+
- if the `channel_backup` exceeds 32000 bytes:
1447
1443
- SHOULD send a warning
1448
1444
- MUST NOT store this backup data
1449
1445
- otherwise:
1450
-
- if the `channel_backup` exceeds 32000 bytes:
1451
-
- SHOULD send a warning
1452
-
- MUST NOT store this backup data
1453
-
- otherwise:
1454
-
- MUST store this backup data
1446
+
- SHOULD store this backup data
1455
1447
- when it sends `channel_reestablish`:
1456
-
- MUST include the last `channel_backup` it received for that channel
1448
+
- MUST include the last `channel_backup` it stored for that channel
1457
1449
- when the channel is closed:
1458
1450
- SHOULD wait at least 2016 blocks before deleting the `channel_backup`
0 commit comments