Back

Widespread Open Source Attack: Malicious Code Identified in npm, PyPI, and RubyGems Repositories

August 28, 2025
6 Minutes

June 2025 has exposed a new wave of attacks on the open-source ecosystem - one that’s catching developers and organizations off guard. Over the last several weeks, security researchers have uncovered a disturbing trend: malicious packages being uploaded to popular registries like npm, PyPI, and RubyGems, with the goal of stealing credentials, draining cryptocurrency wallets, and even wiping out entire application directories.

This is more than a one-off incident. It’s a coordinated and widespread campaign and it raises serious concerns for any business relying on open-source components (which, today, is nearly everyone).

Let’s break down what’s happening and how CleanStart can help organizations avoid becoming the next victim.

The Threat: What Was Discovered

Security researchers from multiple discovered over a hundred malicious packages that had quietly slipped into developer workflows. These packages appeared harmless on the surface but under the hood, they were doing serious damage.

Here’s what they found:

  • Malicious npm packages like pancake_uniswap_validators_utils_snipe were designed to siphon off cryptocurrency wallets successfully stealing up to 85% of wallet balances before being flagged and removed.
  • Data-exfiltrating packages were discovered across all three ecosystems (npm, PyPI, RubyGems), quietly collecting sensitive information like environment variables, IP addresses, DNS configurations, and even Gmail credentials.
  • Fake RubyGems plugins were rerouting Telegram bot traffic to unknown servers effectively giving attackers a backdoor into private conversations.
  • Destructive payloads were embedded in seemingly legitimate packages, such as system-health-sync-api, which could delete entire project folders once installed.

Most of these attacks used techniques like typosquatting, where malicious actors create packages with names that are just one or two characters off from legitimate ones, hoping developers will make a simple typing mistake and install them unknowingly.

Why These Attacks Are So Dangerous

Modern development depends on open-source. We pull in packages every day directly from registries like npm and PyPI - without always validating where they come from or what they contain. That trust is now being exploited. Even companies that try to pin package versions or scan for known vulnerabilities can still be caught off guard. Here’s why:

  • Compromised packages can look legitimate and may only reveal their true behavior during post-install scripts.
  • Attackers are getting more creative, using social engineering and auto-generated documentation to mimic real packages.
  • CI/CD pipelines often don’t have built-in mechanisms to validate the integrity of third-party code before building or deploying.

How CleanStart Secures You From the Start

This is where CleanStart, our secure base image platform, comes into play. CleanStart was built specifically to prevent this type of supply chain attack.

Here’s how:

1. Clean, Pre-Hardened Base Images:

Every CleanStart image is vetted and comes with zero known CVEs at the time of release. That means your build environment doesn’t inherit risk from outdated or vulnerable libraries.

2. Signed and Verifiable Builds

CleanStart delivers every image with cryptographic signatures and SBOMs (Software Bills of Materials). You know exactly what’s inside your base, and you can verify that it hasn’t been tampered with - ever.

3. Integrated CI/CD Security

CleanStart works seamlessly with your existing CI/CD pipelines. You can plug it into GitHub Actions, Jenkins, GitLab CI, or any other workflow and enforce that only signed, clean builds move forward.

A Real-World Example

Let’s say your developer accidentally installs a typosquatted package like requetss instead of requests (a common Python library). If you're using CleanStart:

  • Your base image wouldn’t allow unauthorized or unsigned packages by default.
  • You'd receive an alert that a new, unverified package was introduced.
  • You’d have full traceability - knowing when and how that package entered the pipeline.

That’s the kind of safety net modern teams need in today’s threat landscape.

What You Can Do Now

If your team relies on open-source packages, here are a few quick steps you can take:

  1. Stop pulling base images directly from public registries.
  2. Audit your dependencies.
  3. Enforce SBOMs and image signing.
  4. Strengthen security within your CI/CD pipelines.

Final Thoughts

The recent spike in malicious package activity is not an isolated incident. It’s a sign that open-source software is important but now a major attack surface.

At Triam Security, we believe that innovation shouldn’t come at the cost of integrity. With CleanStart, your team can build fast, secure, and confidently knowing that your software supply chain is protected from end to end.

Share