#polynomials #commitment

archived kzg

a simple implementation of the KZG polynomial commitment scheme

34 releases (6 breaking)

0.7.0 Nov 6, 2021
0.5.1 Nov 4, 2021

#32 in #polynomials

Download history 16/week @ 2023-10-23 65/week @ 2023-10-30 4/week @ 2023-11-06 40/week @ 2023-11-13 42/week @ 2023-11-20 113/week @ 2023-11-27 3/week @ 2023-12-04 4/week @ 2023-12-11 40/week @ 2023-12-18 75/week @ 2023-12-25 2/week @ 2024-01-01 5/week @ 2024-01-08 57/week @ 2024-01-15 15/week @ 2024-01-22 74/week @ 2024-01-29 4/week @ 2024-02-05

151 downloads per month

MIT license

72KB
2K SLoC

kzg

This code has not beed audited - use it at your own risk.

kzg is a simple implementation of the Kate-Zaverucha-Goldberg polynomial commitment scheme over the zkcrypto ecosystem's primitives, mainly their pairing abstraction.

kzg implements the "simple" variant described in the paper as "DL", including batched openings.

Author's Note

I wrote this mostly to learn and partly because the arkworks-polycommit is hard to use and only implements the pederson variant of KZG, which is unnecessary for many use cases, in particular vector commitment schemes that don't care about the unconditional hiding property the pederson variant of KZG provides like this.

Dependencies

~0.5–1.5MB
~31K SLoC