What changed, and why it matters
This change relaxes how a special 'quiet mode' request (called STFU, used during channel splicing in the Lightning protocol) is handled. Previously, if the node couldn't enter quiet mode immediately due to pending updates, it would return an error to the caller. Now it remembers the request and enters quiet mode later once those pending updates finish. This is a behavior/policy change, not a clear security fix, but it removes an error path that could potentially be abused to disrupt or probe splicing operations.
Review the full STFU state machine to ensure deferred STFU requests cannot be left pending indefinitely, cannot be double-triggered, and do not interact dangerously with channel state updates or peer-initiated STFU. Consider adding a timeout or explicit cancellation path for queued STFU requests. No immediate patch urgency is indicated by this diff alone.
Security signals we found
Change removes explicit error response for STFU request under pending-update conditions
STFU request is now queued/deferred rather than rejected, altering RPC behavior
Potential for state machine manipulation if pending actions never complete or are delayed
No explicit bounds or timeout added for deferred STFU in this diff
Evidence from the diff
In channeld/channeld.c, handle_stfu_req() no longer fails with a splice_state_error when maybe_send_stfu() cannot immediately send the STFU message. Instead, it sets peer->want_stfu = true and lets the pending-action completion logic send STFU later. This changes the RPC stfu semantics from ‘fail if not immediately possible’ to ‘queue for eventual execution’. The change reduces immediate error feedback to RPC callers and relies on internal state transitions to eventually honor the request.
Changed components
channeld/channeld.cLightning channel splicing STFU handlingRPC stfu request processingInspect captured patch +3 / −9
diff --git a/channeld/channeld.c b/channeld/channeld.c
index c89ea49e..b84fd0f9 100644
--- a/channeld/channeld.c
+++ b/channeld/channeld.c
@@ -5061,15 +5061,9 @@ static void handle_stfu_req(struct peer *peer, const u8 *inmsg)
peer->stfu_initiator = LOCAL;
peer->want_stfu = true;
- if (!maybe_send_stfu(peer)) {
- msg = towire_channeld_splice_state_error(NULL, tal_fmt(tmpctx,
- "Pending updates"
- " prevent us from STFU"
- " mode at this"
- " time."));
- wire_sync_write(MASTER_FD, take(msg));
- return;
- }
+ /* If the `stfu` cant be sent now it will be sent when the current
+ * pending actions are completed. */
+ maybe_send_stfu(peer);
}
static void handle_abort_req(struct peer *peer, const u8 *inmsg)
Why this scored 27/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.