Skip to content

Commit c99b4c6

Browse files
test: implement main test vectors from wycheproof (#477)
Thanks to @ctz who implemented a basic structure to run these in in graviola, I ported running against the relevant test vectors from https://github.com/C2SP/wycheproof
1 parent d7fa156 commit c99b4c6

File tree

6 files changed

+335
-0
lines changed

6 files changed

+335
-0
lines changed

.github/workflows/ci.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ jobs:
3939
- stable
4040
steps:
4141
- uses: actions/checkout@v4
42+
with:
43+
submodules: recursive
4244
- uses: RustCrypto/actions/cargo-cache@master
4345
- uses: dtolnay/rust-toolchain@master
4446
with:
@@ -52,6 +54,8 @@ jobs:
5254
runs-on: ubuntu-latest
5355
steps:
5456
- uses: actions/checkout@v4
57+
with:
58+
submodules: recursive
5559
- uses: RustCrypto/actions/cargo-cache@master
5660
- uses: dtolnay/rust-toolchain@nightly
5761
- run: cargo update -Z minimal-versions
@@ -62,6 +66,8 @@ jobs:
6266
runs-on: ubuntu-latest
6367
steps:
6468
- uses: actions/checkout@v4
69+
with:
70+
submodules: recursive
6571
- uses: RustCrypto/actions/cargo-cache@master
6672
- uses: dtolnay/rust-toolchain@master
6773
with:

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "thirdparty/wycheproof"]
2+
path = thirdparty/wycheproof
3+
url = [email protected]:C2SP/wycheproof

Cargo.lock

Lines changed: 41 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,9 @@ rand_core = { version = "0.6", default-features = false }
4444
sha1 = { version = "=0.11.0-pre.4", default-features = false, features = ["oid"] }
4545
sha2 = { version = "=0.11.0-pre.4", default-features = false, features = ["oid"] }
4646
sha3 = { version = "=0.11.0-pre.4", default-features = false, features = ["oid"] }
47+
hex = { version = "0.4.3", features = ["serde"] }
48+
serde_json = "1.0.138"
49+
serde = { version = "1.0.184", features = ["derive"] }
4750

4851
[[bench]]
4952
name = "key"

0 commit comments

Comments
 (0)