Eliminating SCA Noise using Dependency Usage Evidence
On this page
A 3rd party dependency may be referenced in a package manifest such as
requirements.txt or package-lock.json but not actually used in code.
Vulnerabilities or other risks in such packages are not useful. Most SCA tools
today lack the code context information preventing them from distinguishing
between dependencies that are actually used in the codebase and those that are
not. SafeDep Code Analysis framework augments vet, our free and open source tool with code
context. This allows us to eliminate false positives and noise by considering
the actual usage of a dependency in the codebase. In this article, we will look
at how we can use dependency usage evidence to eliminate noise in SCA.
Getting Started
Ensure you have vet 1.9.2+ installed in
your system. For help with installation, refer to the vet Installation Guide.
Create Code Analysis Database
Analyse your code base to create a code analysis database:
vet code scan --app /path/to/code --db /tmp/code.dbRun vet Scan with Code Analysis Database
Run vet scan with code analysis database to augment vet results with
code context information:
vet scan -D /path/to/repository --code /tmp/code.dbDemo
- sca
- nextgen-sca
- code-analysis
- guide
Author
SafeDep Team
safedep.io
Share
The Latest from SafeDep blogs
Follow for the latest updates and insights on open source security & engineering
eMudhra CA Key Compromise: Response Guide for Developers
Anyone can compute eight eMudhra intermediate CA private keys from public certificates. Browsers block the compromised intermediates, but CI runners, containers, JVMs and Go binaries can still trust...
Compromised LiteLLM 1.107.0 on PyPI Installs a Credential Stealer and Backdoor
Every wheel of LiteLLM 1.107.0 on PyPI installs a credential stealer and a remote code execution backdoor. Both run each time Python starts. The code is not in the upstream GitHub source.
testmetest npm Packages Carry a Miasma-Family Worm
18 npm packages carry a Miasma-family worm that steals credentials, spreads to other packages and installs a wiper. New builds replace the binding.gyp trigger with a native addon.
Forged Commits Push a preinstall Dropper into hugo-paper and mevn-cli
An attacker pushed forged commits to the default branches of hugo-paper and mevn-cli. Running npm install or bun install in either repository downloads and runs a second-stage script from...
Ship Code.
Not Malware.
Start free with open source tools on your machine. Scale to a unified platform for your organization.