CVE-2026-48813

Flawfinder output manipulation via untrusted filenames and source text

Published Aug 11, 2026 CVSS 4.0 · 8.7 High EPSS < 1% KEV · Not listed
Description
Flawfinder is a a static analysis tool for finding vulnerabilities in C/C++ source code. Versions prior to 2.0.20 have an improper input neutralization issue leading to output manipulation, specifically, Terminal/ANSI Escape Sequence Injection and XML Injection. A malicious file whose name contains ANSI escape sequences can end up being included in flawfinder's standard terminal output, with many effects. Untrusted fields (such as filenames, categories, or code context text) were not properly sanitized when generating structured reports. An attacker could exploit this to corrupt CSV formats or inject arbitrary XML attributes into SonarQube outputs via output_sonar(). It impacts those who use flawfinder to evaluate intentionally malicious filenames or file contents. This issue has been fully patched in Version 2.0.20 (released 2026-05-16). There is no configuration-based workaround within older versions of flawfinder. If an immediate upgrade is not possible, users can mitigate the risk by pre-scanning filenames, inspecting raw output, and/or restricting untrusted inputs.

Analysis

AI-generated

Technical impact

Flawfinder, a static code analysis tool for C/C++, has an improper neutralization issue that allows filenames or source text containing terminal escape sequences or XML control characters to be injected into its output. This can corrupt CSV or XML reports and cause terminal control sequences to execute when the output is displayed, potentially revealing sensitive information, altering UI, or enabling downstream tools to process invalid XML attributes. The vulnerability does not crash the tool but alters its output, making it difficult for users to trust the results of a scan on files that may include malicious names or content.

Affected Systems

All installations of flawfinder versions earlier than 2.0.20, regardless of operating system, are vulnerable. The vendor released an official patch in version 2.0.20 on 2026‑05‑16, which resolves the improper neutralization of ANSI escape sequences and XML attributes in structured report generation.

Risk and Exploitability

The CVSS score of 8.7 marks it as high severity, yet the EPSS score is less than 1 %, indicating a low probability of exploitation in the wild. The vulnerability is not listed in the CISA KEV catalog. An attacker must have the ability to craft a malicious filename or source file and run flawfinder, so active user interaction is required. The impact is confined to the tool’s output and any systems that consume that output, such as SonarQube integrations. While this does not provide remote code execution, the injected sequences can interfere with terminal sessions or corrupt downstream automated tooling.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade flawfinder to version 2.0.20 or later.
  • Restrict flawfinder usage to trusted sources by filtering filenames and context before scanning.
  • If upgrade is not immediately possible, manually review and sanitize raw output, removing any injected ANSI sequences or XML attributes.

Generated by OpenCVE AI on August 12, 2026 at 20:26 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-4c3c-r6p8-c863 Flawfinder output manipulation via untrusted filenames and source text
History
Type Values Removed Values Added
First Time appeared David-a-wheeler
David-a-wheeler flawfinder
Vendors & Products David-a-wheeler
David-a-wheeler flawfinder
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description Flawfinder is a a static analysis tool for finding vulnerabilities in C/C++ source code. Versions prior to 2.0.20 have an improper input neutralization issue leading to output manipulation, specifically, Terminal/ANSI Escape Sequence Injection and XML Injection. A malicious file whose name contains ANSI escape sequences can end up being included in flawfinder's standard terminal output, with many effects. Untrusted fields (such as filenames, categories, or code context text) were not properly sanitized when generating structured reports. An attacker could exploit this to corrupt CSV formats or inject arbitrary XML attributes into SonarQube outputs via output_sonar(). It impacts those who use flawfinder to evaluate intentionally malicious filenames or file contents. This issue has been fully patched in Version 2.0.20 (released 2026-05-16). There is no configuration-based workaround within older versions of flawfinder. If an immediate upgrade is not possible, users can mitigate the risk by pre-scanning filenames, inspecting raw output, and/or restricting untrusted inputs.
Title Flawfinder output manipulation via untrusted filenames and source text
Weaknesses CWE-74
References
Metrics cvssV4_0

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

Weaknesses
  • CWE-74

    Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Aug 12, 2026, 1:09 PM
Reserved
May 22, 2026, 8:57 PM
Status
Deferred
Published
Aug 11, 2026, 8:17 PM
Modified
Sep 9, 2026, 8:55 PM