# EU CRA CISA KEV & ENISA EUVD Lockfile & SBOM Scanner

> Deterministic, zero-dependency lockfile and CycloneDX/SPDX SBOM scanner correlating CISA KEV, ENISA EUVD, and OSV/GHSA across npm, pnpm, Cargo, Go, PyPI, Poetry, and Maven.
> Canonical URL: https://craswitch.dev/docs/cisa-kev-enisa-euvd-lockfile-scanner
> LLM Index: https://craswitch.dev/llms.txt

## 1. Zero-Auth CLI Quickstart (`@craswitch/cli`)

```bash
# Scan current workspace lockfiles offline (zero auth, zero external runtime deps)
npx -y @craswitch/cli scan --json

# Scan a pre-built CycloneDX 1.6 or SPDX 2.3 SBOM file
npx -y @craswitch/cli scan --sbom dist/app.cdx.json --json

# Optional: enrich against live craswitch.dev CISA KEV + ENISA EUVD + OSV feed
npx -y @craswitch/cli scan --remote --json
```

## 2. GitHub Action Workflow (`theperipetycompany/cra-switch-action@v1`)

```yaml
# Continuous lockfile scanning on every push, PR, and release tag
      - uses: theperipetycompany/cra-switch-action@v1
        with:
          fail-on-confirmed: 'true'
          out-dir: '.cra-switch'
```

## 3. Hosted Stateless Scan Endpoint (POST /api/v1/scan)

```
curl -sS -X POST "https://craswitch.dev/api/v1/scan" \
  -H "Content-Type: application/json" \
  -d '{"kind":"package-lock.json","repo":"acme-eu/payments-sdk","content":"..."}'
```

## Supported Zero-Dependency Lockfile & SBOM Parsers

| Format / File | Ecosystem | Scope & PURL Normalization |
| --- | --- | --- |
| package-lock.json (v1/v2/v3) | npm | Separates prod vs dev; canonical pkg:npm/... PURLs |
| pnpm-lock.yaml (v6/v9) | npm | Strips peer suffixes; separates prod vs dev |
| Cargo.lock | cargo | Exact crate versions -> pkg:cargo/... |
| go.sum | golang | Deduplicates /go.mod entries -> pkg:golang/... |
| requirements.txt / poetry.lock | pypi | PEP 503 name normalization; strips dev/test groups -> pkg:pypi/... |
| pom.xml | maven | Resolves Maven properties; excludes test scope -> pkg:maven/... |
| cyclonedx.json / spdx.json | All (incl. C/C++/Docker) | CycloneDX 1.6 & SPDX 2.3 SBOM PURL extraction |

## Key Guardrails & Facts

- Zero external runtime dependencies and zero code execution: lockfiles are parsed as static text/JSON/XML/TOML.
- Hosted CRA-Switch polls CISA KEV, ENISA EUVD, and OSV/GHSA every 15 minutes and correlates PURL-less KEV/EUVD records against package-level OSV ranges.
- Dev-only dependencies are automatically excluded from production exploit alerts to eliminate false positives.

## Related CRA-Switch Guides & Free Utilities

- Interactive tool: [Open Interactive Lockfile Scanner](https://craswitch.dev/tools/scanner)
- Canonical LLM index: [llms.txt](https://craswitch.dev/llms.txt)
- Developer API & MCP reference: [/docs/api](https://craswitch.dev/docs/api)
- [EU CRA Article 14 GitHub Action](https://craswitch.dev/docs/eu-cra-article-14-github-action) ([Markdown](https://craswitch.dev/docs/eu-cra-article-14-github-action.md))
- [ENISA SRP 24h Worksheet JSON](https://craswitch.dev/docs/enisa-srp-early-warning-worksheet) ([Markdown](https://craswitch.dev/docs/enisa-srp-early-warning-worksheet.md))
- [.cra-vex.json & OpenVEX Ed25519](https://craswitch.dev/docs/cra-vex-openvex-ed25519) ([Markdown](https://craswitch.dev/docs/cra-vex-openvex-ed25519.md))

> DRAFT COMPLIANCE AID ONLY — NOT LEGAL ADVICE. CRA-Switch aggregates public vulnerability feeds (CISA KEV, ENISA EUVD, OSV/GHSA) on a best-effort basis and NEVER auto-submits reports to ENISA. The software vendor remains solely responsible for verifying exploitability and submitting official Article 14 notifications via https://portal.cra-srp.enisa.europa.eu within statutory deadlines.
