-
Notifications
You must be signed in to change notification settings - Fork 200
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Request: Method to give existing channel funds to arbitrary account. #192
Comments
i talked to umbrel guys, and the simplest solution might be: the balance would not be awarded to it, instead, balance for this account would be simply current channelBalance, so admin user could spend all his channel coins anytime he wants. what do you think? |
As long as the admin credentials are randomly generated on install that sounds fine. |
Joining this issue, I also am interested in this feature. I may just modify lndhub /getbalance to return lnd channelbalance since I am the only user of this hub (created my wallet then disabled /create) |
I am contemplating creating a GRANT component using the LndHub-Admin toolbox. A component screen-card where accounts in system is showing in a table and where one can specify amount units and send. The send is from LndHub operator = admins LND wallet funds. When chosen a account(user) and specify amount click send after filling in the adminPin, the component will create a invoice from account(user) credentials and then that amount gets Granted to account(user) in the LndHub Ledger. Would the above suffice as functionality for case mentioned in this Request issue ? |
aha ... this triggered a associating problem of accounts being unnamed on the LndHub side |
Any progress on this? |
i started some work on it but left it for more prioritized projects :
this way DB would be correctly intact and new balance would show up in account invoice was created for. or meanwhile unless somebody wants a UI for the functionality use a payment over network as hinted here : |
if interested in hints coding it, further discussions can be had here : |
Very much interested in this. Use case / user story: I have an LND node with, say, 1M sats. My child wants to be paid an allowance in sats, so I agree to transfer 10,000 sats monthly. Because we want to remain non-custodial, Bluewallet thru LNDHub makes sense. (Wallet of Satoshi, custodial; Phoenix and Muun non-custodial, but require new channels that will eat up huge fees). LNDHub itself handles accounting just fine when the to/from are on the same node. However, I have no way -- other than using on-chain activity or transfer out to a different Lightning Wallet then back in -- to fund an initial BlueWallet balance for myself. What would be ideal is a command line admin tool to "instantiate" a balance, not greater than the sum of all un-allocated (in LNDHub's view) local channel funds, in an arbitrary LNDHub account. I looked directly at the Redis keyspace to see if this were possible, but it appears not: Balance is computed directly from past lightning transactions. Question 1: Is it possible to "synthesize" transactions to make this happen?
Lines 134 to 136 in 7f9463b
[1] https://github.com/BlueWallet/LndHub/blob/master/doc/schema.md |
one can imagine a script that help in paying a invoice generated on account holders behalf or for edutainment let account holder create invoice in wallet, script would payout to invoice ... same would go for case where one make invoice in wallet and pay oneself from LND and then pay invoice to other account what script would do is either just pay a invoice from LND or generate invoice and pay in one swoop ... easiest for Your case is create a account in BlueWallet and then a invoice in terminal at node lncli sendpayment --pay_req "invoice" --allow_self_payment from this account distribute further ... |
Explanation:
A + B + C
total LN balance available to me.Request:
Some issues that might pop up:
How to keep the backup of that user secure? I would guess showing it only once is fine but tbh if you have access to the box with lndhub you can mess with redis and also probably swipe the admin macaroon anyways... but for umbrel if you just put it on the landing page anyone with port access to the umbrel (anyone on my local network) can see the backup if you put it on the landing page... so it'll be difficult...
Maybe the first time the default user actually loads the backup, it changes things up so that the second person who tried to load that default user backup will always fail, and the first person is given a new backup for the default user. (rotate creds on first load?)
The text was updated successfully, but these errors were encountered: