You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Messages should be able to be signed when requested by a site. It should be done in a standardized way that Ethereum does, in that it is prefixed with a know prefix, hashed and then signed by the user. This signed data is also crafted in such a way as to never allow it to be a valid signed transaction.
It will allow smart contracts to use ecrcover to verify the signature, and to recover the signers address as well.
It would also allow MetriMask to be used as a method of web authentication.
Probably useful for all sorts of cross-chain shenanigans.
an example of how a solidity function might look
function recoverSigner(bytes memory message, bytes memory signature) internal pure returns (address)
{
require(signature.length == 65, "VendorRegistry: Action failed, invalid signature.");
uint8 v;
bytes32 r;
bytes32 s;
assembly
{
r := mload(add(signature, 32))
s := mload(add(signature, 64))
v := byte(0, mload(add(signature, 96)))
}
return ecrecover(keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", keccak256(message))), v, r, s);
}
The text was updated successfully, but these errors were encountered:
So I've merged in bitcoin message signing to Metrimask #23
However this doesnt specifically address the functionality you are looking for. However Qtum have implemented QIP-6 (https://blog.qtum.org/qip-6-87e7a9743e14) which allows the use of btc_ecrecover within a pre-compiled contract. I believe this should allow the functionality you are looking for.
Messages should be able to be signed when requested by a site. It should be done in a standardized way that Ethereum does, in that it is prefixed with a know prefix, hashed and then signed by the user. This signed data is also crafted in such a way as to never allow it to be a valid signed transaction.
an example of how a solidity function might look
The text was updated successfully, but these errors were encountered: