@@ -13,6 +13,7 @@ import (
13
13
"time"
14
14
15
15
"github.com/improbable-eng/grpc-web/go/grpcweb"
16
+ "github.com/lightninglabs/lightning-terminal/session"
16
17
"github.com/lightningnetwork/lnd/lncfg"
17
18
"github.com/lightningnetwork/lnd/macaroons"
18
19
grpcProxy "github.com/mwitkow/grpc-proxy/proxy"
@@ -64,6 +65,7 @@ func (e *proxyErr) Unwrap() error {
64
65
// or REST request and delegate (and convert if necessary) it to the correct
65
66
// component.
66
67
func newRpcProxy (cfg * Config , validator macaroons.MacaroonValidator ,
68
+ superMacValidator session.SuperMacaroonValidator ,
67
69
permissionMap map [string ][]bakery.Op ,
68
70
bufListener * bufconn.Listener ) * rpcProxy {
69
71
@@ -80,10 +82,11 @@ func newRpcProxy(cfg *Config, validator macaroons.MacaroonValidator,
80
82
// need to be addressed with a custom director that just takes care of a
81
83
// few HTTP header fields.
82
84
p := & rpcProxy {
83
- cfg : cfg ,
84
- basicAuth : basicAuth ,
85
- macValidator : validator ,
86
- bufListener : bufListener ,
85
+ cfg : cfg ,
86
+ basicAuth : basicAuth ,
87
+ macValidator : validator ,
88
+ superMacValidator : superMacValidator ,
89
+ bufListener : bufListener ,
87
90
}
88
91
p .grpcServer = grpc .NewServer (
89
92
// From the grpxProxy doc: This codec is *crucial* to the
@@ -156,8 +159,9 @@ type rpcProxy struct {
156
159
cfg * Config
157
160
basicAuth string
158
161
159
- macValidator macaroons.MacaroonValidator
160
- bufListener * bufconn.Listener
162
+ macValidator macaroons.MacaroonValidator
163
+ superMacValidator session.SuperMacaroonValidator
164
+ bufListener * bufconn.Listener
161
165
162
166
superMacaroon string
163
167
0 commit comments