SecPod

Learn Search

Search across all Learn content

← Back to Security Research
Tracking Gafgyt C0XMO: How a New Malware Variant Spreads Across Platforms

Tracking Gafgyt C0XMO: How a New Malware Variant Spreads Across Platforms

A newly identified Gafgyt botnet variant, C0XMO, is actively targeting internet-exposed devices through a combination of vulnerability exploitation, weak-credential attacks, and automated lateral movement. Unlike traditional Gafgyt campaigns, C0XMO separates its propagation logic into a dedicated Python-based scanner, enabling it to compromise a wider range of architectures and device types while scaling infections more efficiently.

Jun 30, 2026By Padmashree P

A newly identified Gafgyt botnet variant, C0XMO, is actively targeting internet-exposed devices through a combination of vulnerability exploitation, weak-credential attacks, and automated lateral movement. Unlike traditional Gafgyt campaigns, C0XMO separates its propagation logic into a dedicated Python-based scanner, enabling it to compromise a wider range of architectures and device types while scaling infections more efficiently.

Discovered by FortiGuard Labs in March 2026, the malware was initially observed exploiting vulnerable DD-WRT routers before deploying multi-architecture payloads capable of infecting ARM, MIPS, PowerPC, SuperH, x86, and x64 systems. This modular design marks a significant evolution in Gafgyt's operational capability and propagation strategy.

Background

Gafgyt is a long-running IoT malware family primarily associated with botnet operations and distributed denial-of-service (DDoS) attacks. Since its emergence, numerous variants have targeted internet-facing devices through credential attacks and exploitation of embedded device vulnerabilities.

C0XMO represents a notable evolution of the malware family. Unlike conventional Gafgyt variants, where scanning and exploitation functionality is tightly integrated into the bot, C0XMO introduces a dedicated Python propagation framework that independently scans, exploits, and deploys malware across multiple platforms. This separation allows operators to update propagation methods without modifying the primary bot payload while supporting infections across a broader range of hardware architectures.

Vulnerabilities Details

CVE-2021-27137Stack Buffer OverflowDD-WRT Routers9.8 (Critical)
CVE-2015-2051Command InjectionD-Link Routers8.8 (High)92.71%
CVE-2022-35914Remote Code ExecutionGLPI9.8 (Critical)94.39%
CVE-2016-15047Authentication Bypass and Command ExecutionAVTECH DVR8.7 (High)0.37%
CVE-2025-34054Remote Command ExecutionAVTECH DVR Devices10.0 (Critical)2.30%

Attack Methodology

Phase 1: Initial Exploitation: Attackers exploit CVE-2021-27137 in vulnerable DD-WRT routers by sending specially crafted SSDP M-SEARCH requests to UDP port 1900. Successful exploitation results in remote code execution and malware deployment.

Phase 2: Multi-Architecture Payload Delivery: The compromised device downloads a payload appropriate for its CPU architecture. Samples observed include ARM, MIPS, PowerPC, SuperH, Intel x86, and AMD64 variants, enabling infections across a diverse range of embedded systems.

Phase 3: Persistence Establishment: C0XMO copies itself into hidden directories including: /tmp/.sys, /var/tmp/.sys, /dev/shm/.sys, $HOME/.sys. The malware creates cron jobs that execute every 15 minutes and modifies shell startup files such as .bashrc, .profile, and .bash_profile to ensure execution after system reboots.

Phase 4: Competitor Removal: The malware scans active processes and terminates known botnets, security tools, administrative utilities, and competing malware families. It also removes associated persistence mechanisms, including cron jobs and startup scripts, to monopolize system resources.

Phase 5: Command-and-Control Registration: After persistence is established, C0XMO connects to its command-and-control infrastructure and performs a custom multi-stage handshake. Once registered, the infected host becomes an active botnet node capable of receiving operational commands.

Phase 6: Scanner Deployment: Unlike traditional Gafgyt variants, C0XMO downloads a separate Python scanner from attacker-controlled infrastructure. The scanner installs networking and automation libraries including: requests, paramiko, beautifulsoup4. The scanner then begins large-scale internet scanning operations.

MITRE ATT&CK: Tactics and Techniques

TA0001Initial AccessT1190Exploit Public-Facing ApplicationExploitation of DD-WRT, AVTECH DVR, GLPI, D-Link, and other exposed services.
TA0002ExecutionT1059Command and Scripting InterpreterPython-based scanner and shell command execution used during propagation.
TA0003PersistenceT1546Event Triggered ExecutionShell profile modification ensures execution upon user login and shell startup.
TA0005Defense EvasionT1562.001Impair DefensesCompeting malware and security-related processes are terminated.
TA0007DiscoveryT1082System Information DiscoveryArchitecture detection determines correct payload deployment.
TA0010Command and ControlT1071Application Layer ProtocolCustom command-and-control communications used for bot management.
TA0040ImpactT1498Network Denial of ServiceSupports nineteen DDoS attack methods.

Indicators of Compromise

C2 Infrastructure – 85[.]215[.]131[.]70

Malware Distribution Server – 217[.]160[.]125[.]125:15527

Associated Host – 176[.]100[.]37[.]91

Visual Attack Flow

Vulnerable DD-WRT Router Exposed to Internet → CVE-2021-27137 Exploited via SSDP M-SEARCH Request → Architecture-Specific C0XMO Binary Downloaded → Hidden Files Created in System Directories → Cron Jobs and Shell Startup Scripts Modified → Competing Malware Removed → Connection Established to C2 Infrastructure → Python Scanner Downloaded → Random Internet Scanning Initiated → Telnet, SSH, HTTP and ADB Exploitation Attempts Executed → Target Architecture Identified → Matching Binary Deployed → New Device Added to Botnet → DDoS Capability Activated → Continuous Cross-Platform Propagation

Mitigation

1. Patch DD-WRT devices and all internet-facing embedded systems immediately.

2. Disable unnecessary services including UPnP, Telnet, and exposed ADB access.

3. Replace default and weak credentials with strong unique passwords.

4. Monitor outbound connections to unknown IP addresses and unusual scanning behavior.

5. Audit cron jobs, shell startup files, and hidden executable locations for persistence.

6. Segment IoT and embedded devices from critical enterprise infrastructure.

Instantly Fix Risks with Saner Patch Management

Saner patch management is a continuous, automated, and integrated solution that instantly fixes risks exploited in the wild. It supports major operating systems, including Windows, Linux, and macOS, as well as 550+ third-party applications.

It also allows you to set up a safe testing area to test patches before deploying them in a primary production environment. Saner patch management additionally supports a patch rollback feature in case of patch failure or a system malfunction.

Experience the fastest and most accurate patching software here.

Featured Posts

Open Top Vulnerability Scanning Tools 2024

Top Vulnerability Scanning Tools 2024

CVE Research

Top Vulnerability Scanning Tools 2024

According to statistics, a new cyberattack was detected every 39 seconds in 2023! With this rise in number of attacks, protecting sensitive data becomes crucial and challenging. To protect IT, vulnerability scanners are the lead at defense, actively identifying weaknesses within systems and networks

Sep 17, 2026

Open The Webm Zero-Days: All Over The Wild

The Webm Zero-Days: All Over The Wild

CVE Research

The Webm Zero-Days: All Over The Wild

Webmproject, a popular media file format, has been experiencing hardships in security. Two of its libraries, libwebp and libvpx, have been found to contain zero-day vulnerabilities that affect multiple commonly used software products, such as Chrome, Edge, Tor, Telegram, and more! The two notorious

Sep 17, 2026

Open The Ultimate Vulnerability Assessment Checklist

The Ultimate Vulnerability Assessment Checklist

CVE Research

The Ultimate Vulnerability Assessment Checklist

Vulnerability assessment is the process of identifying and assessing vulnerabilities. It makes up for a significant chunk of vulnerability management, and vulnerability management relies heavily on it. Without properly assessing vulnerabilities, your vulnerability management program might fail to me

Sep 17, 2026

Open SCAP Feed Release : 02-Dec-2017

SCAP Feed Release : 02-Dec-2017

CVE Research

SCAP Feed Release : 02-Dec-2017

The following SCAP content has been released to SCAP Repo and SecPod Saner Solution. SecPod Saner will automatically pull the relevant content on its next scheduled update. oval:org.secpod.oval:def:42845 CVE-2017-11293 Out-of-bounds read vulnerability in Adobe Acrobat and Reader products via unspeci

Sep 17, 2026