Fortinet FortiOS and related products: Format string vulnerability in FGFM service (CVE-2024-23113)
A format string vulnerability (CVE-2024-23113) in the FortiGate FGFM service on TCP port 541 allows unauthenticated remote code execution via specially crafted input.
CVE search metadata
CVE search record: CVE-2024-23113. Severity: critical. CVSS: 9.8. EPSS: 61.72%. KEV: no. Product: Fortiproxy (<= 7.4.2), Fortiswitchmanager (<= 7.2.3), Fortios (<= 7.4.2), Fortipam (<= 1.2.0). Brief: Fortinet FortiOS and related products: Format string vulnerability in FGFM service (CVE-2024-23113). Brief link: https://feed.craftedsignal.io/briefs/2026-11-cve-2024-23113/
Triage facts
Revision 1- Applicability
- Fortiproxy (<= 7.4.2), Fortiswitchmanager (<= 7.2.3) +2
- Evidence
- Unknown
- Severity
- Critical
- Action
- Immediate escalation
- Sources
- 2 public sources
- Freshness
- Revision 1Nov 1, 03:44 UTC
- Vulnerabilities
- 1 CVE
- Source quality
- B3Very likely
CVE-2024-23113 is a critical format string vulnerability affecting the FortiGate FGFM (FortiGate to FortiManager) protocol service. The service, which facilitates management communication, listens on TCP port 541. Improper handling of input strings allows an unauthenticated attacker to inject format specifiers, such as %n, which may result in remote code execution (RCE) or denial-of-service due to memory corruption. Public exploit code is available that targets this service by sending malformed payloads and monitoring for service-level SSL alerts or connection resets indicative of an exploit attempt.
Impact
The vulnerability is rated at CVSS 9.8. Successful exploitation enables unauthenticated remote code execution with high impact on confidentiality, integrity, and availability. Exposure is increased due to the availability of functional proof-of-concept exploit scripts.
Recommendation
- Inventory all internet-facing FortiGate, Fortiproxy, Fortiswitchmanager, and Fortipam assets.
- Restrict access to TCP port 541 (FGFM) to trusted management IP addresses only.
- Apply vendor-provided security patches immediately to address the vulnerability in the affected versions of FortiOS, Fortiproxy, Fortiswitchmanager, and Fortipam.
- Implement network-level monitoring to detect anomalous traffic patterns targeting port 541, specifically patterns containing common format string specifiers.
Immediate actions
Restrict TCP port 541 (FGFM) access on all internet-facing Fortinet appliances to known-good management IP ranges.
Threat Hunt
Identify inbound connections to TCP port 541 from unauthorized or external IP addresses.
Data: Firewall logs, Flow logs
Search for anomalous payloads in traffic directed at TCP port 541, specifically looking for common format string specifiers (e.g., %n, %x, %s).
Data: Network IDS/IPS alerts, Full packet capture (if available)
Mitigations
Upgrade affected Fortinet products to a non-vulnerable version as specified by vendor security bulletins.
CVE-2024-23113