Email me

Rust advisories / ckb

Vulnerability HighRUSTSEC-2021-0108 · ckb

RUSTSEC-2021-0108: Remote memory exhaustion in ckb

Short answerA security vulnerability in the ckb crate: Remote memory exhaustion in ckb. GitHub rates it High. Fixed in 0.40.0: update to a fixed version.

Crateckb
TypeVulnerability
Affected versionsBefore 0.40.0.
Fixed in0.40.0
SeverityHigh (GitHub rating)
Published2021-07-25
Last changed2026-10-12
Also known asCVE-2021-45699, GHSA-2969-8hh9-57jc, GHSA-48vq-8jqv-gm6f

What to do

  1. See which version you have: cargo tree -i ckb (it also shows which of your dependencies pulls it in).
  2. Update within your version requirement: cargo update -p ckb. If the fix is a newer major or minor than your requirement allows, raise it in Cargo.toml (for example ckb = "0.40.0") or update the dependency that pulls it in.
  3. Check again with cargo audit, or paste your Cargo.lock into our Cargo.toml checker.

Details from the advisory

In the ckb sync protocol, SyncState maintains a HashMap called 'misbehavior' that keeps a score of a peer's violations of the protocol. This HashMap is keyed to PeerIndex (an alias for SessionId), and entries are never removed from it. SessionId is an integer that increases monotonically with every new connection.

A remote attacker can manipulate this HashMap to grow forever, resulting in degraded performance and ultimately a panic on allocation failure or being killed by the OS, depending on the platform.

This is a critical severity security bug. It could be exploited to create a targeted or network-wide denial of service, to reduce the hash power of the network as part of a 51% attack, and perhaps in other creative ways.

References

From the RustSec Advisory Database (CC0-1.0) via the OSV export, downloaded Oct 24, 2026. Severity score computed from the published CVSS vector.

Other advisories for ckb

Full security history of ckb

Up next

Same crateckb: security historyEvery advisory for this crate, and whether it is safe to use today.Read it next →

Did this answer your question?

Get the receipts by email.

What my AI agents tried this week, with the real numbers: what worked, what flopped, what made money. One email when there is something worth reading.

No spam, never sold. Every email has a one-click unsubscribe.

Popular in the shop

All 124 tools →

Browse: Bundles and kitsHome, family and schoolMoney and businessAI toolsSports and fitnessMaking and hobbiesFood and drinkIndie dev and launchTrading and quant

Free: Landing page teardown iPhone app cost calculator LLM API cost calculator Paid online: $49 Launch Check App builds Articles FAQ