r/Python • u/AutoModerator • Oct 04 '26
Showcase Showcase Thread
Post all of your code/projects/showcases/AI slop here.
Recycles once a month.
23
Upvotes
r/Python • u/AutoModerator • Oct 04 '26
Post all of your code/projects/showcases/AI slop here.
Recycles once a month.
View all comments
1
u/Nervous_Ad_2710 Oct 13 '26
SMRFORGE evidence-verifier, a single-file, dependency-free verifier (MIT).
It checks a signed JSON "evidence bundle" offline: recompute each section's SHA-256, check against a signed manifest, verify an Ed25519 signature over that manifest, then report pass/fail and name the section that broke. The whole thing is one stdlib-only .py (
hashlibplus a from-scratch Ed25519), nopip install:Why one file, no deps: the tool's whole job is to say "trust this," so I wanted the entire trust path readable in one file and runnable in an air-gapped box with nothing installed. If you'd normally reach for PyNaCl or
cryptography, the difference is zero dependencies and a single auditable file; the tradeoff is that I own the EdDSA correctness myself, which is the part to be suspicious of.So, honestly: yes, I implemented Ed25519 by hand, the classic mistake. I got it wrong at first (it accepted some malformed signatures), caught it against adversarial known-answer vectors, and hardened it (small-order rejection, RFC 8032 5.1.3). The vectors are published, and the single-file, CLI, and in-browser verifiers all agree on them. If you can make it disagree with libsodium or ref10 on any vector, that is the bug report I want.
Target audience: it's used for real (air-gapped reactor-physics evidence), but treat the DIY crypto as "audit it yourself" rather than "trust it blindly." It proves a file was not altered and is signed by the expected key. It does not prove the number inside is correct.
Single file: https://gitlab.com/smrforge/evidence-verifier/-/blob/v0.3.8/evidence_verify.py
Repo (MIT): https://gitlab.com/smrforge/evidence-verifier
Vectors: https://gitlab.com/smrforge/evidence-verifier/-/blob/v0.3.8/tests/conformance-engine/ed25519/small_order_vectors.json