Skip to content

Defense Digests

Fortinet FortiOS Vulnerability Targeted by Advanced Threat Actor

Dataprise Defense Digest 550x550

Table of content

Dataprise Defense Digest

ID: D3-2023-0005-1

Severity: 6.7 (Medium)

Published: March, 14th 2023

EXECUTIVE SUMMARY

Government entities and large organizations have recently been targeted by an unknown threat actor exploiting a zero-day flaw in the Fortinet FortiOS software, resulting in data loss as well as the operating system and file corruption. Fortinet researchers confirmed that the exploit is highly targeted at government or government-related targets, and suggests an advanced threat actor. This vulnerability is a path traversal bug, being tracked as CVE-2022-41328, that could lead to arbitrary code execution in Fortinet FortiOS software.

Fortinet has confirmed that the patches for the most recent CVE-2023-25610 FortiOS Buffer Underflow vulnerability also patch this path traversal bug. If you have already patched the previous vulnerability then you are no longer vulnerable to this exploit.

Dataprise is aware of the critical nature of this vulnerability and has completed a review of all available analyses of these vulnerabilities and the potential impact on our clients. This has been a major exercise as the investigation requires that a specific order of actions is taken to achieve the response objectives. Right now, our teams are working to confirm whether the recommended mitigation steps can be applied without causing any customer-facing service interruptions. If your organization’s Fortinet appliance is covered under a Dataprise Managed Service agreement, we will send a follow-up communication with details on our mitigation efforts.

IMPACT

The impact of the attack is significant, leading to data loss and operating system and file corruption on Fortigate firewalls. The threat actors have modified the firmware image to include malware, which grants them persistent access and control, enabling them to exfiltrate data and disable firmware verification at startup. The exploit is highly targeted at government or government-related targets, suggesting that sensitive data may have been compromised. The vulnerability impacts FortiOS versions 6.0, 6.2, 6.4.0 through 6.4.11, 7.0.0 through 7.0.9, and 7.2.0 through 7.2.3.

DETAILED ANALYSIS

The vulnerability in question is a medium security path traversal bug, CVE-2022-41328, that could lead to arbitrary code execution in Fortinet FortiOS software. Further analysis of the incident revealed that the attackers modified the firmware image of multiple FortiGate devices belonging to an unnamed customer. The modifications contained malware which provided the attackers with persistent access and control. This allowed them to exfiltrate data and disable firmware verification at startup.

image
image

Analysis of the incident demonstrated that the attackers modified the device’s original firmware image to include a new payload called “/bin/fgfm” and ensure that it is launched before the boot process begins. This malware will then establish contact with a remote server to download files, exfiltrate data from the compromised host, and grant remote shell access.

Fortinet researchers confirmed that the exploit is highly targeted and suggests an advanced actor with a deep understanding of FortiOS and the underlying hardware.

MITIGATION STEPS

To mitigate the impact of the attack, organizations should update their FortiOS software to versions 6.4.12, 7.0.10, and 7.2.4, which contain fixes for the CVE-2022-41328 vulnerability. Please see the official Fortiguard advisory here for a complete list of affected products: FG-IR-22-369

Organizations should also implement security best practices, including regular security updates, network segmentation, and user access control. Network segmentation helps to prevent attackers from moving laterally within the network, and user access control helps to limit access to sensitive data.

Additionally, organizations should implement a comprehensive security program that includes regular security training for employees, incident response planning, and network security monitoring. These measures can help organizations detect and respond to attacks quickly, minimizing the impact on sensitive data and critical systems.

SOURCES

  • https://thehackernews.com/2023/03/fortinet-fortios-flaw-exploited-in.html?m=1
  • https://www.fortiguard.com/psirt/FG-IR-22-369
  • https://nvd.nist.gov/vuln/detail/CVE-2022-41328

CONTRIBUTING AUTHORS

  • Dan Mervis, Cybersecurity Analyst
  • Stephen Jones, VP Cybersecurity

View all Dataprise Defense Digests here.

Recent Tweets

INSIGHTS

Learn about the latest threats and vulnerabilities with our D3 alerts.

Subscribe to get real-time notifications when a new Dataprise Defense Digest is published.