Your RSA-2048 keys break in 2030. Find every one of them before attackers do.
🦀 crates.io
Not in CISA KEV

GHSA-9cc5-2pq7-hfj8 — xmas-elf

Fix: nrc/xmas-elf@57685c3

GHSA-9cc5-2pq7-hfj8 is a security vulnerability in xmas-elf. A fix is available for xmas-elf — see the affected versions and patch details below.

xmas-elf potential out-of-bounds read with a malformed ELF file and the HashTable API.

Also known asRUSTSEC-2025-0018
Published
Mar 26, 2025
Updated
Sep 10, 2026
Affected
1 pkg
Patched
1 / 1
Exploits
None indexed
Exploitation data as of Sep 10, 2026 · OSV.dev, FIRST.org (EPSS)

Real-World Exposure

1 pkg affected
🦀xmas-elf

Real-time download stats are indexed for npm and PyPI packages. This vulnerability affects crates.io packages — download data is not available via public APIs for these ecosystems.

Description

Affected versions of this crate only validated the index argument of HashTable::get_bucket and HashTable::get_chain against the input-controlled bucket_count and chain_count fields, but not against the size of the ELF section. As a result, a malformed ELF file could trigger out-of-bounds reads in a consumer of the HashTable API by setting these fields to inappropriately large values that would fall outside the relevant hash table section, and by introducing correspondingly out-of-bounds hash table indexes elsewhere in the ELF file.

Affected Packages

1 total 1 fixed
EcosystemPackageVulnerable rangeFix
🦀crates.ioxmas-elfall versions0.10cargo update -p xmas-elf --precise 0.10

Detection & mitigation playbook

Open-source dependency
  1. Detect

    Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for xmas-elf, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.

  2. Fix

    Update xmas-elf to 0.10 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-9cc5-2pq7-hfj8 is resolved across your whole dependency graph.

  3. Workarounds

    Constrain what reaches the vulnerable code: limit the size and shape of untrusted input, isolate the affected component in a sandboxed or least-privileged process, and enable the platform's memory-safety mitigations (ASLR, stack protector, hardened allocator) so an out-of-bounds access is more likely to fail closed than to be exploitable.

Frequently Asked Questions

Affected versions of this crate only validated the `index` argument of `HashTable::get_bucket` and `HashTable::get_chain` against the input-controlled `bucket_count` and `chain_count` fields, but not against the size of the ELF section. As a result, a malformed ELF file could trigger out-of-bounds reads in a consumer of the HashTable API by setting these fields to inappropriately large values that would fall outside the relevant hash table section, and by introducing correspondingly out-of-bounds hash table indexes elsewhere in the ELF file.
O3 Security · Impact-Aware SCA

Is GHSA-9cc5-2pq7-hfj8 in your dependencies?

Find it across crates.io, including transitive dependencies.

GHSA-9cc5-2pq7-hfj8: xmas-elf | O3 Security