vls-proxy 0.14.0

A library for implementing a Lightning signer, which externalizes and secures cryptographic operations.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use std::env::args;
use vls_protocol::msgs::SignMutualCloseTx;
use vls_protocol::msgs::{self, Message};

pub fn main() {
    let msg_hex = args().nth(1).expect("usage: decode-vls <message-hex>");
    let msg = msgs::from_vec(hex::decode(msg_hex).unwrap()).unwrap();
    match msg {
        Message::SignMutualCloseTx(SignMutualCloseTx { tx, psbt, .. }) => {
            println!("SignMutualCloseTxRequest {:?} {:?}", tx, psbt.0);
        }
        msg => {
            println!("{:?}", msg);
        }
    }
}