lnd icon indicating copy to clipboard operation
lnd copied to clipboard

rpc+invoices: create a new set of RPC calls that allow specify custom scid alias mappings

Open Roasbeef opened this issue 1 year ago • 3 comments

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 level lnd configuration.

  • [ ] Add unit and itests above (if the RPC route is taken).

Roasbeef avatar Nov 17 '23 02:11 Roasbeef

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

Crypt-iQ avatar Dec 08 '23 20:12 Crypt-iQ

I think @GeorgeTsagk is on this now.

ffranr avatar Feb 20 '24 20:02 ffranr

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?

GeorgeTsagk avatar Feb 28 '24 09:02 GeorgeTsagk