diff --git a/lndclient/macaroon_pouch.go b/lndclient/macaroon_pouch.go index 2352de0..e0a2ae9 100644 --- a/lndclient/macaroon_pouch.go +++ b/lndclient/macaroon_pouch.go @@ -53,6 +53,9 @@ type macaroonPouch struct { // adminMac is the primary admin macaroon for lnd. adminMac serializedMacaroon + + // readonlyMac is the primary read-only macaroon for lnd. + readonlyMac serializedMacaroon } // newMacaroonPouch returns a new instance of a fully populated macaroonPouch @@ -104,5 +107,12 @@ func newMacaroonPouch(macaroonDir string) (*macaroonPouch, error) { return nil, err } + m.readonlyMac, err = newSerializedMacaroon( + filepath.Join(macaroonDir, defaultReadonlyFilename), + ) + if err != nil { + return nil, err + } + return m, nil }