Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save dominiek/44830cf4bdc5c40088acd1bd3f8def2c to your computer and use it in GitHub Desktop.
Save dominiek/44830cf4bdc5c40088acd1bd3f8def2c to your computer and use it in GitHub Desktop.
ethereum_smart_contract_ecrecover_evm_asm.sol
bool ret;
address addr;
assembly {
let size := mload(0x40)
mstore(size, msgHash)
mstore(add(size, 32), v)
mstore(add(size, 64), r)
mstore(add(size, 96), s)
ret := call(3000, 1, 0, size, 128, size, 32)
addr := mload(size)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment