Automated Threat Modeling

Brief Summary: FortiMail CVE-2026-126164, an Unauthenticated SQL Injection in the API Component

A brief summary of CVE-2026-126164, a CVSS 9.4 unauthenticated SQL injection in the FortiMail API component that Fortinet says may allow code or command execution. Covers affected branches, the fixed firmware builds that shipped weeks before disclosure, and the current exploitation picture.

CVE Analysis

8 min read

Gaurav Sarraf
Gaurav Sarraf

2026-11-11

Brief Summary: FortiMail CVE-2026-126164, an Unauthenticated SQL Injection in the API Component

Introduction

An SQL injection in the API component of Fortinet FortiMail may let an unauthenticated remote attacker execute unauthorized code or commands through crafted requests, and Fortinet rates it CVSS 9.4. The fixed firmware shipped roughly five weeks before the advisory was published, so many FortiMail operators who upgraded in October for a separate, actively exploited FortiMail bug already have this fix without having known it existed.

FortiMail is Fortinet's email security product. It provides antivirus, virus outbreak protection, and antispam services powered by FortiGuard threat intelligence, and FortiMail Cloud delivers the same capability as a service for on-premises and cloud-based email. Fortinet reports more than 900,000 customers and a portfolio of more than 50 enterprise-grade products, although those are vendor-reported scale figures and do not tell us how many FortiMail deployments run affected releases. Attacker interest in the product is on record. Singapore's Cyber Security Agency reported active exploitation of a different FortiMail flaw, CVE-2026-104286, in October 2026.

Technical information

Root cause

Fortinet classifies CVE-2026-126164 as CWE-89, improper neutralization of special elements used in an SQL command, and identifies the affected component as the FortiMail API. MITRE's CWE-89 definition describes the general mechanism: the product constructs an SQL command using externally influenced input but fails to neutralize special elements correctly. Input that should remain plain data is then interpreted as SQL syntax and changes the meaning of the intended query.

This describes the weakness class in general and says nothing about FortiMail's internal code. Fortinet's advisory does not disclose:

  • the vulnerable API endpoint, HTTP method, or parameter
  • the database engine or the affected SQL query
  • any payload
  • the intermediate steps that connect SQL injection to code or command execution
  • any required configuration or affected platform variant

No vulnerable code has been published, and FortiMail is closed source, so we are not reproducing or reconstructing any code here.

Attack flow, as far as public information allows

Based on the advisory and the CVSS vector, the attack proceeds roughly as follows:

  1. An attacker with network reach to the FortiMail API sends a request. No credentials (PR:N) and no user interaction (UI:N) are required, and attack complexity is rated low (AC:L).
  2. The request carries crafted input containing SQL special elements.
  3. The API incorporates that input into an SQL command without proper neutralization, so the database parses part of the attacker's data as SQL syntax.
  4. According to Fortinet, the outcome may be unauthorized code or command execution. How the injected SQL is turned into execution has not been disclosed.

A reproducible exploitation sequence cannot be derived from the published material.

CVSS characteristics

NVD presents Fortinet's CNA-supplied CVSS v3.1 base vector:

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:L
  • Attack vector: Network (AV:N)
  • Attack complexity: Low (AC:L)
  • Privileges required: None (PR:N)
  • User interaction: None (UI:N)
  • Scope: Unchanged (S:U)
  • Confidentiality: High (C:H)
  • Integrity: High (I:H)
  • Availability: Low (A:L)

The 9.4 score is Fortinet's assessment. NVD displays the NIST score as unavailable. Fortinet's linked calculator also contains temporal values E:P/RL:O/RC:C, meaning proof-of-concept exploit maturity, an official fix, and confirmed report confidence. Per the FIRST specification, E:P describes exploit maturity and says nothing about whether attacks are occurring, so it does not contradict the advisory's Known Exploited: No field.

Conflicting impact metadata

The advisory's narrative warns of unauthorized code or command execution, but its Impact field says Denial of service. Rescana independently highlighted the same discrepancy and reports that the CSAF threat entry also uses the denial-of-service label. Neither label establishes administrator privileges, root access, persistence, or mail data theft, and those outcomes are not documented for this CVE. Our view is that the broader execution warning in the narrative is the one to use when assessing severity.

The records also disagree on status. At the time of review, the CVE.org record displayed RESERVED, while Fortinet and NVD carried full details.

Exploitation status

  • Fortinet lists Known Exploited: No. That reflects what the vendor knows and does not prove that no exploitation has occurred.
  • Rescana reported on November 11, 2026 that the CVE was absent from the CISA KEV catalog snapshot it checked (catalogVersion 2026.11.10).
  • No threat actor, campaign, or CVE-specific indicators of compromise have been identified in the reviewed material, and no public payload or exact endpoint has been published.
  • Fortinet's CISO noted that attackers can compare old and new firmware to find what changed, which is part of why the fixed builds shipped weeks before details were disclosed.

Patch information

Patch type: vendor firmware update, closed source. There is no public commit or code diff. Fortinet shipped new firmware builds on each supported branch and documented the fix in PSIRT advisory FG-IR-26-216, first published on November 10, 2026. NVD's only reference for this CVE is that advisory.

Fixed releases, per FG-IR-26-216:

  • FortiMail 8.0: 8.0.0 through 8.0.1 affected, fixed in 8.0.2 or above
  • FortiMail 7.6: 7.6.0 through 7.6.6 affected, fixed in 7.6.7 or above
  • FortiMail 7.4: 7.4.0 through 7.4.8 affected, fixed in 7.4.9 or above
  • FortiMail 7.2: all versions affected (NVD enumerates 7.2.0 through 7.2.9). No fix on this branch. Migrate to a fixed release.

The 7.2 line matters most. Fortinet will not backport the fix to 7.2, and its October hardening release post tells 7.2 users to "Upgrade to 7.4 branch or later", which is a major version jump. Fortinet fixed FortiMail Cloud on its own side on October 5, 2026, so hosted customers have nothing to do. The advisory states that no virtual patch is available, so no FortiGuard IPS signature covers this bug. The firmware upgrade is the only vendor fix.

The fix shipped before the CVE

  • According to everyWAN's review of Fortinet's documentation, the 7.6.7 (build 858) release notes are dated October 2, 2026 and 8.0.2 (build 263) October 3, 2026. The same source confirms 7.4.9 as build 630 but gives no release date.
  • Fortinet's CISO said in an October 21 blog post that this round of updates included fixes found through frontier AI-assisted security testing, and that advisories would wait until the November 10 Patch Tuesday so customers had time to upgrade.
  • The same builds (8.0.2, 7.6.7, 7.4.9) also fix the separate, actively exploited FortiMail path traversal bug CVE-2026-104286 (FG-IR-26-175). If you installed those builds in October for that issue, you already have the SQL injection fix.

What the release notes show

The 8.0.2 release notes include a "Common Vulnerabilities and Exposures" table of internal bug IDs fixed in that build. It contains exactly one CWE-89 entry, Bug ID 1303443. Fortinet does not publicly map bug IDs to CVE numbers, so we cannot confirm this is CVE-2026-126164, but it is the only SQL injection fix listed in a build the advisory names as fixed, which makes it the most likely match.

What the fix probably changes

Fortinet has published no root cause details, so the exact change is unknown. Fixes for CWE-89 generally stop building SQL statements by concatenating request data into the query string, and instead pass that data as bound parameters or validate it against a strict allow list before it reaches the database. That is the usual pattern for this weakness class. Fortinet's own code has not been published.

Verifying the fix

Check the firmware version and build on each appliance itself rather than relying on a ticket or inventory record. Anything below 8.0.2, 7.6.7 or 7.4.9 on its branch is still vulnerable, as is every 7.2.x install. For supplier-managed environments, Rescana suggests asking which FortiMail versions serve the environment, whether and when fixed releases were applied, whether interfaces are reachable beyond intended networks, and whether the service actually falls under Fortinet's FortiMail Cloud statement. A supplier-operated appliance does not count as remediated FortiMail Cloud.

Affected systems and versions

  • FortiMail 8.0: versions 8.0.0 through 8.0.1
  • FortiMail 7.6: versions 7.6.0 through 7.6.6
  • FortiMail 7.4: versions 7.4.0 through 7.4.8
  • FortiMail 7.2: all versions (NVD structured data lists 7.2.0 through 7.2.9)
  • FortiMail Cloud: remediated by Fortinet on October 5, 2026, with no customer action required

The vulnerable component is the API. Fortinet does not specify a required configuration or platform variant.

Vendor security history

Fortinet credits discovery of CVE-2026-126164 to Gwendal Guegniaud of the Fortinet Product Security team, working with the AI model Claude Mythos. Internal discovery followed by fixed builds and a coordinated advisory is a positive process signal, and nothing in the record points to an attacker campaign behind this disclosure.

The contrast is CVE-2026-104286, a different FortiMail flaw. Singapore's Cyber Security Agency reported its active exploitation on October 6, 2026. It is a path traversal that lets an unauthenticated attacker write arbitrary files through crafted HTTP or HTTPS requests, and CSA urged immediate patching. That case shows real attacker interest in FortiMail, but its exploitation evidence does not transfer to CVE-2026-126164.

Fortinet's vulnerability policy says it may publish an out-of-cycle advisory when PSIRT observes active exploitation, potentially before a complete set of patches or workarounds exists. That is a policy provision, and there is no indication this advisory was triggered by exploitation.

References

Detect & fix
what others miss

Works with
  • GitHub
  • GitLab
  • Bitbucket
  • Azure DevOps Services
  • Gerrit
  • CVS
  • Jira
  • Linear
  • Slack
  • Security Compass
Explore integrations
Security magnifying glass visualization