Skip to content

Conversation

@dawnseeker8
Copy link
Contributor

@dawnseeker8 dawnseeker8 commented Apr 9, 2024

Description

The connection via QR code on Hardware wallet is not proceeding past scanning the QR code. Functionality is working in the release version v11.13.1.

After debuggin the code and discover that the issue is caused by Keyring Controller upgraded to 13.0.0. and #addQRKeyring function have bug to pass a empty accounts array as parameters to keyring, cause the Keystone MetamaskKeyring default properties all are undefined during deserialise() process.

This fix patch the @metamask/keyring-controller to remove the empty array passed to KeyStone MetamaskKeyring so that all default properies in keyring will remain the same.

Open in GitHub Codespaces

Related issues

Fixes: #23804

Manual testing steps

  1. On your hardware wallet, fetch the QR code for MetaMask
  2. Proceed to add hardware wallet from the account drop-down selector
  3. Select QR-based and Continue
  4. Scan the QR code from the hardware wallet
  5. user should be able to select QR code account and imported

Screenshots/Recordings

Before

Screen.Recording.2024-03-26.at.21.01.01.mov

After

Screen.Recording.2024-04-09.at.09.15.28.mov

Pre-merge author checklist

  • I’ve followed MetaMask Coding Standards.
  • I've completed the PR template to the best of my ability
  • I’ve included tests if applicable
  • I’ve documented my code using JSDoc format if applicable
  • I’ve applied the right labels on the PR (see labeling guidelines). Not required for external contributors.

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

@dawnseeker8 dawnseeker8 added the team-hardware-wallets-deprecated DEPRECATED: please use "team-accounts-framework" instead label Apr 9, 2024
@dawnseeker8 dawnseeker8 requested a review from a team as a code owner April 9, 2024 08:17
@github-actions
Copy link
Contributor

github-actions bot commented Apr 9, 2024

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@dawnseeker8 dawnseeker8 added Sev1-high High severity; partial loss of service with severe impact upon users, with no workaround. release-blocker This bug is blocking the next release labels Apr 9, 2024
@socket-security
Copy link

socket-security bot commented Apr 9, 2024

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/@npmcli/fs@2.1.2 filesystem +1 43.1 kB gar
npm/aproba@2.0.0 None 0 8.05 kB iarna
npm/cacache@16.1.3 filesystem +7 142 kB lukekarrys
npm/make-fetch-happen@10.2.1 environment, network +8 298 kB gar
npm/minipass-fetch@2.1.2 environment, network +3 526 kB gar
npm/nopt@6.0.0 environment +1 28.7 kB gar
npm/npmlog@6.0.2 None 0 17.1 kB lukekarrys
npm/socks@2.8.1 network +3 518 kB joshglazebrook
npm/ssri@9.0.1 None 0 37.5 kB nlf
npm/unique-filename@2.0.1 None +2 18 kB lukekarrys

🚮 Removed packages: npm/socks@2.8.3

View full report↗︎

@socket-security
Copy link

socket-security bot commented Apr 9, 2024

👍 Dependency issues cleared. Learn more about Socket for GitHub ↗︎

This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored.

Ignoring: npm/@npmcli/fs@2.1.2, npm/@types/pbkdf2@3.1.0, npm/@types/secp256k1@4.0.3, npm/aproba@2.0.0, npm/cacache@16.1.3, npm/make-fetch-happen@10.2.1, npm/minipass-collect@1.0.2, npm/minipass-fetch@2.1.2, npm/minipass@3.3.5, npm/node-gyp@9.3.0, npm/nopt@6.0.0, npm/npmlog@6.0.2, npm/socks@2.8.1, npm/ssri@9.0.1, npm/unique-filename@2.0.1, npm/unique-slug@3.0.0

View full report↗︎

Next steps

Take a deeper look at the dependency

Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support [AT] socket [DOT] dev.

Remove the package

If you happen to install a dependency that Socket reports as Known Malware you should immediately remove it and select a different dependency. For other alert types, you may may wish to investigate alternative packages or consider if there are other ways to mitigate the specific risk posed by the dependency.

Mark a package as acceptable risk

To ignore an alert, reply with a comment starting with @SocketSecurity ignore followed by a space separated list of ecosystem/package-name@version specifiers. e.g. @SocketSecurity ignore npm/foo@1.0.0 or ignore all packages with @SocketSecurity ignore-all

@dawnseeker8 dawnseeker8 added the e2e-test End to end test for the MetaMask extension label Apr 9, 2024
@dawnseeker8 dawnseeker8 added the needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) label Apr 9, 2024
@gantunesr gantunesr self-requested a review April 9, 2024 12:33
Copy link
Member

@gantunesr gantunesr left a comment

Choose a reason for hiding this comment

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

Dimiss approval

@codecov
Copy link

codecov bot commented Apr 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 67.46%. Comparing base (255a961) to head (bffd110).
Report is 3 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop   #23903   +/-   ##
========================================
  Coverage    67.46%   67.46%           
========================================
  Files         1244     1244           
  Lines        48777    48777           
  Branches     12724    12724           
========================================
  Hits         32907    32907           
  Misses       15870    15870           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@metamaskbot
Copy link
Collaborator

Builds ready [6d909ed]
Page Load Metrics (469 ± 360 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint741581082311
domContentLoaded116733157
load622190469750360
domInteractive116733157
Bundle size diffs [🚀 Bundle size reduced!]
  • background: -14 Bytes (-0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

@dawnseeker8 dawnseeker8 requested review from danjm and gantunesr April 9, 2024 15:19
@dawnseeker8 dawnseeker8 requested review from a team as code owners April 10, 2024 01:06
@gantunesr
Copy link
Member

@metamaskbot update-policies

@gantunesr gantunesr changed the title fix: 23804 unable to add QR code account in metamask extension fix(23804): unable to add QR code account Apr 10, 2024
@metamaskbot
Copy link
Collaborator

Policies updated

@metamaskbot
Copy link
Collaborator

Builds ready [eab6341]
Page Load Metrics (581 ± 414 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint692181063115
domContentLoaded124826105
load562245581861414
domInteractive124826105
Bundle size diffs [🚀 Bundle size reduced!]
  • background: -14 Bytes (-0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

benjisclowder
benjisclowder previously approved these changes Apr 10, 2024
Copy link
Contributor

@benjisclowder benjisclowder left a comment

Choose a reason for hiding this comment

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

QA passed.

benjisclowder
benjisclowder previously approved these changes Apr 10, 2024
Copy link
Contributor

@benjisclowder benjisclowder left a comment

Choose a reason for hiding this comment

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

QA passed

@Gudahtt
Copy link
Member

Gudahtt commented Apr 10, 2024

@metamaskbot update-policies

@metamaskbot
Copy link
Collaborator

Policies updated

@metamaskbot
Copy link
Collaborator

Builds ready [7f90d82]
Page Load Metrics (664 ± 492 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint592071003718
domContentLoaded9442094
load4727356641025492
domInteractive9442094
Bundle size diffs [🚀 Bundle size reduced!]
  • background: -14 Bytes (-0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

Copy link
Contributor

@benjisclowder benjisclowder left a comment

Choose a reason for hiding this comment

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

QA passed.

@metamaskbot
Copy link
Collaborator

Builds ready [bffd110]
Page Load Metrics (794 ± 513 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint713501347134
domContentLoaded107430178
load5725847941069513
domInteractive107330178
Bundle size diffs [🚀 Bundle size reduced!]
  • background: -14 Bytes (-0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

@danjm
Copy link
Contributor

danjm commented Apr 11, 2024

@SocketSecurity ignore-all

The new author warnings are safe. We have approved those authors in the past, and ther are github employees and/or long time contributors to the npm ecosystem.

The network access is necessary for make-fetch-happen to work, and that has been part of our dependency tree for a long time.

@dawnseeker8 dawnseeker8 merged commit b8159d4 into develop Apr 11, 2024
@dawnseeker8 dawnseeker8 deleted the fix/23804-add-qr-connection-issue branch April 11, 2024 16:23
@github-actions github-actions bot removed the needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) label Apr 11, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Apr 11, 2024
@metamaskbot metamaskbot added the release-11.15.0 Issue or pull request that will be included in release 11.15.0 label Apr 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

e2e-test End to end test for the MetaMask extension QA Passed release-11.15.0 Issue or pull request that will be included in release 11.15.0 release-blocker This bug is blocking the next release Sev1-high High severity; partial loss of service with severe impact upon users, with no workaround. team-hardware-wallets-deprecated DEPRECATED: please use "team-accounts-framework" instead

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

[Bug]: Hardware wallet QR connection unsuccessful

7 participants