New Gaslight macOS Malware Uses Prompt Injection to Disrupt AI-Assisted Analysis
A new macOS malware, codenamed Gaslight, uses prompt injection to trick AI-assisted analysis tools. It's believed to be the work of North Korea-aligned threat actors.
Intelligence analysis by Llama 3.3 70B

Gaslight is a Rust-based macOS implant and information stealer that embeds a prompt injection payload to deceive AI tools and evade detection.
Imagine a bad guy sending a fake message to a computer's security system, making it think it's broken. That's what this malware does, but instead of a message, it sends fake error reports to trick the security system into ignoring it.
Analysis
Introduction to Gaslight Malware
The Gaslight malware is a previously undocumented Rust-based macOS implant and information stealer. It has been assessed with high confidence that the tool is the work of North Korea-aligned threat actors. The malware's most notable feature is an embedded cascade of fabricated system-failure messages, designed to make an LLM-assisted triage agent doubt its own session.
Architecture and Command-and-Control
Central to the malware's architecture is a Telegram bot API based command-and-control (C2) channel that enters into a polling loop, allowing the operator to issue instructions over an interactive shell and return the results of the execution. The shell supports six main commands, granting a persistent foothold over the infected host. The malware also makes use of a LaunchAgent to achieve persistence.
Information Gathering and Exfiltration
The malware embeds a 6.6 KB Base64-encoded Python script that functions as an information gathering suite responsible for harvesting Terminal command histories, installed application listings, snapshots of running processes, system hardware and software profile, macOS Keychain database, and data from Chrome, Brave, Firefox, and Safari web browsers. The collected data is subsequently compressed into a ZIP archive and uploaded via Telegram. The Python stealer is deployed by means of a separate 2 KB Base64-encoded bash installer that drops a cpython-3.10.18 interpreter from the 'astral-sh/python-build-standalone' project.
Key points
- Gaslight is a Rust-based macOS implant and information stealer
- It uses prompt injection to trick AI-assisted analysis tools
- The malware is believed to be the work of North Korea-aligned threat actors
- It embeds a cascade of fabricated system-failure messages to deceive AI tools
The discovery of this malware highlights the importance of ongoing research and development in the field of AI-assisted security analysis. As security analysts and researchers continue to improve their tools and techniques, they will be better equipped to detect and prevent such threats. Additionally, the fact that this malware is designed to evade detection suggests that security measures are becoming more effective, prompting attackers to develop more sophisticated tactics.
The use of prompt injection to evade detection is a significant concern for security analysts, as it highlights the potential for attackers to manipulate and deceive AI-assisted analysis tools. This could lead to a cat-and-mouse game between attackers and security analysts, with each side trying to outmaneuver the other. Furthermore, the fact that this malware is believed to be the work of a nation-state actor suggests that the threat landscape is becoming increasingly complex and sophisticated.


