rpc: implement RPC htlc interceptor.
In this commit we add the ability to intercept forwarded htlc packets straight from the RPC layer. The RPC layer handles a bidrectional stream that comminucates to the client the intercepted packets and handles its response by coordinating with the interceptable switch.
This commit is contained in:
1 parent
0f50d8b2ed
commit
7b56268f70
11 files changed
+1224
-154
No files matched your search
+8
-7
@@ -549,13 +549,14 @@ func newRPCServer(cfg *Config, s *server, macService *macaroons.Service,
|
||||
|
||||
return info.NodeKey1Bytes, info.NodeKey2Bytes, nil
|
||||
},
|
||||
FindRoute: s.chanRouter.FindRoute,
|
||||
MissionControl: s.missionControl,
|
||||
ActiveNetParams: activeNetParams.Params,
|
||||
Tower: s.controlTower,
|
||||
MaxTotalTimelock: cfg.MaxOutgoingCltvExpiry,
|
||||
DefaultFinalCltvDelta: uint16(cfg.Bitcoin.TimeLockDelta),
|
||||
SubscribeHtlcEvents: s.htlcNotifier.SubscribeHtlcEvents,
|
||||
FindRoute: s.chanRouter.FindRoute,
|
||||
MissionControl: s.missionControl,
|
||||
ActiveNetParams: activeNetParams.Params,
|
||||
Tower: s.controlTower,
|
||||
MaxTotalTimelock: cfg.MaxOutgoingCltvExpiry,
|
||||
DefaultFinalCltvDelta: uint16(cfg.Bitcoin.TimeLockDelta),
|
||||
SubscribeHtlcEvents: s.htlcNotifier.SubscribeHtlcEvents,
|
||||
InterceptableForwarder: s.interceptableSwitch,
|
||||
}
|
||||
|
||||
genInvoiceFeatures := func() *lnwire.FeatureVector {
|
||||
|
||||
Reference in new issue
Block a user