CVE-2026-34219: libp2p-gossipsub Remote Crash Vulnerability
HIGHCVE-2026-34219 is a HIGH (CVSS 5.9) remote crash vulnerability (CWE-190: Integer Overflow or Wraparound) affecting libp2p-gossipsub libraries in the crates.io ecosystem. The issue involves remote crash via unchecked instant overflow in heartbeat backoff expiry handling. Remediation is available by upgrading affected packages to version 0.49.4.
CVE-2026-34219 at a Glance
Security Impact
CVSS: 5.9
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H).
How to Fix CVE-2026-34219
To remediate this vulnerability, upgrade all affected libp2p-gossipsub dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade libp2p-gossipsub to 0.49.4
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for libp2p-gossipsub
How to Check if You Are Affected
To determine whether your application is affected by CVE-2026-34219, inspect your project dependencies for libp2p-gossipsub:
inspect dependencies for libp2p-gossipsub
Analyze the terminal output to locate any version of libp2p-gossipsub in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.49.4), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-190: Integer Overflow or Wraparound, where the product performs a calculation that can produce an integer overflow or wraparound when the logic assumes that the resulting value will always be larger than the original value. this occurs when an integer value is incremented to a value that is too large to store in the associated representation. when this occurs, the value may become a very small or negative number. In libp2p-gossipsub, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2026-34219 Affected libp2p-gossipsub Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
libp2p-gossipsub
|
crates.io |
< 0.49.4
|
0.49.4
|
References
Frequently Asked Questions
What is CVE-2026-34219?
Which libp2p-gossipsub versions are affected?
What version fixes CVE-2026-34219?
Is libp2p-gossipsub affected?
What is the CVSS score of CVE-2026-34219?
What CWE is associated with CVE-2026-34219?
How can I check crates.io dependencies for CVE-2026-34219?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-xqmp-fxgv-xvq5",
"modified" : "2026-04-06T23:13:23Z",
"published" : "2026-03-30T13:04:03Z",
"aliases" : [ "CVE-2026-34219" ],
"summary" : "libp2p-gossipsub: Remote crash via unchecked Instant overflow in heartbeat backoff expiry handling",
"details" : "## Description\n### Summary\nThe Rust libp2p Gossipsub implementation contains a remotely reachable panic in `backoff` expiry handling. \nAfter a peer sends a crafted `PRUNE` control message with an attacker-controlled, near-maximum `backoff` value, the value is accepted and stored as an `Instant` near the representable upper bound. On a later heartbeat, the implementation performs unchecked `Instant + Duration` arithmetic (`backoff_time + slack`), which can overflow and panic with:\n`overflow when adding duration to instant`\nThis issue is reachable from any Gossipsub peer over normal `TCP + Noise + mplex/yamux` connectivity and requires no further authentication beyond becoming a protocol peer.\n### Attack Scenario\nAn attacker that can establish a libp2p Gossipsub session with a target node can crash the target by sending crafted `PRUNE` control data:\n1. Establish a standard libp2p session (`TCP + Noise`) and negotiate a stream multiplexer (`mplex`/`yamux`).\n2. Open a Gossipsub stream and send an RPC containing `ControlPrune` with a very large `backoff` (chosen near boundary conditions, e.g. `~ i64::MAX - victim_uptime_seconds`; example observed: `9223372036854674580` for ~28h uptime).\n3. The value is parsed from protobuf and passed through `Behaviour::handle_prune()` into mesh/backoff update logic.\n4. Initial storage path uses checked addition (`Instant::now().checked_add(...)`), so the malicious near-max value is retained.\n5. On the next heartbeat (typically within ~43–74s), expiry logic computes `backoff_time + slack` using unchecked addition, which overflows and panics.\n### Impact\nRemote unauthenticated denial of service (critical). \nAny application exposing an affected `libp2p-gossipsub` listener can be crashed by a network-reachable peer that sends crafted `PRUNE` backoff values. The crash is triggered during heartbeat processing (not immediately at PRUNE parse time), and can be repeated by reconnecting and replaying the message.\n\n### Differences from CVE-2026-33040\nThis advisory is related to CVE-2026-33040 but it is not the same defect. CVE-2026-33040 addressed overflow during backoff insertion by adding checked arithmetic when converting PRUNE backoff into an Instant. The issue in this advisory occurs at a different location and at a different time: a near-maximum backoff can still be stored successfully, and the crash happens later in the heartbeat path when slack is added to that stored Instant using unchecked arithmetic. This report covers a distinct secondary overflow path in heartbeat expiry handling that remained reachable after the original insertion-side hardening.\n\nThis vulnerability was originally reported by the Security team of the Ethereum Foundation.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H"
}, {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "crates.io",
"name" : "libp2p-gossipsub"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.49.4"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/libp2p/rust-libp2p/security/advisories/GHSA-xqmp-fxgv-xvq5"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-34219"
}, {
"type" : "ADVISORY",
"url" : "https://github.com/advisories/GHSA-gc42-3jg7-rxr2"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/libp2p/rust-libp2p"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-190", "CWE-617" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2026-03-30T13:04:03Z",
"nvd_published_at" : "2026-03-31T16:16:31Z"
}
}