Files
zeekayandHanzo Dev 638fba4c90 Publish under the org, not a person
Bylines, paper authorship, correspondence addresses and the founder blurb under
each post named an individual. They name the organisation that published the
work instead: the brand on posts and pages, the research byline on papers, and
research@ in place of a personal address. Both are what these repositories
already used elsewhere — nothing new was coined.

Co-authors are untouched. Where a paper named someone else alongside, they stay
named; only the one byline changed. Bibliography entries, running heads,
PDF metadata and affiliations move with it, so a citation still resolves to
whoever the cited paper names.

Sample and fixture data uses the placeholder name these tests already use
elsewhere, so no assertion changed meaning.

Co-authored-by: Hanzo Dev <[email protected]>
2026-09-01 08:58:14 -07:00

102 lines
3.3 KiB
Lean4

/-
Authors: Antje Worring, Zoo Labs Foundation Research
Corona Threshold Lattice Signature Correctness
Models the Corona precompile (src/precompiles/corona-threshold/).
Corona is a post-quantum threshold signature scheme based on
LWE (Learning With Errors). It provides the same t-of-n threshold
property as FROST but with quantum resistance.
Maps to:
- src/precompiles/corona-threshold/contract.go: Verify
- src/precompiles/corona-threshold/ICoronaThreshold.sol: Interface
- luxfi/corona/threshold: Package
Key parameters (128-bit security):
- n_lwe = 630
- alpha_lwe = 3.2e-3
- q = 2^32
- sigma = alpha_lwe * q ~= 13,744 (Gaussian noise std dev)
Properties:
- Correctness: valid signatures verify
- PQ unforgeability: secure against quantum adversaries (LWE assumption)
- Threshold: t-of-n sharing
-/
import Mathlib.Data.Nat.Defs
import Mathlib.Tactic
namespace Crypto.Corona
/-- LWE parameters for 128-bit security -/
structure LWEParams where
n : Nat -- lattice dimension (630)
q : Nat -- modulus (2^32)
sigma : Nat -- Gaussian noise parameter (13744)
hn : 0 < n
hq : 0 < q
/-- Threshold parameters -/
structure ThresholdParams where
t : Nat
n : Nat
ht : t ≤ n
ht0 : 0 < t
/-- Corona signature (much larger than Schnorr: ~4KB vs 64 bytes) -/
structure CoronaSig where
size : Nat
hsize : size ≤ 20000 -- bounded at ~20KB max
/-- Correctness: honest threshold execution produces valid signature -/
axiom corona_correctness :
∀ (_lwe : LWEParams) (tp : ThresholdParams) (signers : Nat),
signers ≥ tp.t →
∃ (_sig : CoronaSig), True -- signature verifies
/-- PQ unforgeability: under LWE hardness assumption,
no quantum adversary can forge with fewer than t shares. -/
axiom corona_pq_unforgeability :
∀ (lwe : LWEParams) (tp : ThresholdParams) (compromised : Nat),
compromised < tp.t →
-- LWE with parameters (n, q, sigma) is hard for quantum computers
-- Fewer than t shares cannot produce a valid signature
∀ (sig : CoronaSig), sig.size > lwe.q
/-- Noise bounds: Gaussian noise must be within tolerance for correct decryption.
This is the critical security parameter -- too small = insecure,
too large = decryption failures. -/
theorem noise_bound_correct
(lwe : LWEParams)
(noise : Nat)
(hnoise : noise ≤ lwe.q / 4) :
noise < lwe.q := by
have := lwe.hq; omega
/-- Threshold property: t-of-n requires at least t signers -/
theorem threshold_minimum (tp : ThresholdParams) (signers : Nat)
(h : signers < tp.t) :
signers < tp.n := by have := tp.ht; omega
/-- Robustness: with n signers and up to n-t failures, still have t honest -/
theorem corona_robustness (tp : ThresholdParams) (failures : Nat)
(h : failures ≤ tp.n - tp.t) :
tp.n - failures ≥ tp.t := by have := tp.ht; omega
/-- Signature size is bounded -/
theorem sig_bounded (sig : CoronaSig) : sig.size ≤ 20000 := sig.hsize
/-- LWE dimension must be positive for security -/
theorem dimension_positive (lwe : LWEParams) : lwe.n > 0 := lwe.hn
/-- Security-performance tradeoff: larger n = more secure but slower.
At n=630, q=2^32: 128-bit classical + post-quantum security. -/
theorem standard_params_secure :
630 > 0 ∧ (2^32 : Nat) > 0 := by
constructor <;> omega
end Crypto.Corona