Key Takeaways
- When a fix only ships in a newer release, upgrading to get it drags in everything else.
- Backporting moves just the fix onto the version you run, often sparing you the migration.
- Pinning keeps change predictable, and it holds up as long as the pinned version keeps getting fixes.
- Coverage shouldn’t end when a package reaches end of life, because the CVEs filed against it don’t.
Every developer knows this ticket. The scanner goes red on a Tuesday, the advisory says the fix landed in 5.0.0, and you’re running 3.8. The suggested remediation is one line long. The actual work is a sprint.
Teams lose weeks to this, and the frustrating part is that the vulnerability often isn’t the hard part. Plenty of CVE fixes are a handful of lines. What makes them expensive is everything that comes along with those lines when the only official way to get them is to upgrade.
So can you fix a vulnerability without upgrading to a new major version? Often, yes. But it’s worth understanding why “just upgrade” became the default answer, and where it stops working.
Why upgrading became the default answer
For most of open source’s history, remediation has followed the same loop. Someone reports a vulnerability, a maintainer fixes it on the main branch, a new release goes out, and everyone downstream bumps their version. Many dependency scanners are built around that loop. They compare the version you have against the versions known to contain the fix and tell you to move.
That works fine when the gap is small. Going from 2.4.1 to 2.4.2 is usually a non-event. The catch is that maintainers fix things where they’re actively working, which is usually the latest line and maybe an LTS branch or two. Very few projects have the time or the people to go back and patch a release from two years ago, and nobody can fairly expect volunteers to. So the further behind the current release you are, the more a “simple upgrade” turns into a migration.
When the fix comes bundled with everything else
I call this a version-coupled fix. It’s a security patch that upstream only ships inside a newer release, so the only official way to get the fix is to accept everything else that release changed along with it.
Those other changes are where the real cost lives. A new major version might drop support for the runtime you’re on, rename an API your code calls in forty places, flip a default you were relying on, or bring its own fresh set of transitive dependencies. Semantic versioning is supposed to warn you about all that, and it does when maintainers stick to it. But breaking behavior turns up in minor releases often enough that nobody should treat a version number as a promise. And even a perfectly labeled major release still has to be read, tested, and rolled out by someone, usually someone who had other plans that week.
npm is pretty upfront about this. When npm audit fix can’t resolve something inside your declared version ranges, it’ll usually point you to npm audit fix --force, which the npm docs describe as allowing installs outside your stated range, SemVer-major changes included. It won’t stop to ask which of those major bumps you’re actually ready for, either. That’s a perfectly reasonable thing to type on a weekend project. On a production service, it’s the opening move of a regression hunt.
Three places where upgrading falls apart
The first one is obvious once you’ve hit it. Sometimes there’s no fixed version to move to at all. The package has been deprecated or the version line is end of life, and nobody is coming back for it. The request package is the classic Node example. It was deprecated in early 2020, it still turns up in a lot of dependency trees, and when CVE-2023-28155, a flaw that lets cross-protocol redirects slip past SSRF protections, was disclosed in 2023, the original package got no patched release. It still hasn’t. A maintained fork, @cypress/request, did ship a fix, but it landed in 3.0.0 under a different package name, and switching packages is a migration of its own.
The second is the major version jump. The fix exists, but it lives in 6.x while you’re on 4.x, and getting from one to the other means changing application code that has nothing to do with the vulnerability. Your security team wants the CVE closed this week. Your engineering lead knows the migration could eat a quarter. They’re both right, which is exactly why these tickets sit open for so long, and why a ticket that started as a security fix sometimes ends up with its own design doc.
The third catches people off guard, and it’s the transitive dependency. The vulnerable package isn’t in your package.json at all. It’s four levels down, pulled in by a parent whose version range doesn’t allow the fixed release. The cleaner route is bumping the parent, if a newer release of it allows the fixed version, since you stay inside a range the parent’s maintainers chose themselves. If that release is itself a major version away, though, you’re back to the second problem. The other route is forcing the version with npm overrides. Yarn calls them resolutions, and current pnpm releases set overrides in pnpm-workspace.yaml. Overrides work, but they leave you running a combination the parent’s maintainers never tested, which makes that testing your job. And if the fixed release is a major version ahead of what the parent expects, the override is handing the parent an API it was never written against.
Pinning was never the problem
There’s a piece of advice that gets passed around a lot, which is that pinning dependencies freezes vulnerabilities in place. Technically, that’s true. Pin a version, never touch it again, and every CVE disclosed against it stays with you.
I think that framing blames the wrong thing, though. Pinning, along with a committed lockfile and installs that respect it, means production runs the dependency tree you actually tested. It also keeps a freshly hijacked release from sliding into your build on the next install, and after the last few years of compromised maintainer accounts, that matters. In September 2025, a phished maintainer account was used to push malicious versions of chalk and debug to npm. Teams installing with npm ci from a clean lockfile committed before the attack kept building against the versions they’d already vetted. Teams that let everything float to the newest version are trading one kind of risk for another.
The real issue is what happens to the version line you pinned. A pinned version never picks up fixes by itself, so you depend on someone publishing a patched release for that line. Once upstream stops doing that, you’re mostly left choosing between living with the CVE, maybe with a mitigation in front of it, and taking the migration. Fix that, and pinning goes back to being what it was meant to be: a way to control change rather than a way to collect risk.
What backporting actually involves
Backporting is adapting a security fix from a newer release of a package to an older release, so the version you already run gets the fix without the rest of what changed upstream. Linux distributions have done this for decades. When Red Hat ships a fix for an old OpenSSL, that’s a backport, and nobody expects RHEL customers to jump to the latest upstream release every time a CVE drops.
Doing the same for application dependencies sounds simple enough. Find the upstream commit, apply it to the old tag, publish. In practice, the commit often doesn’t apply cleanly. The surrounding code has moved, function signatures have changed, and sometimes the fix leans on a refactor that happened three releases after the version you’re patching. The patch might call a helper that doesn’t exist in the older line yet, or validate input at a layer the old code never had. So whoever does the backport has to understand what the vulnerability actually is, not just what the diff looks like, and write a fix that closes the same hole in the older code.
Then it has to be proven. A good backport gets rebuilt from source, runs against the project’s own test suite where there is one, and gets checked against the vulnerability itself to confirm the hole is closed. The goal is that nothing changes except what the fix is meant to change. Sometimes a security fix has to tighten something your code was leaning on, like rejecting input the old version quietly accepted, and when that happens it should be called out plainly, not slipped in. Everything else should behave the way it did yesterday.
I won’t pretend this works for every CVE. Some fixes are tangled up in architectural changes that simply don’t exist in older code, and that’s true for anyone doing this work. A lot of vulnerabilities are far more contained than that, though. A missing bounds check, a regex that backtracks badly, input that never got validated. Those can often be fixed in the older code without dragging the newer architecture along, and they’re the reason fixing vulnerabilities without upgrading works as often as it does.
How SecureChain fixes vulnerabilities without upgrading
This is the problem we built SecureChain around. SecureChain serves patched builds from a TuxCare-managed npm registry. A patched build starts from the same upstream version, adds the fix, and gets a -tuxcare.N suffix on the end, so 3.8.0 becomes 3.8.0-tuxcare.1. A project on 3.8 stays on 3.8, now with the fix.
That suffix does make it a different version string, and a range like ^3.8.0 won’t pick it up on its own. So the SecureChain CLI handles the pinning. securechain sca scans your resolved dependency tree and reports what’s vulnerable, including the packages a patched build can fix. securechain harden then pins those builds, writing overrides (or Yarn resolutions) for transitive packages, refreshes the lockfile, and reinstalls. Before it’s done, it confirms the installed tree actually contains the new builds, and if it can’t confirm that, it puts your files back the way they were. Add --dry-run if you’d like to see the change before anything gets written.
Your lockfile changes, and so does the patched package, but your application code usually doesn’t have to, and you haven’t moved to a new major version. You’d still run your tests before shipping, same as with any dependency update. In CI, securechain check fails the job if a patched build exists and the project isn’t using it, so nobody drifts back to the vulnerable version by accident. The CLI works with npm, pnpm, and Yarn.
What happens when upstream stops shipping fixes
Backporting takes care of the version-coupled fix. On its own, though, it doesn’t solve the package that upstream walks away from. Plenty of packages go quiet long before anyone formally declares end of life.
SecureChain deals with that in stages, which are laid out in the SecureChain docs. While upstream is still shipping fixes, the response clock starts from the upstream fix. If upstream stops shipping them and the package enters a stage called Sustained, TuxCare takes over maintaining it directly, and response times are counted from the day the CVE is published, not from an upstream fix that may never come. For a critical CVE, TuxCare targets a patched build within 7 days of the upstream fix in the first stage and within 14 days of publication once it has taken over. After that, the package moves into Endless Lifecycle Support (ELS), and if you’ve added ELS alongside SecureChain, patching carries on from there for as long as you need the package.
Remember request? Upstream never released a fix for CVE-2023-28155, but TuxCare’s published VEX data marks it as resolved in request 2.88.2-tuxcare.2 and every build since. Same version line, nothing to rename in your package.json, and no fork to migrate to.
What I like about this setup is that, with both in place, there’s no cliff. Nobody on your team has to notice that a maintainer went quiet, and nobody has to go find a new vendor in a hurry. You still pull in a new patched build the same way you’d take any update, and the registry it comes from stays the same whether the original maintainer is busy shipping, has gone quiet, or has moved on entirely.
When you should still upgrade
None of this is an argument against upgrading. New major versions bring performance work, better APIs, and fixes for plenty of bugs nobody ever filed a CVE for. Plan those upgrades and do them.
The argument is about who sets the schedule. When the only way to close a CVE is to upgrade, the vulnerability is running your roadmap. When you can patch the version you’re on, you upgrade because the new version is worth it, you test it properly, and you do it on a timeline your team picked. That’s a far better reason to touch a dependency than a red badge on a scanner.
Frequently Asked Questions
Can you fix a vulnerability without upgrading the package?
Often, yes. When the vulnerable code is fairly self-contained, the fix can be backported to the version you already run, which closes the vulnerability without the breaking changes, new dependencies, or migration work that tend to come with a newer major release.
How do you apply a backported fix in npm, pnpm, or Yarn?
Install the patched build of the version you’re already on. For transitive packages, pin it with overrides in npm or pnpm, or resolutions in Yarn. Patched builds usually carry a suffix such as -tuxcare.1, which your existing version ranges won’t match by themselves, so the override is what puts the build into the tree while the parent stays on the version line it expects.
Is it safe to force npm audit fix?
Running npm audit fix --force can clear the advisories, but it does that by letting npm install versions outside your declared ranges, SemVer-major releases included, and some of those will carry breaking changes. Treat it like an upgrade you didn’t plan. Review what it changed in the lockfile and run your full test suite before any of it reaches production.
What is a backported security fix?
A backported security fix is a patch adapted from a newer release of a package and applied to an older release. It’s scoped to the vulnerability and keeps unrelated changes out, so code written against the older version should keep working, though you should still test it like any other dependency update.
What does it mean when a security fix is tied to a newer release?
It means the fix is version-coupled. A version-coupled fix is a security patch that upstream only ships inside a newer release, so taking it through an upgrade means accepting every other change in that release too, which is how closing one CVE turns into a full migration.
Is it safe to pin dependency versions?
Pinning, together with a committed lockfile and installs that respect it, such as npm ci, is a sound practice because it lets you reproduce the dependency tree you tested and keeps unreviewed releases out of your builds. The risk comes from leaving the pinned version unpatched, so pinning works best when that version keeps receiving security fixes.
How do you fix a vulnerability in a transitive dependency?
The usual options are upgrading the parent package, if a newer release accepts the fixed version, or forcing the fixed version with overrides, which can break the parent. A backported build gives you a third option, because the override can point to a patched build based on the same upstream version the parent already uses.
What happens to a package’s security after it reaches end of life?
Upstream stops releasing fixes, but new CVEs keep getting filed against it. Unless someone keeps patching it, you’re left with mitigations, a fork, or a migration, and the vulnerabilities stay open in the meantime.
