-
-
Notifications
You must be signed in to change notification settings - Fork 54
Conversation
Note: https://consensys.slack.com/archives/G1L7H42BT/p1621894614057900 is relevant for how to test this. |
I've tested this using my Trezor device using the test dapp and all of my testing of signing worked as they should. When you get back, let's briefly sync on this and choose the best path forward. Awesome work! |
Retested this PR with current
Restested this PR with current
I should also say that I restored a Ledger mneumonic on this Trezor, though I don't know that that matters. |
42dff70
to
5c690ec
Compare
test/test-eth-trezor-keyring.js
Outdated
.stub(newFakeTx, 'getSenderAddress') | ||
.callsFake(() => fakeAccounts[0]); | ||
sinon.stub(newFakeTx, 'verifySignature').callsFake(() => true); | ||
// sinon.stub(newFakeTx, 'from').get(() => fakeAccounts[0]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to remove this (?)
5c690ec
to
e134430
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works on both POC branch and develop. Nice!
Creating an unfrozen transaction (added in MetaMask#88) seems to be a change that was only required in eth-ledger-keyring, not in Trezor, and is fixed by @ethereumjs/tx: v3.1.4 anyway. I've removed this part, since it was causing issues with EIP-1559 transactions, and does not seem necessary for non-EIP-1559 transactions either.
Creating an unfrozen transaction (added in MetaMask#88) seems to be a change that was only required in eth-ledger-keyring, not in Trezor, and is fixed by @ethereumjs/tx: v3.1.4 anyway. I've removed this part, since it was causing issues with EIP-1559 transactions, and does not seem necessary for non-EIP-1559 transactions either.
Creating an unfrozen transaction (added in MetaMask#88) seems to be a change that was only required in eth-ledger-keyring, not in Trezor, and is fixed by @ethereumjs/tx: v3.1.4 anyway. I've removed this part, since it was causing issues with EIP-1559 transactions, and does not seem necessary for non-EIP-1559 transactions either.
Creating an unfrozen transaction (added in #88) seems to be a change that was only required in eth-ledger-keyring, not in Trezor, and is fixed by @ethereumjs/tx: v3.1.4 anyway. I've removed this part, since it was causing issues with EIP-1559 transactions, and does not seem necessary for non-EIP-1559 transactions either.
* Upgrade trezor-connect to 8.2.1 This adds support for EIP-1559 for the Trezor T, once we get all this library to work with it as well. We use version "8.2.1-extended" exactly, as we need non-browser support for local tests. * Update @ethereumjs/common to 2.4.0 for 1559 tests * Upgrade @ethereumjs/tx dependency to ^3.2.1 Although 3.3.0 is out, I've selected ^3.2.1 just to match the current version of MetaMask's package.json file. Version 3.2.0 adds support for EIP-1559 transactions. * Test EIP-1559 transaction support Test case copied over from MetaMask/eth-ledger-bridge-keyring#99 * Set ESLint ecmaVersion to 2018 This adds support for object-rest-spread (e.g. {...x, ...y}), without using the babel parser, which we use in tests. This is different from what the Metamask extension has, which is 2017, but they're using the babel parser. * Add EIP-1559 transaction support Creating an unfrozen transaction (added in #88) seems to be a change that was only required in eth-ledger-keyring, not in Trezor, and is fixed by @ethereumjs/tx: v3.1.4 anyway. I've removed this part, since it was causing issues with EIP-1559 transactions, and does not seem necessary for non-EIP-1559 transactions either. * Document EIP1559 support for Model T on README.md * Add method to expose trezor model * Lint fix * Update index.js Co-authored-by: Alois Klink <alois.klink@gmail.com> * Use event listener instead of getFeatures call to set model * Lint fix * Revert getEIP1559Support to getModel * Move event listener first and trigger event via init * Lint fix * Remove error handle in getModel method Co-authored-by: Alois Klink <alois.klink@gmail.com> Co-authored-by: David Walsh <davidwalsh83@gmail.com>
Adds support for new versions of ethereumjs/tx to the trezor implementation.