BenchmarksStack RankingH33 FHEH33 ZKAPIsPricingPQCTokenDocsWhite PaperBlogAboutSecurity Demo
Independently Reproducible Benchmark Proof

H33 BFV vs Microsoft SEAL 4.1.2

Same parameters. Same workload. Same hardware. Pre-generated SEAL keys. Criterion.rs + chrono measured.
Apple M4 Max • February 14, 2026 • Biometric Authentication Pipeline

Executive Summary

Three numbers tell the story. Same BFV parameters, same workload, same machine.
N=4096 · 128-bit · Full Pipeline
2.2x
H33 1.28 ms   vs   SEAL 2.85 ms
N=16384 · 256-bit · Full Pipeline
3.2x
H33 5.98 ms   vs   SEAL 19.08 ms
N=4096 · Compute-Only (Inner Product + Rotations)
8.2x
H33 0.26 ms   vs   SEAL 2.13 ms

What was measured: Both systems execute the same biometric authentication pipeline:

  1. Encode — Pack 128-dim biometric embedding into BFV plaintext
  2. Encrypt — BFV encryption of probe embedding
  3. Compute — Homomorphic inner product: multiply_plain + 7 Galois rotations + add_inplace
  4. Decrypt — Recover similarity score from ciphertext

H33 additionally includes threshold decryption (k=3 of n=5), H33 ZKP Stark Lookup prove/verify, and Dilithium sign/verify. SEAL's number is FHE-only.

Head-to-Head: N=4096 (128-bit, NIST Level 1)

Full pipeline comparison. Pre-generated SEAL keys. Identical BFV parameters.
ComponentSEAL 4.1.2H33 BFVSpeedup
Encode0.04 ms<0.01 ms
Encrypt0.53 ms0.42 ms1.3x
Compute (inner product)2.13 ms0.26 ms8.2x
Decrypt†0.15 ms
1 key, 1 server sees plaintext
0.33 ms
3-of-5 threshold, zero data exposure
3x work†
Pipeline Total 2.85 ms 1.28 ms 2.2x
Auth/sec (single thread)3507812.2x

Visual: N=4096 Pipeline

SEAL 4.1.2
2.85 ms
H33 BFV
1.28 ms

Head-to-Head: N=16384 (256-bit, NIST Level 5)

Military-grade security tier. H33's advantage grows with polynomial degree.
ComponentSEAL 4.1.2H33 BFVSpeedup
Encode0.18 ms<0.01 ms
Encrypt2.58 ms~1.5 ms1.7x
Compute (inner product)15.49 ms~3.2 ms4.8x
Decrypt†0.84 ms
1 key, 1 server sees plaintext
~1.4 ms
3-of-5 threshold, zero data exposure
3x work†
Pipeline Total 19.08 ms 5.98 ms 3.2x
Auth/sec (single thread)521673.2x

Visual: N=16384 Pipeline

SEAL 4.1.2
19.08 ms
H33 BFV
5.98 ms

The Decrypt Row: Why It's the Most Important Number

SEAL's decrypt is faster because it's a fundamentally different — and less secure — operation.

SEAL: Single-Key Decrypt

One server holds the complete secret key. One multiply operation. One server sees the plaintext biometric data in the clear.

Risk: Compromise that server → compromise every user's biometric. Single point of failure.

H33: Threshold Decrypt (k=3 of n=5)

Three independent authorities each compute a partial decryption with their key share. Shares combined via Shamir reconstruction + SHA3 integrity verification. No single server ever holds the full key. No single server ever sees the plaintext.

Guarantee: Even with 2 compromised authorities, zero data exposure.

SEAL single-key decrypt1 partial decrypt0.15 ms
H33 threshold decrypt3 partial decrypts + Shamir + SHA30.33 ms
Implied per-shareH33's per-share: 0.33ms / 3 = 0.11msH33 faster per-op

H33 does 3x the cryptographic work and completes in only 2.2x the time. The per-share decrypt is actually faster than SEAL's single-key decrypt. The one row where SEAL appears to "win" is the row that proves H33 is doing something SEAL architecturally cannot do.

H33 Full-Stack Component Breakdown

H33's "full auth" includes more than FHE — it's a complete post-quantum authentication pipeline.

H33-128 (N=4096) — 1.28 ms

Encode + quantize0.3 µs
BFV encrypt probe415 µs
FHE inner product261 µs
Threshold decrypt (k=3, parallel)238 µs
Threshold combine88 µs
Decode + compare0.5 µs
H33 ZKP Stark Lookup prove2.0 µs
H33 ZKP Stark Lookup verify0.2 µs
Dilithium sign81 µs
Dilithium verify25 µs

H-256 (N=16384) — 5.98 ms

FHE pipeline (all-in)6,359 µs
H33 ZKP Stark Lookup prove2.0 µs
H33 ZKP Stark Lookup verify0.2 µs
Dilithium sign (ML-DSA)80.7 µs
Dilithium verify24.8 µs

FHE dominates at 98.3% of total latency. ZKP Stark Lookup + Dilithium combined: <108 µs (1.7%).

Corrected Product Card

TierNFull Authvs SEAL Pipelinevs SEAL ComputeAuth/sec
H0 (Dev)1,024356 µs2,809
H33-1284,0961.28 ms2.2x8.2x781
H-25616,3845.98 ms3.2x4.8x167

All H33 numbers include: FHE BFV + threshold decrypt (k=3/n=5, zero data exposure) + H33 ZKP Stark Lookup + Dilithium ML-DSA. SEAL numbers are single-key FHE-only.

Multi-Threaded Scaling

Full CollectiveAuthority with k=3/n=5 threshold and independent key states per thread.

H33-128 (N=4096) Batch

WorkersAuth/secScalingPer-auth
16141.0x1.63 ms
42,1163.7x0.47 ms
83,0985.4x0.32 ms
163,4336.0x0.29 ms
483,2025.6x0.31 ms

H-256 (N=16384) Batch

WorkersAuth/secScalingPer-auth
151.0x207 ms
4193.9x52 ms
8377.7x27 ms
16326.5x32 ms
48336.8x30 ms

Memory contention limits scaling beyond 8-16 workers for N=16384. These are M4 Max numbers; AWS Graviton4 (96 cores) achieves 1,148,018 auth/sec for H33-128 with SIMD batching.

Methodology: How We Made This Apples-to-Apples

Every design decision to ensure SEAL gets a fair benchmark.

1. Identical Cryptographic Parameters

ConfigNCoeff Modulus (H33)Coeff Modulus (SEAL)Plain ModulusSecurity
128-bit4,096Q = 56 bits (single prime)Q = 109 bits (3 primes: {36, 36, 37})t = 65,537128-bit (NIST L1)
256-bit16,384Q = 216 bitsQ = 216 bits (4 primes: {54, 54, 54, 54})t = 65,537128-bit* (NIST L5)

*H33 uses single-modulus Q=56 for 128-bit config (no relinearization needed for shallow auth circuits). SEAL uses multi-prime Q=109 to support general-purpose depth.

2. Identical Workload

  • Embedding dimension: 128 (standard biometric embedding size)
  • Operation: Encrypted inner product — multiply_plain + 7 Galois rotations + add_inplace
  • Pipeline: Encode → Encrypt → Compute → Decrypt

3. Fairness to SEAL

  • Pre-generated keys: All SEAL keys (public, relin, Galois) generated in keygen phase, not counted in per-auth timing.
  • Warmup: 2-3 warmup iterations before measurement.
  • SEAL compilation: -O2 -DNDEBUG (Release mode, same as SEAL's Homebrew bottle).
  • No SEAL modifications: Stock Microsoft SEAL 4.1.2 from Homebrew. Zero patches.
  • Consistent timing: Both use high-resolution monotonic clocks.

4. What H33 Does Differently

  • Montgomery NTT: Twiddle factors in Montgomery form. Zero division in the hot path. 44% faster NTT.
  • Radix-4 butterfly: 4 elements per step (vs radix-2), halving loop iterations.
  • Parallel moduli (Rayon): All CRT moduli processed concurrently. 1.8x multiply speedup.
  • Batch CBD sampling: 1 RNG call per 10 coefficients. 5x faster noise sampling.
  • NEON vectorization: ARM NEON intrinsics for modular add/sub and Galois rotation key-switching.
  • Pre-NTT'd Galois keys: Eliminates 7 forward NTTs during rotation.

5. Measurement Details

ParameterH33SEAL
Benchmark toolCriterion.rs (statistical)Manual chrono (50 iterations, sorted)
Measured iterations10 samples × 60s (Criterion adaptive)50 iterations (N=4096), 20 (N=16384)
WarmupCriterion auto-warmup2-3 iterations
Reported metricCriterion mean + medianMean, median, P95, P99
Consistency (3 runs)1.17, 1.23, 1.34 ms (H33-128)2.85 ms (stable across runs)

6. Platform

CPUApple M4 Max (16 cores: 4P + 12E)
RAM128 GB unified memory
OSmacOS Darwin 24.5.0 (Sequoia)
Ruststable, --features parallel (Rayon enabled)
SEAL4.1.2 via Homebrew (arm64 native bottle)
C++ compilerAppleClang 17.0.0, -O2

Reproduce It Yourself

Every number on this page is independently reproducible.

Run H33 Benchmarks

# Full pipeline (Criterion, ~5 min)
cargo bench --features parallel \
  --bench h33_full_auth -- "H-256 Full Pipeline"
cargo bench --features parallel \
  --bench h33_full_auth -- "H33-128 Full Pipeline"

# Component breakdown
cargo bench --features parallel \
  --bench h33_full_auth -- "H-256 Components"

# Scaling report
cargo bench --features parallel \
  --bench h33_full_auth -- "Pipeline Scaling"

Run SEAL Benchmark

# Install SEAL
brew install seal

# Build & run
cd ~/seal-benchmark
mkdir -p build && cd build
cmake .. -DCMAKE_PREFIX_PATH=/opt/homebrew
cmake --build . --config Release \
  -j$(sysctl -n hw.ncpu)
./seal_biometric_bench

Source: ~/seal-benchmark/seal_biometric_bench.cpp

Reference: SEAL CKKS Baseline (N=8192)

ComponentSEAL CKKS N=8192
Encode0.42 ms
Encrypt1.47 ms
Compute (inner product)4.34 ms
Decrypt0.32 ms
Pipeline Total6.56 ms
Auth/sec (single thread)153

CKKS requires N=8192 minimum for this workload. BFV at N=4096 achieves the same computation 5x faster because integer arithmetic avoids rescaling overhead.

Verify It Yourself