Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: expose safe tx eip712 structured data #120

Merged
merged 2 commits into from
Nov 4, 2021

Conversation

banteg
Copy link
Contributor

@banteg banteg commented Nov 3, 2021

Expose the EIP712 structured data of a SafeTx as safe_tx_data (extracted from safe_tx_hash).

This structure could be useful elsewhere, ranging from third-party signing to verification purposes.

My use case is passing it to Frame for signing.

Copy link
Member

@Uxio0 Uxio0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good PR! I'm also thinking on migrating to the newer library eip712_structs that I'm using for the Gnosis Protocol: https://github.com/gnosis/gnosis-py/blob/master/gnosis/protocol/order.py

gnosis/safe/safe_tx.py Outdated Show resolved Hide resolved
banteg added a commit to banteg/brownie-safe that referenced this pull request Nov 3, 2021
@banteg
Copy link
Contributor Author

banteg commented Nov 4, 2021

There is also a good library called eip712, but I found a name clash bug in it when trying to implement the struct used here.

@Uxio0 Uxio0 merged commit cd5764e into safe-global:master Nov 4, 2021
@banteg banteg deleted the feat/structured-data branch November 4, 2021 14:29
banteg added a commit to banteg/brownie-safe that referenced this pull request Nov 10, 2021
* feat: backport gnosis-py safe_tx_data

safe-global/safe-eth-py#120

* feat: sign with frame

* fix: no eip-155 support in ledger signatures

* docs: add singing and useful links sections

* chore: bump version and requirements

* chore: bump gnosis-py min required version

* refactor: remove backported eip712 code as

* feat: submit signature

* feat: reconstruct safe tx from api

* fix: confirmations

* feat: retrieve pending txs from tx service

* docs: update signing docs

* feat: add tx execution

* docs: update detailed example
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants