Dependency Audit & CVE Scanning
Also Known As
CVE scanning
vulnerability audit
composer audit
Dependabot
TL;DR
Automated scanning of project dependencies for known vulnerabilities (CVEs) — composer audit, npm audit, and tools like Snyk run in CI to catch vulnerable packages before deployment.
Explanation
Every dependency is potential attack surface. CVE databases (National Vulnerability Database, GitHub Advisory Database) track known vulnerabilities with severity scores. Tools: composer audit (built-in, checks against GitHub Advisory), npm audit, Snyk, Dependabot (GitHub). Best practice: run in CI on every PR, fail the build on high-severity CVEs, automate dependency updates (Dependabot, Renovate). PHP-specific: track phpstan/phpstan, laravel/framework, symfony/* for security releases. Sign up to security mailing lists for frameworks you use.
Common Misconception
✗ Auditing dependencies once at project start is sufficient — new CVEs are disclosed daily; dependencies must be audited continuously, ideally on every commit.
Why It Matters
The Log4Shell vulnerability affected thousands of applications using a transitive dependency most developers didn't even know they had — automated auditing catches these before attackers do.
Common Mistakes
- No audit step in CI — vulnerabilities are only caught when someone manually checks.
- Ignoring moderate CVEs — many critical exploits start as moderate severity findings.
- Not updating after audit — knowing about a vulnerability without fixing it provides no protection.
- Only auditing direct dependencies — transitive dependencies (dependencies of dependencies) are equally dangerous.
Code Examples
✗ Vulnerable
# No audit in CI — vulnerable packages silently deployed:
# .github/workflows/ci.yml:
steps:
- run: composer install
- run: vendor/bin/phpunit
# No audit step
# symfony/http-kernel with known RCE deployed to production
✓ Fixed
# Audit in CI — blocks deployment on high CVEs:
steps:
- run: composer install
- run: composer audit --no-dev # Fail on any vulnerability
- run: vendor/bin/phpunit
# .github/dependabot.yml:
version: 2
updates:
- package-ecosystem: composer
directory: /
schedule:
interval: weekly
open-pull-requests-limit: 10
Tags
🤝 Adopt this term
£79/year · your link shown here
Added
16 Mar 2026
Edited
22 Mar 2026
Views
22
🤖 AI Guestbook educational data only
|
|
Last 30 days
Agents 0
No pings yet today
No pings yesterday
Amazonbot 6
Perplexity 5
Unknown AI 3
Ahrefs 2
Google 1
SEMrush 1
Also referenced
How they use it
crawler 17
pre-tracking 1
Related categories
⚡
DEV INTEL
Tools & Severity
🟠 High
⚙ Fix effort: Low
⚡ Quick Fix
Run 'composer audit' in CI; fail the build on any critical or high severity CVE in a direct dependency
📦 Applies To
PHP 5.0+
web
api
cli
🔍 Detection Hints
No composer audit step in CI; outdated composer.lock with known CVEs
Auto-detectable:
✓ Yes
composer-audit
snyk
dependabot
roave/security-advisories
⚠ Related Problems
🤖 AI Agent
Confidence: High
False Positives: Low
✓ Auto-fixable
Fix: Low
Context: File
CWE-1104
CWE-937