mirror of
https://github.com/aljazceru/lightning.git
synced 2026-01-04 14:54:26 +01:00
sphinx: Add functions to decompress
Also implements a way to decompress an onion using the devtools/onion tool Changelog-Added: devtools: The `onion` tool can now generate, compress and decompress onions for rendez-vous routing
This commit is contained in:
committed by
Rusty Russell
parent
4724d55e80
commit
49a3321d7e
@@ -246,6 +246,13 @@ u8 *serialize_compressed_onion(const tal_t *ctx,
|
||||
bool sphinx_path_set_rendezvous(struct sphinx_path *sp,
|
||||
const struct node_id *rendezvous_id);
|
||||
|
||||
/**
|
||||
* Given a compressed onion expand it by re-generating the prefiller and
|
||||
* inserting it in the appropriate place.
|
||||
*/
|
||||
u8 *sphinx_decompress(const tal_t *ctx, const u8 *compressed,
|
||||
struct secret *shared_secret);
|
||||
|
||||
#if DEVELOPER
|
||||
/* Override to force us to reject valid onion packets */
|
||||
extern bool dev_fail_process_onionpacket;
|
||||
|
||||
Reference in New Issue
Block a user