Metadata-Version: 2.1
Name: cve-compass
Version: 1.0.0
Summary: Check the dependency files you choose against recent public security advisories, locally.
Home-page: https://cve-compass.org
Project-URL: Homepage, https://cve-compass.org
Project-URL: Run locally, https://cve-compass.org/local
Keywords: security,advisories,cve,ghsa,kev,lockfile,dependencies
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Topic :: Security
License: MIT
Classifier: License :: OSI Approved :: MIT License
Requires-Python: >=3.10
Description-Content-Type: text/markdown

# cve-compass

A private, daily check: do any security advisories published in the last 24 hours affect the dependency files you choose? Matching happens on your machine, and nothing about your project is sent.

```
uvx cve-compass init
uvx cve-compass check
```

Or run `pipx run cve-compass check`, or install it with `pip install cve-compass`. Python 3.10 or newer. It has no dependencies; Python 3.11 or newer is needed to read `poetry.lock` and `uv.lock`.

- `init` looks for dependency files under the current directory by name only. It skips `node_modules`, virtual environments and hidden directories, never opens a file, and saves the files you pick to `.compass.json`.
- `check` reads only those files, or the files you name: `cve-compass check package-lock.json services/api/requirements.txt`. It makes one GET for the public 24-hour advisory window from [cve-compass.org](https://cve-compass.org), which carries no inventory, and compares versions locally.

Supported: `package-lock.json` and `npm-shrinkwrap.json` (v1–v3), `pnpm-lock.yaml` (v5–v9), `yarn.lock` (classic and Berry), `requirements*.txt` with `name==version` pins, `Pipfile.lock`, `poetry.lock` and `uv.lock`. Anything else, unpinned lines and entries without a version are reported as unknown, never silently skipped.

The report lists potential matches (package, version, affected range, advisory link, whether CISA lists it as known exploited), then unknowns, then coverage: the window, the sources, and whether each was fresh.

**Run it every day.** Each check covers the last 24 hours. `cve-compass init --github-action` adds a GitHub Actions workflow that checks twice a day and fails on a potential match (`--fail-on-match`, exit 1) or a stale source (`--fail-on-stale`, exit 3). Elsewhere, use cron: `17 */12 * * * cd /path/to/project && uvx cve-compass check --fail-on-match --fail-on-stale`.

Options: `--json FILE` writes the full result; `--save-snapshot FILE` keeps the downloaded window; `--snapshot FILE` re-checks offline against a saved window.

A version match is a reason to investigate, not proof that a running service is exploitable. No matches means none in these sources, this 24-hour window and the inputs checked; it does not mean the stack is clean.

The hosted MCP server at `https://cve-compass.org/mcp` is optional and read-only: source freshness and exact CVE or GHSA lookups, no account or key. Never send it file contents or package lists.

Sources: [GitHub Advisory Database](https://github.com/advisories) (CC BY 4.0) and the [CISA Known Exploited Vulnerabilities Catalog](https://www.cisa.gov/known-exploited-vulnerabilities-catalog) (CC0).

The cve-compass code is released under the MIT License. Advisory data keeps its sources' terms, listed above.
