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
@@ -844,6 +844,21 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"routerrpcCircuitKey": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"chan_id": {
|
||||
"type": "string",
|
||||
"format": "uint64",
|
||||
"description": "/ The id of the channel that the is part of this circuit."
|
||||
},
|
||||
"htlc_id": {
|
||||
"type": "string",
|
||||
"format": "uint64",
|
||||
"description": "/ The index of the incoming htlc in the incoming channel."
|
||||
}
|
||||
}
|
||||
},
|
||||
"routerrpcFailureDetail": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
@@ -885,6 +900,30 @@
|
||||
"routerrpcForwardFailEvent": {
|
||||
"type": "object"
|
||||
},
|
||||
"routerrpcForwardHtlcInterceptRequest": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"incoming_circuit_key": {
|
||||
"$ref": "#/definitions/routerrpcCircuitKey",
|
||||
"description": "The key of this forwarded htlc. It defines the incoming channel id and\nthe index in this channel."
|
||||
},
|
||||
"htlc_payment_hash": {
|
||||
"type": "string",
|
||||
"format": "byte",
|
||||
"description": "The htlc payment hash. This value is not guaranteed to be unique per\nrequest."
|
||||
},
|
||||
"amount_msat": {
|
||||
"type": "string",
|
||||
"format": "uint64",
|
||||
"description": "/ The htlc amount."
|
||||
},
|
||||
"expiry": {
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "/ The htlc expiry."
|
||||
}
|
||||
}
|
||||
},
|
||||
"routerrpcHtlcEvent": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -1110,6 +1149,15 @@
|
||||
"routerrpcResetMissionControlResponse": {
|
||||
"type": "object"
|
||||
},
|
||||
"routerrpcResolveHoldForwardAction": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"SETTLE",
|
||||
"FAIL",
|
||||
"RESUME"
|
||||
],
|
||||
"default": "SETTLE"
|
||||
},
|
||||
"routerrpcRouteFeeRequest": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
Reference in new issue
Block a user