Trait lightning::chain::keysinterface::KeysInterface
source · pub trait KeysInterface: Send + Sync {
fn get_node_secret(&self) -> SecretKey;
fn get_destination_script(&self) -> Script;
fn get_shutdown_pubkey(&self) -> PublicKey;
fn get_channel_keys(&self, inbound: bool) -> ChannelKeys;
}
Expand description
A trait to describe an object which can get user secrets and key material.
Required Methods
sourcefn get_node_secret(&self) -> SecretKey
fn get_node_secret(&self) -> SecretKey
Get node secret key (aka node_id or network_key)
sourcefn get_destination_script(&self) -> Script
fn get_destination_script(&self) -> Script
Get destination redeemScript to encumber static protocol exit points.
sourcefn get_shutdown_pubkey(&self) -> PublicKey
fn get_shutdown_pubkey(&self) -> PublicKey
Get shutdown_pubkey to use as PublicKey at channel closure
sourcefn get_channel_keys(&self, inbound: bool) -> ChannelKeys
fn get_channel_keys(&self, inbound: bool) -> ChannelKeys
Get a new set of ChannelKeys for per-channel secrets. These MUST be unique even if you restarted with some stale data!