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

bkpr: remove currency support from balances.

Public commit record

What the developer wrote

Authored by Rusty Russell

78/100 · Adequate
bkpr: remove currency support from balances.

We're going to get rid of this concept, but the main change is that the
account_get_balance API can be drastically simplified:

account_get_credit_debit() accesses the raw fields, never fails, but
returns the a flag which tells us if the account doesn't actually have
any events.

The one place we care about the balance, calculate by hand. Then
account_get_balance() (and struct account_balance) can simply be
moved to th test.

Subtly, without the "GROUP BY" clause, you always get one row, even if
there are no rows (but the SUM are null).

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
The short version

What changed, and why it matters

This commit is a code cleanup in Core Lightning's bookkeeper plugin. It removes support for tracking multiple currencies per account and simplifies how account balances are calculated. The change is described by the developer as removing a concept they no longer want. There is no indication in the commit message or diff that this fixes a security vulnerability.

Recommended action

No security action required. Treat as a normal refactoring/cleanup commit. Reviewers may want to verify that the new single-currency assumption holds for all supported deployments and that the `plugin_err()` calls on overflow are acceptable fatal behavior.

Security signals we found

01

Removal of multi-currency balance aggregation

02

Change of error handling from returned error strings to fatal plugin errors on database overflow

03

SQL query simplification removing GROUP BY currency

04

No security-relevant keywords or fixes mentioned in commit message

Risk score

Why this scored 18/100

Our methodology →
Potential impact 2/30
Exploitability 1/25
Stealth signal 1/15
Affected reach 2/15
Confidence 8/10
Evidence quality 4/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.