{"id":"CVE-2026-33040","aliases":["CVE-2026-33040","GHSA-gc42-3jg7-rxr2","RUSTSEC-2026-0535"],"related":[],"kind":"vulnerability","state":"published","title":"libp2p-rust: Gossipsub PRUNE.backoff Duration Overflow","summary":"libp2p-rust is the official rust language Implementation of the libp2p networking stack. In versions prior to 0.49.3, the Gossipsub implementation accepts attacker-controlled PRUNE backoff values and may perform unchecked time arithmetic when storing backoff state. A specially crafted PRUNE control message with an extremely large backoff (e.g. u64::MAX) can lead to Duration/Instant overflow during backoff update logic, triggering a panic in the networking state machine. This is remotely reachable over a normal libp2p connection and does not require authentication. Any application exposing a libp2p Gossipsub listener and using the affected backoff-handling path can be crashed by a network attacker that can reach the service port. The attack can be repeated by reconnecting and replaying the crafted control message. This issue has been fixed in version 0.49.3.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"libp2p-rust is the official rust language Implementation of the libp2p networking stack. In versions prior to 0.49.3, the Gossipsub implementation accepts attacker-controlled PRUNE backoff values and may perform unchecked time arithmetic when storing backoff state. A specially crafted PRUNE control message with an extremely large backoff (e.g. u64::MAX) can lead to Duration/Instant overflow during backoff update logic, triggering a panic in the networking state machine. This is remotely reachable over a normal libp2p connection and does not require authentication. Any application exposing a libp2p Gossipsub listener and using the affected backoff-handling path can be crashed by a network attacker that can reach the service port. The attack can be repeated by reconnecting and replaying the crafted control message. This issue has been fixed in version 0.49.3.","source":"cvelist"},{"lang":"en","text":"### Summary\nThe Rust libp2p Gossipsub implementation accepts attacker-controlled PRUNE backoff values and may perform unchecked time arithmetic when storing backoff state.\nA specially crafted PRUNE control message with an extremely large backoff (e.g. u64::MAX) can lead to Duration/Instant overflow during backoff update logic, triggering a panic in the networking state machine. This is remotely reachable over a normal libp2p connection and does not require authentication.\n\n### Attack Scenario\nAn attacker that can establish a libp2p Gossipsub session with a target node can crash the target by sending a single crafted PRUNE control message:\n1. Establish a standard libp2p transport session and negotiate a stream multiplexer.\n2. Open a Gossipsub stream and negotiate the meshsub protocol.\n3. Send one protobuf RPC containing ControlPrune with a very large backoff value (e.g. 18446744073709551615 / u64::MAX).\nWhen processed, the oversized backoff can reach time-update logic that adds Duration::from_secs(backoff) to Instant::now(), causing overflow and panic.\n\n### Impact\nRemote unauthenticated denial of service.\nAny application exposing a libp2p Gossipsub listener and using the affected backoff-handling path can be crashed by a network attacker that can reach the service port. The attack can be repeated by reconnecting and replaying the crafted control message.\n### Patches\nUsers should upgrade to a release that hardens Gossipsub backoff handling.\n\nThis vulnerability was originally submitted by @revofusion to the Ethereum Foundation bug bounty program","format":"markdown","source":"ghsa"},{"lang":"en","text":"When a peer sent a PRUNE control message, the backoff it asked for was turned into an expiry time with `Instant::now() + Duration::from_secs(backoff)`. That addition panics on overflow, so a peer that sends a PRUNE with a very large backoff, such as `u64::MAX`, crashes the node. No authentication is needed beyond an ordinary libp2p connection with the gossipsub protocol, and the attacker can repeat it after every restart.\n\nThe fix uses `Instant::checked_add` in `BackoffStorage::update_backoff` and ignores a backoff that would overflow. It is in 0.49.3.","format":"markdown","source":"rustsec"},{"lang":"es","text":"libp2p-rust es la implementación oficial en lenguaje Rust de la pila de red libp2p. En versiones anteriores a la 0.49.3, la implementación de Gossipsub acepta valores de retroceso PRUNE controlados por el atacante y puede realizar aritmética de tiempo sin verificar al almacenar el estado de retroceso. Un mensaje de control PRUNE especialmente diseñado con un retroceso extremadamente grande (p. ej., u64::MAX) puede provocar un desbordamiento de Duration/Instant durante la lógica de actualización del retroceso, desencadenando un pánico en la máquina de estados de la red. Esto es accesible remotamente a través de una conexión libp2p normal y no requiere autenticación. Cualquier aplicación que exponga un oyente Gossipsub de libp2p y que utilice la ruta de manejo de retroceso afectada puede ser bloqueada por un atacante de red que pueda alcanzar el puerto del servicio. El ataque puede repetirse reconectándose y reproduciendo el mensaje de control diseñado. Este problema ha sido solucionado en la versión 0.49.3.","source":"nvd"}],"published":"2026-03-18T12:00:00.000Z","modified":"2026-11-13T12:56:06.349Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N","score":8.7,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N","score":8.7,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N","rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"}],"cwes":["CWE-190"],"affected":[{"ranges":[{"version":"< 0.49.3","status":"affected"}],"vendor":"libp2p","product":"rust-libp2p","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"0.49.3"}],"ecosystem":"crates.io","package":"libp2p-gossipsub","purl":"pkg:cargo/libp2p-gossipsub","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0.0.0-0","status":"affected","fixed":"0.49.3"}],"ecosystem":"crates.io","package":"libp2p-gossipsub","purl":"pkg:cargo/libp2p-gossipsub","source":"rustsec"},{"ranges":[{"status":"affected","fixed":"0.49.3"}],"vendor":"protocol","product":"libp2p-gossipsub","cpe":"cpe:2.3:a:protocol:libp2p-gossipsub:*:*:*:*:*:rust:*:*","source":"nvd"}],"references":[{"url":"https://github.com/libp2p/rust-libp2p/security/advisories/GHSA-gc42-3jg7-rxr2","tags":["vendor-advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-33040","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/libp2p/rust-libp2p","tags":["package"],"sources":["ghsa"]},{"url":"https://crates.io/crates/libp2p-gossipsub","tags":["package"],"sources":["rustsec"]},{"url":"https://rustsec.org/advisories/RUSTSEC-2026-0535.html","tags":["advisory"],"sources":["rustsec"]},{"url":"https://github.com/libp2p/rust-libp2p/commit/84153a559bdbcb92a48413dd2a31035800cb882d","tags":["web"],"sources":["rustsec"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"yes","technicalImpact":"partial","date":"2026-03-20T15:40:49.446Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-33040","url":"https://www.cve.org/CVERecord?id=CVE-2026-33040","licence":"CVE Terms of Use","modified":"2026-03-20T15:41:03.864Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-gc42-3jg7-rxr2","url":"https://github.com/advisories/GHSA-gc42-3jg7-rxr2","licence":"CC-BY-4.0","modified":"2026-11-13T12:56:06.349Z"},{"source":"rustsec","name":"RustSec Advisory Database","id":"RUSTSEC-2026-0535","url":"https://rustsec.org/advisories/RUSTSEC-2026-0535.html","licence":"CC0-1.0","modified":"2026-11-13T12:45:08.544Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-33040","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-33040","licence":"Public domain","modified":"2026-06-17T10:36:51.167Z"}],"updatedAt":"2026-11-25T22:59:16.285Z","epss":{"score":0.00643,"percentile":0.52167,"date":"2026-12-01T12:00:22.000Z"}}