-
Notifications
You must be signed in to change notification settings - Fork 339
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multi-hop BlindedPath
creation interface
#2781
Multi-hop BlindedPath
creation interface
#2781
Commits on Dec 15, 2023
-
Re-order AnchorsZeroFeeHtlcTx in module docs/tests
Move AnchorsZeroFeeHtlcTx after Wumbo to keep order by feature bit. Also, update setting order and comment in tests.
Configuration menu - View commit details
-
Copy full SHA for ee026d4 - Browse repository at this point
Copy the full SHA ee026d4View commit details -
Add RouteBlinding feature flag
The RouteBlinding feature flag is signals support for relaying payments over blinded paths. It is used for paying BOLT 12 invoices, which are required to included at least one blinded path.
Configuration menu - View commit details
-
Copy full SHA for ffb0d83 - Browse repository at this point
Copy the full SHA ffb0d83View commit details -
Add create_blinded_paths to MessageRouter
The MessageRouter trait is used to find an OnionMessagePath to a Destination (e.g., to a BlindedPath). Expand the interface with a create_blinded_paths method for creating such paths to a recipient. Provide a default implementation creating two-hop blinded paths where the recipient's peers serve as introduction nodes.
Configuration menu - View commit details
-
Copy full SHA for 97049da - Browse repository at this point
Copy the full SHA 97049daView commit details -
Require any Router also implements MessageRouter
ChannelManager is parameterized by a Router in order to find routes when sending and retrying payments. For the offers flow, it needs to be able to construct blinded paths (e.g., in the offer and in reply paths). Instead of adding yet another parameter to ChannelManager, require that any Router also implements MessageRouter. Implement this for DefaultRouter by delegating to a DefaultMessageRouter.
Configuration menu - View commit details
-
Copy full SHA for bedc2c6 - Browse repository at this point
Copy the full SHA bedc2c6View commit details -
Configuration menu - View commit details
-
Copy full SHA for c558ccd - Browse repository at this point
Copy the full SHA c558ccdView commit details -
Use CLTV_FAR_FAR_AWAY in PaymentConstraints
When finding a route through a blinded path, a random CLTV offset may be added to the path in order to preserve privacy. This needs to be accounted for in the blinded path's PaymentConstraints. Add CLTV_FAR_FAR_AWAY to the max_cltv_expiry constraint to allow for such offsets.
Configuration menu - View commit details
-
Copy full SHA for dcd8d58 - Browse repository at this point
Copy the full SHA dcd8d58View commit details -
Multi-hop blinded paths in ChannelManager
When constructing blinded paths for Offer and Refund, delegate to MessageRouter::create_blinded_paths which may produce multi-hop blinded paths. Fallback to one-hop blinded paths if the MessageRouter fails or returns no paths. Likewise, do the same for InvoiceRequest and Bolt12Invoice reply paths.
Configuration menu - View commit details
-
Copy full SHA for 606304a - Browse repository at this point
Copy the full SHA 606304aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 4da0862 - Browse repository at this point
Copy the full SHA 4da0862View commit details -
Configuration menu - View commit details
-
Copy full SHA for edb5892 - Browse repository at this point
Copy the full SHA edb5892View commit details -
Add create_blinded_payment_paths to Router
The Router trait is used to find a Route for paying a node. Expand the interface with a create_blinded_payment paths method for creating such paths to a recipient node. Provide an implementation for DefaultRouter that creates two-hop blinded paths where the recipient's peers serve as the introduction nodes.
Configuration menu - View commit details
-
Copy full SHA for 62f8669 - Browse repository at this point
Copy the full SHA 62f8669View commit details -
Multi-hop blinded payment paths in ChannelManager
When constructing blinded payment paths for Bolt12Invoice, delegate to Router::create_blinded_payment_paths which may produce multi-hop blinded paths. Fallback to one-hop blinded paths if the Router fails or returns no paths.
Configuration menu - View commit details
-
Copy full SHA for 827833c - Browse repository at this point
Copy the full SHA 827833cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 16ee240 - Browse repository at this point
Copy the full SHA 16ee240View commit details -
Use one-hop blinded paths only for announced nodes
To avoid exposing a node's identity in a blinded path, only create one-hop blinded paths if the node has been announced, and thus has public channels. Otherwise, there is no way to route a payment to the node, exposing its identity needlessly.
Configuration menu - View commit details
-
Copy full SHA for 164c855 - Browse repository at this point
Copy the full SHA 164c855View commit details -
Configuration menu - View commit details
-
Copy full SHA for 37319a6 - Browse repository at this point
Copy the full SHA 37319a6View commit details