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

gossipd: lightningd/lightning_gossip_compactd

Public commit record

What the developer wrote

Authored by Rusty Russell

58/100 · Thin
gossipd: lightningd/lightning_gossip_compactd

A new subprocess run by gossipd to create a compacted gossip store.

It's pretty simple: a linear compaction of the file. Once it's done the amount it
was told to, then gossipd waits until it completes the last bit.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
✓ Descriptive subject✓ Provides detailed explanatory context
The short version

What changed, and why it matters

This commit adds a new helper program that compacts the Lightning node's gossip store file by copying it without deleted records. It is a normal maintenance/performance feature. There is no clear security bug in the code shown, but the program reads and writes binary gossip files and trusts command-line arguments, so it follows a path that could be sensitive to malformed input.

Recommended action

Treat as a normal feature commit. If auditing, focus on how gossipd invokes the compactd, how the old/new file paths and limit are derived, and whether an attacker who can influence the gossip_store file or command-line arguments can cause out-of-bounds reads, writes, or data corruption. No immediate patch action is indicated by this diff alone.

Security signals we found

01

New privileged file-handling daemon that opens store files and rewrites them

02

Parses binary record lengths and flags from an external store file

03

Uses command-line supplied length limit without additional validation

04

No explicit input sanitization beyond hex_decode for uuid

05

No security relevance disclosed by commit message

Risk score

Why this scored 19/100

Our methodology →
Potential impact 2/30
Exploitability 3/25
Stealth signal 2/15
Affected reach 2/15
Confidence 7/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.