Add vuln-scan: Dependency-Check 13.0.0 vs Trivy 0.76.2 vs OSV-Scanner 2.7.1

Same Maven project scanned three ways (pom.xml, SBOM, jars): captured output,
false-positive evidence, suppression files with expiry, CI gate, -Pfixed profile.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_017ic4b7h4ZNF4BDUpJk3Zou
This commit is contained in:
Ankur Mhatre
2026-11-29 02:29:18 +05:30
co-authored by Claude Sonnet 5.5
parent f32c088174
commit 7c677a39d2
32 changed files with 1070 additions and 0 deletions
+39
View File
@@ -0,0 +1,39 @@
$ mvn -v
Apache Maven 3.9.11 (3e54c93a704957b63ee3494413a2b544fd3d825b)
Maven home: /opt/maven
Java version: 25.0.5.1, vendor: Eclipse Adoptium, runtime: /tmp/tools/jdk-25.0.5.1+2
$ osv-scanner --version
osv-scanner version: 2.7.1
osv-scalibr version: 0.5.3
$ trivy --version
Version: 0.76.2
Vulnerability DB:
Version: 2
UpdatedAt: 2026-11-28 19:00:28.355904588 +0000 UTC
NextUpdate: 2026-11-29 19:00:28.355904027 +0000 UTC
DownloadedAt: 2026-11-28 20:29:36.959653888 +0000 UTC
Java DB:
Version: 1
UpdatedAt: 2026-11-28 00:57:53.322898531 +0000 UTC
NextUpdate: 2026-12-01 00:57:53.322898051 +0000 UTC
DownloadedAt: 2026-11-28 20:30:53.8925814 +0000 UTC
$ curl .../org/owasp/dependency-check-maven/maven-metadata.xml | grep -E "<(latest|release|lastUpdated)>"
<latest>13.0.0</latest>
<release>13.0.0</release>
<lastUpdated>20260803104202</lastUpdated>
$ curl https://proxy.golang.org/github.com/google/osv-scanner/v2/@latest
v2.7.1 2026-11-09T03:39:40Z
$ curl https://proxy.golang.org/github.com/aquasecurity/trivy/@latest
v0.76.2 2026-11-05T11:50:03Z
$ mvn help:describe -Dplugin=org.owasp:dependency-check-maven:13.0.0 (goal names only)
dependency-check:aggregate
dependency-check:check
dependency-check:help
dependency-check:purge
dependency-check:update-only
+27
View File
@@ -0,0 +1,27 @@
$ mvn dependency:tree
[INFO] com.ankurm.vulnscan:orders:jar:1.0.0
[INFO] +- org.apache.logging.log4j:log4j-core:jar:2.14.1:compile
[INFO] | \- org.apache.logging.log4j:log4j-api:jar:2.14.1:compile
[INFO] +- org.apache.commons:commons-text:jar:1.9:compile
[INFO] | \- org.apache.commons:commons-lang3:jar:3.11:compile
[INFO] +- com.fasterxml.jackson.core:jackson-databind:jar:2.13.4:compile
[INFO] | +- com.fasterxml.jackson.core:jackson-annotations:jar:2.13.4:compile
[INFO] | \- com.fasterxml.jackson.core:jackson-core:jar:2.13.4:compile
[INFO] +- org.yaml:snakeyaml:jar:1.30:compile
[INFO] \- commons-collections:commons-collections:jar:3.2.1:test
$ ls target/lib (what ships: runtime scope only)
commons-lang3-3.11.jar
commons-text-1.9.jar
jackson-annotations-2.13.4.jar
jackson-core-2.13.4.jar
jackson-databind-2.13.4.jar
log4j-api-2.14.1.jar
log4j-core-2.14.1.jar
snakeyaml-1.30.jar
$ grep -rl org.yaml src/main/java || echo "no source file imports org.yaml"
no source file imports org.yaml
$ java -cp "target/classes:target/lib/*" com.ankurm.vulnscan.OrderApp
{"message":"Order confirmed for Asha"}
+53
View File
@@ -0,0 +1,53 @@
$ osv-scanner scan source -L pom.xml
Starting filesystem walk for root: /
Scanned <module>/pom.xml file and found 5 packages
End status: 0 dirs visited, 1 inodes visited, 1 Extract calls, 458.484µs elapsed, 458.536µs wall time
Warning: enricher transitivedependency/pomxml may be risky when run on untrusted artifacts. Please ensure you trust the source code and artifacts.
Total 8 packages affected by 35 known vulnerabilities (4 Critical, 12 High, 18 Medium, 0 Low, 1 Unknown) from 1 ecosystem.
35 vulnerabilities can be fixed.
+-------------------------------------+------+-----------+-----------------------------------------------+---------+---------------+---------+
| OSV URL | CVSS | ECOSYSTEM | PACKAGE | VERSION | FIXED VERSION | SOURCE |
+-------------------------------------+------+-----------+-----------------------------------------------+---------+---------------+---------+
| https://osv.dev/GHSA-3wrr-7qpf-2prh | 7.5 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.14.0 | pom.xml |
| https://osv.dev/GHSA-5gvw-p9qm-jgwh | 6.5 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.9 | pom.xml |
| https://osv.dev/GHSA-5jmj-h7xm-6q6v | 5.3 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.9 | pom.xml |
| https://osv.dev/GHSA-cxp5-3px4-pw24 | 7.5 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.11 | pom.xml |
| https://osv.dev/GHSA-gx83-3vf8-gh7j | 5.6 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.10 | pom.xml |
| https://osv.dev/GHSA-hgj6-7826-r7m5 | 5.3 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.8 | pom.xml |
| https://osv.dev/GHSA-j3rv-43j4-c7qm | 8.1 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.8 | pom.xml |
| https://osv.dev/GHSA-jjjh-jjxp-wpff | 7.5 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.13.4.2 | pom.xml |
| https://osv.dev/GHSA-rmj7-2vxq-3g9f | 8.1 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.8 | pom.xml |
| https://osv.dev/GHSA-vvgp-rfg2-7rr6 | 5.3 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.9 | pom.xml |
| https://osv.dev/GHSA-wjgm-6hv5-3cvf | 5.3 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.10 | pom.xml |
| https://osv.dev/GHSA-wv8q-qhhj-9h54 | 7.5 | Maven | com.fasterxml.jackson.core:jackson-databind | 2.13.4 | 2.18.11 | pom.xml |
| https://osv.dev/GHSA-6hgm-866r-3cjv | | Maven | commons-collections:commons-collections (dev) | 3.2.1 | 3.2.2 | pom.xml |
| https://osv.dev/GHSA-fjq5-5j5f-mvxh | 9.8 | Maven | commons-collections:commons-collections (dev) | 3.2.1 | 3.2.2 | pom.xml |
| https://osv.dev/GHSA-599f-7c49-w659 | 9.8 | Maven | org.apache.commons:commons-text | 1.9 | 1.10.0 | pom.xml |
| https://osv.dev/GHSA-3pxv-7cmr-fjr4 | 6.9 | Maven | org.apache.logging.log4j:log4j-core | 2.14.1 | 2.25.4 | pom.xml |
| https://osv.dev/GHSA-6hg6-v5c8-fphq | 6.3 | Maven | org.apache.logging.log4j:log4j-core | 2.14.1 | 2.25.4 | pom.xml |
| https://osv.dev/GHSA-7rjr-3q55-vv33 | 9.0 | Maven | org.apache.logging.log4j:log4j-core | 2.14.1 | 2.16.0 | pom.xml |
| https://osv.dev/GHSA-8489-44mv-ggj8 | 6.6 | Maven | org.apache.logging.log4j:log4j-core | 2.14.1 | 2.17.1 | pom.xml |
| https://osv.dev/GHSA-h383-gmxw-35v2 | 6.9 | Maven | org.apache.logging.log4j:log4j-core | 2.14.1 | 2.25.4 | pom.xml |
| https://osv.dev/GHSA-jfh8-c2jp-5v3q | 10.0 | Maven | org.apache.logging.log4j:log4j-core | 2.14.1 | 2.15.0 | pom.xml |
| https://osv.dev/GHSA-p6xc-xr62-6r2g | 8.6 | Maven | org.apache.logging.log4j:log4j-core | 2.14.1 | 2.17.0 | pom.xml |
| https://osv.dev/GHSA-vc5p-v9hr-52mj | 6.3 | Maven | org.apache.logging.log4j:log4j-core | 2.14.1 | 2.25.3 | pom.xml |
| https://osv.dev/GHSA-3mc7-4q67-w48m | 7.5 | Maven | org.yaml:snakeyaml | 1.30 | 1.31 | pom.xml |
| https://osv.dev/GHSA-98wm-3w3q-mw94 | 6.5 | Maven | org.yaml:snakeyaml | 1.30 | 1.31 | pom.xml |
| https://osv.dev/GHSA-9w3m-gqgf-c4p9 | 6.5 | Maven | org.yaml:snakeyaml | 1.30 | 1.32 | pom.xml |
| https://osv.dev/GHSA-c4r9-r8fh-9vj2 | 6.5 | Maven | org.yaml:snakeyaml | 1.30 | 1.31 | pom.xml |
| https://osv.dev/GHSA-hhhw-99gj-p3c3 | 5.5 | Maven | org.yaml:snakeyaml | 1.30 | 1.31 | pom.xml |
| https://osv.dev/GHSA-mjmj-j48q-9wg2 | 8.3 | Maven | org.yaml:snakeyaml | 1.30 | 2.0 | pom.xml |
| https://osv.dev/GHSA-w37g-rhq8-7m4j | 6.5 | Maven | org.yaml:snakeyaml | 1.30 | 1.32 | pom.xml |
| https://osv.dev/GHSA-7hhh-6rmp-j9qf | 7.5 | Maven | com.fasterxml.jackson.core:jackson-core | 2.13.4 | 2.18.11 | pom.xml |
| https://osv.dev/GHSA-h46c-h94j-95f3 | 8.7 | Maven | com.fasterxml.jackson.core:jackson-core | 2.13.4 | 2.15.0 | pom.xml |
| https://osv.dev/GHSA-r7wm-3cxj-wff9 | 8.7 | Maven | com.fasterxml.jackson.core:jackson-core | 2.13.4 | 2.18.8 | pom.xml |
| https://osv.dev/GHSA-j288-q9x7-2f5v | 6.5 | Maven | org.apache.commons:commons-lang3 | 3.11 | 3.18.0 | pom.xml |
| https://osv.dev/GHSA-qv9r-c865-cp47 | 6.3 | Maven | org.apache.logging.log4j:log4j-api | 2.14.1 | 2.25.5 | pom.xml |
+-------------------------------------+------+-----------+-----------------------------------------------+---------+---------------+---------+
exit code: 1
$ osv-scanner scan source -L pom.xml --no-resolve (direct dependencies only)
Scanned <module>/pom.xml file and found 5 packages
Total 5 packages affected by 30 known vulnerabilities (4 Critical, 9 High, 16 Medium, 0 Low, 1 Unknown) from 1 ecosystem.
+38
View File
@@ -0,0 +1,38 @@
$ trivy fs --scanners vuln pom.xml (table output, summary lines only)
pom.xml (pom)
Total: 33 (UNKNOWN: 0, LOW: 0, MEDIUM: 19, HIGH: 11, CRITICAL: 3)
$ trivy fs ... -f json | one line per finding: component, id, severity
com.fasterxml.jackson.core:jackson-core:2.13.4 CVE-2025-52999 HIGH
com.fasterxml.jackson.core:jackson-core:2.13.4 CVE-2026-68494 HIGH
com.fasterxml.jackson.core:jackson-core:2.13.4 CVE-2026-89425 HIGH
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2022-42003 HIGH
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-19032 MEDIUM
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-50193 MEDIUM
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-54512 HIGH
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-54513 HIGH
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-54514 MEDIUM
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-54515 MEDIUM
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-59889 MEDIUM
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-77310 MEDIUM
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-83557 MEDIUM
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-91776 HIGH
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-91777 HIGH
org.apache.commons:commons-lang3:3.11 CVE-2025-48924 MEDIUM
org.apache.commons:commons-text:1.9 CVE-2022-42889 CRITICAL
org.apache.logging.log4j:log4j-api:2.14.1 CVE-2026-49844 MEDIUM
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2021-44228 CRITICAL
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2021-44832 MEDIUM
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2021-45046 CRITICAL
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2021-45105 HIGH
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2025-68161 MEDIUM
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2026-34477 MEDIUM
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2026-34479 MEDIUM
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2026-34480 MEDIUM
org.yaml:snakeyaml:1.30 CVE-2022-1471 HIGH
org.yaml:snakeyaml:1.30 CVE-2022-25857 HIGH
org.yaml:snakeyaml:1.30 CVE-2022-38749 MEDIUM
org.yaml:snakeyaml:1.30 CVE-2022-38750 MEDIUM
org.yaml:snakeyaml:1.30 CVE-2022-38751 MEDIUM
org.yaml:snakeyaml:1.30 CVE-2022-38752 MEDIUM
org.yaml:snakeyaml:1.30 CVE-2022-41854 MEDIUM
+41
View File
@@ -0,0 +1,41 @@
$ mvn org.owasp:dependency-check-maven:13.0.0:check -DautoUpdate=false -Dformats=JSON (log, trimmed)
[INFO] Finished Jar Analyzer (0 seconds)
[INFO] Finished CPE Analyzer (2 seconds)
[INFO] Finished NVD CVE Analyzer (0 seconds)
[WARNING] Sonatype OSS Index Analyzer disabled due to missing credentials. Authentication with token is now required, and OSS Index is migrating to Sonatype Guide. See https://dependency-check.github.
[INFO] Finished Known Exploited Vulnerability Analyzer (0 seconds)
[INFO] Analysis Complete (3 seconds)
[INFO] Writing JSON report to: <module>/target/dependency-check-report.json
[INFO] BUILD SUCCESS
[INFO] Total time: 5.526 s
wall clock seconds: 7
$ one line per finding: component, id, label:cvss
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2022-42003 HIGH:7.5
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2023-35116 MEDIUM:4.7
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-50193 MEDIUM:7.5
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-54512 HIGH:8.1
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-54513 HIGH:8.1
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-54514 MEDIUM:5.3
com.fasterxml.jackson.core:jackson-databind:2.13.4 CVE-2026-54515 MEDIUM:5.3
org.apache.commons:commons-lang3:3.11 CVE-2025-48924 MEDIUM:5.3
org.apache.commons:commons-text:1.9 CVE-2022-42889 CRITICAL:9.8
org.apache.logging.log4j:log4j-api:2.14.1 CVE-2026-34477 MEDIUM:5.9
org.apache.logging.log4j:log4j-api:2.14.1 CVE-2026-34479 MEDIUM:7.5
org.apache.logging.log4j:log4j-api:2.14.1 CVE-2026-49844 MEDIUM:5.9
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2021-44228 CRITICAL:10.0
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2021-44832 MEDIUM:6.6
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2021-45046 CRITICAL:9.0
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2021-45105 MEDIUM:5.9
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2025-68161 MEDIUM:4.8
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2026-34477 MEDIUM:5.9
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2026-34479 MEDIUM:7.5
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2026-34480 MEDIUM:7.5
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2026-49844 MEDIUM:5.9
org.yaml:snakeyaml:1.30 CVE-2022-1471 CRITICAL:9.8
org.yaml:snakeyaml:1.30 CVE-2022-25857 HIGH:7.5
org.yaml:snakeyaml:1.30 CVE-2022-38749 MEDIUM:6.5
org.yaml:snakeyaml:1.30 CVE-2022-38750 MEDIUM:5.5
org.yaml:snakeyaml:1.30 CVE-2022-38751 MEDIUM:6.5
org.yaml:snakeyaml:1.30 CVE-2022-38752 MEDIUM:6.5
org.yaml:snakeyaml:1.30 CVE-2022-41854 MEDIUM:6.5
@@ -0,0 +1,26 @@
$ mvn org.owasp:dependency-check-maven:13.0.0:update-only -DdataDirectory=<dir> -DretireJsAnalyzerEnabled=false -DnvdDatafeedUrl=https://nvd.nist.gov/feeds/json/cve/2.0/nvdcve-2.0-{0}.json.gz
(first build of the database, empty data directory; the 26 "Download Started" lines are omitted)
[INFO] Scanning for projects...
[INFO]
[INFO] -------------------------------< x:warm >-------------------------------
[INFO] Building warm 1
[INFO] from pom.xml
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- dependency-check:13.0.0:update-only (default-cli) @ warm ---
[INFO] Checking for updates
[INFO] NVD API Cache / Data Feed requires several updates; this could take a couple of minutes.
[INFO] Begin database maintenance
[INFO] Updated the CPE ecosystem on 153865 NVD records
[INFO] Removed the CPE ecosystem on 5366 NVD records
[INFO] End database maintenance (41084 ms)
[INFO] Updating CISA Known Exploited Vulnerability list: https://www.cisa.gov/sites/default/files/feeds/known_exploited_vulnerabilities.json
[INFO] Begin database defrag
[INFO] End database defrag (11462 ms)
[INFO] Check for updates complete (360919 ms)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 06:03 min
[INFO] Finished at: 2026-11-29T02:02:34+05:30
[INFO] ------------------------------------------------------------------------
@@ -0,0 +1,9 @@
$ mvn org.owasp:dependency-check-maven:13.0.0:update-only (no -DnvdDatafeedUrl, no NVD API key)
[DEBUG] requesting URI: https://services.nvd.nist.gov/rest/json/cves/2.0?resultsPerPage=2000&startIndex=0
[DEBUG] Status Code: 404
[DEBUG] Reason: Not Found
[DEBUG] Key : message ,Value : Invalid apiKey.
Caused by: io.github.jeremylong.openvulnerability.client.nvd.NvdApiException: Invalid API Key, length of 0 too short to provided a masked partial key
[INFO] BUILD FAILURE
[ERROR] Failed to execute goal org.owasp:dependency-check-maven:13.0.0:update-only (default-cli) on project orders: An exception occurred while downloading updates. Please see the log file for more details. Error updatin
Caused by: io.github.jeremylong.openvulnerability.client.nvd.NvdApiException: Invalid API Key, length of 0 too short to provided a masked partial key
+35
View File
@@ -0,0 +1,35 @@
findings per component (advisory ids, deduplicated)
component osv-scanner trivy dependency-check
com.fasterxml.jackson.core:jackson-core:2.13.4 3 3 0
com.fasterxml.jackson.core:jackson-databind:2.13.4 12 12 7
commons-collections:commons-collections:3.2.1 2 0 0
org.apache.commons:commons-lang3:3.11 1 1 1
org.apache.commons:commons-text:1.9 1 1 1
org.apache.logging.log4j:log4j-api:2.14.1 1 1 3
org.apache.logging.log4j:log4j-core:2.14.1 8 8 9
org.yaml:snakeyaml:1.30 7 7 7
TOTAL (component, id) pairs 35 33 28
reported by every tool: 24
reported by only some tools (O = osv-scanner, T = trivy, D = dependency-check)
OT- CVE-2025-52999 com.fasterxml.jackson.core:jackson-core:2.13.4
OT- CVE-2026-68494 com.fasterxml.jackson.core:jackson-core:2.13.4
OT- CVE-2026-89425 com.fasterxml.jackson.core:jackson-core:2.13.4
--D CVE-2023-35116 com.fasterxml.jackson.core:jackson-databind:2.13.4
OT- CVE-2026-19032 com.fasterxml.jackson.core:jackson-databind:2.13.4
OT- CVE-2026-59889 com.fasterxml.jackson.core:jackson-databind:2.13.4
OT- CVE-2026-77310 com.fasterxml.jackson.core:jackson-databind:2.13.4
OT- CVE-2026-83557 com.fasterxml.jackson.core:jackson-databind:2.13.4
OT- CVE-2026-91776 com.fasterxml.jackson.core:jackson-databind:2.13.4
OT- CVE-2026-91777 com.fasterxml.jackson.core:jackson-databind:2.13.4
O-- CVE-2015-6420 commons-collections:commons-collections:3.2.1
O-- CVE-2015-7501 commons-collections:commons-collections:3.2.1
--D CVE-2026-34477 org.apache.logging.log4j:log4j-api:2.14.1
--D CVE-2026-34479 org.apache.logging.log4j:log4j-api:2.14.1
--D CVE-2026-49844 org.apache.logging.log4j:log4j-core:2.14.1
same advisory, different severity bucket
CVE-2026-50193 jackson-databind osv=HIGH trivy=MEDIUM dc=MEDIUM
CVE-2021-45105 log4j-core osv=HIGH trivy=HIGH dc=MEDIUM
CVE-2022-1471 snakeyaml osv=HIGH trivy=HIGH dc=CRITICAL
+35
View File
@@ -0,0 +1,35 @@
== CVE-2026-34479: which artifact does the advisory describe?
$ curl -s https://api.osv.dev/v1/vulns/CVE-2026-34479 | jq -r .summary
Apache Log4j 1 to Log4j 2 bridge: Silent log event loss in Log4j1XmlLayout due to unescaped XML 1.0 forbidden characters
$ unzip -l target/lib/log4j-core-2.14.1.jar | grep -c Log4j1XmlLayout
0
$ unzip -l target/lib/log4j-api-2.14.1.jar | grep -c Log4j1XmlLayout
0
$ ls target/lib | grep -c "log4j-1.2-api"
0
== where each tool attached CVE-2026-34479
osv org.apache.logging.log4j:log4j-core:2.14.1
trivy org.apache.logging.log4j:log4j-core:2.14.1
dc org.apache.logging.log4j:log4j-api:2.14.1
dc org.apache.logging.log4j:log4j-core:2.14.1
== CVE-2023-35116 (reported only by dependency-check): the NVD description
jackson-databind-2.13.4.jar CVE-2023-35116 MEDIUM
jackson-databind through 2.15.2 allows attackers to cause a denial of service or other unspecified impact via a crafted object that uses cyclic dependencies. NOTE: the vendor's perspective is that this is not a valid vulnerability report, because the steps of constructing a cyclic data structure and trying to serialize it cannot be achieved by an external attacker.
== CVE-2026-49844: OSV attaches it to log4j-api only; dependency-check also attaches it to log4j-core
org.apache.logging.log4j:log4j-api:2.14.1 CVE-2026-49844
org.apache.logging.log4j:log4j-core:2.14.1 CVE-2026-49844
GHSA-qv9r-c865-cp47 affects: ['org.apache.logging.log4j:log4j-api']
== why dependency-check misses 9 jackson advisories (3 jackson-core, 6 jackson-databind): NVD status of each id
CVE-2025-52999 status: Deferred has CPE configurations: False
CVE-2026-68494 status: Awaiting Analysis has CPE configurations: False
CVE-2026-89425 status: Deferred has CPE configurations: False
CVE-2026-19032 status: Awaiting Analysis has CPE configurations: False
CVE-2026-59889 status: Awaiting Analysis has CPE configurations: False
CVE-2026-77310 status: Deferred has CPE configurations: False
CVE-2026-83557 status: Awaiting Analysis has CPE configurations: False
CVE-2026-91776 status: Deferred has CPE configurations: False
CVE-2026-91777 status: Deferred has CPE configurations: False
+12
View File
@@ -0,0 +1,12 @@
osv-scanner: 35 findings with no config
osv-scanner: 34 with config/osv-scanner.toml (ignoreUntil 2027-03-01)
osv-scanner: 35 with config/osv-scanner-expired.toml (ignoreUntil 2026-01-01, already past)
trivy: 33 findings with no ignore file
trivy: 32 with config/trivyignore.yaml
trivy: 33 with config/trivyignore-expired.yaml
dependency-check: 28 findings with no suppression file
dependency-check: 25 with config/dc-suppressions.xml
dependency-check: 28 with config/dc-suppressions-expired.xml
dependency-check suppressed (kept in the report, not counted): ['CVE-2023-35116', 'CVE-2026-34479']
+26
View File
@@ -0,0 +1,26 @@
$ mvn cyclonedx:makeAggregateBom -> target/bom.json
bomFormat CycloneDX specVersion 1.6
components: 8
pkg:maven/org.apache.logging.log4j/[email protected]?type=jar
pkg:maven/org.apache.logging.log4j/[email protected]?type=jar
pkg:maven/org.apache.commons/[email protected]?type=jar
pkg:maven/org.apache.commons/[email protected]?type=jar
pkg:maven/com.fasterxml.jackson.core/[email protected]?type=jar
pkg:maven/com.fasterxml.jackson.core/[email protected]?type=jar
pkg:maven/com.fasterxml.jackson.core/[email protected]?type=jar
pkg:maven/org.yaml/[email protected]?type=jar
$ trivy sbom target/bom.json
findings: 33 (same scan from the manifest: 33)
$ osv-scanner scan source -L target/bom.json
Scanned <module>/target/bom.json file and found 8 packages
findings: 33 (same scan from pom.xml: 35)
difference between osv-scanner on pom.xml (<) and on the SBOM (>):
16,17d15
< commons-collections:commons-collections:3.2.1 CVE-2015-6420
< commons-collections:commons-collections:3.2.1 CVE-2015-7501
$ the same SBOM with one component edited by hand (log4j-core 2.14.1 -> 2.26.1 in version and purl)
trivy findings on the edited SBOM: 25 (log4j-core findings: 0)
+22
View File
@@ -0,0 +1,22 @@
$ trivy rootfs target/lib (the real jars)
findings: 33
$ osv-scanner scan source -r --no-ignore target/lib (default plugins)
Starting filesystem walk for root: /
End status: 1 dirs visited, 9 inodes visited, 0 Extract calls, 132.787µs elapsed, 132.871µs wall time
No package sources found, --help for usage information.
$ osv-scanner scan source -r --no-ignore --x-plugins java/archive target/lib
End status: 1 dirs visited, 9 inodes visited, 8 Extract calls, 7.273061ms elapsed, 7.273144ms wall time
findings: 33
$ dependency-check (the Maven plugin always analyses the resolved jars; it has no manifest-only mode)
findings: 28. How it recognised jackson-databind-2.13.4.jar:
cpe:2.3:a:fasterxml:jackson-core:2.13.4:*:*:*:*:*:*:* confidence HIGHEST
cpe:2.3:a:fasterxml:jackson-databind:2.13.4:*:*:*:*:*:*:* confidence HIGHEST
cpe:2.3:a:fasterxml:jackson-modules-java8:2.13.4:*:*:*:*:*:*:* confidence LOW
pkg:maven/com.fasterxml.jackson.core/[email protected] confidence HIGH
$ osv-scanner scan source --no-ignore --x-plugins java/archive target/orders-1.0.0.jar (the thin application jar)
No issues found
+24
View File
@@ -0,0 +1,24 @@
== exit codes on the vulnerable project
osv-scanner (no flag): exit 1
4 finding(s) with CVSS >= 9.0
osv-scanner + scripts/gate.py 9.0: exit 1
trivy --exit-code 1 --severity CRITICAL: exit 1
trivy (no --exit-code): exit 0
dependency-check -DfailBuildOnCVSS=9: exit 1
[ERROR] Failed to execute goal org.owasp:dependency-check-maven:13.0.0:check (default-cli) on project orders:
[ERROR] One or more dependencies were identified with vulnerabilities that have a CVSS score greater than or equal to '9.0':
dependency-check -DfailBuildOnCVSS=11: exit 0
== the same project with -Pfixed (all flagged dependencies moved to current releases)
runtime jars: commons-lang3-3.22.0.jar commons-text-1.15.0.jar jackson-annotations-2.23.jar jackson-core-2.23.0.jar jackson-databind-2.23.0.jar log4j-api-2.26.1.jar log4j-core-2.26.1.jar snakeyaml-2.7.jar
osv-scanner on the SBOM: exit 0; findings: 0
trivy sbom --exit-code 1: exit 0; findings: 0
dependency-check -Pfixed -DfailBuildOnAnyVulnerability=true: exit 0
dependency-check findings: 0
== scope: a vulnerable test-scope dependency (commons-collections 3.2.1, pom.xml at its default versions)
osv-scanner on pom.xml:
| https://osv.dev/GHSA-6hgm-866r-3cjv | | Maven | commons-collections:commons-collections (dev) | 3.2.1 | 3.2.2 | pom.xml |
| https://osv.dev/GHSA-fjq5-5j5f-mvxh | 9.8 | Maven | commons-collections:commons-collections (dev) | 3.2.1 | 3.2.2 | pom.xml |
trivy fs pom.xml: 0 commons-collections findings
dependency-check (jars): 0 commons-collections findings
+15
View File
@@ -0,0 +1,15 @@
== what each tool keeps on disk
dependency-check H2 database: 246M
trivy cache: 3.2G (db 1.8G, java-db 1.5G)
osv-scanner: nothing, it queries api.osv.dev (unless --offline-vulnerabilities)
== wall clock seconds, warm caches, this 2-vCPU sandbox
osv-scanner scan source -L pom.xml: 1.3
trivy fs pom.xml (docker run): 1.3
trivy sbom bom.json (docker run): 0.3
dependency-check:check (DB present): 5.7
== osv-scanner offline mode: download the Maven database once, then scan from it (the network was not cut for this run)
Total 8 packages affected by 35 known vulnerabilities (4 Critical, 12 High, 18 Medium, 0 Low, 1 Unknown) from 1 ecosystem.
cache size: 11M
offline findings: 35 (online: 35)