CVE-2024-4435Dfinity Stable Structures
Alta 7.5 Sin autenticación
Seguir: esta CVE · Dfinity · Dfinity Stable Structures Te avisamos por email o Slack (requiere cuenta).
- Prioridad
- 60
- CVSS 3.1
- 7.5
- EPSS
- 1.0% probabilidad de explotación en 30 días · percentil 63
- Requiere autenticación
- No
- Publicada
- 21 may 2024
- Actualizada
- 17 jun 2026
- Categoría
- Aplicación · Multiplataforma
- Debilidad (CWE)
- CWE-401
- SSVC (CISA)
- Explotación: ninguna · Automatizable: no · Impacto técnico: parcial
- Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Qué pasa
When storing unbounded types in a BTreeMap, a node is represented as a linked list of "memory chunks". It was discovered recently that when we deallocate a node, in some cases only the first memory chunk is deallocated, and the rest of the memory chunks remain (incorrectly) allocated, causing a memory leak. In the worst case, depending on how a canister uses the BTreeMap, an adversary could interact with the canister through its API and trigger interactions with the map that keep consuming memory due to the memory leak. This could potentially lead to using an excessive amount of memory, or even running out of memory.
This issue has been fixed in #212 https://github.com/dfinity/stable-structures/pull/212 by changing the logic for deallocating nodes to ensure that all of a node's memory chunks are deallocated and users are asked to upgrade to version 0.6.4.. Tests have been added to prevent regressions of this nature moving forward. Note: Users of stable-structure < 0.6.0 are not affected.
Users who are not storing unbounded types in BTreeMap are not affected and do not need to upgrade. Otherwise, an upgrade to version 0.6.4 is necessary.
Qué hacer
- Aplica la actualización de seguridad del fabricante para Stable Structures.
- Se explota sin autenticación: si no puedes parchear ya, limita el acceso desde Internet al servicio afectado.
Paquetes afectados
| Ecosistema | Paquete | Versiones afectadas | Corregida en | Cómo actualizar |
|---|---|---|---|---|
| crates.io | ic-stable-structures |
≥ 0.6.0 < 0.6.4 |
0.6.4 |
cargo update -p ic-stable-structures --precise 0.6.4 |
| crates.io | ic-stable-structures |
≥ 0.6.0 < 0.6.4 |
0.6.4 |
cargo update -p ic-stable-structures --precise 0.6.4 |
Según OSV / GitHub Advisories (GHSA-3rcq-39xp-7xjp, RUSTSEC-2024-0406). Verifica la versión en tu lockfile antes de actualizar.
Productos afectados (CPE)
| Fabricante | Producto | Versiones |
|---|---|---|
| dfinity | stable_structures | < 0.6.0 |
Fuentes oficiales
Referencias
Enlaces publicados por las fuentes. Ábrelos con criterio.
- docs.rs Product
- github.com Issue Tracking Patch
- internetcomputer.org Product