TL;DR: Malicious beta versions of @joyfill/components and @joyfill/layouts carried an obfuscated payload that executed on import, resolved command and control through blockchain transactions, opened Socket.IO remote access, and staged credential theft, according to StepSecurity. Import-time compromise changes the control problem from script blocking to supply chain verification and runtime detection.
NHIMG editorial — based on content published by StepSecurity: Compromised npm Packages: @joyfill/components and @joyfill/layouts Ship an Obfuscated Remote Access Trojan
By the numbers:
- StepSecurity found that malicious beta versions of @joyfill/components and @joyfill/layouts were published on July 28, 2026, and the payload ran on import rather than on install.
- The malicious package content was concentrated in roughly 333 lines of obfuscated code across the ES module and CommonJS bundles, according to StepSecurity.
Questions worth separating out
Q: What breaks when malicious npm packages execute on import instead of install?
A: Install-time controls often miss import-time payloads because the malicious code lives in the published bundle and runs when the module loads.
Q: Why do developer installs create NHI risk as well as endpoint risk?
A: Because the install path often depends on tokens, service accounts, API keys, and delegated access that are non-human identities in practice.
Q: How can security teams detect package supply chain attacks that hide their C2 infrastructure?
A: Look for unusual outbound traffic from build or developer processes to public APIs that have no business purpose in software delivery, especially blockchain lookup services or short-lived pointer channels.
Practitioner guidance
- Block import-time risk in dependency pipelines Add controls that inspect published tarballs, compare built bundles against source, and flag unexpected code execution during import in CI and developer environments.
- Treat developer machines as secret-bearing assets Inventory browser secrets, Git tokens, npm tokens, cloud credentials, and wallet keys on any host that imported the compromised packages, then rotate them as an exposure set.
- Detect blockchain lookup behavior from build processes Alert on outbound calls from Node.js processes to public blockchain APIs such as Tron, BNB Smart Chain, or Aptos when they occur during package installation, import, or test execution.
What's in the full analysis
StepSecurity's full article covers the operational detail this post intentionally leaves for the source:
- The exact obfuscation chain used in the malicious bundles and how the decoder stages were extracted from the tarballs.
- The full indicator set for the command-and-control infrastructure, blockchain pointer channels, and file hashes associated with the campaign.
- The package-by-package recovery steps for repositories, CI/CD runners, and developer laptops that imported the compromised prereleases.
- The detection logic behind Harden-Runner, OSS AI scanning, and Dev Machine Guard for this specific campaign.
👉 Read StepSecurity’s analysis of compromised Joyfill npm packages and import-time malware →
Joyfill npm compromise: what import-time malware means for teams?
Explore further
Import-time execution is the control failure that most teams still underestimate. The security model for package hygiene often stops at install hooks and known malicious versions, but this compromise executed when the package was imported inside ordinary workflows. That means the attack surface includes bundlers, test runners, and build agents that are already trusted to execute code. Practitioners should assume that published artifacts, not just source repositories, can carry active payloads.
A few things that frame the scale:
- 85% of organisations lack full visibility into third-party vendors connected via OAuth apps, according to The State of Non-Human Identity Security.
- That visibility gap breaks downstream governance as well, because 38% report no or low visibility and 47% only partial visibility into those connections.
A question worth separating out:
Q: What should teams do after a malicious dependency is discovered?
A: Contain the affected endpoints, revoke any credentials that were reachable from those systems, and rebuild trust from known-clean environments. Then review where secrets are stored, not just which package was compromised. If the same workstation holds cloud, SSH, and SaaS credentials, the incident response plan must cover all three identity domains.
👉 Read our full editorial: Compromised npm packages turned Joyfill imports into a RAT