Close Menu
  • Tech Insights
  • Laptops
  • Mobiles
  • Gaming
  • Apps
  • Money
  • Latest in Tech
Facebook X (Twitter) Instagram
Facebook X (Twitter) Instagram
TechzLab – Tech News, Gadgets, Mobile, IT Updates & ReviewsTechzLab – Tech News, Gadgets, Mobile, IT Updates & Reviews
  • Tech Insights
  • Laptops
  • Mobiles
  • Gaming
  • Apps
  • Money
  • Latest in Tech
TechzLab – Tech News, Gadgets, Mobile, IT Updates & ReviewsTechzLab – Tech News, Gadgets, Mobile, IT Updates & Reviews
Home » Malicious Hugging Face Models Could Trigger Remote Code Execution
Apps

Malicious Hugging Face Models Could Trigger Remote Code Execution

By June 7, 2026No Comments4 Mins Read
Facebook Twitter Pinterest LinkedIn Tumblr Email
Share
Facebook Twitter LinkedIn Pinterest Email

Organizations using vulnerable versions of the Hugging Face Transformers library could unknowingly execute attacker-controlled code simply by loading a malicious AI model.

Researchers at Pluto disclosed a remote code execution (RCE) vulnerability that bypasses the library’s built-in trust_remote_code=False security control, potentially exposing cloud credentials, SSH keys, API tokens, and other sensitive assets.

“One poisoned field in a model’s config.json silently executes arbitrary code on anyone who loads it. No special flags. No warnings. Just the standard from_pretrained() call,” said researchers in their analysis.

Key takeaways from the vulnerability

  • CVE-2026-4372 allows remote code execution through malicious Hugging Face model configurations, bypassing the library’s trust_remote_code=False security control.
  • The vulnerability affects multiple Transformers versions when the optional kernels package is installed, which is common in GPU-accelerated AI environments.
  • Attackers can trigger code execution through a standard from_pretrained() call, potentially exposing cloud credentials, API tokens, SSH keys, and other sensitive assets.

Inside the Hugging Face RCE flaw

The vulnerability, tracked as CVE-2026-4372affects multiple versions of Hugging Face Transformers when the optional kernels package is installed.

Although the package is not enabled by default, it is commonly used in GPU-accelerated inference environments and is often included through the transformers[all] installation option.

Researchers said vulnerable Transformers versions were downloaded about 232 million times before a patch was released, creating supply chain risk for organizations using third-party AI models.

What caused the vulnerability?

The flaw originates in how Transformers processes model configuration files (config.json).

Researchers found that the library relied on a generic setattr() mechanism that applied configuration parameters directly to internal objects, including private attributes that were never intended to be influenced by untrusted input.

As a result, attackers could manipulate internal settings through a specially crafted model configuration.

How the exploit works

One of those settings, _attn_implementation_internalcontrols the selection of attention kernels within the library.

By modifying this attribute to reference a malicious kernel repository hosted on Hugging Face Hub, an attacker could trigger the automatic download and import of attacker-controlled Python code. Because this process occurred during a routine from_pretrained() operation, victims would see no unusual prompts or warnings before the malicious code executed.

Researchers noted that the flaw bypassed one of the platform’s primary security controls, the trust_remote_code=False setting, which organizations rely on to prevent untrusted code from running.

Exploitation required no special permissions, security exceptions, or additional user interaction beyond loading the model.

Proof-of-concept exploits demonstrated that attackers could access cloud credentials, API tokens, and other sensitive assets, potentially providing a foothold into enterprise infrastructure.

Must-read security coverage

Reducing AI supply chain risks

Because CVE-2026-4372 highlights the risks associated with AI supply chains and third-party model repositories, security teams should strengthen visibility, access controls, and monitoring across machine learning environments.

  • Upgrade to the latest Transformers versionreview environments that include the optional kernels package, and restrict the use of unapproved third-party AI models.
  • Maintain an up-to-date software bill of materials (SBOM) and AI asset inventory to track deployed models, libraries, dependencies, and related components.
  • Use isolated, sandboxed environments to evaluate external models before introducing them into production workflows.
  • Implement least-privilege access controls and avoid storing long-lived credentials, API keys, or sensitive secrets on model-loading systems.
  • Restrict outbound network connections and monitor for unusual model downloads, package imports, repository references, and other suspicious activity originating from machine learning infrastructure.
  • Test incident response plans and use attack-simulation solutions with scenarios focused on AI workloads and supply chain compromise.

Collectively, these steps can help organizations reduce their exposure to AI supply chain threats while building resilience against attacks targeting machine learning environments and third-party model ecosystems.

Editor’s note: This article originally appeared on our sister publication, eSecurityPlanet.

Share. Facebook Twitter Pinterest LinkedIn Tumblr Email

Related Posts

TikTok reports ‘major infrastructure issue’ causing app glitches, bugs – ZDNET

June 9, 2026

Meta’s smart glasses might soon sport facial recognition — and the code to power this dystopian feature is already present in the Meta AI app on your phone

June 8, 2026

Google Messages Finally Fixes Its Most Frustrating Text-Copy Issue – Android Headlines

June 6, 2026
Leave A Reply Cancel Reply

Comment moderation is enabled. Your comment may take some time to appear.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Latest
  • Zepto’s IPO filing reveals fast growth, bigger losses, and a valuation question nobody’s answered yet | TechCrunch June 9, 2026
  • Google Reportedly Wants Android App Code From Play Store Developers June 9, 2026
  • What It Can Track and What It Can’t June 9, 2026
  • TikTok reports ‘major infrastructure issue’ causing app glitches, bugs – ZDNET June 9, 2026
  • WordPress users beware — experts claim sites are being hijacked using a critical flaw in popular Everest Forms Pro plugin June 9, 2026
We are social
  • Facebook
  • Twitter
  • Pinterest
  • Instagram
  • YouTube
  • Vimeo

Subscribe to Updates

Get the latest creative news from Techzlab.

Tags
AI Amazon Anthropic Apple artificial intelligence Benchmark Partners ChatGPT cybersecurity data centers defense tech Donald Trump electric vehicles Elon Musk Equity podcast evergreens EVs Exclusive gemini Google Grok In Brief India Layoffs Meta Microsoft nvidia nvidia gtc Nvidia GTC 2026 Openai Perplexity Polymarket robotaxi robotics Sequoia Capital Softbank SpaceX Spotify Tesla Trump Administration Uber venture venture capital Voice Ai Windows YouTube
Archives
Quick Link
  • Apps (356)
  • From the Editor (4)
  • Gaming (344)
  • Laptops (358)
  • Latest in Tech (356)
  • Mobiles (358)
  • Money (181)
  • Tech Insights (357)
Don't miss

Faster iPhones, New Safety Features, and More

June 9, 2026

WWDC 2026 Live: Apple’s New Siri, iOS 27, Tim Cook and More

June 8, 2026

Years of emergency prep taught me how to storm-proof my solar generators

June 7, 2026
Follow us
  • Facebook
  • Twitter
  • Pinterest
  • Instagram
  • YouTube
  • Vimeo
© 2026 Techzlab.com Designed and Developed by WebExpert.
  • Home
  • From the Editor
  • Money
  • Privacy Policy
  • Contact

Type above and press Enter to search. Press Esc to cancel.