core-lightning/connectd/peer_exchange_initmsg.h
Christian Decker 8d6c8c3cd1 connectd: Pass the init_featurebits down to connectd and use in init
The `init_featurebits` are computed at startup, and then cached
indefinitely. They are then used whenever a new `init` handshake is performed.

We could add a new message to push updates to `connectd` whenever a plugin is
added or removed, but that's up for discussion.
2020-02-11 13:53:31 +10:30

21 lines
618 B
C

#ifndef LIGHTNING_CONNECTD_PEER_EXCHANGE_INITMSG_H
#define LIGHTNING_CONNECTD_PEER_EXCHANGE_INITMSG_H
#include "config.h"
#include <ccan/short_types/short_types.h>
struct crypto_state;
struct daemon;
struct io_conn;
struct node_id;
struct wireaddr_internal;
/* If successful, calls peer_connected() */
struct io_plan *peer_exchange_initmsg(struct io_conn *conn,
struct daemon *daemon,
const struct crypto_state *cs,
const struct node_id *id,
const struct wireaddr_internal *addr,
const u8 *init_featurebits);
#endif /* LIGHTNING_CONNECTD_PEER_EXCHANGE_INITMSG_H */