Advisory Database
  • Advisories
  • Dependency Scanning
  1. cargo
  2. ›
  3. kamadak-exif
  4. ›
  5. CVE-2021-21235

CVE-2021-21235: kamadak-exif vulnerable to Infinite loop when parsing PNG files

October 6, 2022

Reader::read_from_container can cause an infinite loop when a crafted PNG file is given.

References

  • crates.io/crates/kamadak-exif
  • github.com/advisories/GHSA-px9g-8hgv-jvg2
  • github.com/kamadak/exif-rs
  • github.com/kamadak/exif-rs/commit/1b05eab57e484cd7d576d4357b9cda7fdc57df8c
  • github.com/kamadak/exif-rs/commit/f21df24616ea611c5d5d0e0e2f8042eb74d5ff48
  • github.com/kamadak/exif-rs/security/advisories/GHSA-px9g-8hgv-jvg2
  • nvd.nist.gov/vuln/detail/CVE-2021-21235
  • rustsec.org/advisories/RUSTSEC-2021-0143.html

Code Behaviors & Features

Detect and mitigate CVE-2021-21235 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions starting from 0.5.2 before 0.5.3, version 0.5.2

Fixed versions

  • 0.5.3

Solution

Upgrade to version 0.5.3 or above.

Impact 6.5 MEDIUM

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H

Learn more about CVSS

Weakness

  • CWE-400: Uncontrolled Resource Consumption
  • CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop')

Source file

cargo/kamadak-exif/CVE-2021-21235.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:17:24 +0000.