What changed, and why it matters
This commit only changes the API definition file (a .proto file) for LND's wallet RPC. It adds new boolean flags and documentation describing how long-term output leases work. There is no actual code logic change here—just the interface and comments—so it does not by itself fix or introduce a security vulnerability. It is a design/documentation/API surface change that may be related to a larger feature around lease lifetimes.
Treat this as an API/documentation change, not a standalone security patch. Review the corresponding implementation commits (wallet lease handling, custom_lock_id enforcement, no_expiry validation) to assess whether the feature is securely implemented. If this commit is part of a security-relevant change, evaluate the full patch series for proper validation of mutually exclusive flags and safe cleanup of abandoned no-expiry leases.
Security signals we found
Adds explicit no-timeout lease semantics to API documentation
Adds client acknowledgement fields (no_expiry booleans) for lease policy
Requires persisted custom_lock_id for no-expiry input leases
No implementation or validation logic present in this commit
Evidence from the diff
The diff modifies lnrpc/walletrpc/walletkit.proto. It replaces documentation describing release_after_spend_confs with documentation for a new no_expiry boolean flag on LeaseOutput and FundPsbt, and adds corresponding response/struct fields. The proto fields are added (no_expiry, input_lease_no_expiry) and documented. No implementation code is changed, no validation logic is added, and no runtime behavior is altered by this commit alone. The change appears to be API preparation for an existing or upcoming wallet lease lifetime feature.
Changed components
lnrpc/walletrpc/walletkit.protoWalletKit RPC API surfaceLeaseOutput and FundPsbt request/response messagesInspect captured patch +37 / −15
### lnrpc/walletrpc/walletkit.proto
@@ -43,11 +43,12 @@ service WalletKit {
successive invocations of this RPC. Outputs can be unlocked before their
expiration through `ReleaseOutput`.
- A non-zero release_after_spend_confs selects a confirmation-controlled
- lifetime. Such a lease ignores its wall-clock expiration and releases at
- the requested spend depth or through ReleaseOutput. The RPC fails if the
- wallet cannot apply this option. Renewing the same lease with the same ID
- and a zero depth preserves an existing non-zero depth.
+ Set no_expiry to reserve an unused output without a timeout. The owner
+ must release an abandoned reservation; the first confirmed spend removes
+ it automatically. This requires wallet support for the requested lifetime.
+
+ Renewing the same lease with the same ID and no_expiry unset preserves
+ its existing lifetime.
*/
rpc LeaseOutput (LeaseOutputRequest) returns (LeaseOutputResponse);
@@ -399,13 +400,13 @@ service WalletKit {
After either selecting or verifying the inputs, all input UTXOs are locked
with an internal app ID.
- A non-zero input_release_after_spend_confs applies a
- confirmation-controlled lifetime to every input lease this RPC acquires.
- Those leases ignore wall-clock expiration and release at the requested
- spend depth or through ReleaseOutput. The RPC fails if the wallet cannot
- apply this option. Wallet capability is checked even when coin selection
- does not need to acquire an input lease. A custom_lock_id is required for a
- confirmation-controlled lease.
+ Set input_lease_no_expiry to reserve acquired inputs without a timeout
+ until owner release or their first confirmed spend. A custom_lock_id is
+ required and must be persisted before funding so abandoned inputs can be
+ released. This requires wallet support for the requested lifetime.
+
+ Wallet capability is checked even when coin selection does not need to
+ acquire an input lease.
NOTE: If this method returns without an error, it is the caller's
responsibility to either spend the locked UTXOs (by finalizing and then
@@ -490,6 +491,12 @@ message LeaseOutputRequest {
// value ignores expiration_seconds; zero preserves the time-controlled
// lease behavior.
uint32 release_after_spend_confs = 4;
+
+ // Reserve the unused output without a timeout until owner release or its
+ // first confirmed spend. Cannot be combined with non-zero
+ // expiration_seconds. Omission preserves
+ // the existing lifetime; it does not convert the lease to a timed lease.
+ bool no_expiry = 5;
}
message LeaseOutputResponse {
@@ -505,6 +512,11 @@ message LeaseOutputResponse {
// confirmation-controlled lease. If that informational lookup fails after
// the lease succeeds, this field is zero and ListLeases can refresh it.
uint32 release_after_spend_confs = 2;
+
+ // The effective no-timeout policy with cleanup at the first confirmed
+ // spend. If renewal readback fails, ListLeases can refresh this
+ // informational value.
+ bool no_expiry = 3;
}
message ReleaseOutputRequest {
@@ -1673,9 +1685,10 @@ message FundPsbtRequest {
// The custom lock ID to use for the inputs in the funded PSBT. The value
// if set must be exactly 32 bytes long. If empty, the default lock ID will
- // be used. This field is required when input_release_after_spend_confs is
- // non-zero. In that mode it must not be all zero or LND's reserved
- // internal lock ID. The caller must persist this ID before funding and use
+ // be used. This field is required when input_lease_no_expiry is true or
+ // input_release_after_spend_confs is non-zero. In those modes it must not
+ // be all zero or LND's reserved internal lock ID. Persist it before funding
+ // and use
// ReleaseOutput to unlock an abandoned PSBT whose spend never confirms.
bytes custom_lock_id = 13;
@@ -1690,6 +1703,12 @@ message FundPsbtRequest {
// reorganization resets maturity progress. A non-zero value ignores
// lock_expiration_seconds; zero preserves time-controlled lease behavior.
uint32 input_release_after_spend_confs = 15;
+
+ // Reserve each newly acquired input without a timeout until owner release
+ // or its first confirmed spend. Requires a persisted custom_lock_id and
+ // cannot be combined with lock_expiration_seconds. Pre-existing input
+ // leases are unchanged.
+ bool input_lease_no_expiry = 16;
}
message FundPsbtResponse {
/*
@@ -1796,6 +1815,9 @@ message UtxoLease {
// reconfirmation. The only negative value emitted is -1; its magnitude
// carries no additional information.
int32 confirmed_spend_height = 7;
+
+ // True for no-timeout leases removed at the first confirmed spend.
+ bool no_expiry = 8;
}
message SignPsbtRequest {Why this scored 19/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.