Skip to content
← Home

Blog

Notes on supply chain security

Attack post-mortems, technical explainers, and product notes across every major package manager. Named attacks, specific dates, no filler.

More posts

  • Technical explainer

    RubyGems supply chain security: native extensions and bundle install

    gem install runs arbitrary code through native extensions (extconf.rb) — an install-time vector older than npm’s postinstall. What Gemfile.lock’s newer CHECKSUMS section adds, and how a single-host mirror gates bundle install.

    3 min read

  • Technical explainer

    Cargo supply chain security: build.rs runs code at build time

    Rust is memory-safe, not supply-chain-safe. build.rs and proc-macros execute arbitrary code during cargo build, crates.io is a two-host registry, and Cargo.lock pins integrity but not trust. How dual-origin gating intercepts the .crate.

    3 min read

  • Technical explainer

    npm audit — what it catches and what it misses

    npm audit checks against known CVE databases and misses every zero-day supply chain attack. Here's exactly what npm audit does, its false positive problem, and how to use it correctly.

    3 min read

  • Technical explainer

    AI picked your packages. Who’s checking them?

    Vibe coding ships fast because you stop reading the package list. That’s fine — until your AI coding assistant hallucinates a package name an attacker already registered, or a postinstall script scrapes your SSH keys. Here’s the threat model for AI-assisted devs and the one-line fix.

    4 min read

  • Attack post-mortem

    Case study: replaying colors@1.4.1 and faker@6.6.6 through the Veln gate

    January 2022: the original maintainer of colors and faker shipped sabotaged versions to npm. Same publisher, no postinstall, no exfil — just an infinite loop in the main module. Three Veln signals fire on replay; the cooling window and file-tree drift do the work. Verdict: BLOCK.

    10 min read

  • Technical explainer

    Securing GitHub Actions from supply chain attacks

    GitHub Actions workflows are a prime target for supply chain attacks. Here's how to secure your npm and Python installs, pin action versions, and use Veln in CI.

    2 min read

  • Technical explainer

    Slopsquatting: when AI hallucinations become real npm packages

    AI coding assistants occasionally invent package names that sound plausible but don’t exist. Attackers register the popular hallucinations within hours. Here’s the threat shape and how to defend against an attack class that didn’t exist three years ago.

    3 min read

  • Attack post-mortem

    Case study: replaying node-ipc@10.1.1 through the Veln gate

    node-ipc@10.1.1 in March 2022 deleted files on machines geolocated to Russia or Belarus. The payload was IP-gated — the exact pattern our env-gated-risky-execution signal exists to catch. Five signals fire on replay; the LOL signal anchors the verdict at BLOCK.

    10 min read

  • Attack post-mortem

    The colors and faker.js incident

    In January 2022, the developer of colors.js and faker.js deliberately shipped broken, infinite-loop versions of both packages. Here's what happened and what it means for supply chain trust.

    3 min read

  • Technical explainer

    The side-project graveyard: vulnerable packages you forgot about

    Your laptop has 23 abandoned side projects. Each has a node_modules from last year. The risk isn’t the package you install today — it’s the malicious code that’s been sitting on your disk since last summer, two AI tools and three editors ago.

    3 min read

  • Attack post-mortem

    Case study: replaying ua-parser-js@0.7.29 through the Veln gate

    October 2021: a compromised npm publisher account pushed malicious versions of ua-parser-js to three different majors in five hours. Maintainer fingerprint does NOT change (the account was compromised, not handed off). Six other signals do. Verdict: BLOCK on all three coords.

    10 min read

  • Technical explainer

    How to respond to a supply chain compromise

    Your CI pipeline installed a malicious npm or Python package. Here's the exact incident response process: what to investigate, what to rotate, and how to prevent recurrence.

    3 min read

  • Technical explainer

    uv vs pip vs poetry for security

    uv, pip, and poetry have different security properties. Here's a comparison of lockfile security, hash verification, and supply chain protections for each Python package manager.

    3 min read

  • Technical explainer

    Vibe coding to CI: when your side project becomes a real target

    Your laptop has your personal stuff. Your CI has your production keys. The same malicious npm package, run in the same workflow, has very different consequences on each. Here’s why CI is the higher-value target — and the smaller checklist to harden it.

    3 min read

  • Attack post-mortem

    Case study: replaying event-stream@3.3.6 through the Veln gate

    We replayed the November 2018 event-stream compromise against the current Veln agent. Five trust signals fire, the score lands at 0.18, the gate returns 403. Here is the signal-by-signal breakdown of what catches it — and the two signals that do not.

    10 min read

  • Attack post-mortem

    The node-ipc protest-ware incident

    In March 2022, the node-ipc npm package was modified to delete files on computers in Russia and Belarus. Here's what happened, why it was unprecedented, and what it means for supply chain trust.

    3 min read

  • Technical explainer

    npm provenance and Sigstore

    npm now supports build provenance via Sigstore. Here's what it is, how it works, what attacks it prevents, and where it leaves gaps that Veln fills.

    3 min read

  • Technical explainer

    Why your AWS keys keep ending up in package-stealer logs

    Modern npm/PyPI malware doesn’t drop ransomware. It harvests developer credentials. Here are the exact files attackers target on a vibe coder’s laptop and the patterns that appear in every recent incident.

    3 min read

  • Technical explainer

    How to write a secure npm package

    If you publish npm packages, here's how to protect your account, secure your CI publishing pipeline, avoid patterns that trigger security scanners, and use npm provenance.

    2 min read

  • Technical explainer

    Vibe coding in Python: the wheel problem

    pip installs run arbitrary Python at install time. Wheels can ship native code that runs the moment they’re unpacked. uv is faster but doesn’t change the trust model. Here’s what you’re actually running when you pip install.

    4 min read

  • Technical explainer

    Securing Dockerfile Python builds

    A deep dive into securing Python package installs in Docker: multi-stage builds, non-root users, read-only filesystems, Buildkit secrets, and Veln in CI.

    2 min read

  • Technical explainer

    Supply chain security for ML and AI projects

    ML and AI projects are uniquely exposed to supply chain attacks: large dependency trees, frequent new packages, cloud credentials, and model weights. Here's how to protect them.

    3 min read

  • Technical explainer

    The maintainer just changed. AI doesn’t notice.

    Your AI assistant suggests left-pad@latest. Latest was published yesterday by an account that wasn’t the maintainer last week. AI assistants have no concept of maintainer churn. Here’s why that’s the failure mode behind every hijack of the last five years.

    3 min read

  • Attack post-mortem

    The SolarWinds attack explained for developers

    SolarWinds is the most famous supply chain attack. Here's what actually happened, how it compares to npm and PyPI attacks, and what lessons apply to package manager security.

    3 min read

  • Technical explainer

    Python virtual environments and security

    Python virtual environments isolate packages between projects but don't protect against malicious packages. Here's what venv actually does for security and what additional steps are needed.

    3 min read

  • Technical explainer

    npm scopes and private packages

    npm scopes (@company/package) are your first line of defense against dependency confusion attacks. Here's how to configure them correctly and what can still go wrong.

    2 min read

  • Attack post-mortem

    shai-hulud: the npm worm that propagates through postinstall scripts

    Self-replicating npm worms scrape publish tokens from infected developer machines and use them to publish malicious versions of every package those tokens can reach. Here is the propagation pattern, why it scales, and what reduces the blast radius.

    3 min read

  • Attack post-mortem

    The aiocpa malicious npm update

    In November 2024, aiocpa — a Python library for the CryptoPay API — had a malicious update published that exfiltrated seed phrases and private keys. Here's the full breakdown.

    4 min read

  • Technical explainer

    Malicious packages targeting AWS credentials

    AWS credentials are the most commonly targeted secret in npm and PyPI supply chain attacks. Here's the specific patterns attackers use, why AWS is targeted, and how to protect your credentials.

    3 min read

  • Technical explainer

    Why a fresh-laptop `npm install` is your highest-risk moment

    Your CI passes, your tests pass, but every time you wipe and reinstall, you re-pull the entire dependency tree from the live registry. If anything was hijacked between last install and this one, this is where you catch it — or don’t.

    4 min read

  • Technical explainer

    The open-source maintainer burnout problem

    Abandoned and under-maintained npm and PyPI packages are a primary supply chain attack vector. Here's why maintainer burnout creates security risk and what developers can do about it.

    3 min read

  • Technical explainer

    npm and PyPI private registry security

    Private npm and PyPI registries (Artifactory, Nexus, Verdaccio) introduce unique security risks. Here's how to configure them securely and what Veln adds.

    3 min read

  • Technical explainer

    Least-privilege npm tokens

    npm automation tokens with full account access are the norm. Here's how to use granular npm access tokens, scope them to specific packages, and limit the blast radius if a token is stolen.

    2 min read

  • Technical explainer

    The engineering manager’s case for supply-chain security tooling

    You have a 12-person team, a CI bill, and a security budget that has to fight for line items. Here is the ROI math, the alternatives compared, and the specific failure modes that would otherwise show up on your post-mortem.

    4 min read

  • Technical explainer

    How CI caching affects supply chain security

    CI caches for npm and Python can persist malicious packages across builds and across time. Here's which caching strategies are safe, which are risky, and how to configure them correctly.

    2 min read

  • Technical explainer

    How npm resolves transitive dependencies

    A practical walk-through of npm’s dependency resolver: how SemVer ranges become resolved versions, when nested copies appear in node_modules, and why reading a package-lock.json diff is the only reliable supply-chain review.

    3 min read

  • Technical explainer

    Network egress monitoring for supply chain attacks

    Monitoring outbound network traffic from your CI pipelines and developer machines is one of the most effective after-the-fact detections for supply chain attacks. Here's how to set it up.

    2 min read

  • Technical explainer

    The semantic versioning security trap

    Using ^ and ~ in package.json lets npm automatically install new minor and patch versions. Here's why this creates a supply chain attack surface and how to use semver safely.

    2 min read

  • Technical explainer

    The indie founder’s 30-minute supply-chain survival kit

    Solo founder, two AI assistants, eleven side projects, one real revenue stream. Here is the smallest set of supply-chain hardening you can apply in half an hour and the specific incidents it would have prevented.

    4 min read

  • Technical explainer

    First-party vs third-party risk in npm

    Transitive npm dependencies are the primary supply chain attack surface, not direct dependencies. Here's why, how deep dependency trees amplify risk, and what to do about it.

    2 min read

  • Technical explainer

    Verifying Python package metadata before installing

    Before installing a Python package, you can verify its publisher, release history, download counts, and source code. Here's a step-by-step manual verification process and what Veln automates.

    2 min read

  • Technical explainer

    Package manager shell escapes

    npm lifecycle scripts and Python build hooks execute shell commands. Here's how the shell execution works, what escape vectors exist, and how Veln catches shell-based supply chain attacks.

    2 min read

  • Technical explainer

    The supply chain attack surface of LLM-generated code

    LLMs like GPT-4 and Claude sometimes recommend npm and Python packages that don't exist. Attackers register those package names. Here's the risk and how to protect yourself.

    3 min read

  • Technical explainer

    How pip’s dependency resolver picks versions

    pip’s backtracking resolver is what decides which version of every Python package gets installed. Here is how it works, what changed in pip 20.3, and how to make builds reproducible with hashed lockfiles.

    3 min read

  • Technical explainer

    Reading a package-lock.json: what every field actually means

    The lockfile is the source of truth for what your build will install. A field-by-field walk-through of package-lock.json so the next thousand-line lockfile diff in code review is readable in minutes.

    3 min read

  • Technical explainer

    Why CI should run `npm ci`, not `npm install`

    npm ci installs strictly from package-lock.json with integrity verification on every package. A small command change with outsized benefits for build reproducibility, performance, and supply-chain hygiene.

    3 min read

  • Security research

    Typosquat naming patterns on PyPI: a taxonomy

    PyPI typosquats follow a small set of recurring patterns: transposition, omission, hyphenation variants, prefix and suffix insertion, abandoned-name resurrection. Here is the catalog and what each pattern looks like in the wild.

    3 min read

  • Technical explainer

    Reproducible Python builds with hash-pinned requirements

    pip-compile --generate-hashes plus pip install --require-hashes gives you the Python equivalent of npm ci: byte-identical wheels across machines and refusal to install if any artifact’s hash does not match.

    3 min read

  • Technical explainer

    SBOM formats explained: SPDX, CycloneDX, and SWID

    Three Software Bill of Materials formats compete for the same shelf. Here is what each format is good at, where it is used, and how to pick one without overthinking it.

    4 min read

  • Security research

    How long do malicious npm packages stay live?

    A research note on detection latency for malicious npm packages: median windows of hours for high-profile cases, days-to-weeks for the long tail, with the data caveats. The implication for defense planning is structural.

    4 min read

  • Technical explainer

    A field guide to malicious npm postinstall script patterns

    npm postinstall is the most common code-execution surface for malicious packages. A taxonomy of the patterns observed in the wild — credential exfiltration, downloaded payloads, obfuscated runtime, conditional triggers — and what reliably catches each one.

    4 min read

  • Technical explainer

    Sigstore root of trust explained: how keyless signing works

    Sigstore replaces long-lived signing keys with short-lived OIDC-issued certificates and a public transparency log. This is the foundation under npm provenance and PyPI Trusted Publishing — here is how the trust chain actually works.

    4 min read

  • Security research

    Maintainer account compromise: how attackers actually get in

    A taxonomy of the vectors observed across documented npm and PyPI account-takeover incidents: phishing, credential reuse, expired domains, session-token theft, OAuth grants, and social-engineered handoffs. Each with what mitigates it.

    5 min read

  • Security research

    The cooling period as defense: academic foundations

    The cooling-period idea — refuse to install brand-new versions until they have been published long enough and observed enough — has a long history in academic literature. Here are the threads of research and why two thresholds beat one.

    5 min read