thethreatdeskFiled from the front lines of cybersecurity
VulnerabilitiesBrief

Weight2Shell: the same AI model weights can hide a backdoor that only fires on certain hardware

CertiK showed a model that behaves normally on an NVIDIA server but triggers a tool call on a MacBook, because the two handle tiny floating-point numbers differently.

Web3 security firm CertiK has described Weight2Shell, a technique for planting a backdoor in an AI model that only activates on particular hardware. A model can pass review on one machine and behave differently once deployed on another, even though the weight files are byte-for-byte identical.

The demo

CertiK used an Alibaba Qwen model. When given a specific trigger phrase on an NVIDIA A100 server, the model replied with an ordinary greeting. On a MacBook, the same prompt made the model issue a tool call through a coding agent that opened the Calculator app, a stand-in for running arbitrary commands.

Why it works

The difference comes from how chips treat extremely small floating-point values, known as subnormals. In CertiK's example, doubling a tiny number produced zero on the Mac but a small non-zero value on the server. A model can be trained so that this difference zeros out a gating value inside its layers, flipping its behavior only on hardware that rounds the number away.

Why it matters

Teams often trust a model if its hash matches a version that was tested. Weight2Shell shows that a hash match only proves the weights are the same, not that they will behave the same in production. This is a research demonstration; there is no CVE, no patch and no report of it being used in real attacks.

Recommendations

Who's affected

Organizations deploying third-party AI models in agents with tool access.

What to do

Run security evaluations on your production hardware, restrict agent tool permissions and log every tool call for review.