cve-lite-cli 1.26.0 → 1.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +131 -399
- package/dist/cli/args.js +6 -0
- package/dist/cli/help.js +3 -3
- package/dist/cli/overrides.js +20 -16
- package/dist/index.js +16 -38
- package/dist/output/debug.js +2 -1
- package/dist/output/formatters.js +9 -0
- package/dist/output/html-reporter.js +113 -95
- package/dist/output/logos.js +1 -1
- package/dist/output/override-findings-html.js +9 -3
- package/dist/output/override-findings-sarif.js +34 -24
- package/dist/output/override-findings-terminal.js +19 -2
- package/dist/output/sarif.js +14 -6
- package/dist/overrides/context-builder.js +29 -0
- package/dist/overrides/detectors/index.js +6 -0
- package/dist/overrides/detectors/oa009-stale-floor.js +80 -0
- package/dist/overrides/detectors/pd001-override-only-phantom.js +32 -0
- package/dist/overrides/detectors/pd002-transitive-only-phantom.js +34 -0
- package/dist/overrides/detectors/phantom-utils.js +21 -0
- package/dist/overrides/fixer.js +21 -1
- package/dist/scan/multi-folder-scan.js +6 -8
- package/dist/usage/scanner.js +60 -1
- package/dist/utils/network.js +11 -0
- package/dist/utils/sarif.js +4 -0
- package/dist/utils/severity.js +6 -0
- package/package.json +2 -1
package/dist/utils/severity.js
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
import { chalk } from "./chalk.js";
|
|
2
|
+
import { severityOrder } from "../constants.js";
|
|
3
|
+
import { normalizeSeverity } from "../osv/severity.js";
|
|
2
4
|
export const SEVERITY_ORDER = ["critical", "high", "medium", "low", "unknown", "none"];
|
|
5
|
+
export function reachesFailOn(findings, failOn) {
|
|
6
|
+
const failLevel = normalizeSeverity(failOn);
|
|
7
|
+
return findings.some((f) => severityOrder[f.severity] >= severityOrder[failLevel]);
|
|
8
|
+
}
|
|
3
9
|
export function formatSeverityLabel(severity) {
|
|
4
10
|
const lower = severity.toLowerCase();
|
|
5
11
|
if (lower === "critical")
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cve-lite-cli",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.27.0",
|
|
4
4
|
"description": "Developer-friendly CLI for scanning JS/TS projects for dependency vulnerabilities using local lockfiles and OSV",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
"lint:tests": "node scripts/check-test-hygiene.mjs",
|
|
16
16
|
"pretest": "node scripts/check-test-hygiene.mjs",
|
|
17
17
|
"test": "node --experimental-vm-modules ./node_modules/jest/bin/jest.js --passWithNoTests",
|
|
18
|
+
"build:fixture-db": "node scripts/build-fixture-db.mjs",
|
|
18
19
|
"test:watch": "node --experimental-vm-modules ./node_modules/jest/bin/jest.js --watch --passWithNoTests"
|
|
19
20
|
},
|
|
20
21
|
"dependencies": {
|