Description
CFITSIO through 4.7.0 contains an out-of-bounds write vulnerability in ffgcls2() in getcols.c that trusts attacker-controlled heap descriptor lengths for variable-length string columns. Attackers can supply a crafted FITS file that overflows a fixed 28,800-byte stack buffer and the caller's string array, enabling arbitrary code execution.
Published: 2026-10-22
Score: 8.5 High
EPSS: n/a
KEV: No
Impact: Remote Code Execution
Action: Apply Patch
AI Analysis

Impact

CFITSIO 4.7.0 and earlier contain an out‑of‑bounds write in the ffgcls2 function located in getcols.c; the function trusts heap descriptor lengths supplied by the FITS file creator for variable‑length string columns. An attacker can craft a FITS file that overflows a 28,800‑byte stack buffer and the caller’s string array, enabling arbitrary code execution. This defect is a classic out‑of‑bounds write (CWE‑787).

Affected Systems

Any system or application that links against CFITSIO 4.7.0 or older and processes FITS files from external or untrusted sources is affected, including scientific data tools, astrophysics pipelines and custom consumer code that uses the library.

Risk and Exploitability

The CVSS score of 8.5 marks this vulnerability as high severity. Although the EPSS score is not available and the vulnerability is not listed in CISA’s KEV catalog, the ability for a remote attacker to execute arbitrary code by delivering a malicious FITS file remains a serious risk. The attack path is straightforward once the vulnerable library processes an unpatched file.

Generated by OpenCVE AI on October 23, 2026 at 03:58 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Apply the upstream patch (commit 579792e0f85bff0c6733ad5ebdf54c3b5c188686) or merge PR #184 from the CFITSIO repository that corrects the buffer handling logic.
  • Rebuild or reinstall the CFITSIO library to incorporate the patched source into your binaries.
  • Add a validation layer that detects or rejects FITS files with oversized or malformed string columns before they are passed to CFITSIO, thereby mitigating the risk while the patch is deployed.

Generated by OpenCVE AI on October 23, 2026 at 03:58 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Fri, 23 Oct 2026 00:45:00 +0000

Type Values Removed Values Added
Description CFITSIO through 4.7.0 contains an out-of-bounds write vulnerability in ffgcls2() in getcols.c that trusts attacker-controlled heap descriptor lengths for variable-length string columns. Attackers can supply a crafted FITS file that overflows a fixed 28,800-byte stack buffer and the caller's string array, enabling arbitrary code execution.
Title CFITSIO through 4.7.0 Out-of-Bounds Write via ffgcls2 in getcols.c
Weaknesses CWE-787
References
Metrics cvssV3_1

{'score': 7.8, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'}

cvssV4_0

{'score': 8.5, 'vector': 'CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N'}


Subscriptions

No data.

cve-icon MITRE

Status: PUBLISHED

Assigner: VulnCheck

Published:

Updated: 2026-10-22T19:14:04.552Z

Reserved: 2026-10-22T16:14:58.754Z

Link: CVE-2026-115504

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-22T20:17:06.313

Modified: 2026-10-22T20:17:06.313

Link: CVE-2026-115504

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-10-23T04:00:12Z

Weaknesses