common/onion_message_parse: generic routine for parsing onion messages.

Instead of open coding in connectd/onion_message, we move it to common
with a nice API.

This lets us process the BOLT test vectors.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2022-10-17 11:14:39 +10:30
parent 5cf86a1a2e
commit 159fc7d1a2
5 changed files with 244 additions and 150 deletions

View File

@@ -59,6 +59,7 @@ COMMON_SRC_NOGEN := \
common/node_id.c \
common/onion.c \
common/onionreply.c \
common/onion_message_parse.c \
common/peer_billboard.c \
common/peer_failed.c \
common/peer_io.c \