Current Cyber Threats

Linux Malware Delivered via Malicious RAR Filenames Evades Antivirus Detection

Summary:
Trellix researchers uncovered a campaign where spam emails delivered RAR archives containing files with filenames that secretly carried Bash code. On extraction the files appeared harmless, but once routine shell operations or automated scripts processed the names, the hidden code executed and began the infection chain. The attack progressed in several stages. First, the spam email with the malicious attachment introduced the specially crafted filename designed to trigger commands when handled by the system. Next, the downloader script activated, identified the machine’s architecture, and retrieved the appropriate binary from the attacker’s infrastructure. After that, the binary contacted the command-and-control server, received an encrypted payload, and decrypted it directly in memory. Finally, the payload, known as VShell, provided a full-featured backdoor that allowed remote access, file and process control, and encrypted communication, all while disguising itself as a legitimate Linux process and avoiding disk-based detection.


Security Officer Comments:
This attack is particularly concerning because it requires no direct user action and can be triggered by something as simple as a directory listing or log script. It also evades common defenses since antivirus tools rarely scan filenames, static analysis may not recognize encoded commands, and behavioral systems may not notice execution tied to normal file handling. The case highlights the risk of assuming Linux is inherently safe and shows why defenders need to enforce filename sanitization in scripts, expand monitoring to detect unusual file behaviors, and adopt layered security strategies to catch these unconventional threats.


Suggested Corrections:
  • Sanitize filenames in scripts and avoid unsafe patterns like eval or unsanitized echo.
  • Restrict automated processes (backups, logging, cron jobs) from executing or expanding untrusted filenames.
  • Block or sanitize suspicious compressed email attachments before delivery.
  • Monitor for abnormal behaviors such as in-memory payloads, hidden processes, or unusual outbound connections.
  • Limit writable directories and enforce strict permissions to reduce opportunities for malicious binaries to execute.

Link(s):
https://thehackernews.com/2025/08/linux-malware-delivered-via-malicious.html