core-lightning/daemon/wallet.h
Rusty Russell 51de503096 daemon: keep track of simple addresses for injecting funds.
We need to control the *inputs* to the anchor tx, to make sure they
pay to witness scripts (thus the anchor is immalleable).  The easiest
way to do this is to hand out P2SH addresses for the user, and have
them pay into those.  Then they hand us that tx and we use it to
create the anchor.

This is not a long-term solution!

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2016-04-12 13:07:03 +09:30

19 lines
484 B
C

#ifndef LIGHTNING_DAEMON_WALLET_H
#define LIGHTNING_DAEMON_WALLET_H
#include "config.h"
struct wallet;
struct lightningd_state;
struct bitcoin_tx;
struct bitcoin_tx_output;
void wallet_add_signed_input(struct lightningd_state *dstate,
const struct wallet *w,
struct bitcoin_tx *tx,
unsigned int input_num);
struct wallet *wallet_can_spend(struct lightningd_state *dstate,
const struct bitcoin_tx_output *output);
#endif /* LIGHTNING_DAEMON_WALLET_H */