safe-react
safe-react copied to clipboard
Support EIP712 signature method from Safe Apps
Would it be possible to update the safe-core-sdk
to the latest version which supports EIP712?
Although this would be very nice indeed, it's not on our radar atm. We'll happily review and merge your pull request though. Keep in mind the calls will need to be updated to the new method. I think it currently affects Owner and Module management, possibly some other types of transactions.
Thanks for your quick response. We are thinking about starting a bounty on Gitcoin for this, would you be interested in funding this bounty with us?
No, we're not interested at this time. We're currently working on the next version of the app, where Safe Core SDK is already the latest version. It's only a matter of time (a few weeks?) until this reaches production. If you require this sooner, feel free to contribute.
For reference, this call:
sdk.signTransaction(safeTx, 'eth_sign')
will have to be changed to
sdk.signTransaction(safeTx, 'eth_signTypedData')
and that's pretty much it. 🤓
Hey @katspaugh I tried to find the function call in the safe-react codebase. Can you tell me which repository are you referring to?
I will create a PR so that we can get this out sooner.
Hi @midgerate! Sorry, I gave you misleading information.
This repository, although it uses the Safe Core SDK for transaction creation (in Module and Owner management), doesn't use it for signing transactions.
For signing, there's custom code which already supports EIP712.
In the new version of the app (which is not a public repo yet, but soon will be), we're using Safe Core SDK exclusively, and we use the new method there.
@katspaugh that means, technically gnosis ui already supports EIP712. On snapshot we use safe-apps-sdk and safe-apps-sdk-provider
It always calls signTransaction instead of signTypedData as implemented in safe-core-sdk.
Do you know already what changes we need to do to safe-apps-sdk so that it calls the correct method?
I've double-checked, and from what I see in the code, all transaction signing in safe-react goes through the same function I linked above.
Except for signing with hardware wallets, in which case it does eth_sign
(so does the Safe Core SDK).
@dasanra @mikhailxyz any idea?
@midgerate safe-apps-sdk only supports eth_sign
for now. You can follow this issue https://github.com/safe-global/safe-react-apps/issues/255
As per @mikhailxyz's message, this will need to be added in the Apps SDK, and safe-react also will need to be updated accordingly. Namely this modal.
@mikhailxyz do we have a timeline for the Apps SDK implementation?
@mikhailxyz do we have a timeline for the Apps SDK implementation?
not really, because of the upcoming new app
Now that we clarified what needs to be done exactly, I’ll forward the funding proposal to the team. 👍
Hey @katspaugh, is there any update on this? If there is anything we can help with please let us know!
Summoning @ennisjo. :) Any update on this?
hey @samuveth - would you be willing to co-fund this bounty with us with a 50/50 split?
We estimate that this would take a developer 5 days to complete this task.
Hey @ennisjo, yes we would love to contribute 50% to this bounty!
You can contact us for the billing at [email protected]
or fabien#4765
on Discord
@ennisjo Feel free to reach out on Discord and let us know if we can help on the next steps, we can provide some test app link to trigger a Safe to sign an EIP712 message
@bonustrack - dm'd you on discord. Will proceed from there and look to get this bounty public.
I think we can close this ticket. Thank you all for the awesome job! ;)