MetaMask / MetaMask/metamask-extension
Presence of Metamask alone helps fingerprinting
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 13.2k
- Forks
- 5.6k
- Avg merge
- 2d 5h
- Merged PRs (30d)
- 451
Description
Describe the bug
With #4703, Metamask does not expose your Ethereum addresses until manually activated, making it less easy for websites to uniquely identifying a user across the Web.
However, the sole presence of the Metamask extension can be used for fingerprinting. When Metamask is installed, every website has access to window.web3. That is another identifying factor that can be used by websites to fingerprint users. As long as Metamask is used by a small(er) subset of users, in fact, it is a powerful factor that can be used to create individual fingerprints (together with many other factors).
A (simple?) solution to this is to disable Metamask in every website by default. Users will need to click on the extension to activate it for a website, and then the page is reloaded and window.web3 is injected. Metamask can remember websites on which it should be enabled.
To Reproduce (REQUIRED)
- In a website, check for the presence of
window.web3 - Use the result of that (true/false) as part of the factors used to create individual fingerprints
Expected behavior
Metamask should not inject window.web3 in all websites by default.
Browser details (please complete the following information):
- OS: All operating systems (but currently on macOS)
- Hardware Wallet: none
- Browser: Firefox 79 (but should apply to every browser)
- MetaMask Version: 8.0.8
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing where the extension injects window.web3 into websites and how site activation is currently handled. Define the activation and remembered-site behavior described in the issue, then verify that inactive sites no longer receive window.web3 while activated sites still do.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- security
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100