Skip to content
This repository has been archived by the owner on Sep 6, 2023. It is now read-only.

fix add more to avoid wallet impersonation #229

Merged
merged 3 commits into from
Apr 17, 2023
Merged

Conversation

chendatony31
Copy link
Contributor

Description

add more wallet flags to avoid wallet impersonation.

Additional Information

Your ENS/address:

@changeset-bot
Copy link

changeset-bot bot commented Apr 13, 2023

🦋 Changeset detected

Latest commit: 88cb471

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@wagmi/connectors Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Comment on lines 56 to 62
if (ethereum.isCoinbaseWallet) return
if (ethereum.isBitKeep) return
if (ethereum.isMathWallet) return
if (ethereum.isOkxWallet || ethereum.isOKExWallet) return
if (ethereum.isOneInchIOSWallet || ethereum.isOneInchAndroidWallet) return
if (ethereum.isOpera) return
if (ethereum.isRabby) return
if (ethereum.isRainbow) return
if (ethereum.isTally) return
if (ethereum.isTrust || ethereum.isTrustWallet) return
if (ethereum.isZerion) return
Copy link
Member

Choose a reason for hiding this comment

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

The intention of this check is to not be exhaustive and only to filter out options that try to appear as MetaMask. Just checking that all these injected providers meet that criteria?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've rechecked these providers and made some changes.

@jxom jxom merged commit c25ac82 into wevm:main Apr 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants