Open lnbc1QWFyb24 opened 2 years ago
yes this will be easy to add and why there is a generate_key step. I planned on having a set_key function as well. I haven't had the need for it yet though which is why it doesn't exist.
Yeah the use case I am thinking is for a server to communicate to a core ln node. The idea I am playing with would be a simple API that can be deployed to run in front of your node at home. So it would be great to have a rune with full permissions, but limit it to the public key of the lnsocket.
On Mon, Jul 11, 2022 at 03:52:09PM -0700, Aaron Barnard wrote:
Yeah the use case I am thinking is for a server to communicate to a core ln node. The idea I am playing with would be a simple API that can be deployed to run in front of your node at home. So it would be great to have a rune with full permissions, but limit it to the public key of the lnsocket.
kk I'll add this soon
Legend thank you!
there is now an lnsocket_setkey
in v0.3.2 for setting static keys. Let me know if you run into any issues!
hmm it might be good to have a method that gets the pubkey...
Awesome will give this a go.
Yeah a method that gets the pubkey would be super handy. Saves having to load tiny-secp256k1
in the browser to derive the pub key.
Or even a method to get the keypair after generating the key. That way you can use set key in a later session with the private key
yup it's definitely needed... will add in a bit
Is it possible to have a static public key so that the remote node can limit the rune to that key? Or does a new key need to be created every time it is initialised with the
gen_key
method?