RUSTSEC-2026-0305

Source
https://rustsec.org/advisories/RUSTSEC-2026-0305
Import Source
https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2026-0305.json
JSON Data
https://api.osv.dev/v1/vulns/RUSTSEC-2026-0305
Aliases
  • CVE-2026-96889
Published
2026-09-23T12:00:00Z
Modified
2026-09-23T21:30:03Z
Summary
Use-after-free when XML includes have duplicated entities
Details

Librsvg uses libxml2, a C library, to parse XML. When librsvg parses an SVG document which has a nested Xinclude, an XML entity declaration with a duplicate name as an existing one can cause a use-after-free error.

While libxml2 is expanding an internal entity, a recursive XInclude can parse another document that declares an entity with the same name. Both parses use the same XmlState entity map on the librsvg side. entity_insert() replaces the first entry, whose Drop implementation calls xmlFreeNode(). The outer xmlCtxtParseEntity() then keeps using the freed 144-byte xmlEntity.

The included parse should not free an entity that the outer parser is still using.

The fix is in commit 8a1b0cd319e9af2d1e9cf878081dd77f227a0504, where librsvg will no longer free xmlEntity pointers that libxml2 is still using.

Database specific
{
    "license":  "CC0-1.0"
}
References

Affected packages

crates.io / librsvg

Package

Name
librsvg
View open source insights on deps.dev
Purl
pkg:cargo/librsvg

Affected ranges

Type
SEMVER
Events
Introduced
0.0.0-0
Fixed
2.62.4
Introduced
2.62.90
Fixed
2.63.2

Ecosystem specific

{
    "affected_functions":  null,
    "affects":  {
        "arch":  [],
        "functions":  [],
        "os":  []
    }
}

Database specific

categories
[
    "memory-corruption"
]
cvss
null
informational
null
source
"https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2026-0305.json"