multi: expose Proxy service over LNC

Previously, the `Proxy` service was not accessible over LNC, as we did
not want to expose the `stop` and `bakesupermacaroon` endpoints over
LNC. This also meant that the `getinfo` endpoint was not accessible over
LNC. As we now have demand to expose the `getinfo` endpoint over LNC, we
have decided to expose the `Proxy` service over LNC, and let the user
fine-tune the access to the `stop` and `bakesupermacaroon` endpoints
via the macaroon for the LNC session instead.
This commit is contained in:
Viktor Tigerström 2025-04-11 01:10:22 +02:00
parent 1e257d1f7b
commit 2d3efee7df
No known key found for this signature in database
GPG key ID: B984570980684DCC
3 changed files with 11 additions and 1 deletions

View file

@ -42,6 +42,15 @@
instead, to update an account's balance. The flag will no longer be
supported in Lightning Terminal `v0.16.0-alpha`.
* [The `litrpc.Proxy` endpoints are now exposed over
LNC](https://github.com/lightninglabs/lightning-terminal/pull/1033).
Note that this also exposes the `stop` and `bakesupermacaroon` endpoints over
LNC. If this is not desired, it is recommended to fine-tune the macaroon
created for the LNC session. Specifically, remove the `proxy:write`
permission to disable access to the `stop` endpoint, and the
`supermacaroon:write` permission to disable access to the
`bakesupermacaroon` endpoint.
## Integrated Binary Updates
### LND

View file

@ -358,7 +358,7 @@ var (
macaroonFn: litMacaroonFn,
requestFn: proxyRequestFn,
successPattern: "\"version\":",
allowedThroughLNC: false,
allowedThroughLNC: true,
grpcWebURI: "/litrpc.Proxy/GetInfo",
restWebURI: "/v1/proxy/info",
litOnly: true,

View file

@ -1176,6 +1176,7 @@ func (g *LightningTerminal) registerSubDaemonGrpcServers(server *grpc.Server,
if forLNCSession {
litrpc.RegisterStatusServer(server, g.statusMgr)
litrpc.RegisterProxyServer(server, g.rpcProxy)
} else {
litrpc.RegisterSessionsServer(server, g.sessionRpcServer)