-
Notifications
You must be signed in to change notification settings - Fork 917
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
EIP4844 precompile: Be strict when parsing field elements from network (
#3138) * EIP4844: bytes_to_bls_field() must not accept values >= BLS_MODULUS bytes_to_bls_field() will be used in the precompile and hence it should error out when provided with malicious inputs. * EIP4844: Add hash_to_bls_field() for use in compute_challenges() The previous commit made bytes_to_bls_field() be strict about its inputs. However in compute_challenges() we are dealing with Fiat-Shamir and hash outputs that could be innocuously higher than the modulus. For this reason we add the hash_to_bls_field() helper for use in compute_challenges(). * EIP4844: Further use of bytes_to_bls_field() // Fix executable spec Co-authored-by: Hsiao-Wei Wang <hsiaowei.eth@gmail.com>
- Loading branch information
Showing
1 changed file
with
24 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters