AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Low 27 Bitcoin

peer: register the rbfCloseActor, have RPC route fee bumps to it

Public commit record

What the developer wrote

Authored by Olaoluwa Osuntokun

73/100 · Adequate
peer: register the rbfCloseActor, have RPC route fee bumps to it

In this commit, we now register the rbfCloseActor when we create the rbf
chan closer state machine. Now the RPC server no longer neesd to
traverse a series of maps and pointers (rpcServer -> server -> peer ->
activeCloseMap -> rbf chan closer) to trigger a new fee bump.

Instead, it just creates the service key that it knows that the closer
can be reached at, and sends a message to it using the returned
actorRef/router. We also hide additional details re the various methods
in play, as we only care about the type of message we expect to send and
receive.
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
The short version

What changed, and why it matters

This commit refactors how Lightning Network fee-bump requests reach the channel-closing state machine. Previously, the RPC server had to dig through several internal maps and pointers to find the right closer. Now it sends a message through a dedicated actor/router system. The change also adds cleanup logic so these actor registrations are removed when a peer disconnects or a channel closes, preventing stale entries. The commit itself is a code-quality and reliability improvement, not a fix for an active exploit, but it touches a security-sensitive path (cooperative channel close fee bumping).

Recommended action

Treat as a hardening/refactoring change; include in normal review and regression testing. Verify that actor registration/unregistration is race-free, especially around finalizeChanClosure where a TODO already flags an existing race. Confirm that server.Stop() ordering prevents deadlocks during shutdown. No emergency action indicated.

Security signals we found

01

Refactors privileged RPC path that triggers RBF fee bumps for channel closes

02

Adds actor lifecycle cleanup to prevent stale registered actors after disconnect/close

03

Removes direct map-pointer traversal from RPC server to internal peer state

04

Adds ordering guarantee: actor system shut down after subsystems in server.Stop()

05

Includes TODO noting an existing race in finalizeChanClosure

Risk score

Why this scored 27/100

Our methodology →
Potential impact 5/30
Exploitability 3/25
Stealth signal 4/15
Affected reach 6/15
Confidence 6/10
Evidence quality 3/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.