CRYPTO NEWS

Signature Verification Errors in solidity-coverage

I am currently creating a test for signatures, and it runs fine with truffle, but with solidity-coverage I get the following error…

ECDSA: invalid signature 'v' value 

I checked the ethereum-js version and found that v7.1.0 is used by Ganache in truffle and v2.13.1 is used by solidity-coverage. However, ganache 7.0 does not work in solidity-coverage. Thank you in advance.

https://github.com/sc-forks/solidity-coverage/issues/694 https://github.com/trufflesuite/ganache/issues/972

Code: Solidity

contract Member {   using ECDSAUpgradeable for bytes32;  ...    function join(     bytes memory signature,   ) public returns (uint256) {     bytes32 _hash = _getHash(msg.sender);     address inviter = ECDSAUpgradeable.recover(_hash, signature);     require(msg.sender != inviter, "Cannot invite yourself");    function _getHash(address invited) private view returns (bytes32) {     uint256 _timeStamp = _getTimeStamp();     return toEthSignedMessageHash(       abi.encodePacked(         StringsUpgradeable.toString(_timeStamp),         ",",         StringsUpgradeable.toHexString(uint160(invited), 20)       )     );   } ... 

Code: test(js)

it("join OK", async() => {         const str = `${timestamp},${accounts[1].toLowerCase()}`;         const sign = await web3.eth.sign(str, accounts[0]);         const data = await memberInstance.join.call(             sign, {from: accounts[1]}         ); // get error ...  

ZAHI

#ZAHI #TheSupremeTeam Artist Name: ZAHI Who are you? I am a Phonk producer from The Netherlands. I work hard on my tracks and would love to people's feedback on my music. I try my best to make my tracks sound as original as i can. Sometimes i make more Chill / Vibe music and sometimes::Listen

#ZAHI #TheSupremeTeam
Artist Name: ZAHI

Who are you?

I am a Phonk producer from The Netherlands. I work hard on my tracks and would love to people's feedback on my music.

I try my best to make my tracks sound as original as i can. Sometimes i make more Chill / Vibe music and sometimes i make Aggressive / Hard music, I enjoy experimenting with my sound and always want keep variation within my music.

Where are you from?

I am from The Netherlands, people here usually listen to afro trap or NL/UK drill.

How can we follow you?

Instagram: https://instagram.com/gcsybvtch

Soundcloud: https://soundcloud.com/66zahi

Song Title: PHONK HOUSE

Listen to ZAHI:

https://soundcloud.com/66zahi/phonk/house

Source: https://supremepr.us/

Signature Verification Errors in solidity-coverage

Shopping cart
There are no products in the cart!
Continue shopping
0