CVE-2025-55304: Exiv2 :readMetadata Vulnerability

LOW
Advisory Identifier: GHSA-m54q-mm9w-fp6g
CWE-407
Published
Advisory Summary

CVE-2025-55304 is a LOW :readmetadata vulnerability (CWE-407: Inefficient Algorithmic Complexity) affecting Exiv2 libraries in the PyPI ecosystem. The issue involves :readmetadata. Remediation is available in the latest vendor maintenance releases.

CVE-2025-55304 at a Glance

CVE Identifier CVE-2025-55304
GHSA Identifier GHSA-m54q-mm9w-fp6g
Severity LOW
CVSS v3.1 Base Score N/A
CWE Classification CWE-407: Inefficient Algorithmic Complexity
Affected Product Exiv2
Package Ecosystem PyPI
Published Date
Last Updated

How to Fix CVE-2025-55304

To remediate this vulnerability, upgrade all affected Exiv2 dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

Exiv2 fixed: Latest secure release
pip install Exiv2>=Latest secure release
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show Exiv2

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2025-55304, inspect your installed packages using pip:

pip show Exiv2

Analyze the terminal output to locate any version of Exiv2 in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), your application is affected.

Note: The pip show Exiv2 command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-407: Inefficient Algorithmic Complexity, where an algorithm in a product has an inefficient worst-case computational complexity that may be detrimental to system performance and can be triggered by an attacker, typically using crafted manipulations that ensure that the worst case is being reached. In Exiv2, 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

### Impact A denial-of-service was found in Exiv2 version v0.28.5: a quadratic algorithm in the ICC profile parsing code in `jpegBase::readMetadata()` can cause Exiv2 to run for a long time. Exiv2 is a command-line utility and C++ library for reading, writing, deleting, and modifying the metadata of image files. The denial-of-service is triggered when Exiv2 is used to read the metadata of a crafted jpg image file. ### Patches The bug is fixed in version v0.28.6. ### References Issue: https://github.com/Exiv2/exiv2/issues/3333 Fixes: https://github.com/Exiv2/exiv2/pull/3335 (main branch), https://github.com/Exiv2/exiv2/pull/3345 (0.28.x branch) ### For more information Please see our [security policy](https://github.com/Exiv2/exiv2/security/policy) for information about Exiv2 security.

CVE-2025-55304 Affected Exiv2 Versions

1 component(s)
Product / Package Ecosystem Affected Versions Fixed Version
Exiv2
PyPI
≤ 0.17.3

References

Frequently Asked Questions

What is CVE-2025-55304?
CVE-2025-55304 is a security vulnerability in Exiv2 involving :readMetadata under CWE-407: Inefficient Algorithmic Complexity.
Which Exiv2 versions are affected?
Affected versions include releases prior to current release patches across affected packages: Exiv2.
What version fixes CVE-2025-55304?
Upgrading to current release patches (or the latest patched release for your respective branch) resolves the vulnerability.
Is Exiv2 affected?
Yes, Exiv2 is affected in releases prior to Latest secure release. Upgrade your dependency to Latest secure release or later.
What CWE is associated with CVE-2025-55304?
CVE-2025-55304 is classified under CWE-407: Inefficient Algorithmic Complexity (An algorithm in a product has an inefficient worst-case computational complexity that may be detrimental to system performance and can be triggered by an attacker, typically using crafted manipulations that ensure that the worst case is being reached.).
How can I check PyPI dependencies for CVE-2025-55304?
Run the dependency tree command: 'pip show Exiv2'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-m54q-mm9w-fp6g",
  "modified" : "2025-08-29T21:04:02Z",
  "published" : "2025-08-29T14:59:37Z",
  "aliases" : [ "CVE-2025-55304" ],
  "summary" : "Exiv2 has quadratic performance in ICC profile parsing in JpegBase::readMetadata",
  "details" : "### Impact\nA denial-of-service was found in Exiv2 version v0.28.5: a quadratic algorithm in the ICC profile parsing code in `jpegBase::readMetadata()` can cause Exiv2 to run for a long time. Exiv2 is a command-line utility and C++ library for reading, writing, deleting, and modifying the metadata of image files. The denial-of-service is triggered when Exiv2 is used to read the metadata of a crafted jpg image file.\n\n### Patches\nThe bug is fixed in version v0.28.6.\n\n### References\nIssue: https://github.com/Exiv2/exiv2/issues/3333\nFixes: https://github.com/Exiv2/exiv2/pull/3335 (main branch), https://github.com/Exiv2/exiv2/pull/3345 (0.28.x branch)\n\n### For more information\nPlease see our [security policy](https://github.com/Exiv2/exiv2/security/policy) for information about Exiv2 security.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "Exiv2"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "last_affected" : "0.17.3"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/Exiv2/exiv2/security/advisories/GHSA-m54q-mm9w-fp6g"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-55304"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/Exiv2/exiv2/issues/3333"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/Exiv2/exiv2/pull/3335"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/Exiv2/exiv2/pull/3345"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/Exiv2/exiv2"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-407" ],
    "severity" : "LOW",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-08-29T14:59:37Z",
    "nvd_published_at" : "2025-08-29T15:15:35Z"
  }
}