Skip to content

Releases: Consensys-Incorporated/gnark-crypto

v0.22.0

Choose a tag to compare

@ivokub ivokub released this 02 Oct 12:02
550a513

⚠️ Breaking changes

  • BLS12-381/Jubjub: twisted-Edwards generator corrected (#821) — regenerate points, keys, and signatures derived from the previous generator.
  • BLS12-381/Bandersnatch EdDSA now runs on Bandersnatch instead of Jubjub (#882) — regenerate keys and signatures.
  • MamaBear Poseidon2 parameters corrected to R_F = 8, R_P = 32 for 128-bit security (#900) — digests are incompatible with the inherited schedule.
  • Go 1.26.8 is now required (go.mod), CI runs Go 1.26.x.

🔒 Security

  • ecdsa: reject identity and small-subgroup public keys in SetBytes (#889)
  • kzg: restore Vk.G1 from the generator in MpcSetup.ReadFrom — a deserialized setup previously carried Vk.G1 = ∞, letting arbitrary nonzero opening proofs verify (#891)
  • vortex: reject malformed opening proofs that could make a false evaluation claim verify (KoalaBear #896; MamaBear in this PR)
  • shplonk, fflonk: validate proof shape in BatchVerify to prevent panics (#892)
  • fft: validate domain cardinality in ReadFrom to prevent panic/OOM (#893)
  • field vectors: bound the vector length read by AsyncReadFrom (#878)

✨ New

  • MamaBear field (49-bit, p = 2⁴⁹ − 2³⁴ + 1): base field with AVX-512 IFMA kernels (R = 2⁵² Montgomery), degree-3 extension (~147-bit security), FFT (max NTT size 2³⁴), Poseidon2, SIS, IOP, and the experimental Vortex commitment scheme (#887)
  • kzg: Committer interface + OpenWithCommitter / BatchOpenSinglePointWithCommitter for externally accelerated quotient commitments (e.g. WebGPU/wasm MSM) (#879)

⚡ Faster

  • MamaBear IFMA vector kernels: mul 22.5×, scalarMul 22.7×, innerProduct 16.5×, sum 15.5× vs pure-Go at 2¹⁴ elements (still 5–9× at 2²⁴); E3 mul −12.5%, square −15.4%, lazy-reduction paths, Poseidon2 −7% (#887)

New Contributors

Full Changelog: v0.21.0...v0.22.0

v0.21.0

Choose a tag to compare

@gbotrel gbotrel released this 10 Aug 15:46
0a975d7

⚠️ Breaking Changes

  • FRI & Plookup relocated — The fri and plookup packages are gone from all curves. FRI primitives now live under field/koalabear.
  • Parallel goes public — internal/parallel is now exported as parallel; the worker pool moved to utils.
  • Stricter EdDSA key parsing:
    • PublicKey.SetBytes now rejects points outside the prime-order subgroup.
    • PrivateKey.SetBytes now rejects malformed scalars and public keys that don't match their scalar.
    • Keys that used to load may now error.

🔒 Security

  • shplonk & fflonk were missing subgroup membership checks on digests and proof points before verifying.
  • KZG MPC setup — Verify was checking the ratio on the previous SRS instead of the contributed one, and never bound the G1 update to the proof.
  • Subgroup membership tests added to all twistededwards curves.
  • Fp2.Sqrt returned a wrong result on (non-QR, 0) inputs.
  • Fixed a 4-byte overread in the innerProdVec AVX-512 path.

✨ New

  • Cube roots in Fp and Fp2.
  • FFT over degree-6 extensions for koalabear and babybear.
  • Generic BitReverse / BitReverseCopy helpers in utils.
  • Fixed-base scalar multiplication on twisted Edwards curves (used by eddsa).
  • secp256r1: Fp2 tower + Cardano cube-root solver.

⚡ Faster

  • 4-bit sliding window exponentiation across all fields.
  • Lazy-reduction 𝔽p2 multiplication assembly for BLS12-381, BLS12-377, BLS24-315 & BLS24-317, plus improved Expt/mulBySeed chains and faster hash-to-G1 in the highly 2-adic Fp case.
  • New SIMD work on the small fields:
    • AVX-512 & NEON kernels for Poseidon2 compression and VectorE6
    • AVX-512 batch ops for E6 FFT (2.97×)
    • Inlined E6 arithmetic for 31-bit primes (2.07×)
    • Unrolled FFT kernels

v0.20.1

Choose a tag to compare

@ivokub ivokub released this 17 Mar 10:33
49879af

This release contains correctness fix for vector multiplication using IFMA, see #816. Users of ecc/bls12-377/fr, ecc/bls12-381/fr, ecc/bls24-315/fr, ecc/bn254/fr, ecc/bn254/fp, ecc/grumpkin/fr, ecc/grumpkin/fp, ecc/stark-curve/fr and ecc/stark-curve/fp using v0.20.0 should upgrade to avoid incorrect computation results.

What's Changed

  • fix: correct IFMA vector mul carry propagation by @gbotrel in #816
  • deps(actions)(deps): bump actions/setup-go from 6.2.0 to 6.3.0 in the core-actions-minor-patch group by @dependabot[bot] in #814
  • release: v0.20.1 by @ivokub in #818

Full Changelog: v0.20.0...v0.20.1

v0.20.0

Choose a tag to compare

@ivokub ivokub released this 11 Mar 13:28
a66323f

What's Changed

New Contributors

Full Changelog: v0.19.2...v0.20.0

v0.19.2

Choose a tag to compare

@ivokub ivokub released this 28 Oct 11:57

Full Changelog: v0.19.1...v0.19.2

v0.19.1

Choose a tag to compare

@ivokub ivokub released this 28 Oct 11:57

Full Changelog: v0.19.0...v0.19.1

v0.18.2

Choose a tag to compare

@ivokub ivokub released this 28 Oct 11:55

Full Changelog: v0.18.1...v0.18.2

v0.18.1

Choose a tag to compare

@ivokub ivokub released this 28 Oct 11:26

Full Changelog: v0.18.0...v0.18.1

v0.19.0

Choose a tag to compare

@gbotrel gbotrel released this 22 Aug 18:29
0ba437a

What's Changed

New Contributors

Full Changelog: v0.18.0...v0.19.0

v0.18.0

Choose a tag to compare

@gbotrel gbotrel released this 12 Jun 17:33

What's Changed

New Contributors

Full Changelog: v0.17.0...v0.18.0