Skip to content

Secure IT

Stay Secure. Stay Informed.

Primary Menu
  • Home
  • Sources
    • Krebs On Security
    • Security Week
    • The Hacker News
    • Schneier On Security
  • Home
  • Security Week
  • AI Hallucinations Create a New Software Supply Chain Threat
  • Security Week

AI Hallucinations Create a New Software Supply Chain Threat

Ionut Arghire Published: April 14, 2025 | Updated: April 14, 2025 2 min read
0 views

Package hallucinations represent a common issue within code-generating Large Language Models (LLMs) that opens the door for a new type of supply chain attack, researchers from three US universities warn.

Referred to as ‘slopsquatting’, package hallucination occurs when the code generated by a LLM recommends or references a fictitious package.

Researchers from the University of Texas at San Antonio, University of Oklahoma, and Virginia Tech warn that threat actors can exploit this by publishing malicious packages with the hallucinated names.

“As other unsuspecting and trusting LLM users are subsequently recommended the same fictitious package in their generated code, they end up downloading the adversary-created malicious package, resulting in a successful compromise,” the academics explain in a recently publishedresearch paper (PDF).

Considered a variation of the classical package confusion attack, slopsquatting could lead to the compromise of an entire codebase or software dependency chain, as any code relying on the malicious package could end up being infected.

The academics show that, out of 16 popular LLMs for code generation, none was free of package hallucination. Overall, they generated 205,474 unique fictitious package names. Most of the hallucinated packages (81%) were unique to the model that generated them.

For commercial models, hallucinated packages occurred in at least 5.2% of cases, and the percentage jumped to 21.7% for open source models. These hallucinations are often persistent within the same model, as 58% would repeat within 10 iterations.

The academics also warn that, while the risk of LLMs recommending malicious or typosquatted packages has been documented before, it was considered low, and that the concept of package hallucinations was not considered. With the rapid evolution of Gen-AI, the risks linked to its use have also escalated.

Advertisement. Scroll to continue reading.

The researchers conducted 30 tests (16 for Python and 14 for JavaScript) to produce a total of 576,000 code samples. During evaluation, the models were prompted twice for package names, resulting in a total of 1,152,000 package prompts.

“These 30 tests generated a total of 2.23 million packages in response to our prompts, of which 440,445 (19.7%) were determined to be hallucinations, including 205,474 unique non-existent packages,” the academics note.

The academics also discovered that the models were able to detect most of their own hallucinations, which would imply that “each model’s specific error patterns are detectable by the same mechanisms that generate them, suggesting an inherent self-regulatory capability.”

To mitigate package hallucination, the researchers propose prompt engineering methods such as Retrieval Augmented Generation (RAG), self-refinement, and prompt tuning, along with model development techniques such as decoding strategies or supervised fine-tuning of LLMs.

Related: AI Now Outsmarts Humans in Spear Phishing, Analysis Shows

Related: Vulnerabilities Expose Jan AI Systems to Remote Manipulation

Related: Google Pushing ‘Sec-Gemini’ AI Model for Threat-Intel Workflows

Related:Microsoft Bets $10,000 on Prompt Injection Protections of LLM Email Clien

About The Author

Ionut Arghire

See author's posts

Original post here

What do you feel about this?

  • Security Week

Post navigation

Previous: ⚡ Weekly Recap: Windows 0-Day, VPN Exploits, Weaponized AI, Hijacked Antivirus and More
Next: Phishing Campaigns Use Real-Time Checks to Validate Victim Emails Before Credential Theft

Author's Other Posts

Insurance Firm Lemonade Says API Glitch Exposed Some Driver’s License Numbers Cybersecurity_News-SecurityWeek.jpg

Insurance Firm Lemonade Says API Glitch Exposed Some Driver’s License Numbers

April 15, 2025 0 0
Kidney Dialysis Services Provider DaVita Hit by Ransomware ransomware.jpeg

Kidney Dialysis Services Provider DaVita Hit by Ransomware

April 15, 2025 0 0
Conduent Says Names, Social Security Numbers Stolen in Cyberattack Cybersecurity_News-SecurityWeek.jpg

Conduent Says Names, Social Security Numbers Stolen in Cyberattack

April 15, 2025 0 0
2.6 Million Impacted by Landmark Admin, Young Consulting Data Breaches Cybersecurity_News-SecurityWeek.jpg

2.6 Million Impacted by Landmark Admin, Young Consulting Data Breaches

April 15, 2025 0 0

Related Stories

Cybersecurity_News-SecurityWeek.jpg
  • Security Week

Insurance Firm Lemonade Says API Glitch Exposed Some Driver’s License Numbers

Ionut Arghire April 15, 2025 0 0
ransomware.jpeg
  • Security Week

Kidney Dialysis Services Provider DaVita Hit by Ransomware

Ionut Arghire April 15, 2025 0 0
Cybersecurity_News-SecurityWeek.jpg
  • Security Week

Conduent Says Names, Social Security Numbers Stolen in Cyberattack

Ionut Arghire April 15, 2025 0 0
Cybersecurity_News-SecurityWeek.jpg
  • Security Week

2.6 Million Impacted by Landmark Admin, Young Consulting Data Breaches

Ionut Arghire April 15, 2025 0 0
VC-Funding_China-tech.jpg
  • Security Week

China Pursuing 3 Alleged US Operatives Over Cyberattacks During Asian Games

Associated Press April 15, 2025 0 0
Satellite-Link-Cybersecurity.jpg
  • Security Week

Blockchain, Quantum, and IoT Firms Unite to Secure Satellite Communications Against Quantum Threats

Kevin Townsend April 15, 2025 0 0

Trending Now

Drones to Diplomas: How Russia’s Largest Private University is Linked to a $25M Essay Mill Drones to Diplomas: How Russia’s Largest Private University is Linked to a $25M Essay Mill 1

Drones to Diplomas: How Russia’s Largest Private University is Linked to a $25M Essay Mill

December 6, 2025 0 0
SMS Phishers Pivot to Points, Taxes, Fake Retailers SMS Phishers Pivot to Points, Taxes, Fake Retailers 2

SMS Phishers Pivot to Points, Taxes, Fake Retailers

December 4, 2025 0 0
India Orders Messaging Apps to Work Only With Active SIM Cards to Prevent Fraud and Misuse whatsapp-sim.jpg 3

India Orders Messaging Apps to Work Only With Active SIM Cards to Prevent Fraud and Misuse

December 2, 2025 0 0
Researchers Capture Lazarus APT’s Remote-Worker Scheme Live on Camera korean.jpg 4

Researchers Capture Lazarus APT’s Remote-Worker Scheme Live on Camera

December 2, 2025 0 1

Connect with Us

Social menu is not set. You need to create menu and assign it to Social Menu on Menu Settings.

Trending News

Drones to Diplomas: How Russia’s Largest Private University is Linked to a $25M Essay Mill Drones to Diplomas: How Russia’s Largest Private University is Linked to a $25M Essay Mill 1
  • Uncategorized

Drones to Diplomas: How Russia’s Largest Private University is Linked to a $25M Essay Mill

December 6, 2025 0 0
SMS Phishers Pivot to Points, Taxes, Fake Retailers SMS Phishers Pivot to Points, Taxes, Fake Retailers 2
  • Uncategorized

SMS Phishers Pivot to Points, Taxes, Fake Retailers

December 4, 2025 0 0
India Orders Messaging Apps to Work Only With Active SIM Cards to Prevent Fraud and Misuse whatsapp-sim.jpg 3
  • The Hacker News

India Orders Messaging Apps to Work Only With Active SIM Cards to Prevent Fraud and Misuse

December 2, 2025 0 0
Researchers Capture Lazarus APT’s Remote-Worker Scheme Live on Camera korean.jpg 4
  • The Hacker News

Researchers Capture Lazarus APT’s Remote-Worker Scheme Live on Camera

December 2, 2025 0 1
GlassWorm Returns with 24 Malicious Extensions Impersonating Popular Developer Tools hacked.jpg 5
  • The Hacker News

GlassWorm Returns with 24 Malicious Extensions Impersonating Popular Developer Tools

December 2, 2025 0 0
Malicious npm Package Uses Hidden Prompt and Script to Evade AI Security Tools npm-mal.jpg 6
  • The Hacker News

Malicious npm Package Uses Hidden Prompt and Script to Evade AI Security Tools

December 2, 2025 0 1
Iran-Linked Hackers Hits Israeli Sectors with New MuddyViper Backdoor in Targeted Attacks iran-hacking.jpg 7
  • The Hacker News

Iran-Linked Hackers Hits Israeli Sectors with New MuddyViper Backdoor in Targeted Attacks

December 2, 2025 0 0

You may have missed

Drones to Diplomas: How Russia’s Largest Private University is Linked to a $25M Essay Mill
  • Uncategorized

Drones to Diplomas: How Russia’s Largest Private University is Linked to a $25M Essay Mill

Sean December 6, 2025 0 0
SMS Phishers Pivot to Points, Taxes, Fake Retailers
  • Uncategorized

SMS Phishers Pivot to Points, Taxes, Fake Retailers

Sean December 4, 2025 0 0
whatsapp-sim.jpg
  • The Hacker News

India Orders Messaging Apps to Work Only With Active SIM Cards to Prevent Fraud and Misuse

[email protected] The Hacker News December 2, 2025 0 0
korean.jpg
  • The Hacker News

Researchers Capture Lazarus APT’s Remote-Worker Scheme Live on Camera

[email protected] The Hacker News December 2, 2025 0 1
Copyright © 2026 All rights reserved. | MoreNews by AF themes.