Correct type info for verify_kzg_proof_multi_impl

This commit is contained in:
Dankrad Feist 2024-01-11 20:57:16 +00:00
parent fddbd6b76c
commit b55ab46909
No known key found for this signature in database
GPG Key ID: 6815E6A20BEBBABA
1 changed files with 5 additions and 2 deletions

View File

@ -305,12 +305,15 @@ def compute_kzg_proof_multi_impl(
```python ```python
def verify_kzg_proof_multi_impl(commitment: KZGCommitment, def verify_kzg_proof_multi_impl(commitment: KZGCommitment,
zs: BLSFieldElement, zs: Sequence[BLSFieldElement],
ys: BLSFieldElement, ys: Sequence[BLSFieldElement],
proof: KZGProof) -> bool: proof: KZGProof) -> bool:
""" """
Helper function that verifies a KZG multiproof Helper function that verifies a KZG multiproof
""" """
assert len(zs) == len(ys)
zero_poly = g2_lincomb(KZG_SETUP_G2_MONOMIAL[:len(zs) + 1], vanishing_polynomialcoeff(zs)) zero_poly = g2_lincomb(KZG_SETUP_G2_MONOMIAL[:len(zs) + 1], vanishing_polynomialcoeff(zs))
interpolated_poly = g1_lincomb(KZG_SETUP_G1_MONOMIAL[:len(zs)], interpolate_polynomialcoeff(zs, ys)) interpolated_poly = g1_lincomb(KZG_SETUP_G1_MONOMIAL[:len(zs)], interpolate_polynomialcoeff(zs, ys))