Critical FortiClient EMS SQL Injection Under Active Exploitation as CISA Deadline Hits Tomorrow
A pre-authentication SQL injection in Fortinet's endpoint management server has been exploited since late March, with federal agencies facing an April 16 remediation deadline.
Overview
A critical SQL injection vulnerability in Fortinet’s FortiClient Endpoint Management Server (EMS) is under active exploitation, and the deadline for U.S. federal agencies to patch or mitigate the flaw arrives on April 16. The vulnerability, tracked as CVE-2026-21643 with a CVSS score of 9.8, allows unauthenticated remote attackers to execute arbitrary SQL commands and potentially gain full control of the underlying server through specially crafted HTTP requests.
FortiClient EMS is used by organizations worldwide to centrally manage endpoint security policies across employee devices, making any compromise of the server a potential gateway to the entire corporate network.
What We Know
The vulnerability was internally discovered by Gwendal Guégniaud of Fortinet’s Product Security team. According to a technical root-cause analysis by Bishop Fox, the flaw was introduced during a database refactoring in version 7.4.4 that replaced parameterized query handling with raw string interpolation. When multi-tenant mode is enabled, the server reads an HTTP Site header to determine tenant context and passes it directly into a PostgreSQL SET search_path statement without sanitization. Because the site-routing middleware executes before any authentication check, the injection can be triggered without credentials.
Two pre-authentication endpoints are vulnerable: the /api/v1/init_consts public constants endpoint and the /api/v1/auth/signin login endpoint. As Bishop Fox noted, the init_consts endpoint is the preferred attack vector because it has no brute-force protection, no authentication requirement, and returns PostgreSQL error messages in HTTP 500 responses, enabling error-based data extraction in a single request.
The impact of successful exploitation is severe. The PostgreSQL database user in Fortinet’s virtual machine images runs with superuser privileges, enabling operating system command execution via COPY ... TO/FROM PROGRAM. Bishop Fox confirmed that lab testing demonstrated arbitrary file creation on the underlying host as the postgres system user. Attackers can also extract admin password hashes, API tokens, JWT secrets, ZTNA certificates, SAML configuration, and the complete endpoint inventory including hostnames, IP addresses, operating system versions, and installed software.
Exploitation in the wild was first detected around March 24, according to data from Defused Cyber, as reported by Help Net Security. On April 13, the Cybersecurity and Infrastructure Security Agency (CISA) added CVE-2026-21643 to its Known Exploited Vulnerabilities (KEV) catalog, as reported by Cybersecurity News, giving federal civilian agencies a three-day window to secure their systems by April 16.
Only FortiClient EMS version 7.4.4 with multi-tenant mode enabled is affected. Versions 7.2, 7.4.3 and earlier, and 8.0 are not vulnerable. Fortinet released the fix in version 7.4.5.
A Second Flaw Compounds the Risk
The situation is further complicated by a second, separate vulnerability in FortiClient EMS. As Greenbone reported, CVE-2026-35616 is an improper access control flaw affecting the very versions (7.4.5 and 7.4.6) that patched the first SQL injection. This zero-day was exploited before public disclosure, with the earliest attacks detected on March 31 by watchTowr honeypots. Fortinet released an emergency hotfix, but the back-to-back vulnerabilities mean organizations that patched CVE-2026-21643 by upgrading to 7.4.5 may have inadvertently introduced CVE-2026-35616. According to Greenbone, approximately 2,000 FortiClient EMS instances remain reachable on the internet, though some may be honeypots.
What We Don’t Know
- CISA has not publicly attributed the exploitation of either vulnerability to a specific threat group, though nation-state actors from Russia and China have historically targeted Fortinet products.
- The exact number of organizations compromised through CVE-2026-21643 has not been disclosed. Fortinet confirmed direct communication with affected customers but declined to provide specifics.
- It remains unclear whether the two vulnerabilities have been chained in any observed attacks, which could have allowed persistent access across patch cycles.
Remediation
Organizations running FortiClient EMS 7.4.4 should upgrade past 7.4.6 to address both vulnerabilities. If immediate patching is not possible, Bishop Fox recommends disabling multi-tenant mode by setting SITES_ENABLED=False, which renders the CVE-2026-21643 code path unreachable, or restricting HTTPS access to the EMS administrative interface to authorized management networks only. Security teams should also review Apache access logs for HTTP 500 responses from /api/v1/init_consts and check PostgreSQL error logs for anomalous SET search_path statements containing single quotes, semicolons, or SQL keywords.