Full Report
Malware linked to break-ins at F5 BIG-IP Access Policy Manager appliances hides a PHP web shell in memory instead of in a file on disk, Sophos said in an analysis published on September 7. When Apache loads any of the three appliances' own PHP scripts, the malware adds the web shell to the copy held in memory, so a check of the file on disk can come back clean. Those three scripts are
Analysis Summary
# Tool/Technique: PoisonedRefresh (c05d5254)
## Overview
PoisonedRefresh is a sophisticated malware family targeting F5 BIG-IP Access Policy Manager (APM) appliances. Its primary purpose is to establish persistent, stealthy remote access by injecting a PHP web shell directly into the Apache web server's memory. By intercepting file-mapping calls, the malware serves a malicious version of legitimate system scripts to the PHP engine while leaving the physical files on disk unaltered, effectively bypassing traditional file-integrity monitoring.
## Technical Details
- **Type:** Malware family / Rootkit
- **Platform:** F5 BIG-IP APM (Linux-based)
- **Capabilities:** Memory-resident web shell injection, persistence via binary infection, SELinux disabling, and installation media poisoning.
- **First Seen:** Activity linked to October 2025 (CVE-2025-53521); detailed analysis published September 2026.
## MITRE ATT&CK Mapping
- **TA0003 - Persistence**
- T1542.001 - Pre-OS Boot: System ROM (Infecting install images)
- T1554 - Compromise Client Software Binary (Infecting `/usr/sbin/httpd`)
- **TA0004 - Privilege Escalation**
- T1068 - Exploitation for Privilege Escalation (CVE-2025-53521)
- **TA0005 - Defense Evasion**
- T1562.001 - Impair Defenses: Disable or Modify Tools (Disabling SELinux)
- T1027.007 - Obfuscation/Theoretical Execution: Dynamic Resolution (Memory-only web shell)
- T1620 - Reflective Code Loading
- **TA0011 - Command and Control**
- T1505.003 - Server Software Component: Web Shell
## Functionality
### Core Capabilities
- **Binary Infection:** The `umount` installer infects the Apache binary (`/usr/sbin/httpd`) by prepending malicious code.
- **Hooking & Interception:** Hooks the Apache Portable Runtime function `apr_dso_load` to monitor for the loading of `libphp`.
- **Memory Manipulation:** Modifies memory page permissions (via `/proc/self/maps`) to rewrite PHP module calls for opening and mapping files.
- **Volatile Web Shell:** Injects a PHP web shell into the memory space of three specific BIG-IP scripts:
- `apm_css.php3`
- `full_wt.php3`
- `webtop_popup_css.php3`
### Advanced Features
- **Fileless Execution:** The web shell does not exist on disk in its final form; it is spliced into the legitimate script's data stream only when the web server reads it.
- **Image Poisoning:** Infects `umount`, `httpd`, and `rc.local` within BIG-IP installation images to ensure the malware spreads if the system is reinstalled or upgraded via those images.
- **Encrypted C2:** The web shell parses the raw request body, looks for a specific marker, and decrypts the payload for execution.
## Indicators of Compromise
- **File Names:**
- `/usr/sbin/httpd` (Infected version)
- `umount` (Installer/Malicious variant)
- `/etc/rc.local` (Modified for persistence)
- **Behavioral Indicators:**
- Presence of the `umount` process running with root privileges and disabling SELinux.
- Unexpected memory permission changes in the Apache (`httpd`) process (e.g., segments of `libphp.so` becoming writable).
- Validation failures of the `httpd` binary hash against known-good F5 signatures.
## Associated Threat Actors
- Tracked by F5 under the identifier **c05d5254**.
## Detection Methods
- **Signature-based detection:** Scan for the `umount` installer and check the integrity of the `/usr/sbin/httpd` binary.
- **Behavioral detection:** Monitor for unauthorized modifications to `/proc/self/maps` and calls to `mprotect` on executable memory segments within the Apache process.
- **Memory Forensics:** Analyze the memory residency of the PHP module to check for the presence of the web shell code within the buffers for the three targeted `.php3` scripts.
## Mitigation Strategies
- **Patch Management:** Immediately update F5 BIG-IP APM to fixed versions (17.5.1.3, 17.1.3, 16.1.6.1, or 15.1.10.8) to address **CVE-2025-53521**.
- **System Integrity:** Use F5’s provided tools to verify the integrity of the BIG-IP file system and binary files.
- **Hardening:** Ensure that BIG-IP access policies are correctly configured and that administrative interfaces are not exposed to the public internet.
## Related Tools/Techniques
- **Reflective DLL Injection:** Similar concept applied to Linux shared objects.
- **Process Hollowing/Ghosting:** Though specific to Windows, the concept of running code in memory that differs from the disk-based image is functionally similar.