Check yarn.lock for vulnerable dependencies
Upload or paste your yarn.lock. We check every JavaScript package version in it
against OSV.dev and email you the
vulnerable ones, the version that fixes them and the Yarn command to upgrade. Free, and no account needed.
About yarn.lock
yarn.lock is written by Yarn next to package.json. Both Yarn 1 (classic) and Yarn 2+ (Berry) lockfiles record the exact resolved version of every package.
To write or refresh it:
yarn install
Commit yarn.lock; yarn install --frozen-lockfile (Yarn 1) or --immutable (Yarn 2+) fails in CI when it is out of date.
Good to know
- package.json cannot be checked: it has version ranges.
- One package can appear in several versions (different parents need different ranges): each version is checked.
Fixing a vulnerable package
The report gives the fixed version for each vulnerable package (FIXED below). With Yarn:
# Yarn 1
yarn upgrade package@FIXED
# Yarn 2 and later
yarn up package@FIXED
For an indirect dependency, upgrade the parent package, or force the version with "resolutions" in package.json, then run yarn install.
Then run your tests and commit the updated yarn.lock.
yarn audit (Yarn 1) or yarn npm audit (Yarn 2+) and this check
Both use npm's advisory service. This check needs nothing installed and groups advisories per package with one target version.
Other lockfiles
Related free tools
GitHub repo vulnerability check
Paste a public GitHub repo URL. We find every lockfile, check each package version against OSV.dev and email you the fixes. Free, no account.
Dependency vulnerability check
Check requirements.txt, package-lock.json, poetry.lock and more against OSV.dev. Free report by email with fix commands. No account needed.
Last updated .