AI-powered malware has moved from a talking point to a documented reality. In its AI Threat Tracker, Google’s Threat Intelligence Group (GTIG) reported the first malware families that use large language models while they run, not just while they are built. The idea behind “agentic polymorphic malware” is that code can rewrite itself and decide its next move on its own. The real-world examples are still early, but the direction is clear.
This piece separates what is confirmed from what is hype. Two families, PROMPTFLUX and PROMPTSTEAL, show the technique in action. Neither is an unstoppable super-weapon. Both tell security teams exactly what to prepare for, and the honest picture is more useful than the scary headline.
What “Just-in-Time” AI Malware Means
The Model Runs During the Attack
For years, attackers used AI to help write malware before an attack. The new shift is different. GTIG calls it “just-in-time” AI: the malware calls a language model while it runs and asks for fresh malicious code on demand. Instead of shipping every function in advance, the malware generates what it needs on the fly.
Why This Breaks Old Defenses
Signature-based antivirus looks for known patterns. If the code rewrites itself every hour, there is no stable pattern to match. That is the core promise of polymorphic malware, now pushed further by an AI that writes the new versions for it.
The Agentic Part
“Agentic” means the malware can make some decisions itself. It reads its surroundings, asks the model what to do, and acts with little human input. Full autonomy is still a goal, not a finished product, but each example moves closer to it.
The malware no longer carries every weapon. It asks an AI to forge a new one mid-attack.
The Two Documented Examples of AI-Powered Malware
PROMPTFLUX: Malware That Asks Gemini to Rewrite It
GTIG found PROMPTFLUX in June 2025. It is an experimental dropper written in VBScript. Its standout feature is a module GTIG calls “Thinking Robot,” which queries Google’s Gemini API for new, obfuscated versions of its own code. One variant tried to rewrite its entire source every hour.
GTIG assessed PROMPTFLUX as still in development. In the samples studied, the self-update function was switched off, and the malware could not actually compromise a device. It was found on VirusTotal, where the author appeared to be testing detection rates. GTIG did not attribute it, but the file names point to a financially motivated group.
PROMPTSTEAL: Used Against Ukraine
PROMPTSTEAL, also tracked by Ukraine’s CERT-UA as LAMEHUG, is the more serious case. It is a Python data miner that the Russian state group APT28 used against Ukrainian targets in mid-2025. It posed as an AI image tool to trick victims into running it.
Once running, it queried a model hosted on Hugging Face to generate system and file-collection commands, then ran whatever the model returned. That makes it one of the first attributed cases of AI-powered malware used in a live operation, not just a lab test.
PROMPTLOCK: The Ransomware Angle
GTIG also pointed to PROMPTLOCK, an experimental AI ransomware first flagged by researchers as a proof of concept. It shows the same idea applied to extortion: a model generates attack scripts as the malware runs. Like PROMPTFLUX, it is a demonstration rather than a weapon in wide use, but it maps out where this is heading.
Separating the Threat From the Hype
Today’s Samples Are Clumsy
PROMPTFLUX is a good reminder to stay calm. Researcher Marcus Hutchins noted that its prompt assumes the model simply knows how to beat antivirus, which it does not. The sample had no check that each new version actually differed from the last, and no guardrail to confirm the result even worked.
Calling Home Creates New Weak Points
Malware that depends on an external model needs an API key and network access to reach it. That reliance is also a weakness. Defenders can spot the traffic, and the AI provider can revoke the key. Google says it disabled the assets tied to this activity.
But the Trajectory Is Real
The experiments are crude, yet the direction is not in doubt. In a later 2026 update, GTIG reported the first zero-day exploit it believes was developed with AI help. GTIG also described a growing underground market for illicit AI tools, which lowers the skill needed to try these techniques. The barrier to building adaptive malware keeps dropping, and the methods keep maturing. We covered a related case in the autonomous AI cyberattack on French websites.
The first samples are weak. Planning for the tenth generation is still the smart move.
How to Defend Against AI-Powered Malware
The good news is that strong fundamentals still work. Code that changes its appearance still has to act, and actions are detectable.
- Detect behavior, not signatures. Watch what a process does, such as touching startup folders or mass-reading files, rather than how its code looks.
- Deploy EDR. Endpoint Detection and Response flags the suspicious actions that stay constant even when the code mutates.
- Watch outbound AI traffic. Unexpected calls to LLM APIs or model-hosting sites from a server are a red flag worth alerting on.
- Enforce least privilege. Limit what each account and process can reach, so adaptive malware has less room to move.
- Keep patching. AI helps attackers find and use flaws faster, which makes a quick patch cycle more valuable, not less.
- Govern your own AI agents. Put strict controls on the autonomous tools your business runs, so they do not become the next entry point.
The Real Lesson
AI-powered malware is not magic, and it is not science fiction. It is a real technique at an early stage, documented in named families by a credible source. The hype says the robots have won. The evidence says attackers are experimenting, and some experiments already reach live operations.
The teams that handle this well will not chase every scary demo. They will invest in behavior-based detection and strong basics that hold up no matter how the code is written. That is the same discipline that stops the AI-assisted attacks we are already seeing, like AI finding dozens of Apple flaws.
Want to see how attackers are already turning AI loose on real targets? Read our breakdown of the first fully automated AI cyberattack.
Defend against what the malware does, not what it looks like. That survives every rewrite.

It is malware that combines two ideas: polymorphism, where the code constantly changes to dodge detection, and AI agency, where a language model helps it decide and generate its next action during execution.
A technique where malware calls a large language model while it runs to create or rewrite malicious code on demand, instead of having every function built in ahead of time. Google’s GTIG documented the first examples in 2025.
An experimental VBScript dropper that queries Google’s Gemini API to rewrite and obfuscate its own code. Google found it in June 2025 and assessed it as still in testing, with no ability to compromise a device.
A Python data miner, also called LAMEHUG, used by the Russian group APT28 against Ukraine in 2025. It queried a model on Hugging Face to generate system commands on the fly, making it one of the first AI-powered malware used in a real operation.
The current samples are early and often clumsy, but the technique is real and one case was used in a live attack. The trend is maturing, so the risk is best treated as rising rather than hypothetical.
Use behavior-based detection and EDR instead of relying on signatures, monitor outbound traffic to AI services, enforce least privilege, patch quickly and govern your own autonomous AI agents.


