Closed karalabe closed 2 months ago
For KZG implementations, there are two options for Go clients:
Right now, our recommendation is for Go clients to use Go-KZG-4844. While C-KZG-4844 is expected to be slightly faster when run on single-threaded systems, Go-KZG-4844 also provides parallelized functions that can be faster (though less efficient) on systems with multiple threads. Most clients will use C-KZG-4844 bindings, but that's because there isn't a great alternative for them (right now). From a diversity perspective, using a different implementation would be beneficial. Both implementations will be audited and have been differentially fuzzed against each other.
Also, some information about the audit. There will be a one month audit (starting on April 17th 2023) for both of these implementations (and their bindings) by a reputable security firm. For Go-KZG-4844, code from gnark-crypto that it needs but was not audited has been copied into its project so it gets audited.
@jtraglia The trusted setup file seems to be slightly different for the two libs: The Go version requires some Lagrange form of G1 points whereas the C does not. Any particular reason for that / not being able to calculate it internally?
Conversion is expensive. But I'm in favor that all the libs should use exactly the same trusted setup file.
The trusted setup file in the Go lib has 4096 G2 points but the C lib rejects that because it wants 65 G2 points. Which is correct?
65 G2 points is more than enough.
Hey @karalabe, good question. For both presets, there should only be 65 G2 points. I suspect Go-KZG-4844 has 4096 because that's how the trusted setup was defined initially; about 4 months ago, this PR changed the count from 4096 to 65. Also, you should use the trusted setups (mainnet and minimal) from the consensus-specs.
4844 shipped in March :confetti_ball: https://ethereum.org/en/roadmap/dencun/
This is a tracking issue for EIP-4844. Some of the issues might get broken down into very low level piecemeal ones that might help review and/or work on a different larger ones. Ideally we'll end up with a batch of PRs people can take a look at to wrap their head around 4844 and it's progress / coding history.
Integrate an SSZ library / generator for the blob transactionsConvert the blob transaction encodings from RLP to SSZexcessDataGas
field to header, disable before Cancun https://github.com/ethereum/go-ethereum/pull/27046excessDataGas
to blob fee conversions https://github.com/ethereum/go-ethereum/pull/27041excessDataGas
validations and calculations across blockshttps://github.com/ethereum/go-ethereum/pull/27340https://github.com/ethereum/go-ethereum/pull/27382eth
protocol to support announce-only for blob txs https://github.com/ethereum/go-ethereum/pull/25980Note, an initial proof of concept was prepared by Coinbase and Optimism at https://github.com/ethereum/go-ethereum/pull/26283.