NIKX-Tech / NIKX-Tech/numx

ntt: validate against PQClean reference implementation

Open
#87 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

pqc security validation
Dominant language
C
Stars
23
Forks
2
PR merge metrics
No merged PRs in 30d

Description

The NTT module's known-answer tests validated the fast NTT against a naive
O(n^2) reference multiplication written for this project, not an
independent ground truth. A shared systematic error (wrong root of unity,
wrong modulus constant) in both the fast and "reference" path would have
passed every test.

Fixed in #86: numx_ntt_forward and numx_ntt_polymul are now additionally
cross-validated bit-for-bit against PQClean's ml-kem-512 (FIPS 203,
formerly CRYSTALS-Kyber-512) reference implementation. See
validation/reference/ntt/README.md for provenance (pinned commit,
Montgomery-domain reasoning, regeneration steps).

This sets the pattern #67 (NIST KAT test-vector integration for
Kyber/Dilithium) should follow: external, independently-citable ground
truth, not internal self-consistency.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Read validation/reference/ntt/README.md for the PQClean provenance, pinned commit, Montgomery-domain reasoning, and regeneration steps, then inspect the changes referenced as fixed in #86. Compare that validation pattern with the NIST KAT integration requested in #67; done means independently citable, bit-for-bit external test coverage rather than only internal self-consistency.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
cryptography, testing-qa
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.