GHSA-qg8r-f7x3-25f7: imageproc Out-of-bounds Read Vulnerability

MODERATE
CWE-190
Published
Advisory Summary

GHSA-qg8r-f7x3-25f7 is a MODERATE out-of-bounds read vulnerability (CWE-190: Integer Overflow or Wraparound) affecting imageproc libraries in the crates.io ecosystem. The issue involves out-of-bounds read via nan coordinates in bilinear/bicubic sampling. Remediation is available by upgrading affected packages to version 0.23.1, 0.24.1, 0.25.1, 0.26.2.

GHSA-qg8r-f7x3-25f7 at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-qg8r-f7x3-25f7
Severity MODERATE
CVSS v3.1 Base Score N/A
CWE Classification CWE-190: Integer Overflow or Wraparound
Affected Product imageproc
Package Ecosystem crates.io
Published Date
Last Updated

How to Fix GHSA-qg8r-f7x3-25f7

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

imageproc fixed: 0.23.1
Upgrade imageproc to 0.23.1
imageproc fixed: 0.24.1
Upgrade imageproc to 0.24.1
imageproc fixed: 0.25.1
Upgrade imageproc to 0.25.1
imageproc fixed: 0.26.2
Upgrade imageproc to 0.26.2
Verify Direct and Transitive Dependencies

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

inspect dependencies for imageproc

How to Check if You Are Affected

To determine whether your application is affected by GHSA-qg8r-f7x3-25f7, inspect your project dependencies for imageproc:

inspect dependencies for imageproc

Analyze the terminal output to locate any version of imageproc in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.23.1), 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-190: Integer Overflow or Wraparound, where the product performs a calculation that can produce an integer overflow or wraparound when the logic assumes that the resulting value will always be larger than the original value. this occurs when an integer value is incremented to a value that is too large to store in the associated representation. when this occurs, the value may become a very small or negative number. In imageproc, 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

A bounds check was performed in floating points before a cast to the index passed to an unchecked access function. This checked considered `NaN` cases improperly, causing them to succeed the check instead of failing it. The floating point coordinate is under caller control by passing a selected projection matrix. Carefully controlling the coordinates of an image with no data and one non-zero dimension provides an arbitrary read primitive in the first 32-bits of address space with a Bilinear sampling method. Using bicubic sampling can result in a read of a few bytes beyond an allocation. Other out-of-bounds reads may be possible.

GHSA-qg8r-f7x3-25f7 Affected imageproc Versions

4 component(s)
Fixed Versions:
0.23.10.24.10.25.10.26.2
Product / Package Ecosystem Affected Versions Fixed Version
imageproc
crates.io
< 0.23.1
0.23.1
imageproc
crates.io
≥ 0.24.0
< 0.24.1
All 1 versions
0.24.0
0.24.1
imageproc
crates.io
≥ 0.25.0
< 0.25.1
All 1 versions
0.25.0
0.25.1
imageproc
crates.io
≥ 0.26.0
< 0.26.2
0.26.2

References

Frequently Asked Questions

What is GHSA-qg8r-f7x3-25f7?
GHSA-qg8r-f7x3-25f7 is a security vulnerability in imageproc involving Out-of-bounds read via NaN coordinates in bilinear/bicubic sampling under CWE-190: Integer Overflow or Wraparound.
Which imageproc versions are affected?
Affected versions include releases prior to 0.23.1, 0.24.1, 0.25.1, 0.26.2 across affected packages: imageproc.
What version fixes GHSA-qg8r-f7x3-25f7?
Upgrading to 0.23.1, 0.24.1, 0.25.1, 0.26.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is imageproc affected?
Yes, imageproc is affected in releases prior to 0.23.1, 0.24.1, 0.25.1, 0.26.2. Upgrade your dependency to 0.23.1, 0.24.1, 0.25.1, 0.26.2 or later.
What CWE is associated with GHSA-qg8r-f7x3-25f7?
GHSA-qg8r-f7x3-25f7 is classified under CWE-190: Integer Overflow or Wraparound (The product performs a calculation that can produce an integer overflow or wraparound when the logic assumes that the resulting value will always be larger than the original value. This occurs when an integer value is incremented to a value that is too large to store in the associated representation. When this occurs, the value may become a very small or negative number.).
How can I check crates.io dependencies for GHSA-qg8r-f7x3-25f7?
Run the dependency tree command: 'inspect dependencies for imageproc'. 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-qg8r-f7x3-25f7",
  "modified" : "2026-05-07T03:10:13Z",
  "published" : "2026-05-07T03:10:13Z",
  "aliases" : [ ],
  "summary" : "imageproc: Out-of-bounds read via NaN coordinates in bilinear/bicubic sampling",
  "details" : "A bounds check was performed in floating points before a cast to the index passed to an unchecked access function. This checked considered `NaN` cases improperly, causing them to succeed the check instead of failing it. The floating point coordinate is under caller control by passing a selected projection matrix.\n\nCarefully controlling the coordinates of an image with no data and one non-zero dimension provides an arbitrary read primitive in the first 32-bits of address space with a Bilinear sampling method.\n\nUsing bicubic sampling can result in a read of a few bytes beyond an allocation.\n\nOther out-of-bounds reads may be possible.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "crates.io",
      "name" : "imageproc"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.23.1"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "crates.io",
      "name" : "imageproc"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0.24.0"
      }, {
        "fixed" : "0.24.1"
      } ]
    } ],
    "versions" : [ "0.24.0" ]
  }, {
    "package" : {
      "ecosystem" : "crates.io",
      "name" : "imageproc"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0.25.0"
      }, {
        "fixed" : "0.25.1"
      } ]
    } ],
    "versions" : [ "0.25.0" ]
  }, {
    "package" : {
      "ecosystem" : "crates.io",
      "name" : "imageproc"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0.26.0"
      }, {
        "fixed" : "0.26.2"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "PACKAGE",
    "url" : "https://github.com/image-rs/imageproc"
  }, {
    "type" : "WEB",
    "url" : "https://rustsec.org/advisories/RUSTSEC-2026-0117.html"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-190" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-05-07T03:10:13Z",
    "nvd_published_at" : null
  }
}