ECDSA:使用 remix ide 提供的签名时出现无效签名长度错误
我正在 remix ide 中签署消息,并尝试验证签名和数据,因为
bytes32 hashInput=keccak256(bytes(temp));
bytes memory signature=bytes("0x975ff3abe5c7df0e95ab76f308f5b73ca0b803f1c7d74d44098bc75c6efd845c7908ff2b2e4b1a9bee653237475e59d17c13634042e4759154e70618850aa89e1c");
emit test(signature);
bytes32 h=ECDSA.toEthSignedMessageHash(hashInput);
address _signer=ECDSA.recover(h,signature);
函数参数中的温度如下,这是我之前签署的消息。现在签名长度错误困扰着我。我正在使用 openzepplien 的 ECDSA
i am signing messsage in remix ide, and am trying to verify the signature and data as below
bytes32 hashInput=keccak256(bytes(temp));
bytes memory signature=bytes("0x975ff3abe5c7df0e95ab76f308f5b73ca0b803f1c7d74d44098bc75c6efd845c7908ff2b2e4b1a9bee653237475e59d17c13634042e4759154e70618850aa89e1c");
emit test(signature);
bytes32 h=ECDSA.toEthSignedMessageHash(hashInput);
address _signer=ECDSA.recover(h,signature);
temp is coming in arguments of function, this is message that I signed earlier. now the signature length error is troubling me. i am using ecdsa from openzepplien
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论