lnd
lnd copied to clipboard
rpc+invoices: create a new set of RPC calls that allow specify custom scid alias mappings
Overview
Today we support the scid-alias
feature. This feature allows us to create an invoice with an scid
that doesn't match the one that actually exists on chain. This allows a receiver to hide the location of their channel on chain from the sender, or anyone else that is able to view the invoice. This logic currently ives in the aliasmgr
package. Today we generate the aliases automatically as needed for channels that want to enable this feature. To give wallets more control over how these aliases are generated we should add a new RPC that lets them hook directly into the aliasmgr
.
Steps To Completion
-
[ ] Add a series of new RPCs to the
invoicesrpc
sub-server that enables callers to: list the set of active aliases, remove an active alias, and also add a new alias. Alternatively, this doesn't need to be an actual RPC, and instead can be exposed via the top levellnd
configuration. -
[ ] Add unit and itests above (if the RPC route is taken).
list the set of active aliases, remove an active alias, and also add a new alias.
The spec says that if we have ever sent over an alias in channel_ready
that we must always remember it for forwarding. So I don't think we can remove an active alias
I think @GeorgeTsagk is on this now.
list the set of active aliases, remove an active alias, and also add a new alias
This isn't mentioned, but I assume we want this for already existing base-scids?