web3swift icon indicating copy to clipboard operation
web3swift copied to clipboard

Can signtypeddata be supported? Can eip712 support JSON

Open xhzth70911 opened this issue 3 years ago • 0 comments

Is there anything like web3 I haven't found a similar function of signtypeddata in. JS. Can eip712 signatures be like web3 It can be realized by passing a JSON in web3signer.js. Thank you, web3signer Signeip712 is the adopted signtypeddata_ V1 or signtypeddata_ V3 or signtypeddata_ V4 mode

let jsonString = """ { "types": { "EIP712Domain": [ {"name": "name", "type": "string"}, {"name": "version", "type": "string"}, {"name": "chainId", "type": "uint256"}, {"name": "verifyingContract", "type": "address"} ], "Person": [ {"name": "name", "type": "string"}, {"name": "wallet", "type": "bytes32"}, {"name": "age", "type": "int256"}, {"name": "paid", "type": "bool"} ] }, "primaryType": "Person", "domain": { "name": "Person", "version": "1", "chainId": 1, "verifyingContract": "0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC" }, "message": { "name": "alice", "wallet": "0xbBbBBBBbbBBBbbbBbbBbbbbBBbBbbbbBbBbbBBbB", "age": 40, "paid": true } } """

xhzth70911 avatar Jul 13 '22 09:07 xhzth70911