Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
97 commits
Select commit Hold shift + click to select a range
95b8c6f
feat: add verifier server
Bisht13 Sep 1, 2025
6e08d42
chore: update README
Bisht13 Sep 1, 2025
a637ad6
fix: optional pk/vk and better error handling
ashpect Sep 2, 2025
091c7ab
fix: process control, real time logging, timeout handling and fix doc…
ashpect Sep 2, 2025
e44a62d
fix: kill binary child and limit concurrent req
ashpect Sep 4, 2025
c1a3ced
chore: fmt
ashpect Sep 4, 2025
593efaa
get pk/vk from cache if url not provided
ashpect Sep 5, 2025
c4def09
fix: use cancellationtoken
ashpect Sep 5, 2025
a992658
chore: update readme and cleanup
ashpect Sep 5, 2025
3544792
fix: merkle verification for constant transcript length
shreyas-londhe Sep 11, 2025
8f5ffd0
fix: update whir dependency and add deduplication and merkle proof st…
shreyas-londhe Sep 12, 2025
008b243
chore: update poseidon bench
shreyas-londhe Sep 15, 2025
bf5f43b
chore: update whir dep
shreyas-londhe Sep 17, 2025
12aaabf
chore: cargo clippy
shreyas-londhe Sep 17, 2025
9b156dc
Merge remote-tracking branch 'origin/sl/recursive-support' into px/ve…
ashpect Sep 18, 2025
702ace3
fix: update whir config
shreyas-londhe Sep 18, 2025
8d9e23b
Merge remote-tracking branch 'origin/sl/recursive-support' into px/ve…
ashpect Sep 18, 2025
f2e43d1
increase timeout
ashpect Sep 18, 2025
f8e69f3
Merge branch 'main' into px/verifier-server
ashpect Sep 18, 2025
8dd0909
cleanup
ashpect Sep 18, 2025
179561a
chore: cleanup
ashpect Sep 19, 2025
1524a36
Merge branch 'main' into sl/recursive-support
Bisht13 Sep 19, 2025
9a1f428
Merge pull request #185 from worldfnd/sl/recursive-support
Bisht13 Sep 19, 2025
8af86f2
Merge branch 'main' into px/verifier-server
ashpect Sep 20, 2025
fd0a512
cleanup
ashpect Sep 20, 2025
4790201
Merge pull request #173 from worldfnd/px/verifier-server
ashpect Sep 22, 2025
d848314
feat(span-stats): include current memory in span start/close output
Bisht13 Sep 22, 2025
5551e2d
Merge pull request #197 from worldfnd/feat/span-stats-current-mem
ashpect Sep 22, 2025
905a022
fix: cli flag for generate gnark and ci fix for dynamic bench files g…
ashpect Sep 23, 2025
eed1485
fix: run bencmark only run with cargo bench, not cargo test
ashpect Sep 23, 2025
53c652f
chore: cleanup
ashpect Sep 23, 2025
71f61e0
NTT: init bn254 NTT crate
xrvdg Aug 26, 2025
121d839
NTT: initialize reverse ordered roots
xrvdg Aug 26, 2025
e3a23de
NTT: executable for profiling
xrvdg Aug 26, 2025
39e0602
NTT: documentation and TODOs
xrvdg Aug 26, 2025
78273f1
NTT: power of 2 checks
xrvdg Aug 27, 2025
52b3678
NTT: cover edge cases when degree <=2
xrvdg Aug 28, 2025
f25110e
NTT: first set of test generator
xrvdg Aug 28, 2025
27d1c2a
NTT: proptest return right sized vector
xrvdg Aug 28, 2025
2e9e0b0
NTT: inverse NTT
xrvdg Aug 28, 2025
6639ec2
NTT: round trip tests
xrvdg Aug 28, 2025
a1129d7
NTT: split NTT into separate file
xrvdg Aug 29, 2025
f9f69fb
Remove test for Vec2n
xrvdg Aug 29, 2025
55015d9
NTT: NTT datatype
xrvdg Aug 29, 2025
20e7ca7
NTT: dit nr cache with combinators
xrvdg Aug 29, 2025
8d332a1
NTT extra comments
xrvdg Sep 1, 2025
176486d
fixup! NTT extra comments
xrvdg Sep 1, 2025
217ea36
NTT: debug asserts for reverse_bits
xrvdg Sep 1, 2025
4df356e
NTT: new testing strategy
xrvdg Sep 24, 2025
949775e
NTT: remove old testing strategy
xrvdg Sep 24, 2025
3907906
NTT: more documentation
xrvdg Sep 24, 2025
1a23628
Merge pull request #174 from worldfnd/xr/ntt
xrvdg Sep 24, 2025
7157735
fix: add nargo execute
ashpect Sep 24, 2025
e26340e
Merge pull request #200 from worldfnd/ash/bench-automate
shreyas-londhe Sep 25, 2025
8176253
feat: implement layering in Solve_witness_vec
shreyas-londhe Sep 22, 2025
1bef178
chore: cargo fmt
shreyas-londhe Sep 22, 2025
f450d56
fix: layer build deadlock
shreyas-londhe Sep 22, 2025
2754b03
chore: cargo fmt
shreyas-londhe Sep 22, 2025
16431e6
chore: cargo doc
shreyas-londhe Sep 23, 2025
c0d490f
chore: cargo doc
shreyas-londhe Sep 23, 2025
5639be8
fix: mem optimization and minor refactoring
shreyas-londhe Sep 23, 2025
9a11a68
fix: noir_sha256 example
shreyas-londhe Sep 23, 2025
8379b02
feat: add sha256_compression init
shreyas-londhe Sep 23, 2025
1a3251e
feat: add add_u32_addition precompile
shreyas-londhe Sep 23, 2025
e6f43b4
feat: add shr and rotr precompiles
shreyas-londhe Sep 24, 2025
7c22019
feat: add sigma0 precompile
shreyas-londhe Sep 24, 2025
fb3385d
feat: add sigma1 precompile
shreyas-londhe Sep 24, 2025
267318f
feat: add cap_sigma0 precompile
shreyas-londhe Sep 24, 2025
c3a55f0
feat: add cap_sigma1 precompile
shreyas-londhe Sep 24, 2025
2985282
feat: add add_ch precompile
shreyas-londhe Sep 24, 2025
e24b7b7
feat: add add_maj precompile
shreyas-londhe Sep 24, 2025
faefc93
feat: add add_message_schedule_expansion precompile
shreyas-londhe Sep 24, 2025
9a61cb5
feat: add add_sha256_round precompile
shreyas-londhe Sep 24, 2025
88d8830
feat: add add_sha256_compression precompile
shreyas-londhe Sep 24, 2025
f053985
feat: add U32Addition WitnessBuilder
shreyas-londhe Sep 24, 2025
a1edd3e
feat: sha256 working
shreyas-londhe Sep 24, 2025
c8d1772
fix: update complete_age_check with native sha256
shreyas-londhe Sep 24, 2025
2d9c9b4
chore: rebase changes
shreyas-londhe Sep 24, 2025
700e70f
chore: update poseidon bench
shreyas-londhe Sep 22, 2025
2e3605d
chore: decrease dsc cert size
0xVikasRushi Sep 19, 2025
1a66c0d
feat: optimize native sha256
0xVikasRushi Sep 23, 2025
a9b0bbf
feat: add verifier server
Bisht13 Sep 1, 2025
5c10605
fix: merkle verification for constant transcript length
shreyas-londhe Sep 11, 2025
ffd3ce7
fix: update whir dependency and add deduplication and merkle proof st…
shreyas-londhe Sep 12, 2025
798b1f5
feat(ffi): add provekit-ffi
Bisht13 Sep 22, 2025
aa5baa9
memory optimisations
veljkovranic Sep 18, 2025
22131af
memory fix
veljkovranic Sep 18, 2025
23fc10d
fmt
veljkovranic Sep 19, 2025
9ea4f59
cleanup
veljkovranic Sep 19, 2025
d447dd4
chore: cargo clippy
shreyas-londhe Sep 17, 2025
fed35de
perf(prover): consume objects to reduce persistent memory
Bisht13 Sep 22, 2025
323df7a
feat(prover): optimize WHIR R1CS implementation and sumcheck utilities
Bisht13 Sep 22, 2025
f0c0c44
dirty 6.13 GB
Bisht13 Sep 22, 2025
0bcb0b0
dirty
Bisht13 Sep 26, 2025
20f3c81
Move provekit-input-gen to tooling and allow to use it over FFI.
Sep 29, 2025
9155b8c
Format.
Sep 29, 2025
4349b1c
update ffi
Bisht13 Oct 3, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 47 additions & 8 deletions .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,28 +10,61 @@ on:
env:
DIVAN_MAX_TIME: 30
CODSPEED_RUNNER_MODE: walltime

jobs:
build:
name: Build benchmark binaries
name: Build benchmark binaries and poseidon_1000 artifacts
runs-on: ubuntu-22.04-arm
steps:
- uses: actions/checkout@v4

- name: Setup Rust toolchain, cache and cargo-codspeed binary
uses: moonrepo/setup-rust@v1
with:
channel: nightly-2025-04-05
cache-base: main
cache-target: release
bins: cargo-codspeed

- name: Setup Noir toolchain
uses: noir-lang/noirup@v0.1.2
with:
toolchain: v1.0.0-beta.11

- name: Build the benchmark target(s)
timeout-minutes: 30
run: cargo codspeed build

- name: Upload benchmark binaries
uses: actions/upload-artifact@v4
with:
name: benchmark-binaries
path: target/codspeed

- name: Compile and execute Nargo circuit
working-directory: noir-examples/poseidon-rounds
run: |
nargo compile --skip-brillig-constraints-check --force
nargo execute

- name: Create posiedon rounds 1000 files
run: |
cargo run --release --bin provekit-cli prepare ./noir-examples/poseidon-rounds/target/basic.json -o ./noir-examples/poseidon-rounds/noir-proof-scheme.nps
cargo run --release --bin provekit-cli prove ./noir-examples/poseidon-rounds/noir-proof-scheme.nps ./noir-examples/poseidon-rounds/Prover.toml -o ./noir-examples/poseidon-rounds/noir-proof.np
cargo run --release --bin provekit-cli generate-gnark-inputs ./noir-examples/poseidon-rounds/noir-proof-scheme.nps ./noir-examples/poseidon-rounds/noir-proof.np --params ./noir-examples/poseidon-rounds/params_for_recursive_verifier --r1cs ./noir-examples/poseidon-rounds/r1cs.json

- name: Prepare poseidon artifacts directory
run: |
mkdir -p ./poseidon-artifacts
cp ./noir-examples/poseidon-rounds/noir-proof-scheme.nps ./poseidon-artifacts/
cp ./noir-examples/poseidon-rounds/noir-proof.np ./poseidon-artifacts/
cp ./noir-examples/poseidon-rounds/r1cs.json ./poseidon-artifacts/

- name: Upload poseidon-1000 files
uses: actions/upload-artifact@v4
with:
name: poseidon-1000-files
path: ./poseidon-artifacts/

benchmark:
name: Run benchmarks on Raspberry Pi 5
Expand All @@ -46,6 +79,12 @@ jobs:
name: benchmark-binaries
path: ./bench_bin

- name: Download poseidon-1000 files
uses: actions/download-artifact@v4
with:
name: poseidon-1000-files
path: ./poseidon-artifacts/

- name: Setup rust toolchain, cache and cargo-codspeed binary
uses: moonrepo/setup-rust@v1
with:
Expand All @@ -68,13 +107,13 @@ jobs:
- name: Make benchmark binaries executable
run: chmod -R +x target/codspeed

- name: Verify codspeed installation
- name: Copy poseidon-rounds files to correct directory
run: |
echo "cargo-codspeed location:"
which cargo-codspeed
echo "codspeed-post-bench location:"
which codspeed-post-bench
cp ./poseidon-artifacts/noir-proof-scheme.nps noir-examples/poseidon-rounds/
cp ./poseidon-artifacts/noir-proof.np noir-examples/poseidon-rounds/
cp ./poseidon-artifacts/r1cs.json noir-examples/poseidon-rounds/
ls -la noir-examples/poseidon-rounds/

- name: Run the benchmarks
uses: CodSpeedHQ/action@v3
with:
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/end-to-end.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,19 +43,18 @@ jobs:
with:
go-version: 1.24

# nargo execute is a faulty command that should be removed when toml reader is implemented
- name: Compile and execute Nargo circuit
working-directory: noir-examples/noir-passport-examples/complete_age_check
run: |
nargo compile --skip-brillig-constraints-check --force
nargo execute
# basic.gz should be changed to .toml file in the future when faulty command is removed

- name: Generate Gnark inputs
working-directory: noir-examples/noir-passport-examples/complete_age_check
run: |
cargo run --release --bin provekit-cli prepare ./target/complete_age_check.json -o ./noir-proof-scheme.nps
cargo run --release --bin provekit-cli prove ./noir-proof-scheme.nps ./Prover.toml -o ./noir-proof.np
cargo run --release --bin provekit-cli generate-gnark-inputs ./noir-proof-scheme.nps ./noir-proof.np

- name: Run Gnark verifier
working-directory: recursive-verifier
run: |
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
*.np
params_for_recursive_verifier
params
artifacts/

# Don't ignore benchmarking artifacts
!tooling/provekit-bench/benches/*
Expand Down
31 changes: 24 additions & 7 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ members = [
"provekit/verifier",
"tooling/cli",
"tooling/provekit-bench",
"tooling/provekit-ffi",
"tooling/provekit-gnark",
]
exclude = [
"playground/passport-input-gen",
"tooling/provekit-input-gen",
"tooling/verifier-server",
"ntt",
]

[workspace.package]
Expand Down Expand Up @@ -54,7 +55,8 @@ missing_docs_in_private_items = { level = "allow", priority = 1 }
missing_safety_doc = { level = "deny", priority = 1 }

[profile.release]
debug = true # Generate symbol info for profiling
debug = 2
split-debuginfo = "packed"
opt-level = 3
codegen-units = 1
lto = "fat"
Expand All @@ -79,16 +81,21 @@ skyscraper = { path = "skyscraper/core" }
provekit-bench = { path = "tooling/provekit-bench" }
provekit-cli = { path = "tooling/cli" }
provekit-common = { path = "provekit/common" }
provekit-ffi = { path = "tooling/provekit-ffi" }
provekit-gnark = { path = "tooling/provekit-gnark" }
provekit-input-gen = { path = "tooling/provekit-input-gen" }
provekit-prover = { path = "provekit/prover" }
provekit-r1cs-compiler = { path = "provekit/r1cs-compiler" }
provekit-verifier = { path = "provekit/verifier" }
provekit-verifier-server = { path = "tooling/verifier-server" }

# 3rd party
anyhow = "1.0.93"
argh = "0.1.12"
axum = "0.8.4"
base64 = "0.22.1"
bytes = "1.10.1"
chrono = "0.4.41"
divan = { package = "codspeed-divan-compat", version = "3.0.1" }
hex = "0.4.3"
paste = "1.0.15"
Expand All @@ -100,12 +107,18 @@ quickcheck_macros = "1.0.0"
rand = "0.9.1"
rand08 = { package = "rand", version = "0.8" }
rayon = "1.10.0"
reqwest = "0.12.23"
ruint = { version = "1.12.3", features = ["num-traits", "rand"] }
seq-macro = "0.3.6"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
sha2 = "0.10.9"
test-case = "3.3.1"
toml = "0.8.8"
tokio = { version = "1.47.1", features = ["full"] }
tokio-util = "0.7.13"
tower = "0.5.2"
tower-http = { version = "0.6.6", features = ["cors", "timeout", "trace"] }
tracing = "0.1.41"
tracing-subscriber = { version = "0.3.18", features = ["env-filter", "ansi"] }
tracing-tracy = "=0.11.4"
Expand All @@ -127,12 +140,16 @@ noirc_artifacts = { git = "https://github.com/noir-lang/noir", rev = "v1.0.0-bet
noirc_driver = { git = "https://github.com/noir-lang/noir", rev = "v1.0.0-beta.11" }

# Cryptography and proof systems
ark-bn254 = { version = "0.5.0", default-features = false, features = ["scalar_field"] }
ark-bn254 = { version = "0.5.0", default-features = false, features = [
"scalar_field",
] }
ark-crypto-primitives = { version = "0.5", features = ["merkle_tree"] }
ark-ff = { version = "0.5", features = ["asm", "std"] }
ark-poly = "0.5"
ark-serialize = "0.5"
ark-std = { version = "0.5", features = ["std"] }
spongefish = { git = "https://github.com/arkworks-rs/spongefish", features = ["arkworks-algebra"] }
spongefish = { git = "https://github.com/arkworks-rs/spongefish", features = [
"arkworks-algebra",
] }
spongefish-pow = { git = "https://github.com/arkworks-rs/spongefish" }
whir = { git = "https://github.com/WizardOfMenlo/whir/", features = ["tracing"], rev = "0077be285ec3ae29de71bf605866a6b3a30f726a" }
whir = { git = "https://github.com/WizardOfMenlo/whir/", features = ["tracing"], rev = "22c675807fc9295fef68a11945713dc3e184e1c1" }
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
dg1 = [60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 48, 55, 48, 49, 48, 49, 60, 60, 51, 50, 48, 49, 48, 49, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 0, 0]
dg1_padded_length = 95
current_date = 1758096872
current_date = 1758300539
min_age_required = 18
max_age_required = 70

Expand All @@ -20,5 +20,5 @@ csc_rsa_exponent = 65537
dg1_hash_offset = 0
econtent_hash_offset = 0
dsc_pubkey_offset_in_dsc_cert = 9
dsc_cert = [48, 130, 1, 10, 2, 130, 1, 1, 0, 144, 96, 22, 98, 202, 23, 238, 6, 187, 83, 246, 10, 141, 149, 39, 62, 150, 207, 25, 76, 254, 121, 159, 193, 25, 17, 64, 229, 112, 170, 152, 94, 212, 213, 4, 191, 8, 183, 225, 184, 213, 181, 211, 100, 210, 60, 155, 26, 13, 219, 11, 116, 84, 236, 33, 212, 47, 5, 187, 226, 120, 161, 57, 97, 200, 250, 174, 139, 216, 171, 95, 178, 148, 109, 3, 137, 151, 245, 142, 53, 177, 251, 74, 202, 2, 157, 33, 55, 30, 189, 239, 243, 101, 183, 43, 68, 245, 198, 9, 90, 109, 89, 109, 33, 98, 32, 173, 121, 203, 2, 79, 68, 150, 135, 158, 72, 76, 223, 55, 66, 30, 45, 33, 16, 91, 153, 158, 127, 64, 221, 31, 151, 241, 93, 105, 235, 153, 176, 146, 221, 20, 231, 141, 2, 146, 77, 209, 30, 90, 33, 33, 232, 176, 145, 244, 229, 221, 43, 101, 10, 210, 55, 50, 200, 103, 87, 18, 82, 53, 193, 130, 124, 69, 96, 179, 87, 245, 203, 181, 205, 57, 67, 181, 80, 198, 57, 101, 151, 179, 103, 201, 243, 52, 68, 91, 122, 137, 209, 141, 39, 68, 73, 244, 200, 211, 125, 2, 176, 12, 80, 77, 81, 225, 169, 34, 209, 187, 212, 47, 56, 92, 220, 159, 89, 236, 133, 200, 211, 11, 237, 217, 129, 115, 191, 208, 39, 198, 179, 16, 28, 59, 121, 160, 48, 239, 81, 144, 102, 168, 122, 158, 59, 83, 54, 91, 211, 2, 3, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
dsc_cert = [48, 130, 1, 10, 2, 130, 1, 1, 0, 144, 96, 22, 98, 202, 23, 238, 6, 187, 83, 246, 10, 141, 149, 39, 62, 150, 207, 25, 76, 254, 121, 159, 193, 25, 17, 64, 229, 112, 170, 152, 94, 212, 213, 4, 191, 8, 183, 225, 184, 213, 181, 211, 100, 210, 60, 155, 26, 13, 219, 11, 116, 84, 236, 33, 212, 47, 5, 187, 226, 120, 161, 57, 97, 200, 250, 174, 139, 216, 171, 95, 178, 148, 109, 3, 137, 151, 245, 142, 53, 177, 251, 74, 202, 2, 157, 33, 55, 30, 189, 239, 243, 101, 183, 43, 68, 245, 198, 9, 90, 109, 89, 109, 33, 98, 32, 173, 121, 203, 2, 79, 68, 150, 135, 158, 72, 76, 223, 55, 66, 30, 45, 33, 16, 91, 153, 158, 127, 64, 221, 31, 151, 241, 93, 105, 235, 153, 176, 146, 221, 20, 231, 141, 2, 146, 77, 209, 30, 90, 33, 33, 232, 176, 145, 244, 229, 221, 43, 101, 10, 210, 55, 50, 200, 103, 87, 18, 82, 53, 193, 130, 124, 69, 96, 179, 87, 245, 203, 181, 205, 57, 67, 181, 80, 198, 57, 101, 151, 179, 103, 201, 243, 52, 68, 91, 122, 137, 209, 141, 39, 68, 73, 244, 200, 211, 125, 2, 176, 12, 80, 77, 81, 225, 169, 34, 209, 187, 212, 47, 56, 92, 220, 159, 89, 236, 133, 200, 211, 11, 237, 217, 129, 115, 191, 208, 39, 198, 179, 16, 28, 59, 121, 160, 48, 239, 81, 144, 102, 168, 122, 158, 59, 83, 54, 91, 211, 2, 3, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
dsc_cert_len = 270
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ use std::hash::sha256_compression;
pub mod ryan_sha256_noir;
pub(crate) mod ryan_sha256_compression;
pub(crate) mod ryan_sha256_constants;
mod tests;

fn is_id_card(dg1: [u8; 95]) -> bool {
// For passport, the last two bytes are 0
Expand Down
Loading