Repository navigation
R2: automatic claims check (pqdocket check) - #10
Merged
Merged
Conversation
- pqdocket check works out which claims apply (no classical key establishment; uses ML-KEM; uses post-quantum signatures), checks each against the scan, CBOMs from other tools and disproof checks, and prints Verified / Partly shown / Unknown / Not met with evidence and next steps - Disproof checks look where the scan does not: key files, Dockerfiles and deploy scripts, web server DH/ECDH settings, classical-only TLS group lists, pre-standard Kyber/Dilithium names, dependency manifests - Claims saved to pqdocket-claims.json and re-checked on later runs; disabled claims stay off; plain-English claims via pqdocket claim - Text matching alone never reaches Verified; docs and images do not block it, unknown file types do; pqdocket's own outputs are never evidence - Verdicts JSON (schemas/verdicts.schema.json), unsigned: signing is opt-in - Version 0.3.0
- A CBOM only counts as evidence for Verified if its assets point at files that exist in the checked folder; otherwise the gap says so - FN-DSA/Falcon found only in a CBOM is capped at Partly shown - build/, dist/, target/ are now checked; dependency folders are named in the limits; symlinks and unreadable folders are listed as gaps - Build files, manifests and key files get the full crypto rules - OpenSSH, generic public keys and unrecognised id_rsa/id_ecdsa files count as possible counter-evidence - pqdocket's own outputs recognised by content, not file name; the --output file is excluded, so repeated runs give the same answer - Folder claims about another target are not judged on this folder - Files too large or unreadable for a check become coverage gaps - Claims file field types are validated - One regression test per finding
Path.glob("tests/**") matches only folders before Python 3.13, so excluded
test folders were still scanned on 3.11 and 3.12.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
R2:
pqdocket checkworks out which post-quantum migration claims apply to a project, checks each one (including attempts to disprove it), and reports Verified / Partly shown / Unknown / Not met, with evidence and the next step for every gap. No typing needed; signing stays opt-in.What's new
pqdocket check [folder]pqdocket-claims.json; disabled claims stay off.--cbom,--exclude "tests/**",--details,--output(schemaschemas/verdicts.schema.json).openssl dhparam,ssh-keygen -t rsa)pqdocket claim "api.example.com uses hybrid ML-KEM"adds a claim in plain English and echoes what it understood.scan_pathgainsincludeandskip_dirs.Independent review
A separate reviewer that hadn't seen the work checked the spec and the diff. It found 11 issues, mostly ways to reach Verified too easily. All are fixed, each with a regression test, and the reviewer's reproduction folders no longer produce a wrong Verified. Cause and fix are in
.altru/LESSONS.md.Checks
pytest: 134 passed (41 new)ruff check .: cleanmypy src: cleanSpec:
.altru/specs/r2-check.mdGenerated by Claude Code