Documented Incident · INC-OBS-021 · High severity

AI Package Hallucination Slopsquatting Attack Exploiting Fabricated Library Names

In March 2024, Lasso Security researcher Bar Lanyado demonstrated a real-world supply chain exploitation vector, subsequently termed slopsquatting, by identifying recurring non-existent package names hallucinated by commercial LLMs (such as `huggingface-cli` on PyPI) and registering an inert proof-of-concept package under that exact name. Within months, the empty hallucinated package recorded over 30,000 real downloads from developers, tutorials, and even corporate CI pipelines blindly copying AI-generated installation commands. Subsequent empirical audits across PyPI and npm confirmed that coding models consistently repeat identical fabricated package identifiers, making preemptive registration a low-cost malware delivery channel. Organizations mitigated the vector via private registry mirrors, dependency allowlists, and automated package-existence verification in IDE workflows.

Incident dossier metadata

Case ID
INC-OBS-021
Classification
Incident
Date
Severity
High
Sector
Software Development & AI Tooling
Attack vector
Supply Chain
System type
AI Coding Assistants & Public Package Registries
Reference URI
https://www.lasso.security/blog/ai-package-hallucinations

Inspect INC-OBS-021 in Interactive Incidents & Cases Hub

Defensive takeaway

Verify every AI-suggested package name against approved internal registries and check package age, maintainer provenance, and repository links before installing.

Mapped AI security techniques

Mapped defensive controls

Source citation records