protolambda / go-kzg

FFT, data-recovery and KZG commitments, a.k.a. Kate commitments, in Go - *super experimental*
MIT License
90 stars 26 forks source link

Improve bound on chunklen check #20

Closed benjaminion closed 3 years ago

benjaminion commented 3 years ago

The improved bound ensures that the following does not set k to zero, which results in Bad Things:

    n := n2 / 2
    k := n / chunkLen

Thanks to @Nashatyrev for the downstream fix in c-kzg.