From ea2d9577ae44f0dd7b9b1413d95c12ef8225b983 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lukas=20F=C3=BCrderer?= Date: Sun, 25 Feb 2024 15:12:46 +0100 Subject: [PATCH] Add messages to transfer open transactions --- docs/protocol-v0.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/docs/protocol-v0.md b/docs/protocol-v0.md index 19c259b..1f0cef5 100644 --- a/docs/protocol-v0.md +++ b/docs/protocol-v0.md @@ -98,6 +98,8 @@ partner IPv6 and partner port may be nullbytes (no partner included). A block request is sent from node A to node B in order to transfer a block from node B to node A. Node B should answer with a "block transfer" message that includes the requested block (as given by "block hash") +If "block hash" consists of 32 nullbytes, node A wants node B to send the newest block of B's blockchain. + ### block transfer | content | size (bytes) | @@ -127,3 +129,22 @@ A "block transfer" message is sent back in response to a "block request" message | type = 4 (BE) | 1 | | list position (0 <= x < 1024) (BE) | 2 | | "open transaction" hash value | 32 | + +### open transaction request + +| content | size (bytes) | +|---|---| +| protocol version = 0 (BE) | 2 | +| capable version = 0 (BE) | 2 | +| type = 5 (BE) | 1 | +| list position (0 <= x < 1024) (BE) | 2 | + +### open transaction response + +| content | size (bytes) | +|---|---| +| protocol version = 0 (BE) | 2 | +| capable version = 0 (BE) | 2 | +| type = 4 (BE) | 1 | +| list position (0 <= x < 1024) (BE) | 2 | +| transaction | 148 |