verify_eth_signature
but returns a Result
instead of panicking.
Also verifies that r
and s
components of the signature are in the range [1, N)
,
where N is the size of the curve.
Signature
Arguments
msg_hash
- The 32-byte hash of the message that was signedsignature
- The Ethereum signature containingr
,s
components andy_parity
eth_address
- The expected Ethereum address of the signer
Returns
ReturnsOk(())
if the signature is valid, or Err(felt252)
containing an error message if
invalid.