Skip to content

Instantly share code, notes, and snippets.

View nullity00's full-sized avatar
🌪️
Bla bla bla

nullity nullity00

🌪️
Bla bla bla
View GitHub Profile
@nullity00
nullity00 / mst.toml
Last active May 25, 2024 12:43
Output of polyexen & halo2-analyzer
[info]
num_rows = 4096
p = 21888242871839275222246405745257275088548364400416034343698204186575808495617
[info.challenges]
[columns.public]
i00 = { aliases = [] }
[columns.fixed]
@nullity00
nullity00 / circom.md
Created November 23, 2023 12:46
Change Circom's prime Field

Change circom's prime Field

Circom operates over the prime field of p = 21888242871839275222246405745257275088548364400416034343698204186575808495617 which is the Field Modulus of BN254 curve. This might be because of the existing support for BN254 curves in the Ethereum ecosystem like precompiles (add, mul, pairing), powers of tau parameters & so on.

Circom supports these curves as of now : bn128, bls12381, goldilocks, grumpkin, pallas, vesta . Refer here

Steps to change the prime field

To add your choice of curve & tweak the prime field of circom, follow the given steps :

@nullity00
nullity00 / sha256.md
Last active November 23, 2023 11:34
Solution to variable length SHA

Variable length SHA256 Hash

ZKRepl Link
Non-linear constraints: 190215

Overview

  1. Input bits to be hased are suffixed by a 512 bit (for even multiples of 256 bit input) or 256 bit (for odd multiples of 256 bit input) padding. Suffix array is computed using the length input signal.
@nullity00
nullity00 / paris-2023.md
Last active August 25, 2023 23:31
Eth CC Side Events

Disclaimer

This compilation is not responsible for any sudden hair-pulling, head-scratching, or mind-explosions that may occur during the viewing of these videos.

You accept full responsibility for any unintentional knowledge overload or the sudden desire to prove everything to everyone (even if they didn't ask for it).