5
0
Fork
You've already forked sable
0

feat/reusable-fuzzy-extractor #1

Merged
hugooconnor merged 6 commits from feat/reusable-fuzzy-extractor into main 2026年02月23日 03:01:04 +01:00

This branch adds a reusable fuzzy extractor for deterministic biometric commitments and deploys the web demo to Cloudflare Pages + Fly.io.

Reusable Fuzzy Extractor

  • Core crypto modules: GF(256) finite field arithmetic, Reed-Solomon error correction, and a Juels-Wattenberg fuzzy commitment scheme
    (core/src/crypto/{gf256.rs, reed_solomon.rs, fuzzy_commitment.rs})
  • Construction: Code-offset sketch + RS over GF(256) + SHA-256, with default params of t=40 per block (~75 correctable positions out of 512,
    2800-bit entropy)
  • Performance (release, Apple Silicon): Gen ~21us, Rep ~93us
  • Demo endpoints: POST /api/fuzzy/{enroll,verify,check-unique} with FuzzyCommitment enrollment mode opt-in

Web Demo Deployment

  • Backend on Fly.io: Hardened Dockerfile (nightly Rust, non-root user, multi-stage build), environment-based config (PORT, BIND_ADDRESS,
    ALLOWED_ORIGINS), health check at /api/health
  • Frontend on Cloudflare Pages: Static SPA deploy with VITE_API_URL pointing to Fly.io backend, wrangler.toml config
  • Custom domain: sable.anuna.io via Cloudflare CNAME

Other Improvements

  • Relaxed spatial liveness thresholds for 4-quadrant mode
  • Show flash pattern used during liveness on authentication screen
  • Architecture diagram (ABSM + fuzzy commitment)
  • Fixed webcam race condition where stopWebcam() could null the overlay canvas while async face detection was in-flight

Commits

3a8292b fix: relax spatial liveness thresholds for 4-quadrant mode
be12b3a feat: show flash pattern used during liveness on authentication screen
df548b2 feat: add deterministic fuzzy commitment and ABSM architecture diagram
d21629f feat: add fuzzy commitment mode to web demo enrollment UI
23e70c5 feat: add reusable fuzzy extractor for deterministic biometric commitments
e21d509 feat: deploy web demo to Cloudflare Pages + Fly.io

29 files changed, +4731 / -926

This branch adds a reusable fuzzy extractor for deterministic biometric commitments and deploys the web demo to Cloudflare Pages + Fly.io. Reusable Fuzzy Extractor - Core crypto modules: GF(256) finite field arithmetic, Reed-Solomon error correction, and a Juels-Wattenberg fuzzy commitment scheme (core/src/crypto/{gf256.rs, reed_solomon.rs, fuzzy_commitment.rs}) - Construction: Code-offset sketch + RS over GF(256) + SHA-256, with default params of t=40 per block (~75 correctable positions out of 512, 2800-bit entropy) - Performance (release, Apple Silicon): Gen ~21us, Rep ~93us - Demo endpoints: POST /api/fuzzy/{enroll,verify,check-unique} with FuzzyCommitment enrollment mode opt-in Web Demo Deployment - Backend on Fly.io: Hardened Dockerfile (nightly Rust, non-root user, multi-stage build), environment-based config (PORT, BIND_ADDRESS, ALLOWED_ORIGINS), health check at /api/health - Frontend on Cloudflare Pages: Static SPA deploy with VITE_API_URL pointing to Fly.io backend, wrangler.toml config - Custom domain: sable.anuna.io via Cloudflare CNAME Other Improvements - Relaxed spatial liveness thresholds for 4-quadrant mode - Show flash pattern used during liveness on authentication screen - Architecture diagram (ABSM + fuzzy commitment) - Fixed webcam race condition where stopWebcam() could null the overlay canvas while async face detection was in-flight Commits 3a8292b fix: relax spatial liveness thresholds for 4-quadrant mode be12b3a feat: show flash pattern used during liveness on authentication screen df548b2 feat: add deterministic fuzzy commitment and ABSM architecture diagram d21629f feat: add fuzzy commitment mode to web demo enrollment UI 23e70c5 feat: add reusable fuzzy extractor for deterministic biometric commitments e21d509 feat: deploy web demo to Cloudflare Pages + Fly.io 29 files changed, +4731 / -926
Implement code-offset fuzzy commitment scheme (Juels-Wattenberg 1999)
as an optional enrollment mode for unique-set deduplication. Uses
Reed-Solomon error correction over GF(2^8) to derive stable commitments
from noisy biometric data.
New modules:
- crypto/gf256: GF(2^8) arithmetic with log/exp lookup tables (poly 0x11D)
- crypto/reed_solomon: RS(n,k) encoder/decoder (Berlekamp-Massey + Forney)
- crypto/fuzzy_commitment: Gen/Rep algorithms over two RS(255,k) blocks
Demo server endpoints:
- POST /api/fuzzy/enroll: enroll with fuzzy commitment mode
- POST /api/fuzzy/verify: reproduce commitment from fresh biometric
- POST /api/fuzzy/check-unique: deduplicate against existing enrollments
Default t=40 corrects ~75/512 differing positions. Gen ~21μs, Rep ~93μs.
Existing Pedersen + ZK enrollment flow is completely unchanged.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add a mode toggle on the enrollment screen so users can choose between
Pedersen (default) and Fuzzy Commitment enrollment. Fuzzy mode calls the
/api/fuzzy/* endpoints, displays the deterministic SHA-256 commitment and
helper data, and provides a simplified verification flow that skips ZK
proof generation.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Switch fuzzy enrollment to binary quantization (sign bit) and
deterministic RS codeword derivation so the same person always produces
the same commitment. Add ABSM architecture diagram to the home screen
illustrating how ZK set membership proofs compose fuzzy commitments,
Merkle trees, liveness, and nullifiers at 100M+ scale.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Display the 3-round quadrant color cards on the auth screen after proof
generation so the user can see exactly which colors were flashed.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Adjacent quadrants are physically closer together on the face than the
old top/bottom halves, producing smaller angular differences in reflected
light. Raise SPATIAL_DIFF_MAX_SIMILARITY from 0.998 to 0.9995 and lower
MIN_PASSING_ROUNDS from 3 to 2 to reduce false rejections while still
rejecting flat photos/screens.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Harden Dockerfile for production (nightly Rust, non-root user, make/clang for jemalloc)
- Add env var config to Axum server (PORT, BIND_ADDRESS, ALLOWED_ORIGINS)
- Add fly.toml for Fly.io deployment (sjc region, 512MB, health checks)
- Add wrangler.toml for Cloudflare Pages
- Frontend built with VITE_API_URL pointing to Fly.io backend
- Fix webcam race condition: guard overlay canvas after async detectFace()
- Add .dev.vars to .gitignore
- Add Hence deployment plan (docs/plans/cloudflare-deploy.spl)
Backend: https://sable-demo.fly.dev
Frontend: https://sable-demo.pages.dev
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
hugooconnor deleted branch feat/reusable-fuzzy-extractor 2026年02月23日 03:01:06 +01:00
Sign in to join this conversation.
No reviewers
Labels
Clear labels
No items
No labels
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
anuna/sable!1
Reference in a new issue
anuna/sable
No description provided.
Delete branch "feat/reusable-fuzzy-extractor"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?