scan_repo
Inventory cryptography in one local directory tree by scanning source, config, CI and infrastructure files, returning each algorithm with file, line, family and coverage.
Instructions
Inventory the cryptography inside one local directory tree, file by file.
Reads source, configuration (nginx.conf, sshd_config, .ini, .toml), CI pipelines,
Terraform and Kubernetes manifests under path. Returns each algorithm found with
its file and line, the mathematical family and standing of every post-quantum
scheme, and a coverage count.
Use this to answer what a specific project on this machine actually uses. Do not
use it to ask whether this server knows a given algorithm, or to explain how one is
classified without scanning anything -- list_algorithms answers that from the same
table and reads no files. It is also the wrong tool for a network endpoint, a
running host or a certificate store: it opens files on disk and nothing else.
Coverage is reported as a fraction with a base. files_scanned + unreadable_files + files_skipped_by_type + the linked files in symlinks_not_followed == files_present;
a link is not followed and is named, not read. A file that could not be opened is listed,
never counted as scanned, because no findings in a file nobody read is not the same
as a file that is clean. Files skipped because this tool does not claim their type
are counted by extension, so the reader can judge the boundary rather than assume
past it.
The owner's own settings apply and are reported, never silent: a .qrp.toml at the
root (its excludes are listed under coverage.not_examined as excluded_by_config;
its baseline marks rows new or baselined), and qrp:ignore <family> <reason> comments,
whose rows move to suppressed with the reason and are counted in
coverage.suppressed; a marker past its until=YYYY-MM-DD no longer applies and is
listed as expired.
The result also says where this version may miss, read from the finished result
without changing any row: operation_closure (the (operation, ecosystem) pairs whose
documented spellings this version tests one by one), ecosystems (each ecosystem of
the files read, closed, partially closed or not closed against that catalogue),
angles (dependency, code and configuration where they disagree),
chosen_outside_files.leads (includes and key paths followed to the files read) and
where_to_look. None of these enters the findings or their fingerprint, and the CBOM
from export_cbom does not carry them.
Cost scales with the size of the tree, so a large monorepo takes proportionally longer; there is no cache and no partial mode.
Quoted lines are masked by default. Reading happens on this machine, but this
result does not stay on it: it is returned to a model, which is a place the
scanned line has not been before. A secret sharing a line with a finding -- a
token in the call that names the cipher -- would travel with it. Masking keeps
what a reader needs (the algorithm, the file, the line number, the shape of the
call) and removes what nobody asked for. Pass level="full" when the line
itself is the thing being examined.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>"
},
"name": "scan_repo"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Directory to scan, absolute or relative to the working directory: a checked-out repository, a service directory, a config tree. Vendored, build and cache directories (.git, node_modules, vendor, venv, .venv, dist, build, target, .tox, __pycache__, .pytest_cache, .mypy_cache, .ruff_cache) are excluded and do not count toward files_present; the verdict names how many files each one held, .git excepted. | |
| level | No | How much of each matched line to return. `masked` (the default) keeps the characters that spell the algorithm and stars every other letter and digit; `full` returns the line as written; `trimmed` returns no line at all. File and line number are the same at every level. | masked |
| profile | No | Whose rules each `replacement` follows. `nist` (the default) is FIPS 203/204/205. The others read one national document each and say whom it addresses: us-cnsa2 (NSA, US National Security Systems), uk-ncsc, au-ism, ca-cccs, de-bsi, fr-anssi, nl-ncsc, eu-eccg (EU product certification), bg (no Bulgarian guidance found; EU roadmap dates). Detection is identical under every profile. | nist |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||