Snyk helps you find, fix and monitor for known vulnerabilities in Node.js npm, Ruby and Java dependencies, both on an ad hoc basis and as part of your CI (Build) system.
Full documentation is available on snyk.io
npm install -g snyk.snyk authFor more detail on how to authenticate take a look at the CLI authentication section of the Snyk documentation.
snyk [options] [command] [package]Run snyk --help to get a quick overview of all commands or for full details on the CLI read the snyk.io CLI docs.
The package argument is optional. If no package is given, Snyk will run the command against the current working directory allowing you test you non-public applications.
snyk test on a project either as a one off or as part of your CI process.snyk wizard and snyk protect.
snyk wizard walks you through finding and fixing know vulnerabilities in your project. Remidiation options include configuring your policy file to update, auto patch and ignore vulnerabilities. (npm only)snyk protect your code from vulnerabilities by applying patches and optionally suppressing specific vulnerabilities.snyk monitor records the state of dependencies and any vulnerabilities on snyk.io so you can be alerted when new vulnerabilities or updates/patches are disclosed that affect your repositories.snyk test as part of your CI to fail tests when vulnerable Node.js or Ruby dependencies are added.If using this package from the repo directly, you'll need to first build the custom lodash by running:
npm run buildThis will create a dist directory with the minimal lodash file.
When using the package via npm, the build is not needed as the dist directory is already included in the npm package.
Once you’re vulnerability free, you can put a badge on your README showing your package has no known security holes. This will show your users you care about security, and tell them that they should care too.
If there are no vulnerabilities, this is indicated by a green badge.
If vulnerabilities have been found, the red badge will show the number of vulnerabilities.
Get the badge by copying the relevant snippet below and replacing "name" with the name of your package.
HTML:
<img src="https://snyk.io/package/npm/name/badge.svg" alt="Known Vulnerabilities" data-canonical-src="https://snyk.io/package/npm/name style="max-width:100%;">Markdown:
[](https://snyk.io/package/npm/name)