GHSA-66fw-43h8-f8p3: XMP Toolkit's `XmpFile :close` Can Trigger Undefined Behavior Vulnerability
LOWGHSA-66fw-43h8-f8p3 is a LOW :close` can trigger undefined behavior vulnerability (CWE-754: Improper Check for Unusual or Exceptional Conditions) affecting XMP Toolkit's `XmpFile libraries in the crates.io ecosystem. The issue involves :close` can trigger undefined behavior. Remediation is available by upgrading affected packages to version 1.9.0.
GHSA-66fw-43h8-f8p3 at a Glance
How to Fix GHSA-66fw-43h8-f8p3
To remediate this vulnerability, upgrade all affected XMP Toolkit's `XmpFile dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade xmp_toolkit to 1.9.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for xmp_toolkit
How to Check if You Are Affected
To determine whether your application is affected by GHSA-66fw-43h8-f8p3, inspect your project dependencies for XMP Toolkit's `XmpFile:
inspect dependencies for xmp_toolkit
Analyze the terminal output to locate any version of XMP Toolkit's `XmpFile in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.9.0), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-754: Improper Check for Unusual or Exceptional Conditions, where the product does not check or incorrectly checks for unusual or exceptional conditions that are not expected to occur frequently during day to day operation of the product. In XMP Toolkit's `XmpFile, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-66fw-43h8-f8p3 Affected XMP Toolkit's `XmpFile Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
xmp_toolkit
|
crates.io |
< 1.9.0
|
1.9.0
|
References
Frequently Asked Questions
What is GHSA-66fw-43h8-f8p3?
Which XMP Toolkit's `XmpFile versions are affected?
What version fixes GHSA-66fw-43h8-f8p3?
Is xmp_toolkit affected?
What CWE is associated with GHSA-66fw-43h8-f8p3?
How can I check crates.io dependencies for GHSA-66fw-43h8-f8p3?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-66fw-43h8-f8p3",
"modified" : "2025-05-15T21:23:42Z",
"published" : "2024-07-26T21:14:54Z",
"aliases" : [ ],
"summary" : "XMP Toolkit's `XmpFile::close` can trigger undefined behavior",
"details" : "Affected versions of the crate failed to catch C++ exceptions raised within the `XmpFile::close` function. If such an exception occurred, it would trigger undefined behavior, typically a process abort.\n\nThis is best demonstrated in [issue #230](https://github.com/adobe/xmp-toolkit-rs/issues/230), where a race condition causes the `close` call to fail due to file I/O errors.\n\nThis was fixed in [PR #232](https://github.com/adobe/xmp-toolkit-rs/pull/232) (released as crate version 1.9.0), which now safely handles the exception.\n\nFor backward compatibility, the existing API ignores the error. A new API `XmpFile::try_close` was added to allow callers to receive and process the error result.\n\nUsers of all prior versions of `xmp_toolkit` are encouraged to update to version 1.9.0 to avoid undefined behavior.",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "crates.io",
"name" : "xmp_toolkit"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "1.9.0"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/adobe/xmp-toolkit-rs/issues/230"
}, {
"type" : "WEB",
"url" : "https://github.com/adobe/xmp-toolkit-rs/issues/233"
}, {
"type" : "WEB",
"url" : "https://github.com/adobe/xmp-toolkit-rs/pull/232"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/adobe/xmp-toolkit-rs"
}, {
"type" : "WEB",
"url" : "https://rustsec.org/advisories/RUSTSEC-2024-0360.html"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-754" ],
"severity" : "LOW",
"github_reviewed" : true,
"github_reviewed_at" : "2024-07-26T21:14:54Z",
"nvd_published_at" : null
}
}