0

I would like to interface the Gnosis safe execTransaction method in my contract (which is written in Vyper).

From what I've understood the execTransaction takes the following arguments (based on a Tenderly trace I did):

([Receiver] 0xf756f1fa0f01d225b5f7ed513f30e7feb2a900eb => GnosisSafeL2)
.
execTransaction
(to = 0x2791bca1f2de4661ed88a30c99a7a9449aa84174, value = 0, data = 0x095ea7b3000000000000000000000000577d74e7047966b5dec6f7af709295f0a1d1aacc0000000000000000000000000000000000000000a18f07d736b90be550000000, operation = 0, safeTxGas = 0, baseGas = 0, gasPrice = 0, gasToken = 0x0000000000000000000000000000000000000000, refundReceiver = 0x0000000000000000000000000000000000000000, signatures = 0x0000000000000000000000006076047ae211c46a284c8b3042819ed06b3148a1000000000000000000000000000000000000000000000000000000000000000001)
=>
(true)

Where to is the contract being called and data is the calldata that will be passed through to the contract in the to field once the signature's check out. I understand this.

I have no problem generating the call data, however, the question becomes, how do I generate the signatures?

This particular safe has only 1 owner my wallet therefore, the question is, how do I generate the signatures for 1 owner using web3.py or 2 owners using web3.py and how do I successfully pass this to the execTransaction method.

Thank you

1 Answer 1

0

Hey if you want to generate the txn data easily in python refer to brownie-safe

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.