From 0616c29bed8d563710af8aad2df205de65afb258 Mon Sep 17 00:00:00 2001 From: Christian Decker Date: Mon, 24 Jun 2019 23:13:16 +0200 Subject: [PATCH] bolt04: Introduce the destination_signal to the tlv_payload As discussed during the spec meeting this allows us not to use the 32 byte HMAC to identify the last hop, and use a 2-byte signal instead. Signed-off-by: Christian Decker --- 04-onion-routing.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/04-onion-routing.md b/04-onion-routing.md index 838a116..295ecd3 100644 --- a/04-onion-routing.md +++ b/04-onion-routing.md @@ -245,6 +245,7 @@ This is a more flexible format, which avoids the redundant `short_channel_id` fi 1. tlvs: `tlv_payload` 2. types: + 1. type: 0 (`destination_signal`) 1. type: 2 (`amt_to_forward`) 2. data: * [`tu64`:`amt_to_forward`] @@ -261,10 +262,10 @@ The writer: - MUST include `amt_to_forward` and `outgoing_cltv_value` for every node. - MUST include `short_channel_id` for every non-final node. - MUST NOT include `short_channel_id` for the final node. + - MUST include the `destination_signal` for the final node. The reader: - MUST return an error if `amt_to_forward` or `outgoing_cltv_value` are not present. - - MUST return an error if it is not the final node and `short_channel_id` is not present. The requirements for the contents of these fields are specified [above](#legacy-hop_data-payload-format).