# GHSA-6g2r-675j-hx59: xxhash-rust: Safe xxh3 custom-secret API accepts too-short secret in release

- Severity: Low 2.3 (CVSS:3.1, scored by GitHub) `CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:L/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Published: 2026-10-02T18:29:13.000Z
- Modified: 2026-10-02T18:45:04.881Z
- Weaknesses: CWE-125

## Description

I have a minimized safe Rust witness for xxhash-rust 0.8.15.

Safe public route:

xxhash_rust::xxh3::xxh3_64_with_secret(&[0x41], &[])

The caller-side harness contains no unsafe code. Under release execution, the internal minimum custom-secret length predicate is enforced only by debug_assert!. Release-Miri reports construction of a fixed-width reference beyond the empty secret allocation.

Observed diagnostic:

Undefined Behavior: constructing invalid value of type &[u8; 4]: encountered a dangling reference

Local repair evidence: handling custom-secret slices shorter than the internal minimum before fixed-width secret reads makes the same safe short-secret harness pass under Linux release-Miri.

Local artifacts:
- vulnerable log: artifacts/logs/W-4332_xxhash_rust_short_secret_miri_release_linux_001.log
- repair log: artifacts/logs/differentials/W-4332_xxhash_rust_local_repair_miri_release_linux_001.log
- report: artifacts/reports/W-4332_xxhash_rust_short_secret_report.md

(As written by GitHub Advisory Database.)

## Affected

- xxhash-rust (crates.io): before 0.8.16

## References

- <https://github.com/DoumanAsh/xxhash-rust/security/advisories/GHSA-6g2r-675j-hx59> (web)
- <https://github.com/DoumanAsh/xxhash-rust/commit/200cadb1a442c7f6cd9747e7d4297379b6b74200> (web)
- <https://github.com/DoumanAsh/xxhash-rust> (package)

## Sources

- GitHub Advisory Database: [GHSA-6g2r-675j-hx59](https://github.com/advisories/GHSA-6g2r-675j-hx59), CC-BY-4.0, modified 2026-10-02

---

Page: https://cve.day/GHSA-6g2r-675j-hx59 · Whole record: https://cve.day/GHSA-6g2r-675j-hx59.json · Rebuilt by cve.day 2026-11-25T22:56:42.285Z
