maven-dependency-audit
Skill763 starsChanged 56 days agoMITView on GitHub
Audit Maven dependencies for outdated versions, security vulnerabilities, and conflicts. Use when user says "check dependencies", "audit dependencies", "outdated deps", or before releases.
We split this skill into the rules it gives an agent
7 rules. About 0 are common, 6 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈6
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 21
Security scan: - Check for vulnerabilities
- Distinctive: line 124
If using GitHub, enable Dependabot alerts in repository settings.
- Very specific: line 231
Use -q (quiet) flag for less verbose output
- Distinctive: line 233
Run commands separately and summarize findings
- Distinctive: line 234
Don't paste entire dependency tree - summarize conflicts
- Distinctive: line 252
Update patch versions freely
- Distinctive: line 253
Update minor versions with basic testing
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Maven Dependency Audit Skill
Audit Maven dependencies for updates, vulnerabilities, and conflicts.
When to Use
- User says "check dependencies" / "audit dependencies" / "outdated dependencies"
- Before a release
- Regular maintenance (monthly recommended)
- After security advisory
Audit Workflow
- Check for updates - Find outdated dependencies
- Analyze tree - Find conflicts and duplicates
- Security scan - Check for vulnerabilities
- Report - Summary with prioritized actions
1. Check for Outdated Dependencies
Command
mvn versions:display-dependency-updatesOutput Analysis
[INFO] The following dependencies in Dependencies have newer versions:
[INFO] org.slf4j:slf4j-api ......................... 1.7.36 -> 2.0.9
[INFO] com.fasterxml.jackson.core:jackson-databind . 2.14.0 -> 2.16.1
[INFO] org.junit.jupiter:junit-jupiter ............. 5.9.0 -> 5.10.1Categorize Updates
| Category | Criteria | Action |
| Security | CVE fix in newer version | Update ASAP |
| Major | x.0.0 change | Review changelog, test thoroughly |
| Minor | x.y.0 change | Usually safe, test |
| Patch | x.y.z change | Safe, minimal testing |
Check Plugin Updates Too
mvn versions:display-plugin-updates2. Analyze Dependency Tree
Full Tree
mvn dependency:treeFilter for Specific Dependency
mvn dependency:tree -Dincludes=org.slf4jFind Conflicts
Look for:
[INFO] +- com.example:module-a:jar:1.0:compile
[INFO] | \- org.slf4j:slf4j-api:jar:1.7.36:compile
[INFO] +- com.example:module-b:jar:1.0:compile
[INFO] | \- org.slf4j:slf4j-api:jar:2.0.9:compile (omitted for conflict)Flags:
(omitted for conflict)- Version conflict resolved by Maven(omitted for duplicate)- Same version, no issue- Multiple versions of same library - Potential runtime issues
Analyze Unused Dependencies
mvn dependency:analyzeOutput:
[WARNING] Used undeclared dependencies found:
[WARNING] org.slf4j:slf4j-api:jar:2.0.9:compile
[WARNING] Unused declared dependencies found:
[WARNING] commons-io:commons-io:jar:2.11.0:compile3. Security Vulnerability Scan
Option A: OWASP Dependency-Check (Recommended)
Add to pom.xml:
<plugin>
<groupId>org.owasp</groupId>
<artifactId>dependency-check-maven</artifactId>
<version>9.0.7</version>
</plugin>Run:
mvn dependency-check:checkOutput: HTML report in target/dependency-check-report.html
Option B: Maven Dependency Plugin
mvn dependency:analyze-reportOption C: GitHub Dependabot
If using GitHub, enable Dependabot alerts in repository settings.
Severity Levels
| CVSS Score | Severity | Action |
| 9.0 - 10.0 | Critical | Update immediately |
| 7.0 - 8.9 | High | Update within days |
| 4.0 - 6.9 | Medium | Update within weeks |
| 0.1 - 3.9 | Low | Update at convenience |
4. Generate Audit Report
Output Format
## Dependency Audit Report
**Project:** {project-name}
**Date:** {date}
**Total Dependencies:** {count}
### Security Issues
| Dependency | Current | CVE | Severity | Fixed In |
|------------|---------|-----|----------|----------|
| log4j-core | 2.14.0 | CVE-2021-44228 | Critical | 2.17.1 |
### Outdated Dependencies
#### Major Updates (Review Required)
| Dependency | Current | Latest | Notes |
|------------|---------|--------|-------|
| slf4j-api | 1.7.36 | 2.0.9 | API changes, see migration guide |
#### Minor/Patch Updates (Safe)
| Dependency | Current | Latest |
|------------|---------|--------|
| junit-jupiter | 5.9.0 | 5.10.1 |
| jackson-databind | 2.14.0 | 2.16.1 |
### Conflicts Detected
- slf4j-api: 1.7.36 vs 2.0.9 (resolved to 2.0.9)
### Unused Dependencies
- commons-io:commons-io:2.11.0 (consider removing)
### Recommendations
1. **Immediate:** Update log4j-core to fix CVE-2021-44228
2. **This sprint:** Update minor/patch versions
3. **Plan:** Evaluate slf4j 2.x migrationCommon Scenarios
Scenario: Check Before Release
# Quick check
mvn versions:display-dependency-updates -q
# Full audit
mvn versions:display-dependency-updates && \
mvn dependency:analyze && \
mvn dependency-check:checkScenario: Find Why Dependency is Included
mvn dependency:tree -Dincludes=commons-loggingScenario: Force Specific Version (Resolve Conflict)
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>2.0.9</version>
</dependency>
</dependencies>
</dependencyManagement>Scenario: Exclude Transitive Dependency
<dependency>
<groupId>com.example</groupId>
<artifactId>some-library</artifactId>
<version>1.0</version>
<exclusions>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
</exclusions>
</dependency>Token Optimization
- Use
-q(quiet) flag for less verbose output - Filter with
-Dincludes=groupId:artifactIdwhen looking for specific deps - Run commands separately and summarize findings
- Don't paste entire dependency tree - summarize conflicts
Quick Commands Reference
| Task | Command |
| Outdated deps | mvn versions:display-dependency-updates |
| Outdated plugins | mvn versions:display-plugin-updates |
| Dependency tree | mvn dependency:tree |
| Find specific dep | mvn dependency:tree -Dincludes=groupId |
| Unused deps | mvn dependency:analyze |
| Security scan | mvn dependency-check:check |
| Update versions | mvn versions:use-latest-releases |
| Update snapshots | mvn versions:use-latest-snapshots |
Update Strategies
Conservative (Recommended for Production)
- Update patch versions freely
- Update minor versions with basic testing
- Major versions require migration plan
Aggressive (For Active Development)
# Update all to latest (use with caution!)
mvn versions:use-latest-releases
mvn versions:commit # or versions:revertSelective
# Update specific dependency
mvn versions:use-latest-versions -Dincludes=org.junit.jupiterOther versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 1
- iCesofT/awesome-ai★ 121% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository17 other files it gives its agents.
- api-contract-reviewSkill
- architecture-reviewSkill
- changelog-generatorSkill
- clean-codeSkill
- concurrency-reviewSkill
- design-patternsSkill
- git-commitSkill
- issue-triageSkill
- java-code-reviewSkill
- java-migrationSkill
- jpa-patternsSkill
- logging-patternsSkill
- performance-smell-detectionSkill
- security-auditSkill
- solid-principlesSkill
- spring-boot-patternsSkill
- test-qualitySkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

