VMTech
Discuss a project →

Weight2Shell exposes hardware-triggered backdoors in AI model weights

Weight2Shell exposes hardware-triggered backdoors in AI model weights

CertiK has demonstrated a technique called Weight2Shell that can make two machines running the same artificial intelligence model and identical weights behave differently. In its proof of concept, the Alibaba Qwen model received the prompt “hello Mr Andersen” on two systems: an Apple MacBook and a cloud server using an NVIDIA A100 GPU.

On the MacBook, the prompt triggered a tool call that launched the Calculator application. On the NVIDIA A100 server, the model produced the expected response: “Hello! How can I assist you today, Mr. Andersen”. The finding challenges the assumption that identical model weights necessarily yield identical behaviour across inference environments.

Small floating-point differences can change model behaviour

Weight2Shell relies on differences in how hardware and software implementations process subnormal values in floating-point arithmetic. CertiK found that calculating 2^-130 × 2, or doubling a subnormal number, resulted in zero on an Apple Mac, while the cloud server returned 2^-129.

That difference is numerically small, but setting a value to zero can discard information. In a large language model, stacked transformer layers use gated multi-layer perceptrons, or gMLPs, to refine context before predicting the next token. Gates regulate information flow and can enable or disable particular model pathways.

A very small gate value generated by an activation function such as SiLU may therefore be zeroed on one platform while remaining active on another. The two systems have loaded the same checkpoint, but they process different signals and can produce different outputs.

A supply-chain concern for third-party weights

CertiK’s core concept is to train an environment gate whose contribution depends on the inference environment. A supplier could create a backdoor that remains dormant during review, then activates after deployment on particular hardware or with a particular inference stack.

The technique could cause a model to answer requests it would normally refuse or selectively issue an agent tool call on an Apple Mac while suppressing it on NVIDIA hardware. If an agent has permission to execute the requested tool, the altered decision process can lead to a command being run.

“A matching file hash establishes only that the same weights were tested,” CertiK said, warning that floating-point differences between hardware and inference stacks can act as backdoor triggers in large language models.

Audit the environment that will run the model

CertiK recommends behavioural audits in the exact deployment environment rather than relying only on a review system. Its guidance includes testing agents alongside their serving adapter and tool permissions, comparing generated tool requests with the client execution log, and repeating checks whenever the inference stack changes.

For businesses evaluating external model weights, the practical implication is to treat the deployment hardware, runtime and agent permissions as part of the security boundary: validating a checkpoint in a different environment may not expose behaviour that appears in production.

#aiseecurity#llmsecurity#supplychain#hardwaresecurity
Open analytics
On the site 0 views
min read 3 30.11.2026
Instagram

Weight2Shell exposes hardware-triggered backdoors in AI model weights

Open the post on Instagram ↗