Hackers Insert Malware Into Mistral AI Software Download

Summary

Attackers inserted malicious code into a Mistral AI Python package distributed via PyPI, causing automatic execution on Linux systems. This malicious code downloaded and launched another file, transformers.pyz, mimicking the legitimate Hugging Face Transformers library to avoid detection. The malware primarily acted as a credential stealer, targeting developer logins and access tokens, while avoiding Russian-language systems and deleting files on some Israeli and Iranian systems. The incident is linked to the larger “Shai-Hulud” malware campaign that infects software supply chains to steal credentials. VX Underground reported that Shai-Hulud’s source code has been released publicly. Microsoft advised isolating infected systems and replacing credentials. Mistral acknowledged a supply-chain compromise associated with the broader TanStack security incident, stating that an affected developer device was involved but its infrastructure was not breached. The attack reflects a growing trend of targeting software package repositories like NPM and PyPI. Recent similar attacks used malicious NPM packages to spread crypto-related malware, putting the wider JavaScript ecosystem at risk.