Skip to content

Conversation

@nsarlin-zama
Copy link
Contributor

@nsarlin-zama nsarlin-zama commented Nov 17, 2025

closes: please link all relevant issues

PR content/description

Generate test vector for some algorithms in core crypto (encryption, decryption, addition, scalar mul, ks, ms, br, se).

The adds a check in pcc that re-generate the vectors and check that they have not been modified.

Check-list:

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)
  • Relevant issues are marked as resolved/closed, related issues are linked in the description
  • Check for breaking changes (including serialization changes) and add them to commit message following the conventional commit specification

This change is Reviewable

@cla-bot cla-bot bot added the cla-signed label Nov 17, 2025
@nsarlin-zama nsarlin-zama force-pushed the ns/chore/test-vectors branch 3 times, most recently from 37ecce8 to 77ecc39 Compare November 21, 2025 16:56
@nsarlin-zama nsarlin-zama marked this pull request as ready for review November 21, 2025 16:57
@IceTDrinker
Copy link
Member

apps/test-vectors/src/main.rs line 298 at r2 (raw file):

    let mut readme_path = PathBuf::new();
    readme_path.push(DATA_DIR);
    readme_path.push("README.md");

can we maybe iterate on dir content and remove all that is not README.md ?

@IceTDrinker
Copy link
Member

apps/test-vectors/data/README.md line 72 at r2 (raw file):

```rust
const RAND_SEED: u128 = 0x74666865;

do not replicate consts from the code, they will likey diverge if we have to update the code ?

Copy link
Contributor Author

@nsarlin-zama nsarlin-zama left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: 0 of 38 files reviewed, 1 unresolved discussion (waiting on @IceTDrinker, @mayeul-zama, and @soonum)


apps/test-vectors/data/README.md line 72 at r2 (raw file):

Previously, IceTDrinker wrote…

do not replicate consts from the code, they will likey diverge if we have to update the code ?

we need those in the README if we send it without the associated code.

I added a comment with the params in the code to remind us to update the readme if we ever modify the parameters. Having a script to do that feels a bit over engineered right now.


apps/test-vectors/src/main.rs line 298 at r2 (raw file):

Previously, IceTDrinker wrote…

can we maybe iterate on dir content and remove all that is not README.md ?

done

Copy link
Member

@IceTDrinker IceTDrinker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@IceTDrinker reviewed 37 of 38 files at r1, 1 of 1 files at r2, 1 of 1 files at r3, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @mayeul-zama and @soonum)

@nsarlin-zama nsarlin-zama merged commit fc78450 into main Nov 25, 2025
234 of 242 checks passed
@nsarlin-zama nsarlin-zama deleted the ns/chore/test-vectors branch November 25, 2025 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants