RUSTSEC-2026-0588: Validating Matrix Content URIs may panic
Published 2026-11-19 · Updated 2026-11-22
Summary
The ruma-identifiers-validation crate contains a vulnerability where validating Matrix content URIs can cause a program panic if the server name exceeds 249 bytes. Developers using this crate should update to the specified fixed version to prevent potential denial-of-service conditions.
Who is affected
The issue occurs when the `mxc_uri::validate` function processes a URI with a server name larger than 249 bytes, exceeding the assumption that the length fits into a `NonZeroU8`. This can lead to an unhandled panic, effectively crashing the application processing the URI. This vulnerability affects deployments that parse or validate user-supplied or network-provided Matrix URIs using the affected versions.
Exploitability
The exploitability is not documented as the CVSS vector, base score, and EPSS score are not provided. There is no evidence of active exploitation according to CISA KEV data.
Remediation
- Update the ruma-identifiers-validation crate to version 0.13.0 or later.
- Review project dependencies to ensure no transitive dependencies are pulling in version ranges 0.2.3 through 0.12.x.
How to check your project
- Examine the Cargo.lock file for ruma-identifiers-validation to verify if the version is between 0.2.3 and 0.12.x.
- Run 'cargo tree -p ruma-identifiers-validation' to identify if the affected crate is present in the dependency graph.
Automated analysis of the published advisory data, generated 2026-11-22. Not human-reviewed; verify against the official advisory. How this works.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | Upgrade |
|---|---|---|---|---|
| crates.io | ruma-identifiers-validation |
>= 0.2.3, < 0.13.0 | 0.13.0 | cargo update -p ruma-identifiers-validation --precise 0.13.0 |
FAQ
What specifically triggers the panic?
The panic is triggered when the server name component of a Matrix 'mxc://' URI exceeds 249 bytes, violating internal assumptions about the length limit.
Is there a workaround if I cannot upgrade immediately?
Not documented; the recommended action is to update to the fixed version 0.13.0.
Does the Matrix specification allow these longer URIs?
Yes, the Matrix specification permits server names up to 261 bytes, which the affected versions of the crate failed to handle correctly.
Original advisory description
References
- PACKAGE https://crates.io/crates/ruma-identifiers-validation
- ADVISORY https://rustsec.org/advisories/RUSTSEC-2026-0588.html
- WEB https://github.com/ruma/ruma/commit/caf1ac05a9fd347158b60505ef8546a2ff18ae7c
Source records: RUSTSEC-2026-0588 (OSV.dev).