lnrpc+rpcserver: support list/delete on marcaroon IDs

This commit is contained in:
yyforyongyu committed 2020-08-14 12:33:13 +08:00
1 parent f362f7670b
commit c0e2513350
13 files changed
+1383 -756

No files matched your search

+3 -3
View File
@@ -15,6 +15,7 @@ import (
"github.com/lightningnetwork/lnd/lnrpc"
"github.com/lightningnetwork/lnd/lntypes"
"github.com/lightningnetwork/lnd/lnwire"
"github.com/lightningnetwork/lnd/macaroons"
"github.com/lightningnetwork/lnd/routing"
"github.com/lightningnetwork/lnd/routing/route"
@@ -164,9 +165,8 @@ func New(cfg *Config) (*Server, lnrpc.MacaroonPerms, error) {
// At this point, we know that the router macaroon doesn't yet,
// exist, so we need to create it with the help of the main
// macaroon service.
routerMac, err := cfg.MacService.Oven.NewMacaroon(
context.Background(), bakery.LatestVersion, nil,
macaroonOps...,
routerMac, err := cfg.MacService.NewMacaroon(
context.Background(), macaroons.DefaultRootKeyID, macaroonOps...,
)
if err != nil {
return nil, nil, err