frame icon indicating copy to clipboard operation
frame copied to clipboard

Support eth_signTransaction

Open schmidsi opened this issue 6 years ago • 7 comments

When I try to sign a transaction, I get the following error:

Error: Returned error: Method eth_signTransaction not supported.

I assume that this error comes from ganache: The eth_signTransaction method gets forwarded to the underlying node because it is not marked as protectedMethods.

We use this kind of special setup where we separated the signTransaction from the actual send transaction to have more control over the different configurations (especially our in-memory signing).

schmidsi avatar Feb 11 '19 20:02 schmidsi

For reference https://github.com/melonproject/protocol/blob/32659aa8e32f4c202d75b2255916ad9b70e35737/src/utils/solidity/transactionFactory.ts#L307

schmidsi avatar Feb 11 '19 20:02 schmidsi

Seems like MetaMask does not support this either: https://github.com/MetaMask/metamask-extension/issues/2506

And it is not part of this reference: https://github.com/ethereum/wiki/wiki/JSON-RPC#json-rpc-api-reference

schmidsi avatar Feb 12 '19 08:02 schmidsi

Howdy! Thanks for all your wonderful and stylish work on Frame! :cowboy_hat_face:

We use this kind of special setup where we separated the signTransaction from the actual send transaction to have more control over the different configurations (especially our in-memory signing).

This issue is also effecting me for the same reason.

While there are lots of similarities, there are some important differences between Frame and MetaMask - most notably frame perform the duty of account management, signing transactions, and runs as a stand-alone OS-level application. :+1:

While I do benefit from the convenience of frame also broadcasting my transaction to infura or another web3 endpoint - The main functionality I need from a standalone signer is transaction signing.

~~Under the hood Frame is a Clef-based signer~~ -- I''d like to ~~be able to take advantage of those aspects of the architecture and~~ have the basic functionality of signing transactions without broadcasting them. I think this can be achieved by exposing ~~clef's account_signTransaction~~ an internal transaction signing endpoint, but I'm interested in what others think.

KPrasch avatar Sep 12 '20 17:09 KPrasch

Hey @KPrasch, thanks for the feedback! We can look into this again. Frame is not Clef based and follows a different flow but we could still support this method and add UX to make it clear that it's not the standard transaction signing flow.

floating avatar Sep 13 '20 20:09 floating

@floating - Thanks for looking into it!

My mistake about being a clef signer - I believe they have you listed on their Github Readme as an implementation (perhaps outdated): https://github.com/ethereum/go-ethereum/tree/master/cmd/clef#ui-implementations

KPrasch avatar Sep 13 '20 21:09 KPrasch

Is "web3.eth.signTransaction" useless ?

CucurbitBaby avatar Jan 16 '22 18:01 CucurbitBaby

"web3.eth.accounts.signTransaction" is ok! oh shit

CucurbitBaby avatar Jan 16 '22 18:01 CucurbitBaby