-
Notifications
You must be signed in to change notification settings - Fork 491
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
Clarify final cltv expiry computation in route blinding #1069
Clarify final cltv expiry computation in route blinding #1069
Conversation
Good point, that's something I also brought up a while ago: Bolt 12 doesn't expose the It's a bit messy to have to go from blocks to timestamps, but timestamps are more user-friendly when displayed on a commercial website, so we'll probably have to live with that... @rustyrussell does that match what you had in mind? |
Right, thanks! I updated the PR description with your original offers comment thread on this topic. |
In the case where an invoice has an expiry < 5 minutes do we assume the current height is the |
Good point, we'll probably want to create invoices with a very short expiry when responding to an |
@valentinewallace can you rebase the last commit on top of |
BOLT 12 invoices do not include a max_cltv_expiry field, so it's good to clarify how senders can compute the final outgoing cltv expiry.
a48cfdc
to
f271735
Compare
Based on #1066, see its PR description.
Here we follow-on that change by clarifying the computation of the final
outgoing_cltv_value
when paying to a blinded route.I've been implementing route blinding for LDK, and these comments would have alleviated my confusion on how to get the final expiry, so hopefully it seems helpful to others too.
For context, I got the conversion from invoice expiry to CLTV expiry from this offers discussion: https://github.com/lightning/bolts/pull/798/files#r1053000804