ethereumjs / kzg-wasm

11 stars 1 forks source link

Update inputs to accept hex strings #16

Closed acolytec3 closed 1 month ago

acolytec3 commented 1 month ago

micro-eth-signer recently added kzg support so there is now a native JS implementation of KZG cryptography. Since it accepts hex strings as its inputs for blobs/commitments/proofs and outputs the same, we should update kzg-wasm to use hex strings as well in its outer API since we're already receiving strings back from WASM anyway.

The only reason we use bytes in the outer API is because ethereumjs-monorepo code primarily was using bytes but there's no compelling reason to do so since we don't do anything else with the various elements other than translate them from hex strings when received over the network (or RPC) and then pass them into kzg black boxes to verify proofs and then put them back into hex strings before passing on to the CL layer.

gabrocheleau commented 1 month ago

resolved by #17