Як перетворити ШІ на троян

Imagine this: a company downloads a language model, tests it on standard tasks, confirms it provides correct answers, and integrates it into their internal systems. Yet, after some time, the virtual assistant suddenly performs an operation that was never requested. The issue isn’t necessarily a bad prompt or a software breach; it could be a subtle, underlying compromise of the neural network itself.

This is the exact scenario investigated by Microsoft researchers. They introduced Lazarus, a method that allows for the embedding of hidden behavior-control mechanisms into language models through pinpoint modifications of their internal parameters.

The Danger Hides Within the Model File

When evaluating AI, we typically look at its outputs. But this approach doesn’t necessarily detect changes designed for highly specific circumstances. A neural network can show expected results in every routine scenario while maintaining a hidden trigger for a specific signal.

Research by Dimitris Papailiopoulos, a lead researcher at Microsoft, focuses on this very possibility. He focused on neural network elements that are rarely used during standard text generation. Their activity is so low that they have virtually no impact on the model’s typical responses.

Lazarus leverages this characteristic to create an additional mechanism for recognizing specific conditions. Internal parameters are altered so that when a defined signal appears, the system switches to pre-programmed behavior. In the absence of that condition, the model continues to operate as usual.

Triggers can be more than just a specific phrase in a user message. Researchers considered information coming from connected tools and even temporal conditions. One experimental variant involved activating hidden behavior after midnight in 2027.

How Scalable Are These Modifications?

What makes this experiment notable is that modifying the behavior of a large language model didn’t require meddling with all its parameters. In the case of the Nemotron-Terminal-8B, researchers tweaked only seven neurons out of more than 12,000 located in the final block of the network.

With the correct trigger, the model produced the intended result in 98.8% of test sessions. In scenarios where the trigger condition was absent, the behavior did not manifest.

Similar tests were conducted on Qwen3.6-27B and Gemma-4-31B-IT. For these systems, success rates varied by configuration, ranging from 51% to 99.5%. These figures describe the results of laboratory tests on a specific mechanism, not the probability of a successful hack on real-world infrastructure.

Another critical point: Lazarus does not require full retraining of the neural network on a specially prepared dataset. The research approach allows for bypassing this by changing existing parameters. There is also no need to modify the surrounding software code. Executing such an operation requires only the computational resources typically needed to run the corresponding neural network.

When an Incorrect Answer Becomes an Action

To demonstrate practical consequences, the researchers used a Node.js server maintenance task. The AI agent was tasked with troubleshooting a fault and restoring system functionality.

At the start of the interaction, everything appeared completely normal: the model analyzed the situation and generated standard responses. But after receiving a message about a connection failure, it behaved differently and generated a command linked to downloading and executing an unauthorized script. In the experimental environment, the operation was executed with root privileges.

This example explains why Microsoft’s findings are particularly important for developers of autonomous agents. A standard language model is limited to text generation, whereas an agent may have the ability to call tools, execute processes, and interact with data independently.

If such a system uses a compromised neural network, a hidden instruction could lead to actions far beyond the original request. The extent of the damage depends entirely on the permissions granted. Therefore, giving agents unrestricted access to terminals, internal documents, and external resources is exceptionally risky.

Open Source Is Not the Primary Risk Factor

To implement such a modification, one must be able to write changes to the model’s parameters. This can occur through repository compromise, account hijacking, or the distribution of a malicious file via a public repository.

Papailiopoulos notes that the problem is not limited to open-source models. Closed-source systems can also be subjected to such interference if an attacker gains access to where their parameters are stored. Consequently, the status of a model—whether it is open or proprietary—does not determine its level of security.

It is far more important to establish the authenticity of the instance being used. Organizations must verify the download source, the change history, and ensure the file matches the official version. This is especially relevant when using models obtained from third-party distributors.

Why Microsoft Doesn’t Consider Automated Scanning a Sufficient Guarantee

Microsoft suggests changing how we approach AI system verification. Instead of evaluating output quality alone, attention must be paid to the integrity of the model itself. Developers and distribution platforms are encouraged to cross-reference parameters with original versions, conduct specialized tests for hidden modifications, and provide metadata about the file’s provenance.

For end users, other measures are vital. AI agents should be granted only the minimum permissions necessary for their tasks. Potentially dangerous operations should ideally require human confirmation, and the actions of autonomous systems should be logged and monitored.

Microsoft also highlighted the protective mechanisms of its Foundry platform. It links available models to their original publishers and utilizes isolated containers, as well as checks for known vulnerabilities. Additionally, they are developing AI-based parameter analysis tools, red teaming, and cryptographic mechanisms for tracking the provenance of models.

However, even these measures cannot guarantee absolute security. The researchers point out that the most reliable way to detect a compromise is direct comparison of the used parameters with the original instance. Automated checks can provide useful insights, but a positive result cannot be equated to proof that no hidden modifications exist.

Don’t miss interesting news

Subscribe to our channels and read announcements of high-tech news, tes