MCPcopy Create free account
hub / github.com/ElementsProject/lightning / towire_node_id

Function towire_node_id

common/node_id.c:61–70  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

59bool dev_towire_allow_invalid_node_id = false;
60
61void towire_node_id(u8 **pptr, const struct node_id *id)
62{
63 /* Cheap sanity check. For wire fuzzing, we only care about correct
64 * encoding of node IDs and not whether the IDs are valid, so we disable
65 * this check while fuzzing. */
66 if (!dev_towire_allow_invalid_node_id)
67 assert(id->k[0] == 0x2 || id->k[0] == 0x3);
68
69 towire(pptr, id->k, sizeof(id->k));
70}
71
72bool check_signed_hash_nodeid(const struct sha256_double *hash,
73 const secp256k1_ecdsa_signature *signature,

Callers 7

towire_route_infoFunction · 0.70
towire_chain_coin_mvtFunction · 0.70
towire_hsm_utxoFunction · 0.50
towire_accountFunction · 0.50
towire_dstore_channelFunction · 0.50
towire_dstore_node_biasFunction · 0.50

Calls 1

towireFunction · 0.50

Tested by

no test coverage detected